Pass the font smoothing background color to WebRender

RESOLVED FIXED in mozilla58

Status

()

enhancement
P1
normal
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: mstange, Assigned: mstange)

Tracking

(Blocks 1 bug)

Trunk
mozilla58
All
macOS
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox57 unaffected, firefox58 unaffected)

Details

(Whiteboard: [wr-reserve])

Attachments

(1 attachment)

Assignee

Description

2 years ago
This will make text on top of light vibrancy have correct subpixel AA.

At the moment we don't have such text. But for example bug 1413271 would create some.

The necessary WebRender API was added in https://github.com/servo/webrender/pull/1974 .
Having the font smoothing background color on the ScaledFontMac, i.e. bug 1414154, is a prerequisite for this.

Comment 2

2 years ago
mozreview-review
Comment on attachment 8924845 [details]
Bug 1414157 - Supply the font smoothing background color in the webrender FontInstanceOptions.

https://reviewboard.mozilla.org/r/196102/#review201278

You need to zero this out in the DWrite and Fontconfig GetWRFontInstanceOptions functions that also set FontInstanceOptions.
Priority: -- → P1
Whiteboard: [wr-reserve]
Assignee

Comment 3

2 years ago
(In reply to Lee Salzman [:lsalzman] from comment #2)
> You need to zero this out in the DWrite and Fontconfig
> GetWRFontInstanceOptions functions that also set FontInstanceOptions.

I'm taking care of that in bug 1413178. But I had forgotten the DWrite backend (probably because it didn't show up in the top section in the searchfox results), so thanks for pointing that out. I've commented on bug 1413178.

Comment 4

2 years ago
mozreview-review
Comment on attachment 8924845 [details]
Bug 1414157 - Supply the font smoothing background color in the webrender FontInstanceOptions.

https://reviewboard.mozilla.org/r/196102/#review201462
Attachment #8924845 - Flags: review?(lsalzman) → review+
Comment hidden (mozreview-request)
Assignee

Comment 6

2 years ago
(In reply to Markus Stange [:mstange] from comment #0)
> This will make text on top of light vibrancy have correct subpixel AA.
> 
> At the moment we don't have such text.

That's actually not true - if you open the sidebar and then select "Synced Tabs", there is some text that asks you to sign in to sync or to download other browsers. This text looks really bad in webrender without the fix, and looks great with the fix. It does seem ever so slightly thicker than with webrender off, though, but I'm not going to worry about that.

Comment 7

2 years ago
Pushed by mstange@themasta.com:
https://hg.mozilla.org/integration/autoland/rev/a80606dac393
Supply the font smoothing background color in the webrender FontInstanceOptions. r=lsalzman
https://hg.mozilla.org/mozilla-central/rev/a80606dac393
Status: ASSIGNED → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla58
You need to log in before you can comment on or make changes to this bug.