- From: Shane Stephens <shans@google.com>
- Date: Tue, 18 Nov 2014 21:16:59 +0000
- To: "Сергей Грехов" <sgrekhov@unipro.ru>, public-fx@w3.org
- Cc: dom@unipro.ru
- Message-ID: <CAGTfzwSgZvMNpr0HtOUYTfNN_gWASvOYzNVOgknOAj+gTxTzHA@mail.gmail.com>
Hi Sergey, Yes, this is a good point. I think that we will need to move the wording in the last part of the algorithm ('if the transformed time is unresolved, return an unresolved time value') to the top as a first test. I'll update the spec. Cheers, -Shane On Tue Nov 18 2014 at 8:25:36 PM "Сергей Грехов" <sgrekhov@unipro.ru> wrote: > Hi All, > > Consider the following code: > > var node = new AnimationGroup([]); > node.computedTiming.timeFraction === ???; > > According the spec (http://w3c.github.io/web-animations/#time-fraction) > > "time fraction of an animation node is calculated according to the > following steps: > > If the iteration duration is zero, > > the time fraction is as follows, > > If local time < start delay, > > Return the result of recalculating the transformed time using an > iteration duration of 1. > > Otherwise, > > Let normalized active duration be the result of recalculating > the active duration using an iteration duration of 1. > > Return the result of recalculating the transformed time using > a local time of start delay + normalized active duration and > an iteration duration of 1. > > Otherwise, > > Return transformed time / iteration duration unless transformed time > is unresolved, in which case return an unresolved time value." > > In our case. AnimationGroup has no children so iteration duration is zero > (http://w3c.github.io/web-animations/#the-intrinsic- > iteration-duration-of-an-animation-group). > Next step. "If local time < start delay". In our case node has no parent > group and not associated with the player that means that inherited time > and therefore local time are both unresolved. Comparison with start delay > cannot be performed. > > -- > Regards, > Sergey G. Grekhov > > >
Received on Tuesday, 18 November 2014 21:17:29 UTC