September 18th, 2012, 02:08 PM
Synch images to music
I'm playing a 4 sec wav file which is a music loop using the HTML5 Audio element.
I need to display 48 images, one after the other in 4 seconds at the same time as the music plays
I have tried using the ontimeupdate property from the HTML5 audio element but it does not update quickly enough to allow me to switch the images at the appropriate point in the music loop. With 48 images in 4 seconds I need to receive an update from the audio player at least every 0.083 seconds.
What I am trying to do is sync the images to the music.
Any thoughts on how I could achieve this please?