Set the PolySynths global envelope. This method modifies the envelopes of each monosynth so that all notes are played with this envelope.
Syntax
setADSR([attackTime], [decayTime], [susRatio], [releaseTime])
Parameters
Time (in seconds before envelope reaches Attack Level
Time (in seconds) before envelope reaches Decay/Sustain Level
Ratio between attackLevel and releaseLevel, on a scale from 0 to 1, where 1.0 = attackLevel, 0.0 = releaseLevel. The susRatio determines the decayLevel and the level at which the sustain portion of the envelope will sustain. For example, if attackLevel is 0.4, releaseLevel is 0, and susAmt is 0.5, the decayLevel would be 0.2. If attackLevel is increased to 1.0 (using setRange
), then decayLevel would increase proportionally, to become 0.5.
Time in seconds from now (defaults to 0)