[csswg-drafts] [css-transforms-2] Handling of coplanar elements

smfr has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-transforms-2] Handling of coplanar elements ==
https://docs.google.com/document/d/1FIQW9qVPbZxn0pifFOXWWK0-7fXrjlSeYeZN7wHmIHo/edit#heading=h.rn2bkk7p8jvo

Both TR and ED required that planes that are co-planar shall stack in z-index order. It is impossible to implement because many functions available to transform yields irrational numbers that are not representable in floating point numbers, and is subject to rounding errors. Symbolic implementation is possible given the current function set, but is computationally expensive. Current implementation uses arbitrary threshold for coplanarity, but this practice creates more problems: 1. There is still a dilemma at the threshold. 2. The threshold is not documented nor standardized, and the way the threshold is defined depends on internal details.

Even if coplanarity can be computed cheaply, the tie breaking rule still causes performance problem. Consider the following example:
<div style=”transform-style:preserve-3d;”>
  <div style=”position:relative;”>A</div>
  <div style=”transform:translateZ(1px); will-change:transform;”>B</div>
  <div style=”position:relative;”>C</div>
</div>
Element A and C won’t be able to raster into the same texture cache, because transform animation on B may result in coplanarity with plane AC.


Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1953 using your GitHub account

Received on Tuesday, 7 November 2017 20:41:18 UTC