Open colmandesilva opened 8 years ago
You can specify the number of channels when you load the data. Have a look at the registerSound
method - it accepts a data
parameter that can be the number of channels for the sound.
http://www.createjs.com/docs/soundjs/classes/Sound.html#method_registerSound
This limitation was introduced at first to get around limitations in the number of html audio channels, but was left in to artificially reduce the number of playing instances.
@lannymcnie I have indeed looked into the channel parameter. Here is a little snippet:
for(var i=0;i<CONFIG.AUDIO.length;i++){ var id = CONFIG.AUDIO[i].id; var src = CONFIG.AUDIO[i].src; createjs.Sound.registerSound(src, id, 5); }
but it didn't seem to work. The only work around I have found so far is to create copies of the audio file and alternate playing them. It's an ok solution, but not too happy with it.
I am building a game and have an issue with IE (10, 11) when playing a short sound clip multiple times so they overlap. The audio seems to override/interrupt. The only workaround I have found is to have multiple mp3 files with the exact same sound and alternate playing them.