sclang: ServerShmInterface - try to avoid multiple destructor calls
[supercollider.git] / HelpSource / Classes / Limiter.schelp
blob7dcc6919abede41855456521b369c519feb22b5d
1 class:: Limiter
2 summary:: Peak limiter
3 related:: Classes/Amplitude, Classes/Compander, Classes/CompanderD, Classes/Normalizer
4 categories:: UGens>Dynamics
7 Description::
9 Limits the input amplitude to the given level. Limiter will not overshoot
10 like  link::Classes/Compander::  will, but it needs to look ahead in the
11 audio. Thus there is a delay equal to twice the value of the
12 code::dur::  parameter.
14 Limiter, unlike Compander, is completely transparent for an in range signal.
16 classmethods::
18 method::ar
20 argument::in
21 The signal to be processed.
23 argument::level
24 The peak output amplitude level to which to normalize the input.
26 argument::dur
27 aka lookAheadTime.
28 The buffer delay time. Shorter times will produce smaller delays
29 and quicker transient response times, but may introduce amplitude
30 modulation artifacts.
33 Examples::
35 code::
37 // example signal to process
38 Synth.play({
39         var z;
40         z = Decay2.ar(
41                 Impulse.ar(8, LFSaw.kr(0.25, -0.6, 0.7)),
42                 0.001, 0.3, FSinOsc.ar(500));
43 }, 0.8)
47 Synth.play({
48         var z;
49         z = Decay2.ar(
50                 Impulse.ar(8, LFSaw.kr(0.25, -0.6, 0.7)),
51                 0.001, 0.3, FSinOsc.ar(500));
52         [z, Limiter.ar(z, 0.4, 0.01)]
53 }, 0.5)