Closed Bug 1474968 Opened 6 years ago Closed 6 years ago

Font rendering is sometimes different on Windows with WebRender turned on

Categories

(Core :: Graphics: WebRender, enhancement, P1)

enhancement

Tracking

()

RESOLVED FIXED
mozilla63
Tracking Status
firefox63 --- fixed

People

(Reporter: jrmuizel, Assigned: lsalzman)

References

Details

Attachments

(1 file, 1 obsolete file)

Priority: -- → P1
The when and why is actually known. Currently in Moz2D we track whether ClearType is enabled and limit the FontRenderMode that is passed into WR accordingly. However, any other parameters that govern how ClearType is interpreted (like gamma/contrast/etc.) are not transmitted at all. Glenn and I had roughly sketched out some ideas about how to send this info. Option 1 would be to just send over some global state to the font backend which controls how fonts created afterwards get interpreted, or option 2 is to bloat up FontInstancePlatformOptions substantially with all the necessary parameters. Still to-be-determined which option is least evil and/or ugly.
I'd prefer the global state option. These parameters aren't going to be changing much and if they do it's ok for us to get them sort of wrong.
Assignee: nobody → lsalzman
This will be resolved in part by WR PR https://github.com/servo/webrender/pull/2896
Status: NEW → ASSIGNED
Attachment #8992225 - Flags: review?(jmuizelaar)
Turned out the path of least resistance was just to stuff the parameters in FontInstancePlatformOptions. There didn't end up being too many, and it more closely follows what we do in Skia.
Attachment #8992225 - Flags: review?(jmuizelaar) → review+
Depends on: 1475252
Small fix to prevent an assertion from getting triggered when contrast is bigger than 1.0.
Attachment #8992225 - Attachment is obsolete: true
Attachment #8992441 - Flags: review+
Pushed by lsalzman@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/99f53302e68d pass DWrite font gamma and contrast to WebRender. r=jrmuizel
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla63
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: