[Webkit-unassigned] [Bug 30442] Add helper methods to determine whether a transformation matrix is only scaled or translated

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Oct 28 15:37:36 PDT 2009


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


Jakob Petsovits <jpetsovits at rim.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #41383|0                           |1
        is obsolete|                            |
  Attachment #41383|review?, commit-queue?      |
               Flag|                            |
  Attachment #42062|                            |review?, commit-queue?
               Flag|                            |




--- Comment #8 from Jakob Petsovits <jpetsovits at rim.com>  2009-10-28 15:37:35 PDT ---
Created an attachment (id=42062)
 --> (https://bugs.webkit.org/attachment.cgi?id=42062)
Add FloatQuad::isRectilinear() to check whether it can be represented as
FloatRect.

I had a talk with Simon and Chris on Skype, and it was determined that checking
the matrix would not be the best approach for the intended goal (which can be
paraphrased as "determine whether a transformation will return a rectilinear
quad in order to enable optimizations"). Instead of checking the transformation
itself, they suggested a new method FloatQuad::isRectilinear() to check the
output of that transformation, which is a more generic approach and can be used
in a couple more cases (e.g. also applies to rectangles turned by 90/270
degrees, and a few less common cases).

Here's the implementation; I tested with rectangles that are flipped and turned
by 90, 180 and 5 degrees, the latter will return false for isRectilinear()
while all of the others return true. Please review, hopefully this time it's
the way to go :)

-- 
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