supernova: fix boost.thread move semantics
[supercollider.git] / Help / UGens / Random / LinRand.html
blob34770233f6f85ecf98e292a69a53420fe39012f2
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <meta http-equiv="Content-Style-Type" content="text/css">
6 <title></title>
7 <meta name="Generator" content="Cocoa HTML Writer">
8 <meta name="CocoaVersion" content="949.43">
9 <style type="text/css">
10 p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica}
11 p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 18.0px Helvetica; min-height: 22.0px}
12 p.p3 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica; min-height: 14.0px}
13 p.p4 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; min-height: 16.0px}
14 p.p5 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco}
15 p.p6 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #0000bf}
16 p.p7 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #000000}
17 p.p8 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; min-height: 12.0px}
18 p.p9 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #ad140d}
19 p.p10 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #001bb9}
20 p.p11 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #2c7014}
21 span.s1 {font: 18.0px Helvetica}
22 span.s2 {color: #0000ff}
23 span.s3 {color: #000000}
24 span.s4 {color: #007300}
25 span.s5 {color: #0000bf}
26 span.s6 {color: #001bb9}
27 span.s7 {color: #2c7014}
28 span.Apple-tab-span {white-space:pre}
29 </style>
30 </head>
31 <body>
32 <p class="p1"><span class="s1"><b>LinRand<span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></b></span><b>linear distribution single random float value ugen</b></p>
33 <p class="p2"><br></p>
34 <p class="p1"><b>LinRand(lo, hi, minmax)</b></p>
35 <p class="p3"><br></p>
36 <p class="p1">Generates a single random float value in linear distribution from <b>lo</b> to <b>hi</b>,</p>
37 <p class="p1">skewed towards lo if <b>minmax</b> &lt; 0, otherwise skewed towards hi.</p>
38 <p class="p3"><br></p>
39 <p class="p1">See also: <a href="Rand.html"><span class="s2">Rand</span></a>, <a href="ExpRand.html"><span class="s2">ExpRand</span></a></p>
40 <p class="p4"><br></p>
41 <p class="p5">(</p>
42 <p class="p6">SynthDef<span class="s3">(</span><span class="s4">\help_LinRand</span><span class="s3">, { </span>| out = 0, minmax = 1 |</p>
43 <p class="p7"><span class="Apple-tab-span"> </span><span class="s5">Out</span>.ar(out,<span class="Apple-converted-space"> </span></p>
44 <p class="p6"><span class="s3"><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></span>FSinOsc<span class="s3">.ar(</span></p>
45 <p class="p7"><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span><span class="s5">LinRand</span>(200.0, 10000.0, minmax),<span class="Apple-converted-space"> </span></p>
46 <p class="p7"><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span>0, <span class="s5">Line</span>.kr(0.2, 0, 0.01, doneAction:2))</p>
47 <p class="p7"><span class="Apple-tab-span"> </span>)</p>
48 <p class="p7">}).send(s);</p>
49 <p class="p5">)</p>
50 <p class="p8"><br></p>
51 <p class="p9">// towards hi</p>
52 <p class="p5">(</p>
53 <p class="p10">Routine<span class="s3">({</span></p>
54 <p class="p5"><span class="Apple-tab-span"> </span>loop({</p>
55 <p class="p5"><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span><span class="s6">Synth</span>.new(<span class="s7">\help_LinRand</span>); 0.04.wait;</p>
56 <p class="p5"><span class="Apple-tab-span"> </span>})</p>
57 <p class="p5">}).play;</p>
58 <p class="p5">)</p>
59 <p class="p8"><br></p>
60 <p class="p9">// towards lo (doesn't work like that yet)</p>
61 <p class="p5">(</p>
62 <p class="p10">Routine<span class="s3">({</span></p>
63 <p class="p5"><span class="Apple-tab-span"> </span>loop({</p>
64 <p class="p11"><span class="s3"><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></span><span class="s6">Synth</span><span class="s3">.new(</span>\help_LinRand<span class="s3">, [</span>\minmax<span class="s3">, -1]);<span class="Apple-converted-space"> </span></span></p>
65 <p class="p5"><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span>0.04.wait;</p>
66 <p class="p5"><span class="Apple-tab-span"> </span>})</p>
67 <p class="p5">}).play;</p>
68 <p class="p5">)</p>
69 <p class="p8"><br></p>
70 <p class="p8"><br></p>
71 </body>
72 </html>