CreateJS / SoundJS

A Javascript library for working with Audio. It provides a consistent API for loading and playing audio on different browsers and devices. Currently supports WebAudio, HTML5 Audio, Cordova / PhoneGap, and a Flash fallback.
http://createjs.com/
MIT License
4.42k stars 838 forks source link

workaround for iOS audio corruption bug #235

Closed denisbabineau closed 6 years ago

denisbabineau commented 8 years ago

This is to workaround the following issue which impacts all content using Web Audio on most iOS devices especially those running 9.2.x (most likely including 9.3):

https://bugs.webkit.org/show_bug.cgi?id=154538

when the context sample rate is 48000 at startup, we're likely encountering this bug. Re-creating the context (after playing something to it, even if the context is suspended) avoids this bug. Also checking the state acts as an extra check that we're indeed on iOS.

gSkinner-Blair commented 6 years ago

This issue was already fixed in this commit here eca6b61eb33905ffb593ca53c52492a8d2b1fedc