<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>61824</bug_id>
          
          <creation_ts>2011-05-31 17:33:52 -0700</creation_ts>
          <short_desc>transform-style:flat should draw in document order</short_desc>
          <delta_ts>2023-06-02 10:40:11 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebCore Misc.</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc>https://jsfiddle.net/nq2beh8d/</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Vangelis Kokkevis">vangelis</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ahmad.saleem792</cc>
    
    <cc>cmarrin</cc>
    
    <cc>e.imhotep</cc>
    
    <cc>eoconnor</cc>
    
    <cc>jamesr</cc>
    
    <cc>mail</cc>
    
    <cc>mattwoodrow</cc>
    
    <cc>mrobinson</cc>
    
    <cc>simon.fraser</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>413016</commentid>
    <comment_count>0</comment_count>
    <who name="Vangelis Kokkevis">vangelis</who>
    <bug_when>2011-05-31 17:33:52 -0700</bug_when>
    <thetext>Should children of an element with -webkit-transform-style set to flat draw in document order or be depth sorted?  

Safari depth sorts whereas Chrome&apos;s compositor doesn&apos;t. My take is that unless the transform-style of the parent is set to preserves-3d, children should be drawn in their document (or z-index) order but I don&apos;t think the spec is clear about this.

This page demonstrates the difference:

http://dl.dropbox.com/u/2176065/perspective/index.html#album-4

(you&apos;ll need to mouse over the covers on the right to get them to flip around)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>413021</commentid>
    <comment_count>1</comment_count>
    <who name="James Robinson">jamesr</who>
    <bug_when>2011-05-31 17:40:32 -0700</bug_when>
    <thetext>I think that the elements have to be painted in document order (or more precisely the usual CSS painting order) unless CSS specifies exactly what Safari&apos;s depth sort does, which seems somewhat impractical.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>413028</commentid>
    <comment_count>2</comment_count>
    <who name="Simon Fraser (smfr)">simon.fraser</who>
    <bug_when>2011-05-31 17:45:24 -0700</bug_when>
    <thetext>-webkit-transform-style: flat should draw in document order, with no intersection. Safari isn&apos;t able to do this correctly yet.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1692532</commentid>
    <comment_count>3</comment_count>
    <who name="Francesco Mazzoli">e.imhotep</who>
    <bug_when>2020-09-28 06:54:52 -0700</bug_when>
    <thetext>Just wanted to report that this is still an issue, and is causing us considerable headaches when building a WebGL AR/VR application which needs to transform the HUD, which is partially written with normal DOM elements.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1959549</commentid>
    <comment_count>4</comment_count>
    <who name="Ahmad Saleem">ahmad.saleem792</who>
    <bug_when>2023-06-02 08:34:06 -0700</bug_when>
    <thetext>Test case link from StackOverflow mentioning this bug: https://stackoverflow.com/questions/76248303/z-index-and-translate-3d-not-work-the-same-in-chrome-and-safari/76248787#76248787

It is still reproducible in Safari Technology Preview 171.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>