Plays back break point envelopes. The envelopes are instances of the Env class. The envelope and the arguments for levelScale
, levelBias
, and timeScale
are polled when the EnvGen is triggered, and at the start of a new envelope segment. All values remain constant for the duration of each segment.
envelope |
An Env instance, or an Array of Controls. (See Control and the example below for how to use this.) The envelope is polled when the EnvGen is triggered, and at the start of a new envelope segment. The Env inputs can be other UGens. |
gate |
This triggers the envelope and holds it open while > 0. If the Env is fixed-length (e.g. Env.linen, Env.perc), the gate argument is used as a simple trigger. If it is an sustaining envelope (e.g. Env.adsr, Env.asr), the envelope is held open until the gate becomes 0, at which point is released. If gate < 0, force release with time |
levelScale |
The levels of the breakpoints are multiplied by this value. This value can be modulated, but is only sampled at the start of a new envelope segment. |
levelBias |
This value is added as an offset to the levels of the breakpoints. This value can be modulated, but is only sampled at the start of a new envelope segment. |
timeScale |
The durations of the segments are multiplied by this value. This value can be modulated, but is only sampled at the start of a new envelope segment. |
doneAction |
An integer representing an action to be executed when the env is finished playing. This can be used to free the enclosing synth, etc. See Done for more detail. |
If the gate of an EnvGen is set to -1 or below, then the envelope will cutoff immediately. The time for it to cutoff is the amount less than -1, with -1 being as fast as possible, -1.5 being a cutoff in 0.5 seconds, etc. The cutoff shape and final value are read from the Env's last node.
If the synthDef has an arg named "gate", the convenience method of Node can be used: node.release(releaseTime)
Forced release ignores multi-node release stages, always performing a one-node release, reading curve and end value from the Env's last node, and overwriting its duration.
For more information about the control bus mapping used in the line a = Synth(\sine, [freq: f.asMap]);
, see Node: -map and Bus: -asMap.