Audio play configurations.
If audio should start out paused.
since
v3000.0
loop?: boolean
If audio should be played again from start when its ended.
Volume of audio. 1.0 means full volume, 0.5 means half volume.
Playback speed. 1.0 means normal playback speed, 2.0 means twice as fast.
Detune the sound. Every 100 means a semitone.
// play a random note in the octave
play("noteC", {
detune: randi(0, 12) * 100,
})
seek?: number
The start time, in seconds.
pan?: number
The stereo pan of the sound.
-1.0 means fully from the left channel, 0.0 means centered, 1.0 means fully right.
Defaults to 0.0.