Plays back a sample resident in memory.
Number of channels that the buffer will be. This must be a fixed integer. The architecture of the SynthDef cannot change after it is compiled.
The index of the buffer to use.
NOTE: If you supply a bufnum of a buffer with a differing number of channels than the one specified in this PlayBuf, it will post a warning and output the channels it can.
1.0 is the server's sample rate, 2.0 is one octave up, 0.5 is one octave down -1.0 is backwards normal rate… etc. Interpolation is cubic.
A trigger causes a jump to the startPos. A trigger occurs when a signal changes from negative value to positive value.
Sample frame to start playback.
1 means true, 0 means false. This is modulateable.
an integer representing an action to be executed when the buffer is finished playing. This can be used to free the enclosing synth, etc. See Done for more detail.
In the above example, note how the
doneAction: Done.freeSelf causes the synth to free itself when the buffer reaches its end.
Note again that the number of channels must be fixed for the SynthDef. It cannot vary depending on which buffer you use.