Constructors
constructor
- new ADSR(attackLength: number, decayLength: number, sustainLevel: number, sustainLength: number, releaseLength: number, sampleRate: number): ADSR
Parameters
attackLength: number
decayLength: number
sustainLevel: number
sustainLength: number
releaseLength: number
sampleRate: number
Properties
attack
attack: number
attackLength
attackLength: number
attackSamples
attackSamples: number
decay
decay: number
decayLength
decayLength: number
decaySamples
decaySamples: number
release
release: number
releaseLength
releaseLength: number
releaseSamples
releaseSamples: number
sampleRate
sampleRate: number
samplesProcessed
samplesProcessed: number
sustain
sustain: number
sustainLength
sustainLength: number
sustainLevel
sustainLevel: number
sustainSamples
sustainSamples: number
Methods
disable
Returns void
isActive
Returns boolean
noteOff
Returns void
noteOn
Returns void
process
- process(buffer: number[] | Float64Array): number[] | Float64Array
Parameters
buffer: number[] | Float64Array
Returns number[] | Float64Array
processSample
- processSample(sample: number): number
Parameters
Returns number
update
Returns void
value
Returns number
Attack-Decay-Sustain-Release Envelope