Simple frame animation program in HTML5