Open Bug 1455393 Opened 6 years ago Updated 23 days ago

webrender regression: no subpixel-aa used for fade-clipped (masked) tab titles

Categories

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

enhancement

Tracking

()

People

(Reporter: Gankra, Unassigned)

References

(Blocks 2 open bugs)

Details

(Whiteboard: [gfx-noted])

We taught webrender how to properly layerize masks which has caused us to conservatively never use subpixel-aa in masks, even when unnecessary. You can see this effect in long tab titles in the chrome.

Potentially a blocker for the first release, but also not a *huge* deal.

Issues:

* Technically layerizing *is* correct/necessary, as it's possible for glyphs in a single text-run to run into eachother (happens with basically all arabic/devanagari). That said this is a QOI detail that vanilla firefox also gets wrong, so we can potentially punt on it for the first release.

* We *could* fix this in the same way opacity flattening is implemented, but this doesn't actually work right, because a single gecko nsDisplayText item decomposes into many webrender display items, which shouldn't be individually masked (e.g. underlined text shouldn't individually mask the underline and the text)

* We *could* fix this in webrender by having an optimization that detects if a stacking context is just a mask and the contents are non-overlapping, but this won't work right for the awesomebar yet, because the style change that emphasizes the domain name results in 3 separate text display items, all with identical (read: overlapping) bounds. The identical bounds are the result of us not bothering to tighten the bounds of the full text run for the sub-text-runs, because until now this didn't matter. It's possible we could tighten their bounds, but I'm not certain how expensive that would be.

We could potentially do the background hoisting trick gecko apparently does here to always use subpixel-aa, even when layerization is necessary?

Markus wants to wait on Glenn's text mask caching(?) work before we look into fixing this.
Assignee: nobody → a.beingessner
Status: NEW → ASSIGNED
Priority: -- → P1
Whiteboard: [gfx-noted]
Blocks: stage-wr-next
No longer blocks: stage-wr-trains
Assignee: a.beingessner → nobody
Status: ASSIGNED → NEW
Priority: P1 → P3
Severity: normal → S3
Blocks: wr-correctness
No longer blocks: stage-wr-next
You need to log in before you can comment on or make changes to this bug.