The transition you're suggesting is also implemented and called
'linear' (see the Fx.Transitions documentation for more available
transitions).
Using the cosine function a "natural" acceleration and deceleration is
achieved. I've set up a small example to demonstrate the difference
here: http://mootools.net/shell/FScTL/

Jan


On Jun 7, 9:56 am, Neurostep <[email protected]> wrote:
> Hello all! I have a question: I looked at the source mootools and I do
> not understand why the function getTransition for Fx-class looks like
> that?
>
> getTransition: function(){
>         return function(p){
>                 return -(Math.cos(Math.PI * p) - 1) / 2;
>         };
>
> }
>
> Why transition not simply equals (time - this.time) /
> this.options.duration ?

Reply via email to