Bug 241699 - TextureMapper: nesting 3D rendering context support
Summary: TextureMapper: nesting 3D rendering context support
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on: 244526
Blocks:
  Show dependency treegraph
 
Reported: 2022-06-16 13:56 PDT by Fujii Hironori
Modified: 2022-09-01 18:41 PDT (History)
1 user (show)

See Also:


Attachments
test case (29.12 KB, text/html)
2022-06-16 13:56 PDT, Fujii Hironori
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Fujii Hironori 2022-06-16 13:56:54 PDT
Created attachment 460275 [details]
test case

TextureMapperGL: rendering glitch of a 3d transformed text in Strange-Loop-2012

hyper texts in the slides aren't painted as expected if they are :hover.
https://github.com/BrendanEich/Strange-Loop-2012
Comment 1 Fujii Hironori 2022-06-16 18:30:26 PDT
Safari, Chrome, Firefox: Very smooth animation
WebKitGTK, WinCairo WK1: not smooth animation
WinCairo WK2: not smooth animation, text disappears
Comment 2 Fujii Hironori 2022-06-19 13:38:15 PDT
Disabling tet depth test makes the animation smooth. This seems to be a regression of my change (231816@main) enabling depth test.

diff --git a/Source/WebCore/platform/graphics/texmap/TextureMapperGL.cpp b/Source/WebCore/platform/graphics/texmap/TextureMapperGL.cpp
index f4d99408ff15..3890e1fa8c82 100644
--- a/Source/WebCore/platform/graphics/texmap/TextureMapperGL.cpp
+++ b/Source/WebCore/platform/graphics/texmap/TextureMapperGL.cpp
@@ -1043,7 +1043,6 @@ IntRect TextureMapperGL::clipBounds()
 
 void TextureMapperGL::beginPreserves3D()
 {
-    glEnable(GL_DEPTH_TEST);
     glClear(GL_DEPTH_BUFFER_BIT);
 }
Comment 3 Fujii Hironori 2022-06-19 14:20:28 PDT
In this test case, <section> and <span> elements has transform-style:preseve-3d, but intermediate <a> element doesn't have it.
This is the case not supported as 231816@main change log explains.

<section> transform-style:preseve-3d
 +<a>
   +<span> transform-style:preseve-3d
     +<span::after>
Comment 4 Radar WebKit Bug Importer 2022-06-23 13:57:11 PDT
<rdar://problem/95804784>