Open Bug 1492673 Opened 1 year ago Updated 1 year ago

[WebRender] [Font Rendering] Fonts are rendered a tad poorly with WebRender enabled

Categories

(Core :: Graphics: WebRender, defect, P5)

64 Branch
x86_64
Windows 10
defect

Tracking

()

UNCONFIRMED
Tracking Status
firefox64 --- affected

People

(Reporter: kamranm1200, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(6 files)

Steps to reproduce:
1. Enable WebRender in about:config (or install a fresh copy of Firefox Nightly where it's been enabled by default)
2. Restart Firefox so the changes take effect.
3. Have a 1080p or lower monitor. (Monitors with 1440p or 4K resolutions aren't affected by this)
4. Go back to about:config and look at the configuration item listing.

What should've happened:
The items in about:config should have the same font aliasing/styling that is applied with WebRender turned off, as the fonts are clearer and easier to read on 1080p and other resolution displays(besides 1440p and 4K as they aren't affected by this issue due to the DPI on those displays being higher and the resolution just being higher)

What happened instead:
The items in about:config have a non-crisp styling to them, similar to TrueType being turned off or if a bad setting for it was applied.

I would really like to see if this can be worked on and/or fixed. It could be an issue with WebRender using the GPU to render fonts (if so, this should be avoided, as GPUs do NOT do font rendering well)
Attachment #9010499 - Attachment description: Font → Font rendering with WebRender Enabled
(In reply to kamranm1200 from comment #0)
> Created attachment 9010499 [details]
> Font rendering with WebRender Enabled
> 
> Steps to reproduce:
> 1. Enable WebRender in about:config (or install a fresh copy of Firefox
> Nightly where it's been enabled by default)
> 2. Restart Firefox so the changes take effect.
> 3. Have a 1080p or lower monitor. (Monitors with 1440p or 4K resolutions
> aren't affected by this)
> 4. Go back to about:config and look at the configuration item listing.
> 
> What should've happened:
> The items in about:config should have the same font aliasing/styling that is
> applied with WebRender turned off, as the fonts are clearer and easier to
> read on 1080p and other resolution displays(besides 1440p and 4K as they
> aren't affected by this issue due to the DPI on those displays being higher
> and the resolution just being higher)
> 
> What happened instead:
> The items in about:config have a non-crisp styling to them, similar to
> TrueType being turned off or if a bad setting for it was applied.
> 
> I would really like to see if this can be worked on and/or fixed. It could
> be an issue with WebRender using the GPU to render fonts (if so, this should
> be avoided, as GPUs do NOT do font rendering well)

To continue this comment (I prematurely submitted before I finished writing the description),

Font rendering on the GPU does not seem to work that well, as the TrueType setting seems to be completely ignored (This issue is actually also visible in Firefox tooltips as they don't seem to use TrueType on Windows, which should be fixed as well, but thats for another bug report). So yeah if the font rendering aspect could bypass WebRender, that might fix the issue, as with WebRender off, the issue isn't present.
Component: General → Graphics: WebRender
Product: Firefox → Core
Priority: -- → P4
Thoughts Lee?
Flags: needinfo?(lsalzman)
The screenshots show that in one case subpixel AA is on, and the other subpixel AA is off and just giving grayscale AA. This doesn't appear to be an issue with rasterization itself, and is more likely something happening in layout/display list handling.
Flags: needinfo?(lsalzman)
about:config uses a XUL tree, which goes through fallback painting. So the bug here is that we don't use subpixel AA with opaque fallback items. (Maybe we're not using an opaque Skia DrawTarget?)
kamranm1200, do you only see the problem on about:config?
Flags: needinfo?(kamranm1200)
(In reply to Jeff Muizelaar [:jrmuizel] from comment #6)
> kamranm1200, do you only see the problem on about:config?

No, it happens on websites too such as YouTube. Subpixel AA also seems to derp out on the tab bar itself when there are long tab titles when WebRender is enabled. With WebRender off no issues occur.
Flags: needinfo?(kamranm1200)
Long tab titles are bug 1455393.
YouTube is not known to have broken subpixel AA, can you attach screenshots of it with and without WR?
(In reply to Markus Stange [:mstange] from comment #8)
> Long tab titles are bug 1455393.
> YouTube is not known to have broken subpixel AA, can you attach screenshots
> of it with and without WR?

Alright, I have attached said screenshots.
Thanks! I can confirm this. YouTube has a (completely unnecessary) "will-change: transform" rule on <div id="items"> so we intentionally disable subpixel AA on that element. The fact that we're not doing it with non-WR could arguable be seen as a bug in non-WR.
I can reproduced on https://www.qq.com/
(In reply to nayinain from comment #14)
> Created attachment 9023300 [details]
> www.qq.com - WebRender disabled.png

That seems like a different issue (i.e. non subpixel-aa related). Can you file a separate issue?
(In reply to Jeff Muizelaar [:jrmuizel] on parental leave until Nov 6 from comment #15)
> (In reply to nayinain from comment #14)
> > Created attachment 9023300 [details]
> > www.qq.com - WebRender disabled.png
> 
> That seems like a different issue (i.e. non subpixel-aa related). Can you
> file a separate issue?

OK, I’ve filed a new issue here (Bug 1505459).
Priority: P4 → P5
You need to log in before you can comment on or make changes to this bug.