linux: shared memory interface - link with librt
[supercollider.git] / HelpSource / Classes / Lag2.schelp
blob56bf26068c753cf03be5eca0e0e724eaac11aef7
1 class:: Lag2
2 summary:: Exponential lag
3 related:: Classes/Lag, Classes/Lag3, Classes/Ramp, Classes/Lag2UD
4 categories::  UGens>Filters>Linear
7 Description::
9 Lag2 is equivalent to code:: Lag.kr(Lag.kr(in, time), time) ::, thus resulting in a
10 smoother transition. This saves on CPU as you only have to calculate the
11 decay factor once instead of twice. See  link::Classes/Lag::  for more
12 details.
15 classmethods::
17 method::ar, kr
19 argument::in
21 The input signal.
24 argument::lagTime
26 60 dB lag time in seconds.
29 argument::mul
31 Output will be multiplied by this value.
34 argument::add
36 This value will be added to the output.
39 Examples::
41 code::
43 // used to lag pitch
45         SinOsc.ar(              // sine wave
46                 Lag2.kr(                        // lag the modulator
47                         LFPulse.kr(4, 0, 0.5, 50, 400), // frequency modulator
48                         Line.kr(0, 1, 15)                               // modulate lag time
49                 ),
50                 0,      // phase
51                 0.3     // sine amplitude
52         )
53 }.play