use requestAnimationFrame

This is my attempt to refactor processing to use requestAnimationFrame instead of setInterval.

See http://paulirish.com/2011/requestanimationframe-for-smart-animating/