Usage - GianlucaGuarini/EasyAnimationFrame GitHub Wiki
First you have to create a new instance of EasyAnimationFrame
calss setting the callback loop function, the object inside the the DOM that should be animated and the framerate:
// callback , DOM element to animate , fps var animator = new EasyAnimationFrame( loop , elm , 150);
then you could start, stop and update your animation:
This method starts the animation
animator.startAnimation();
This method stops the animation
animator.clearAnimation();
This method update the framerate without stopping the current animation
animator.updateFramerate(insert here a new framerate);
This method returns the current framerate value
animator.getFramerate()