[Webkit-unassigned] [Bug 40414] Fetching inline style gives different matrix for rotate(90deg) than getComputedStyle

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Jun 11 08:28:36 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=40414





--- Comment #7 from Chris Marrin <cmarrin at apple.com>  2010-06-11 08:28:36 PST ---
Those two matrices are, for all intents and purposes, identical. The only difference is rounding.

The source of the rounding error may be one of the several places we use single precision floating point numbers in TransformationMatrix::rotate3d(). All the use of single precision in this file is a holdover from when the matrix itself was single precision. None of the uses of single precision here seem dangerous. I think they will all up-convert before being used. And the numbers are all 1.0f or 2.0f, which I believe are exactly represented in single precision. But there may be places where single precision math is being performed.

It could also be just general precision loss. We need to convert to radians, which is inherently lossy. But this seems like greater loss than that.

Finally, there could be places outside the TransformationMatrix code where the values could be getting shortened. But that seems unlikely for 90 degrees, since we store rotation values in degrees directly in the style declaration. So there's no conversion there.

At any rate, all the use of single precision in TransformationMatrix should be removed.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list