-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
TransformationMatrix::Recompose() and Decompose() incorrectly transpo…
…se rotation. https://bugs.webkit.org/show_bug.cgi?id=220856 <rdar://problem/73747851> Reviewed by Dean Jackson. The computation of quaternions during matrix decomposition appeared to be based off of the matrix transpose. Indexing in the quaternion calculation is consistent with row-major ordering; however, the "rows" variable is actually column major order (goes back to the original implementation of unmatrix in Graphics Gems II). The rotation matrix constructed from the quaternions also appeared to be assuming row-major ordering. These discrepancies were mostly corrected for by flipping the direction of the quaternion when extracting from the matrix. This is a (partial) cherry-pick from Blink: - https://chromium-review.googlesource.com/c/chromium/src/+/2489727 * Source/WebCore/platform/graphics/transforms/RotateTransformOperation.cpp: (WebCore::RotateTransformOperation::blend): * Source/WebCore/platform/graphics/transforms/TransformationMatrix.cpp: (WebCore::decompose4): (WebCore::slerp): (WebCore::accumulateQuaternion): (WebCore::TransformationMatrix::recompose4): Canonical link: https://commits.webkit.org/267424@main
- Loading branch information
1 parent
616b80d
commit a959acf
Showing
2 changed files
with
124 additions
and
117 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters