Re: [css3-2d-transforms][css3-3d-transforms] Relationship of CSSMatrix interface definitions

On Tue, Sep 7, 2010 at 2:59 PM, Sylvain Galineau <sylvaing@microsoft.com> wrote:
> Both CSS3 2D Transforms [1] and CSS3 3D Transforms [2] define a CSSMatrix DOM interface.
> One describes a 3x2 matrix, the other a 4x4 matrix.
>
> What is the relationship of these two identically named interface ? Is it intended for
> the DOM to have separate object types for 2D and 3D matrices ?
>
> [1] http://dev.w3.org/csswg/css3-3d-transforms/#cssmatrix-interface
> [2] http://dev.w3.org/csswg/css3-2d-transforms/#cssmatrix-interface

In WebKit both interfaces map to one kind of 4x4 matrix object, with
attributes and methods routed appropriately. It even serializes to the
2d or 3d matrix transform functions ('matrix(...)' or 'matrix3d(...)',
respectively) based on the transform it represents at the time.

This behavior is (I think) extremely helpful. It is also implied by
calling both "CSSMatrix," but should perhaps be made explicit if it is
fully intended.

Received on Tuesday, 7 September 2010 20:24:58 UTC