L
L
lemon_spb2013-01-02 05:04:21
JavaScript
lemon_spb, 2013-01-02 05:04:21

Simultaneous playback of multiple HTML5 audio. How and why?

Hello! Happy New Year!!!
I dealt with html5 audio and there was such a glitch: the browser refuses to play more than two or three audio tags at the same time. A similar glitch occurs on three of the seven computers on which I tried. Everywhere fresh browsers are installed. Such a "feature" seems to be browser independent. I have it in Chrome and in FF and in IE, and on a neighboring computer everything is OK everywhere. I insert audio on the page like this:

  <audio id="game_audio" loop controls> 
    	<source src="r3.mp3"  type="audio/mp3"> 
    	<source src="r3.ogg" type="audio/ogg"> 
  </audio> Peu 2<br>
For tests, I compiled a small html . You can start several files for playback (they are all looped), turn their sound to a minimum, start some of the latest "Peu" and listen to how it plays through once, or even after two. Again, if you have this glitch. Moreover, if I run a couple of sounds in Chrome, and one in FF, then the glitch persists.
Tell me, please, how to fight?

PS: Yes, I saw this: habrahabr.ru/post/149518/
But I have it in all browsers, and not only with me. On Safari and Blackberry, I almost don't care, but what to do with Chrome and FF ...

PPS: The glitch is not of any permanent nature. Sometimes 4 "streams", and everything is in order, sometimes it starts to fail. Sometimes after refreshing the page it starts to fail. Sometimes you need to run about 8 files in order to start skipping.
My hardware is normal: 2 year old ASUS laptop with i7. I play Starcraft 2, of course I don’t see any glitches with sounds there.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
R
Rowdy Ro, 2013-01-02
@rowdyro

It appears to be a problem with the sound card driver. When you have several sound sources, they are all mixed at the output into one, this can be done both by the program itself, visible and by the sound card driver.
Try to update the corresponding firewood

A
Aleks_ja, 2013-01-02
@Aleks_ja

Maybe it's a web server that doesn't want to give multiple files to one client at the same time?
Try digging into the config.

A
Alexander Medvedev, 2013-01-03
@lifestar

Firefox - everything works. The only thing is that there is no volume control (it is present on your video)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question