W3C home > Mailing lists > Public > www-svg@w3.org > March 2011

Re: SVG animateMotion specification clarification request

From: Ken Stacey <ken@svgmaker.com>
Date: Tue, 29 Mar 2011 04:59:18 +1000
Message-ID: <4D90DA86.1040504@svgmaker.com>
To: www-svg@w3.org
Hi Shane,

On 28/03/2011, Shane Stephens wrote:
> The main problem with (MP * MR) * RT * AS is that container transforms
> are affected by the motionPath's auto-rotation.  Hence if I do this:
>
> <rect width="20" height="20" transform="translate(100, 100) scale(2,1)">
> <animateMotion path="M 0 0 c 0 150 150 150 150 0" begin="0" dur="3"
> fill="freeze" rotate="auto"/>
> </rect>
>
> then I get a very different motion path to if I do this:
>
> <rect width="20" height="20" transform="translate(100, 100) scale(2,1)">
> <animateMotion path="M 0 0 c 0 150 150 150 150 0" begin="0" dur="3"
> fill="freeze"/>
> </rect>

A similar problem exists for RT * (MP * MR) * AS.  If AS involves 
translation then the apparent motion path between rotate="auto" and 
rotate="none" is also different.

<rect width="20" height="20" transform="translate(100, 100) scale(2,1)">
  <animateMotion path="M 0 0 c 0 150 150 150 150 0" begin="0" dur="3"
  fill="freeze" rotate="auto"/>
   <animateTransform attributeName="transform" type="translate"
    from="0,20" to="0,-20" begin="0" dur="3" additive="sum"
    fill="freeze"/>
</rect>

and

<rect width="20" height="20" transform="translate(100, 100) scale(2,1)">
  <animateMotion path="M 0 0 c 0 150 150 150 150 0" begin="0" dur="3"
  fill="freeze"/>
   <animateTransform attributeName="transform" type="translate"
    from="0,20" to="0,-20" begin="0" dur="3" additive="sum"
    fill="freeze"/>
</rect>

If you allow animateMotion and animateTransform to be given equal 
status, then the RT * (MP * MR) * AS scenario suffers the above apparent 
motion path inconsistency.

That just leaves the specified behavior - RT * AS * (MP * MR) - as the 
only approach which yields a consistent motion path between 
rotate="auto" and rotate="none".

I can't say I like that behavior or that I would use it much (combine 
animateMotion and animateTransform).  But it is consistent!

Ken
Received on Monday, 28 March 2011 18:59:51 GMT

This archive was generated by hypermail 2.3.1 : Friday, 8 March 2013 15:54:47 GMT