What controls the smoothness of an animation?

What controls the smoothness of an animation?

I have a div whose width increases from 0  to the screen width over 5 seconds but the animation is jerky. How can I control the "frame rate" of the animation?

$(myLoader.loadBar).stop().animate(
{width: myLoader.windowWidth}, 
5000, 
"linear", 
function() { 
myLoader.doneLoad();
}
);

Thanks
    • Topic Participants

    • stva