Increasing animation "frame interval" and exposing it

Increasing animation "frame interval" and exposing it

Hello everybody,

I just took the time to dive into jQuery.fx code and I discovered that the interval we are using for animations is currently at 13ms which is equivalent to 77fps !if the browser can keep up to this pace!
The problem is that animations involve heavy computation and numerous DOM access, and the browser is often forced to drop some frames.

I've done some research to see how other libraries are dealing with this parameter:
On a side note, the default value is 12fps in Flash CS3 and it can be modified as well.
In my tests, it appeared that animations seemed often smoother with a 33ms Interval (<=> 30fps) than with the default value.

I think it could be useful to do more tests on the perceived smoothness of animations depending on this parameter. It could probably be increased to at least 20, and making it possible for developers to modify it would be a great addition to the jQuery API.


Louis-Rémi Babé