W3C home > Mailing lists > Public > public-css-archive@w3.org > October 2020

Re: [csswg-drafts] [css-transforms] Error in description of transform in Section 3 example 5 (#4767)

From: afdw via GitHub <sysbot+gh@w3.org>
Date: Sat, 31 Oct 2020 14:08:17 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-719939071-1604153296-sysbot+gh@w3.org>
Moreover, this seems to be incorrect:

> Each \<transform-function\> can get represented by a corresponding 4x4 matrix. To map a point from the coordinate space of the \<div\> box to the coordinate space of the parent element, these transforms get multiplied in the reverse order:
> 1. The rotation matrix gets post-multiplied by the scale matrix.
> 2. The result of the previous multiplication is then post-multiplied by the translation matrix to create the accumulated transformation matrix.
> 3. Finally, the point to map gets pre-multiplied with the accumulated transformation matrix.

As far as I understand, it means that the resulting formula of the above procedure is:

p<sub>_parent_</sub> = M<sub>_rotation_</sub> × M<sub>_scale_</sub>× M<sub>_translation_</sub> × p<sub>_local_</sub>

But the rest of the specification and the Example 1 in particular seems to imply that the formula actually is:

p<sub>_parent_</sub> = M<sub>_translation_</sub> × M<sub>_scale_</sub>× M<sub>_rotation_</sub> × p<sub>_local_</sub>

Am I getting something wrong or is the example really incorrect?

GitHub Notification of comment by afdw
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/4767#issuecomment-719939071 using your GitHub account

Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Saturday, 31 October 2020 14:08:19 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:42:21 UTC