Vocabulary
audio.engine

Inputs
audio-enginean audio-engine
sourcean object implementing the Audio source protocol
audioan audio
loop?a boolean


Outputs
audio-clip/fan audio-clip or f


Word description
Constructs and immediately starts playing a static-audio-clip tied to source and playing audio generated by generator. If loop? is true, the clip will repeat indefinitely until stopped with stop-clip. Otherwise, the clip will automatically be dispose d by the audio-engine when it finishes playing. If the engine has no available voices, no clip will be constructed, and f will be returned.

Notes
Use play-clips with <static-audio-clip> and <streaming-audio-clip> to synchronize the playing of multiple clips.

Definition


: play-static-audio-clip
( audio-engine source audio loop? -- audio-clip/f )
<static-audio-clip> dup [ play-clip ] when* ;