[d2d] TEST-UNEXPECTED-FAIL | svg/text-scale-01.svg

RESOLVED FIXED

Status

()

Core
Graphics
RESOLVED FIXED
7 years ago
6 years ago

People

(Reporter: jrmuizel, Assigned: jrmuizel)

Tracking

(Blocks: 1 bug)

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

7 years ago
Looks like the geometry we send to d2d is different in the cases where we get different pixels. I'm not yet sure why.
(Assignee)

Comment 1

7 years ago
The values that get passed into D2D are different:

font_matrix	{xx=100.00000149011612 ...}
ctm	{xx=1.0000000474974513 ...}	

vs.

font_matrix	{xx=100.00000000000000  ...}
ctm	{xx=1.0000000000000000 ...}

Not exactly sure why.
(Assignee)

Comment 2

7 years ago
The inaccurate values for font_matrix come from converting 6/60 into a float and then treating it as a double. I see two possible fixes: we could add a AppUnitsToDoubleCSSPixels or AppUnitsToFloat64CSSPixels that would do the division at higher precision or we could switch the test to use sizes that have an exact representation in floating point instead of using .1 which does not.
Or we could do something like gfxContext::NudgeCurrentMatrixToIntegers
(Assignee)

Comment 4

7 years ago
Created attachment 463842 [details] [diff] [review]
Fix the test case to use numbers that are exactly representable in floating point
Assignee: nobody → jmuizelaar
Attachment #463842 - Flags: review?(roc)
Attachment #463842 - Flags: review?(roc) → review+

Comment 5

6 years ago
This landed in August 2010:

http://hg.mozilla.org/mozilla-central/rev/237c0f3abaf6
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.