Closed Bug 1420553 Opened 2 years ago Closed 2 years ago

Rendering glitches when ClearType is disabled while running Firefox

Categories

(Core :: Graphics: Text, defect, P3)

x86_64
Windows 10
defect

Tracking

()

RESOLVED DUPLICATE of bug 1435472

People

(Reporter: ignusws, Unassigned)

References

Details

(Keywords: regression, Whiteboard: [gfx-noted])

Attachments

(3 files)

Attached image Rendering glitch
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:59.0) Gecko/20100101 Firefox/59.0
Build ID: 20171124220317

Steps to reproduce:

1. Disable ClearType in windows settings
2. Enable Session Restore in firefox settings
3. Open https://en.wikipedia.org/wiki/List_of_most_popular_websites and some other pages
4. Restart browser


Actual results:

See attached screenshot
2017-11-25T11:22:58: INFO : Narrowed inbound regression window from [a84e3891, d4f80c4b] (4 builds) to [2ba4e83d, d4f80c4b] (2 builds) (~1 steps left)
2017-11-25T11:22:58: DEBUG : Starting merge handling...
2017-11-25T11:22:58: DEBUG : Using url: https://hg.mozilla.org/integration/mozilla-inbound/json-pushes?changeset=d4f80c4ba719d375e3b6d81a2fdd58007475f53c&full=1
2017-11-25T11:23:00: DEBUG : Found commit message:
Bug 1403302 - patch 3 - Remove direct cairo dependency from gfxTextRun and gfxGlyphExtents. r=bas
Blocks: 1403302
Has Regression Range: --- → yes
Has STR: --- → yes
Component: Untriaged → General
Keywords: regression
OS: Unspecified → Windows 10
Hardware: Unspecified → x86_64
Flags: needinfo?(jfkthame)
Component: General → Graphics: Text
Product: Firefox → Core
I can't seem to reproduce this on my Win10 machine. Tried both with and without hardware acceleration, but I'm not seeing the failure.

Reporter: could you try a fresh profile and/or running Firefox in Safe Mode, and see if the problem still occurs? If so, please attach your about:support report for additional details. Thanks!
Flags: needinfo?(jfkthame) → needinfo?(ignusws)
I can reproduce it with fresh profile. Actually this bug is quite similar to Bug 1325743 reported by me a while ago.


Application Basics
------------------

Name: Firefox
Version: 59.0a1
Build ID: 20171125100325
Update Channel: nightly
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:59.0) Gecko/20100101 Firefox/59.0
OS: Windows_NT 10.0
Multiprocess Windows: 1/1 (Enabled by default)
Web Content Processes: 5/4
Stylo: content = true (enabled by default), chrome = false (disabled by default)
Google Key: Found
Mozilla Location Service Key: Found
Safe Mode: false

Crash Reports for the Last 3 Days
---------------------------------

All Crash Reports

Nightly Features
----------------

Name: Activity Stream
Version: 2017.11.16.1254-39442ee8
ID: activity-stream@mozilla.org

Name: Application Update Service Helper
Version: 2.0
ID: aushelper@mozilla.org

Name: Firefox Screenshots
Version: 23.0.0
ID: screenshots@mozilla.org

Name: FlyWeb
Version: 1.0.0
ID: flyweb@mozilla.org

Name: Follow-on Search Telemetry
Version: 0.9.6
ID: followonsearch@mozilla.com

Name: Form Autofill
Version: 1.0
ID: formautofill@mozilla.org

Name: Photon onboarding
Version: 1.0
ID: onboarding@mozilla.org

Name: Pocket
Version: 1.0.5
ID: firefox@getpocket.com

Name: Presentation
Version: 1.0.0
ID: presentation@mozilla.org

Name: Shield Recipe Client
Version: 76.1
ID: shield-recipe-client@mozilla.org

Name: Web Compat
Version: 1.1
ID: webcompat@mozilla.org

Name: WebCompat Reporter
Version: 1.0.0
ID: webcompat-reporter@mozilla.org

Extensions
----------

Graphics
--------

Features
Compositing: Direct3D 11 (Advanced Layers)
Asynchronous Pan/Zoom: wheel input enabled; scrollbar drag enabled; keyboard enabled; autoscroll enabled
WebGL 1 Driver WSI Info: EGL_VENDOR: Google Inc. (adapter LUID: 00000000000094b3) EGL_VERSION: 1.4 (ANGLE 2.1.0.db3422764a9b) EGL_EXTENSIONS: EGL_EXT_create_context_robustness EGL_ANGLE_d3d_share_handle_client_buffer EGL_ANGLE_d3d_texture_client_buffer EGL_ANGLE_surface_d3d_texture_2d_share_handle EGL_ANGLE_query_surface_pointer EGL_ANGLE_window_fixed_size EGL_ANGLE_keyed_mutex EGL_ANGLE_surface_orientation EGL_ANGLE_direct_composition EGL_NV_post_sub_buffer EGL_KHR_create_context EGL_EXT_device_query EGL_KHR_image EGL_KHR_image_base EGL_KHR_gl_texture_2D_image EGL_KHR_gl_texture_cubemap_image EGL_KHR_gl_renderbuffer_image EGL_KHR_get_all_proc_addresses EGL_KHR_stream EGL_KHR_stream_consumer_gltexture EGL_NV_stream_consumer_gltexture_yuv EGL_ANGLE_flexible_surface_compatibility EGL_ANGLE_stream_producer_d3d_texture_nv12 EGL_ANGLE_create_context_webgl_compatibility EGL_CHROMIUM_create_context_bind_generates_resource EGL_CHROMIUM_sync_control EGL_EXT_pixel_format_float EGL_KHR_surfaceless_context EGL_ANGLE_display_texture_share_group EGL_ANGLE_create_context_client_arrays EGL_ANGLE_program_cache_control EGL_EXTENSIONS(nullptr): EGL_EXT_client_extensions EGL_EXT_platform_base EGL_EXT_platform_device EGL_ANGLE_platform_angle EGL_ANGLE_platform_angle_d3d EGL_ANGLE_device_creation EGL_ANGLE_device_creation_d3d11 EGL_ANGLE_experimental_present_path EGL_KHR_client_get_all_proc_addresses EGL_ANGLE_display_robust_resource_initialization
WebGL 1 Driver Renderer: Google Inc. -- ANGLE (AMD Radeon R9 200 Series Direct3D11 vs_5_0 ps_5_0)
WebGL 1 Driver Version: OpenGL ES 2.0 (ANGLE 2.1.0.db3422764a9b)
WebGL 1 Driver Extensions: GL_ANGLE_client_arrays GL_ANGLE_depth_texture GL_ANGLE_framebuffer_blit GL_ANGLE_framebuffer_multisample GL_ANGLE_instanced_arrays GL_ANGLE_lossy_etc_decode GL_ANGLE_pack_reverse_row_order GL_ANGLE_program_cache_control GL_ANGLE_request_extension GL_ANGLE_robust_client_memory GL_ANGLE_robust_resource_initialization GL_ANGLE_texture_compression_dxt3 GL_ANGLE_texture_compression_dxt5 GL_ANGLE_texture_usage GL_ANGLE_translated_shader_source GL_CHROMIUM_bind_generates_resource GL_CHROMIUM_bind_uniform_location GL_CHROMIUM_color_buffer_float_rgb GL_CHROMIUM_color_buffer_float_rgba GL_CHROMIUM_copy_compressed_texture GL_CHROMIUM_copy_texture GL_CHROMIUM_sync_query GL_EXT_blend_minmax GL_EXT_color_buffer_half_float GL_EXT_debug_marker GL_EXT_discard_framebuffer GL_EXT_disjoint_timer_query GL_EXT_draw_buffers GL_EXT_frag_depth GL_EXT_map_buffer_range GL_EXT_occlusion_query_boolean GL_EXT_read_format_bgra GL_EXT_robustness GL_EXT_sRGB GL_EXT_shader_texture_lod GL_EXT_texture_compression_dxt1 GL_EXT_texture_compression_s3tc_srgb GL_EXT_texture_filter_anisotropic GL_EXT_texture_format_BGRA8888 GL_EXT_texture_rg GL_EXT_texture_storage GL_EXT_unpack_subimage GL_KHR_debug GL_NV_EGL_stream_consumer_external GL_NV_fence GL_NV_pack_subimage GL_NV_pixel_buffer_object GL_OES_EGL_image GL_OES_EGL_image_external GL_OES_compressed_ETC1_RGB8_texture GL_OES_depth32 GL_OES_element_index_uint GL_OES_get_program_binary GL_OES_mapbuffer GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_surfaceless_context GL_OES_texture_float GL_OES_texture_float_linear GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_texture_npot GL_OES_vertex_array_object
WebGL 1 Extensions: ANGLE_instanced_arrays EXT_blend_minmax EXT_color_buffer_half_float EXT_frag_depth EXT_sRGB EXT_shader_texture_lod EXT_texture_filter_anisotropic EXT_disjoint_timer_query OES_element_index_uint OES_standard_derivatives OES_texture_float OES_texture_float_linear OES_texture_half_float OES_texture_half_float_linear OES_vertex_array_object WEBGL_color_buffer_float WEBGL_compressed_texture_s3tc WEBGL_compressed_texture_s3tc_srgb WEBGL_debug_renderer_info WEBGL_debug_shaders WEBGL_depth_texture WEBGL_draw_buffers WEBGL_lose_context
WebGL 2 Driver WSI Info: EGL_VENDOR: Google Inc. (adapter LUID: 00000000000094b3) EGL_VERSION: 1.4 (ANGLE 2.1.0.db3422764a9b) EGL_EXTENSIONS: EGL_EXT_create_context_robustness EGL_ANGLE_d3d_share_handle_client_buffer EGL_ANGLE_d3d_texture_client_buffer EGL_ANGLE_surface_d3d_texture_2d_share_handle EGL_ANGLE_query_surface_pointer EGL_ANGLE_window_fixed_size EGL_ANGLE_keyed_mutex EGL_ANGLE_surface_orientation EGL_ANGLE_direct_composition EGL_NV_post_sub_buffer EGL_KHR_create_context EGL_EXT_device_query EGL_KHR_image EGL_KHR_image_base EGL_KHR_gl_texture_2D_image EGL_KHR_gl_texture_cubemap_image EGL_KHR_gl_renderbuffer_image EGL_KHR_get_all_proc_addresses EGL_KHR_stream EGL_KHR_stream_consumer_gltexture EGL_NV_stream_consumer_gltexture_yuv EGL_ANGLE_flexible_surface_compatibility EGL_ANGLE_stream_producer_d3d_texture_nv12 EGL_ANGLE_create_context_webgl_compatibility EGL_CHROMIUM_create_context_bind_generates_resource EGL_CHROMIUM_sync_control EGL_EXT_pixel_format_float EGL_KHR_surfaceless_context EGL_ANGLE_display_texture_share_group EGL_ANGLE_create_context_client_arrays EGL_ANGLE_program_cache_control EGL_EXTENSIONS(nullptr): EGL_EXT_client_extensions EGL_EXT_platform_base EGL_EXT_platform_device EGL_ANGLE_platform_angle EGL_ANGLE_platform_angle_d3d EGL_ANGLE_device_creation EGL_ANGLE_device_creation_d3d11 EGL_ANGLE_experimental_present_path EGL_KHR_client_get_all_proc_addresses EGL_ANGLE_display_robust_resource_initialization
WebGL 2 Driver Renderer: Google Inc. -- ANGLE (AMD Radeon R9 200 Series Direct3D11 vs_5_0 ps_5_0)
WebGL 2 Driver Version: OpenGL ES 3.0 (ANGLE 2.1.0.db3422764a9b)
WebGL 2 Driver Extensions: GL_ANGLE_client_arrays GL_ANGLE_depth_texture GL_ANGLE_framebuffer_blit GL_ANGLE_framebuffer_multisample GL_ANGLE_instanced_arrays GL_ANGLE_lossy_etc_decode GL_ANGLE_multiview GL_ANGLE_pack_reverse_row_order GL_ANGLE_program_cache_control GL_ANGLE_request_extension GL_ANGLE_robust_client_memory GL_ANGLE_robust_resource_initialization GL_ANGLE_texture_compression_dxt3 GL_ANGLE_texture_compression_dxt5 GL_ANGLE_texture_usage GL_ANGLE_translated_shader_source GL_CHROMIUM_bind_generates_resource GL_CHROMIUM_bind_uniform_location GL_CHROMIUM_color_buffer_float_rgb GL_CHROMIUM_color_buffer_float_rgba GL_CHROMIUM_copy_compressed_texture GL_CHROMIUM_copy_texture GL_CHROMIUM_sync_query GL_EXT_blend_minmax GL_EXT_color_buffer_float GL_EXT_color_buffer_half_float GL_EXT_debug_marker GL_EXT_discard_framebuffer GL_EXT_disjoint_timer_query GL_EXT_draw_buffers GL_EXT_frag_depth GL_EXT_map_buffer_range GL_EXT_occlusion_query_boolean GL_EXT_read_format_bgra GL_EXT_robustness GL_EXT_sRGB GL_EXT_shader_texture_lod GL_EXT_texture_compression_dxt1 GL_EXT_texture_compression_s3tc_srgb GL_EXT_texture_filter_anisotropic GL_EXT_texture_format_BGRA8888 GL_EXT_texture_norm16 GL_EXT_texture_rg GL_EXT_texture_storage GL_EXT_unpack_subimage GL_KHR_debug GL_NV_EGL_stream_consumer_external GL_NV_fence GL_NV_pack_subimage GL_NV_pixel_buffer_object GL_OES_EGL_image GL_OES_EGL_image_external GL_OES_EGL_image_external_essl3 GL_OES_compressed_ETC1_RGB8_texture GL_OES_depth32 GL_OES_element_index_uint GL_OES_get_program_binary GL_OES_mapbuffer GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_surfaceless_context GL_OES_texture_float GL_OES_texture_float_linear GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_texture_npot GL_OES_vertex_array_object
WebGL 2 Extensions: EXT_color_buffer_float EXT_texture_filter_anisotropic EXT_disjoint_timer_query OES_texture_float_linear WEBGL_compressed_texture_s3tc WEBGL_compressed_texture_s3tc_srgb WEBGL_debug_renderer_info WEBGL_debug_shaders WEBGL_lose_context
Direct2D: true
Off Main Thread Painting Enabled: true
DirectWrite: true (10.0.15063.674)
GPU #1
Active: Yes
Description: AMD Radeon R9 200 Series
Vendor ID: 0x1002
Device ID: 0x6810
Driver Version: 22.19.162.4
Driver Date: 4-24-2017
Drivers: aticfx64 aticfx64 aticfx64 amdxc64 aticfx32 aticfx32 aticfx32 amdxc32 atiumd64 atidxx64 atidxx64 atiumdag atidxx32 atidxx32 atiumdva atiumd6a atitmm64
Subsys ID: 00000000
RAM: 2048

Diagnostics
ClearType Parameters: Gamma: 2,2 Pixel Structure: RGB ClearType Level: 50 Enhanced Contrast: 50
AzureCanvasAccelerated: 0
AzureCanvasBackend: Direct2D 1.1
AzureCanvasBackend (UI Process): skia
AzureContentBackend: Direct2D 1.1
AzureContentBackend (UI Process): skia
AzureFallbackCanvasBackend (UI Process): cairo
GPUProcessPid: 3132
GPUProcess: Terminate GPU Process
Device Reset: Trigger Device Reset
ClearType Parameters: Gamma: 2,2 Pixel Structure: RGB ClearType Level: 50 Enhanced Contrast: 50
Decision Log
WEBRENDER:
opt-in by default: WebRender is an opt-in feature




Media
-----

Audio Backend: wasapi
Max Channels: 2
Preferred Channel Layout: stereo
Preferred Sample Rate: 48000
Output Devices
Name: Group
SPDIF Interface (TX1) (VIA HD Audio): HDAUDIO\FUNC_01&VEN_1106&DEV_0441&SUBSYS_1458A014&REV_1001\4&36b8cb0&0&0201
1 - Digital Display Audio (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
4 - Digital Display Audio (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
6 - Digital Display Audio (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
5 - Digital Display Audio (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
SPDIF Interface (TX0) (VIA HD Audio): HDAUDIO\FUNC_01&VEN_1106&DEV_0441&SUBSYS_1458A014&REV_1001\4&36b8cb0&0&0201
Speakers (VIA HD Audio): HDAUDIO\FUNC_01&VEN_1106&DEV_0441&SUBSYS_1458A014&REV_1001\4&36b8cb0&0&0201
Headphone (VIA HD Audio): HDAUDIO\FUNC_01&VEN_1106&DEV_0441&SUBSYS_1458A014&REV_1001\4&36b8cb0&0&0201
2 - Digital Display Audio (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
3 - Digital Display Audio (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
Input Devices
Name: Group
Internal AUX Jack (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
Internal AUX Jack (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
Internal AUX Jack (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
Microphone (VIA HD Audio): HDAUDIO\FUNC_01&VEN_1106&DEV_0441&SUBSYS_1458A014&REV_1001\4&36b8cb0&0&0201
Internal AUX Jack (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
Internal AUX Jack (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
Line In (VIA HD Audio): HDAUDIO\FUNC_01&VEN_1106&DEV_0441&SUBSYS_1458A014&REV_1001\4&36b8cb0&0&0201
Internal AUX Jack (AMD High Definition Audio Device): HDAUDIO\FUNC_01&VEN_1002&DEV_AA01&SUBSYS_00AA0100&REV_1003\5&2861c894&2&0001
Stereo Mix (VIA HD Audio): HDAUDIO\FUNC_01&VEN_1106&DEV_0441&SUBSYS_1458A014&REV_1001\4&36b8cb0&0&0201

Important Modified Preferences
------------------------------

browser.cache.disk.capacity: 358400
browser.cache.disk.filesystem_reported: 1
browser.cache.disk.smart_size.first_run: false
browser.cache.frecency_experiment: 2
browser.places.smartBookmarksVersion: 8
browser.startup.homepage_override.buildID: 20171125100325
browser.startup.homepage_override.mstone: 59.0a1
browser.urlbar.timesBeforeHidingSuggestionsHint: 1
dom.forms.autocomplete.formautofill: true
extensions.lastAppVersion: 59.0a1
font.internaluseonly.changed: true
layers.mlgpu.sanity-test-failed: false
media.gmp.storage.version.observed: 1
media.hardware-video-decoding.failed: false
network.cookie.prefsMigrated: true
network.predictor.cleaned-up: true
places.history.expiration.transient_current_max_pages: 104858
plugin.disable_full_page_plugin_for_types: application/pdf
security.sandbox.content.tempDirSuffix: {19afce16-bcf7-4594-96ab-9a621ad1c212}
services.sync.declinedEngines:
services.sync.engine.addresses.available: true
services.sync.engine.creditcards.available: true
ui.osk.debug.keyboardDisplayReason: IKPOS: Touch screen not found.

Important Locked Preferences
----------------------------

Places Database
---------------

JavaScript
----------

Incremental GC: true

Accessibility
-------------

Activated: false
Prevent Accessibility: 0
Accessible Handler Used: true
Accessibility Instantiator:

Library Versions
----------------

NSPR
Expected minimum version: 4.17
Version in use: 4.17

NSS
Expected minimum version: 3.35 Beta
Version in use: 3.35 Beta

NSSSMIME
Expected minimum version: 3.35 Beta
Version in use: 3.35 Beta

NSSSSL
Expected minimum version: 3.35 Beta
Version in use: 3.35 Beta

NSSUTIL
Expected minimum version: 3.35 Beta
Version in use: 3.35 Beta

Experimental Features
---------------------

Sandbox
-------

Content Process Sandbox Level: 5
Effective Content Process Sandbox Level: 5

Internationalization & Localization
-----------------------------------

Application Settings
Requested Locales: ["en-US"]
Available Locales: ["en-US"]
App Locales: ["en-US"]
Regional Preferences: ["en-US"]
Default Locale: "en-US"
Operating System
System Locales: ["en-GB"]
Regional Preferences: ["ru-RU"]
Flags: needinfo?(ignusws) → needinfo?(jfkthame)
Attached image ClearTypeOn.png
Attached image ClearTypeOff.png
Bas, any idea what could be going on here? It appears to have been triggered by bug 1403302, but I haven't been able to reproduce, and I don't see why that should result in symptoms like this.
Flags: needinfo?(jfkthame) → needinfo?(bas)
Got another simple STR
1. Open Browser
2. Open in tab https://en.wikipedia.org/wiki/List_of_most_popular_websites
3. Open again https://en.wikipedia.org/wiki/List_of_most_popular_websites in second tab
4. And again in third tab and so on

Almost always 2nd tab is broken, others at random
Summary: Rendering glitches when ClearType is disabled and Session Restore is enabled while running Firefox → Rendering glitches when ClearType is disabled while running Firefox
Does this seem to have anything to do with what ad you get loaded at the top? I can see some tabs get an ad and some don't. I cannot reproduce this with the STR listed above, but there's something else I -can- reproduce.

The thing I can reproduce, is when I switch cleartype off -while- the browser is running, with the tab open, very briefly I see the text disappear, but it comes back within a second or so (or perhaps on the next draw). This does -not- occur on beta. I have once seen the text actually stay away, Jonathan, perhaps this can be of help to you?

This is on Windows 10, latest update, hardware acceleration on, E10S off (for debugging purposes, I didn't check if it reproduces with E10S on). I keep the window open on the background while changing the cleartype setting from on to off, until things disappear.

Let me know if this helps Jonathan, I'm trying to investigate a little myself as well, I've confirmed inside DrawTargetD2D1::FillGlyphs I get a valid font face, and it correctly detects aaMode as ALIASED, I don't see anything wrong on the DrawTarget side, I'm looking into it a little bit more myself, but hopefully this will already be of some help.
Flags: needinfo?(bas) → needinfo?(jfkthame)
Speaking of E10S, i think my problem in additional Web content processes created after browser start. When i try to set content process limit to 2 via Options every second tab i open ended up bugged (tabs distributed in round-robin manner i presume). If i rise number of content processes further only tab that opened in initial Web Content process working without glitches (got that information from about:memory page). Hope it helps.
When i set content process limit to 1 and restart browser i can't reproduce this bug anymore
So, I did some additional digging, when I ignore font->mParams, the flashing when switching cleartype mode goes away, so Jonathan, this appears to be related to the IDWriteRenderingParams object being passed with the font. This object is gotten from gfxDWriteFont::GetScaledFont, which you didn't alter directly, but it must somehow be related to that I suppose? If you need me to do more digging let me know, but hopefully you can work with this.
I still haven't been able to reproduce this locally, despite the clues above; I haven't seen the "flashing" you describe when toggling the setting, let alone complete loss of the text. So any further digging you can do to figure out what's going wrong with the DW params would be very much appreciated. (Maybe reproducing it is dependent on graphics drivers or something like that...?)
Flags: needinfo?(jfkthame) → needinfo?(bas)
(In reply to Jonathan Kew (:jfkthame) from comment #12)
> I still haven't been able to reproduce this locally, despite the clues
> above; I haven't seen the "flashing" you describe when toggling the setting,
> let alone complete loss of the text. So any further digging you can do to
> figure out what's going wrong with the DW params would be very much
> appreciated. (Maybe reproducing it is dependent on graphics drivers or
> something like that...?)

I was able to reproduce it on both my NVidia and Intel machines.. did you make sure E10S was off and D2D was on on your system?

I put the Firefox window on my screen maximized, ran the ClearType tuner while seeing the firefox window there, and toggled the setting while looking at the window. This was a latest nightly with a clean profile other than disabling e10s (note the pref for this has changed, make sure it's off :-)). In the meanwhile, I'll also have a look to see if I can see something more obvious.
Flags: needinfo?(bas) → needinfo?(jfkthame)
Oh, e10s OFF? Ah yes, I see that's what you said you were using. I'd understood from the reporter's comments that multiple e10s processes seemed to be required in order to reproduce for them. But I'll try again later and see if I can get it to happen with e10s disabled. (My Windows machine is currently doing alternate duty as my Linux machine...)
Here's my theory on how this was affected by your patches:

Calling GetScaledFont from gfxFont::SetupGlyphExtents has caused mAzureScaledFont to get setup at a different time, when the value of sUseClearType was still of a different type as when actual rasterization takes place.

Based on this I had the hypothesis that if mAzureScaledFont was not setup at the time of gfxFont::SetupGlyphExtends the old behavior should be restored, I have verified this hypothesis by adding an mAzureScaledFont = nullptr at gfxFont.cpp:3504, whereby the font gets recreated again on the next call to mAzureScaledFont. This made the issue disappear.

There's numerous ways to fix this, for now I'll leave it up to you which is best since you're far more familiar with this code :-). Let me know if there's anything else I can contribute!
Still can't get this to reproduce here. I see the font rendering in the browser window change when I toggle ClearType off/on, but I've never seen it lose the text, even momentarily. Which means I can't readily test a potential fix....

Does it help if we simply call UpdateClearTypeUsage() from gfxDWriteFont::GetScaledFont if it needs to create the mAzureScaledFont? I.e. add this as the first thing in the "if (!mAzureScaledFont) { ... }" section.
Flags: needinfo?(jfkthame) → needinfo?(bas)
I wonder which part I'm missing in my explanation since I can get this to reproduce on 4 different machines so far :).

Hrm, I gave that a very naieve shot (I literally did just that), and it didn't seem to work, which surprises me a little.
Flags: needinfo?(bas) → needinfo?(jfkthame)
(In reply to Bas Schouten (:bas.schouten) from comment #17)
> I wonder which part I'm missing in my explanation since I can get this to
> reproduce on 4 different machines so far :).

I wonder too! I only have the one Windows machine to try, but I still can't get it to happen, either with multiple content processes (as per the reporter's description) or with e10s disabled (as in your description). about:support confirms that I have D2D (and DWrite), as expected. My machine is running Intel HD Graphics 4600.

> 
> Hrm, I gave that a very naieve shot (I literally did just that), and it
> didn't seem to work, which surprises me a little.

:-(

For now, I'm a bit at a loss how to proceed here... any chance you can propose a fix that works for you?
Flags: needinfo?(jfkthame) → needinfo?(bas)
(In reply to Jonathan Kew (:jfkthame) from comment #18)
> (In reply to Bas Schouten (:bas.schouten) from comment #17)
> > I wonder which part I'm missing in my explanation since I can get this to
> > reproduce on 4 different machines so far :).
> 
> I wonder too! I only have the one Windows machine to try, but I still can't
> get it to happen, either with multiple content processes (as per the
> reporter's description) or with e10s disabled (as in your description).
> about:support confirms that I have D2D (and DWrite), as expected. My machine
> is running Intel HD Graphics 4600.

Hrm, can you print the value of sUseClearType when GetScaledFont is calls and see if it always has the expected values? For me that has unexpected values on the calls just after I switch it off (i.e. it reports true there).

> > 
> > Hrm, I gave that a very naieve shot (I literally did just that), and it
> > didn't seem to work, which surprises me a little.
> 
> :-(
> 
> For now, I'm a bit at a loss how to proceed here... any chance you can
> propose a fix that works for you?

I will look at this later this week.
Flags: needinfo?(bas)
Whiteboard: [gfx-noted]
this issue re-surfaced after 59 went to release and got addressed in bug 1435472
Status: UNCONFIRMED → RESOLVED
Closed: 2 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 1435472
You need to log in before you can comment on or make changes to this bug.