4 ms·
One of the main problems with the html5 audio tag isn't that it doesn't play audio, it is that it doesn't allow the control needed for things like gaming (playi
by keeperofdakeys 15y ago
One of the main problems with the html5 audio tag isn't that it doesn't play audio, it is that it doesn't allow the control needed for things like gaming (playing different streams in different speakers, no latency guarantees, etc).
- nddrylliog 15y agoThis is exactly where jsmad could shine, even on current browsers (on FF4/Chrome10+). Game usually use small sound effects, that can be decoded in a few ms and then stored in buffers. From there, it'd be very easy to do the mixing in pure JS using audiolib.js - which is a treat, btw! You'd get as many audio channels as your CPU can handle, mixed in realtime. If the Audio Data API / Web Audio API support more than 2 channels, we might even be looking at full 5.1 demos real soon. This is so exciting!
- quinnirill 15y agoI agree! And actually you can already do multichannel stuff, but currently that requires you to use either Audio API exclusively, because Chrome supports only 2 channels for javascript processing (but the internal effects are multi-channel), but Firefox supports only javascript processing.