Fonts under certain condition render as white, regression after 46b2

RESOLVED FIXED in Firefox 46

Status

()

Core
Graphics: Layers
RESOLVED FIXED
2 years ago
9 months ago

People

(Reporter: fireattack, Assigned: bas)

Tracking

(Depends on: 3 bugs, {regression})

Trunk
mozilla48
regression
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox45 unaffected, firefox46+ fixed, firefox47+ fixed, firefox48+ fixed)

Details

Attachments

(1 attachment, 2 obsolete attachments)

(Reporter)

Description

2 years ago
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:46.0) Gecko/20100101 Firefox/46.0
Build ID: 20160316065941

Steps to reproduce:

Repro: http://output.jsbin.com/tasikupiwu

Set "gfx.content.use-native-pushlayer" to false can produce expected result.
(Reporter)

Updated

2 years ago
status-firefox45: --- → unaffected
status-firefox46: --- → affected
status-firefox47: --- → affected
status-firefox48: --- → affected
Keywords: regression
(Reporter)

Updated

2 years ago
Component: General → Graphics: Layers
(Reporter)

Updated

2 years ago
Summary: Fonts under certain condition renders as white, regression after 46b2 → Fonts under certain condition render as white, regression after 46b2
(Assignee)

Updated

2 years ago
Assignee: nobody → bas
Status: NEW → ASSIGNED
(Assignee)

Updated

2 years ago
Duplicate of this bug: 1256661
(Assignee)

Comment 2

2 years ago
Created attachment 8732638 [details]
MozReview Request: Bug 1258168: Push ClearType compatible clipping layers when the last pushed layer was marked as opaque. r=jrmuizel

Review commit: https://reviewboard.mozilla.org/r/41265/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/41265/
Attachment #8732638 - Flags: review?(jmuizelaar)
Comment on attachment 8732638 [details]
MozReview Request: Bug 1258168: Push ClearType compatible clipping layers when the last pushed layer was marked as opaque. r=jrmuizel

https://reviewboard.mozilla.org/r/41265/#review37945

Any chance for a test?
Attachment #8732638 - Flags: review?(jmuizelaar) → review+

Comment 4

2 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/f251bbc37cb0
Flags: needinfo?(bas)
Backed out for R(R) failures on Windows 8 x64:

Backout: https://hg.mozilla.org/integration/mozilla-inbound/rev/b21390b218bf

Push with failures: https://treeherder.mozilla.org/#/jobs?repo=mozilla-inbound&revision=f251bbc37cb0
Failure log: https://treeherder.mozilla.org/logviewer.html#?job_id=24335315&repo=mozilla-inbound
08:04:25     INFO -  REFTEST TEST-START | file:///C:/slave/test/build/tests/reftest/tests/layout/reftests/bugs/817019-1.html
08:04:25     INFO -  REFTEST TEST-LOAD | file:///C:/slave/test/build/tests/reftest/tests/layout/reftests/bugs/817019-1.html | 4561 / 13473 (33%)
08:04:25     INFO -  REFTEST TEST-UNEXPECTED-FAIL | file:///C:/slave/test/build/tests/reftest/tests/layout/reftests/bugs/817019-1.html | image comparison (==), max difference: 255, number of differing pixels: 20038
(Assignee)

Comment 6

2 years ago
Ugh I'm sorry. I forget to include win64 on https://treeherder.mozilla.org/#/jobs?repo=try&revision=9aeac1634c4b. :(
Flags: needinfo?(bas)
(Assignee)

Updated

2 years ago
Attachment #8732638 - Attachment is obsolete: true
(Assignee)

Comment 7

2 years ago
Created attachment 8733871 [details] [diff] [review]
Push ClearType compatible clipping layers when the last pushed layer was marked as opaque

This was due to us pushing cleartype clipping layers for temporary targets we were using for complex operators or unsupported patterns. I've removed clipping of the temporary surface as some investigation has lead me to conclude we'll clip the final composition anyway. This should improve performance as well.
Attachment #8733871 - Flags: review?(jmuizelaar)
Attachment #8733871 - Flags: review?(jmuizelaar) → review+
Tracking, since this is a recent regression.
tracking-firefox46: --- → +
tracking-firefox47: --- → +
tracking-firefox48: --- → +

Comment 9

2 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/06a0c49f1206
Backed out for failing Windows 8 x64 opt css-blending reftests:

Backout: https://hg.mozilla.org/integration/mozilla-inbound/rev/a9fbf9394340

Failure log: https://treeherder.mozilla.org/logviewer.html#?job_id=24648249&repo=mozilla-inbound


REFTEST TEST-UNEXPECTED-FAIL | file:///C:/slave/test/build/tests/reftest/tests/layout/reftests/canvas/1151821-1.html | image comparison (==), max difference: 255, number of differing pixels: 5000
REFTEST TEST-UNEXPECTED-FAIL | file:///C:/slave/test/build/tests/reftest/tests/layout/reftests/css-blending/blend-difference-stacking.html | image comparison (==), max difference: 255, number of differing pixels: 12000
REFTEST TEST-UNEXPECTED-FAIL | file:///C:/slave/test/build/tests/reftest/tests/layout/reftests/css-blending/background-blending-alpha.html | image comparison (==), max difference: 255, number of differing pixels: 40000
REFTEST TEST-UNEXPECTED-FAIL | file:///C:/slave/test/build/tests/reftest/tests/layout/reftests/css-blending/background-blending-gradient-color.html | image comparison (==), max difference: 255, number of differing pixels: 40000 
and more
Flags: needinfo?(bas)
(Assignee)

Comment 11

2 years ago
Yep, these failures are actually on my try run too. My mistake. Will keep working on this.
Flags: needinfo?(bas)
(Assignee)

Comment 12

2 years ago
Created attachment 8736719 [details] [diff] [review]
Push ClearType compatible clipping layers when the last pushed layer was marked as opaque v2

This patch passes all tests and should guarantee we always do the optimal thing.
Attachment #8733871 - Attachment is obsolete: true
Attachment #8736719 - Flags: review?(jmuizelaar)
Comment on attachment 8736719 [details] [diff] [review]
Push ClearType compatible clipping layers when the last pushed layer was marked as opaque v2

Review of attachment 8736719 [details] [diff] [review]:
-----------------------------------------------------------------

::: gfx/2d/DrawTargetD2D1.cpp
@@ +1196,5 @@
>    mUsedCommandListsSincePurge++;
>  
> +  D2D1_RECT_F rect;
> +  bool isAligned;
> +  RefPtr<ID2D1Image> tmpImage;

tmpImage looks unused.

@@ +1200,5 @@
> +  RefPtr<ID2D1Image> tmpImage;
> +  bool clipIsComplex = CurrentLayer().mPushedClips.size() && !GetDeviceSpaceClipRect(rect, isAligned);
> +
> +  if (patternSupported && !CurrentLayer().mIsOpaque && D2DSupportsCompositeMode(aOp) &&
> +      IsOperatorBoundByMask(aOp) && clipIsComplex) {

Can we move this condition into a helper function? It's complicated duplicated and as a reader I don't know what it does without reading closely.
Attachment #8736719 - Flags: review?(jmuizelaar) → review+

Comment 14

2 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/538d248fa252

Comment 15

2 years ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/538d248fa252
Status: ASSIGNED → RESOLVED
Last Resolved: 2 years ago
status-firefox48: affected → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla48
Can you request uplift ? I'm not sure how common this is, but since this first appeared in 46 it seems good to fix it in 46.   We can still get it into beta 10 if you think that's a good idea.
Flags: needinfo?(bas)
(Assignee)

Comment 17

2 years ago
Comment on attachment 8736719 [details] [diff] [review]
Push ClearType compatible clipping layers when the last pushed layer was marked as opaque v2

Approval Request Comment
[Feature/regressing bug #]: Native pushlayer/poplayer
[User impact if declined]: Some incorrect text rendering
[Describe test coverage new/current, TreeHerder]: Nightly usage
[Risks and why]: Fairly low, small risk of artifacts should the patch contain a mistake but it's reasonably contained
[String/UUID change made/needed]: None
Flags: needinfo?(bas)
Attachment #8736719 - Flags: approval-mozilla-beta?
Attachment #8736719 - Flags: approval-mozilla-aurora?
Comment on attachment 8736719 [details] [diff] [review]
Push ClearType compatible clipping layers when the last pushed layer was marked as opaque v2

Fix for recent regression, let's take this for aurora and for beta 11
Attachment #8736719 - Flags: approval-mozilla-beta?
Attachment #8736719 - Flags: approval-mozilla-beta+
Attachment #8736719 - Flags: approval-mozilla-aurora?
Attachment #8736719 - Flags: approval-mozilla-aurora+

Comment 19

2 years ago
bugherderuplift
https://hg.mozilla.org/releases/mozilla-aurora/rev/2ff41ae73a11
status-firefox47: affected → fixed
https://hg.mozilla.org/releases/mozilla-beta/rev/803cfc0649bf8601f68f42343bbe961622bc4017
status-firefox46: affected → fixed

Updated

a year ago
Depends on: 1303534

Updated

11 months ago
Depends on: 1333090
Depends on: 1336591

Updated

9 months ago
Depends on: 1348482
You need to log in before you can comment on or make changes to this bug.