don't use setInterval, use requestAnimationFrame instead