Hi!
I have an application which plays 5 sound files together sort of like the
following:
var speech:Array = new Array();
var sc:Array = new Array();
var speechPath:Array = { "x0.mp3", "x1.mp3", "x2.mp3", "x3.mp3", "x4.mp3" };
public function initApp():void
{
for (var i:int = 0; i < 5; ++i) {
speech[i] = new Sound(speechPath[0]);
}
}
public function playSpeech():void
{
for (var i:int = 0; i < 5; ++i) {
sc[i] = speech[i].play();
}
}
Over time, the files start to fall out of sync. I have a timer to move a
slider marking the speech's progress, and in that, every once in a while, I
trace the positions of the sound channels. I see variations of more than
100ms. If I try to correct them I have to first stop that sound and then
play it from the appropriate position, and that introduces a slight skip.
The sounds get out of sync even more if I move the positions back and forth
through a function that is controlled by the slider move event.
Is there another way to keep these multiple sounds in sync?
Mat