Returns a function that iterates over an envelope
const e = Envelopes.adsr();e(); // Yields current value Copy
const e = Envelopes.adsr();e(); // Yields current value
Starts the envelope the first time the return function is called. When the envelope finishes, it continues to return the releaseLevel of the envelope.
releaseLevel
Options can be provided to set the shape of the envelope as usual, eg:
const e = Envelopes.adsr({ attackDuration: 1000, releaseDuration: 500}); Copy
const e = Envelopes.adsr({ attackDuration: 1000, releaseDuration: 500});
Returns a function that iterates over an envelope
Starts the envelope the first time the return function is called. When the envelope finishes, it continues to return the
releaseLevel
of the envelope.Options can be provided to set the shape of the envelope as usual, eg: