Chorus
class Effect ↳ extends StereoFeedbackEffect<ChorusOptions>
Chorus is a stereo chorus effect composed of a left and right delay with an LFO applied to the delayTime of each channel. When feedback is set to a value larger than 0, you also get Flanger-type effects. Inspiration from Tuna.js. Read more on the chorus effect on Sound On Sound.
const chorus = new Tone.Chorus(4, 2.5, 0.5).toDestination().start(); const synth = new Tone.PolySynth().connect(chorus); synth.triggerAttackRelease(["C3", "E3", "G3"], "8n");
Constructor
Section titled “Constructor”new Chorus(frequency?: Frequency, delayTime?: number, depth?: number)Parameters
-
frequency
FrequencyoptionalThe frequency of the LFO.
-
delayTime
numberoptionalThe delay of the chorus effect in ms.
-
depth
numberoptionalThe depth of the chorus.
new Chorus(options?: Partial<ChorusOptions>)Parameters
- options
Partial<ChorusOptions>optional
Properties
Section titled “Properties”feedback
Section titled “feedback”read-only ↳ inherited from StereoFeedbackEffect
feedback: Signal<"normalRange">The amount of feedback from the output back into the input of the effect (routed across left and right channels).
frequency
Section titled “frequency”read-only
frequency: Signal<"frequency">The frequency of the LFO which modulates the delayTime.
read-only ↳ inherited from StereoEffect
input: GainThe input node or nodes. If the object is a source, it does not have any input and this.input is undefined.
output
Section titled “output”read-only ↳ inherited from StereoEffect
output: CrossFadeThe output nodes. If the object is a sink, it does not have any output and this.output is undefined.
read-only ↳ inherited from StereoEffect
wet: Signal<"normalRange">The wet control, i.e. how much of the effected will pass through to the output.
delayTime
Section titled “delayTime”delayTime: numberThe delayTime in milliseconds of the chorus. A larger delayTime will give a more pronounced effect. Nominal range a delayTime is between 2 and 20ms.
depth: numberThe depth of the effect. A depth of 1 makes the delayTime modulate between 0 and 2*delayTime (centered around the delayTime).
spread
Section titled “spread”spread: numberAmount of stereo spread. When set to 0, both LFO’s will be panned centrally. When set to 180, LFO’s will be panned hard left and right respectively.
Methods
Section titled “Methods”start()
Section titled “start()”start(time?: Time): thisStart the effect.
Parameters
- time
Timeoptional
Returns this
stop()
Section titled “stop()”stop(time?: Time): thisStop the lfo
Parameters
- time
Timeoptional
Returns this
sync()
Section titled “sync()”sync(): thisSync the filter to the transport.
See also: LFO.sync
Returns this
getDefaults()
Section titled “getDefaults()”static
getDefaults(): ChorusOptionsReturns all of the default options belonging to the class.
Returns ChorusOptions
Inherited members
Section titled “Inherited members”- From
ToneWithContext: context, blockTime, sampleTime, get(), immediate(), now(), set(), toFrequency(), toSeconds(), toTicks() - From
Tone: debug, version, disposed, toString() - From
ToneAudioNode: channelCount, channelCountMode, channelInterpretation, numberOfInputs, numberOfOutputs, chain(), connect(), disconnect(), fan(), toDestination(), toMaster()