Search code examples
javascriptweb-audio-api

Web Audio: audio 2 sequential playbackRate values only applies first value


I have a song that I'm playing with Web Audio and I schedule two playbackRate changes before I play the song. The first playbackRate change takes effect, but the second one never triggers. Is this expected behavior? Anything I'm missing to make this work?

Basic logic is:

sourceNode = _mySoureNodeGetterFn('blah.mp3');
sourceNode.start(0);
sourceNode.playbackRate.setValueAtTime(.8, 5);
sourceNode.playbackRate.setValueAtTime(1.2, 10);
audioContext.resume();

The second playbackRate value, setValueAtTime(1.2, 10), scheduled for 10s into the song does not trigger. The first playbackRate triggers fine.

I'm using Chrome 56.0.2924.87 on a macbook.


Solution

  • Closing the loop - this is a bug with chrome v55. Fixed in v58 (dunno if fixed in any versions between the two).