linux: shared memory interface - link with librt
[supercollider.git] / HelpSource / Classes / TRand.schelp
blob924daaca64e5c6b27bb23cb2b2b5bd21456c74d5
1 class:: TRand
2 summary:: Triggered random number generator.
3 related:: Classes/ExpRand, Classes/IRand, Classes/LinRand, Classes/NRand, Classes/Rand, Classes/TExpRand, Classes/TIRand
4 categories:: UGens>Random, UGens>Triggers
7 Description::
9 Generates a random float value in uniform distribution from
10 code::lo::  to  code::hi::  each time the
11 trigger signal changes from nonpositive to positive values.
14 classmethods::
16 method::ar, kr
18 argument::lo
19 Lower limit of the output range.
21 argument::hi
22 Upper limit of the output range.
24 argument::trig
26 The trigger. Trigger can be any signal. A trigger happens when
27 the signal changes from non-positive to positive.
30 Examples::
32 code::
36         var trig = Dust.kr(10);
37         SinOsc.ar(
38                         TRand.kr(300, 3000, trig)
39                 ) * 0.1
40 }.play;
45         var trig = Dust.ar(MouseX.kr(1, 8000, 1));
46         SinOsc.ar(
47                         TRand.ar(300, 3000, trig)
48                 ) * 0.1
49 }.play;