livecodelab icon indicating copy to clipboard operation
livecodelab copied to clipboard

sound samples can/should be loaded in the background

Open davidedc opened this issue 11 years ago • 3 comments

right now in Safari and Firefox (but not Chrome/IE) all sounds are loaded on start. This could be improved by loading them in the background while the environment is ready to accept commands.

Would probably require some sort of flag that marks when audio system is ready to run, and some messaging in case audio commands are issued before the loading is complete...

davidedc avatar Nov 12 '12 00:11 davidedc

with the rejigged sound system that takes a callback to fire once everything is loaded this should be pretty easy to do.

probably wants a tab in the top bar that shows when the audio system is ready and for the play function to just not do anything until it's all loaded

rumblesan avatar Nov 18 '12 20:11 rumblesan

lowlag sorts this now doesn't it?

rumblesan avatar Oct 30 '13 08:10 rumblesan

Safari still has a long while at the beginning where it's unresponsive/sluggish.

I believe that that's because of the sounds loading. Besides Safari being unresponsive, all browsers load all the sounds at the beginning.

So I'd like to load sound only when it's needed (say, loading all of them as soon as the first play instruction is run) and showing the loading progress on a bar at the top.

davidedc avatar Oct 30 '13 11:10 davidedc