linux: shared memory interface - link with librt
[supercollider.git] / HelpSource / Classes / PV_MagFreeze.schelp
blob75632f4f771af03487857cbf70dd1606dfe62dce
1 class:: PV_MagFreeze
2 summary:: Freeze magnitudes.
3 categories:: UGens>FFT
5 Description::
7 Freezes magnitudes at current levels when  code::freeze::  > 0.
10 classmethods::
12 method::new
14 argument::buffer
16 FFT buffer.
19 argument::freeze
21 If > 0, then magnitudes are frozen at current levels.
24 Examples::
26 code::
28 s.boot;
29 b = Buffer.read(s, Help.dir +/+ "sounds/a11wlk01.wav");
33 SynthDef("help-magFreeze", { arg out=0;
34         var in, chain;
35         in = SinOsc.ar(LFNoise1.kr(5.2,250,400));
36         chain = FFT(LocalBuf(2048), in);
37         // moves in and out of freeze
38         chain = PV_MagFreeze(chain, SinOsc.kr(0.2) );
39         Out.ar(out, 0.1 * IFFT(chain).dup);
40 }).play(s);
45 //trig with MouseY
46 SynthDef("help-magFreeze2", { arg out=0, soundBufnum=2;
47         var in, chain;
48         in = PlayBuf.ar(1, soundBufnum, BufRateScale.kr(soundBufnum), loop: 1);
49         chain = FFT(LocalBuf(2048), in);
50         chain = PV_MagFreeze(chain, MouseY.kr > 0.5 );
51         Out.ar(out, 0.1 * IFFT(chain).dup);
52 }).play(s,[\soundBufnum, b]);
55 b.free