Get the master volume, aka gain of the root gain node.
Set the master volume, aka gain of the root gain node.
Get play state for every active channel
Get audio context (escape hatch). Not guaranteed to work the same way in future versions.
Load a sound file into a Wave.
Save this wave and reuse it! Construction is slow and expensive. Avoid loading large files (>5 minutes) to avoid using excess memory.
To unload a wave file, simply drop all references to it so the garbage collector can clear it out.
Use promise Wave.ready or check Wave.isReady to know that it
has finished loading.
Play a wave.
If options.channel is set, this will overwrite the playback
state of the previous channel. Otherwise, it allocates a new one.
If the wave is not loaded, LÏKE will begin playing when it is loaded. This does not cause delay, but it may cause cut-in.
use loadWave
Playback options (volume, speed, seek, loop)
The index of the active channel (starting at 1), unless the wave file failed to load.
Query the state of a current playing sound.
said state, unless the sound stopped/ended
Stop a playing channel and deallocate it.
Stop all playing channels.
Query just the current play position of a sound.
For a list of all possible play and update parameters, check ChannelState.
Basic usage
To play a sound, load it and then play it.
When a sound is playing, it can be manipulated just the same with Audio.update