You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
496 B
Plaintext
21 lines
496 B
Plaintext
(
|
|
SynthDef(\gatedReverb, {
|
|
var dry, wet, reverbEnv;
|
|
|
|
// Dry signal
|
|
dry = SinOsc.ar(440) * EnvGen.ar(Env.perc(0.01, 0.1), doneAction: 0);
|
|
|
|
// Wet signal: full reverb
|
|
wet = FreeVerb.ar(dry.dup, mix: 1, room: 0.9, damp: 0.4);
|
|
|
|
// Gating envelope for the reverb ONLY
|
|
reverbEnv = EnvGen.ar(Env.linen(0, 0.2, 0.001), doneAction: 2); // <- Cutoff happens here
|
|
|
|
// Send dry directly, and apply the envelope to the wet
|
|
Out.ar(0, (dry + (wet * reverbEnv)) * 0.5);
|
|
}).add;
|
|
)
|
|
|
|
Synth(\gatedReverb);
|
|
|