Closed
Bug 573027
Opened 14 years ago
Closed 3 years ago
with directwrite, vertical positioning of text depends on opacity
Categories
(Core :: Graphics, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: jfkthame, Assigned: bas.schouten)
References
(Blocks 1 open bug)
Details
Attachments
(2 files)
1.68 KB,
text/html
|
Details | |
1.71 KB,
patch
|
jrmuizel
:
review+
|
Details | Diff | Splinter Review |
Possibly related to bug 550431, or another symptom of the same underlying issue. With DirectWrite enabled, the vertical positioning of text changes slightly, depending on the particular HTML elements in use, when using the canvas painting path rather than an actual browser window. One way to trigger this is if opacity is used to make the text semi-transparent. This is the cause of a number of reftest failures with dwrite, including layout/reftests/bidi/413928-*. These work correctly in the browser window, but fail under the reftest framework, because of the different painting paths used. The attached sample based on reftest 413928 demonstrates the issue; it allows you to flip between a "testcase" using an ordered list, and a "reference" that uses simple <div>s. Without the 50% opacity option, the two display identically; but when 50% opacity is enabled, the testcase and reference no longer match.
Assignee | ||
Comment 1•14 years ago
|
||
This is related to the fact that for non-opaque glyphs (or rendering to non-opaque surfaces) our code applies intermediate surfaces that cause us to render using a fallback path. I'm currently investigating and fixing some things in our fallback in the meanwhile.
Assignee | ||
Comment 2•14 years ago
|
||
If we set the fallback path to : 'DWRITE_RENDERING_MODE_CLEARTYPE_NATURAL' (we lose sub-pixel vertical anti-aliasing). This problem indeed disappears. Currently we're forcing the fallback to enable vertical anti-aliasing, but we're not forcing the normal path to. This is because for the normal path we're allowed to use DWRITE_RENDERING_MODE_DEFAULT, which switches rendering modes based on font sizes. For the font size of the test cases vertical AA will be disabled. The RENDERING_MODE_DEFAULT is not available for the CreateGlyphRunAnalysis we're using to get the alpha texture for our fallback path.
Assignee | ||
Comment 3•14 years ago
|
||
This will use the recommended rendering mode for the current font configuration in the fallback path. This will provide the results most similar to the normal rendering path. Some follow-up patches will come to properly handle subpixel-AA in the fallback path.
Assignee: nobody → bas.schouten
Status: NEW → ASSIGNED
Attachment #455495 -
Flags: review?(jmuizelaar)
Updated•14 years ago
|
Attachment #455495 -
Flags: review?(jmuizelaar) → review+
Assignee | ||
Updated•3 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•