Monday 9 March 2015

Why doesn't Web Audio API sound on iOS?

Why doesn't my script of Web Audio API sound on iOS?

Here are major missing points.

Did you mute your iPhone?

Yeah, really it's possible.

Did you listen to an user action?

Web Audio can't start by script itself on iOS. You need to create a listener, e.g. onclick.

Did you set an argument properly?

bufferSource.start() or oscillator.start()
bufferSource.stop() or oscillator.stop()
work on the desktop browsers but doesn't on iOS.

bufferSource.start(0) or oscillator.start(0)
bufferSource.stop(0) or oscillator.stop(0)
should work on any modern browsers.


No comments:

Post a Comment