Re: [css3-transforms] neutral element for addition - by animation

Am 26.05.2012 um 18:56 schrieb Dirk Schulze:

> Hi SVG folks,
> 
> I have a question to by animations on transforms. See the simple example here:
> 
> <rect width="100" height="100">
>  <animateTransform attributeName="transform" attributeType="XML"
>                    type="scale" by="1" dur="5s" fill="freeze"/>
> </rect>
> 
> This example scales from 0 to 1, since the neutral element for scale is 0. This is relevant because of the definition in SMIL Animation:
> 
> ""
> Normative: A by animation with a by value vb is equivalent to the same animation with a values list with 2 values, the neutral element for addition for the domain of the target attribute (denoted 0) and vb, andadditive="sum". Any other specification of the additive attribute in a by animation is ignored.
> "" [1]
> 
> And according to SVG animation, the animated transform gets post multiplied to the userspace transform of the element (which is the identity matrix).
> 
> My question is the following: Every transform function (independent if translate, scale or rotate) is just a shorthand for the underlaying transformation matrix (3x3/(3x2) or 4x4). Therefore, shouldn't the neutral element for addition on every transform function be the null matrix? If that is the case, what happens for the following example:
Fully agreed.

Have a look at http://brian.sol1.net/svg/animatetransform-issues/by-animation-and-scale-transformations/ where this is also discussed, especially Olafs Comment below.
Note that WebKit recently switched to this interpretation as well, use the zero matrix and not the identity matrix as neutral element for addition.

Cheers,
Niko

Received on Saturday, 26 May 2012 22:10:07 UTC