[webkit-changes] [WebKit/WebKit] 1aa517: Hit testing on element with 180deg flip inside pre...
mattwoodrow
noreply at github.com
Sun Jul 23 18:55:19 PDT 2023
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 1aa517d47471fdc37ac5b6e2f3809de704ea8ac5
https://github.com/WebKit/WebKit/commit/1aa517d47471fdc37ac5b6e2f3809de704ea8ac5
Author: Matt Woodrow <mattwoodrow at apple.com>
Date: 2023-07-23 (Sun, 23 Jul 2023)
Changed paths:
M LayoutTests/compositing/backing/backface-visibility-flip-expected.txt
M LayoutTests/compositing/layer-creation/overlap-transformed-preserved-3d-expected.txt
M LayoutTests/fast/text/combining-character-sequence-vertical.html
M LayoutTests/fast/text/vertical-quotation-marks.html
M LayoutTests/platform/ios-wk2/compositing/tiling/backface-preserve-3d-tiled-expected.txt
M LayoutTests/platform/ios-wk2/compositing/visible-rect/flipped-preserve-3d-expected.txt
M LayoutTests/platform/mac/compositing/tiling/backface-preserve-3d-tiled-expected.txt
M LayoutTests/platform/mac/compositing/visible-rect/flipped-preserve-3d-expected.txt
A LayoutTests/transforms/3d/hit-testing/hit-preserves-3d-3-expected.txt
A LayoutTests/transforms/3d/hit-testing/hit-preserves-3d-3.html
M Source/WebCore/platform/graphics/transforms/TransformationMatrix.cpp
Log Message:
-----------
Hit testing on element with 180deg flip inside preserve-3d not finding correct element.
https://bugs.webkit.org/show_bug.cgi?id=258565
<rdar://111393557>
Reviewed by Simon Fraser.
Floating point precision (using double) meant that sin(180deg) wasn't returning exactly 0.
When combining multiple transforms together using preserve-3d, this meant that layers that are intended to be coplanar
ended up at slightly different depths.
This adds rounding for tiny values to make them exactly zero, so that the layers end up coplanar again, and we hit
test in DOM order for those.
* LayoutTests/transforms/3d/hit-testing/hit-preserves-3d-3-expected.txt: Added.
* LayoutTests/transforms/3d/hit-testing/hit-preserves-3d-3.html: Added.
* Source/WebCore/platform/graphics/transforms/TransformationMatrix.cpp:
(WebCore::roundEpsilonToZero):
(WebCore::TransformationMatrix::rotate3d):
(WebCore::TransformationMatrix::rotate):
Canonical link: https://commits.webkit.org/266237@main
More information about the webkit-changes
mailing list