1 <!DOCTYPE html PUBLIC
"-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
4 <meta http-equiv=
"Content-Type" content=
"text/html; charset=UTF-8">
5 <meta http-equiv=
"Content-Style-Type" content=
"text/css">
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: 18.0px Helvetica
}
11 p
.p2
{margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica
; min-height: 14.0px}
12 p
.p3
{margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica
}
13 p
.p4
{margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco
; color: #000000}
14 p
.p5
{margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco
; color: #000000; min-height: 16.0px}
15 p
.p6
{margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco
; color: #bf0000}
16 p
.p7
{margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco
; color: #606060}
17 p
.p8
{margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco
; color: #000000; min-height: 12.0px}
18 p
.p9
{margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco
; min-height: 12.0px}
19 p
.p10
{margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco
; min-height: 16.0px}
20 span
.s1
{color: #0000bf}
21 span
.s2
{color: #000000}
22 span
.s3
{color: #bf0000}
23 span
.Apple-tab-span
{white-space:pre
}
27 <p class=
"p1"><b>**
<span class=
"Apple-tab-span"> </span><span class=
"Apple-tab-span"> </span><span class=
"Apple-tab-span"> </span><span class=
"Apple-tab-span"> </span>exponentiation
</b></p>
28 <p class=
"p2"><br></p>
29 <p class=
"p3"><b>BinaryOperator
</b></p>
30 <p class=
"p2"><br></p>
31 <p class=
"p3"><b>a ** b
</b></p>
32 <p class=
"p2"><br></p>
33 <p class=
"p3">When the signal is negative this function extends the usual definition of
</p>
34 <p class=
"p3">exponentiation and returns neg(neg(a) ** b). This allows exponentiation of
</p>
35 <p class=
"p3">negative signal values by noninteger exponents.
</p>
36 <p class=
"p2"><br></p>
37 <p class=
"p3">redirects to
<b>pow(a, b)
</b></p>
38 <p class=
"p2"><br></p>
41 <p class=
"p4"><span class=
"s1">var
</span> a;
</p>
42 <p class=
"p4">a =
<span class=
"s1">FSinOsc
</span>.ar(
100);
</p>
43 <p class=
"p4">[a, a **
10]
</p>
44 <p class=
"p4">}.play
</p>
46 <p class=
"p5"><br></p>
47 <p class=
"p5"><br></p>
48 <p class=
"p6">// using exponentiation for compression or expansion
</p>
49 <p class=
"p7"><span class=
"s2">s.sendMsg(
</span>"/b_allocRead"<span class=
"s2">,
0,
</span>"sounds/a11wlk01.wav"<span class=
"s2">);
</span><span class=
"s3">// load a soundfile
</span></p>
50 <p class=
"p8"><br></p>
51 <p class=
"p6">// compression
</p>
54 <p class=
"p4"><span class=
"s1">var
</span> in =
<span class=
"s1">PlayBuf
</span>.ar(
1,
0,
1, loop:
1);
</p>
55 <p class=
"p4">in **
0.7<span class=
"Apple-converted-space"> </span></p>
56 <p class=
"p4">}.play;
</p>
58 <p class=
"p8"><br></p>
59 <p class=
"p6">// expansion
</p>
62 <p class=
"p4"><span class=
"s1">var
</span> in =
<span class=
"s1">PlayBuf
</span>.ar(
1,
0,
1, loop:
1);
</p>
63 <p class=
"p4">in **
2</p>
64 <p class=
"p4">}.play;
</p>
66 <p class=
"p9"><br></p>
67 <p class=
"p9"><br></p>
68 <p class=
"p9"><br></p>
69 <p class=
"p10"><br></p>
70 <p class=
"p10"><br></p>