aboutsummaryrefslogtreecommitdiff
path: root/doc/tutorials/playnow/additive.pd
blob: c326cf0059ec3341f1e1499525de92908bc02706 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
#N canvas 237 83 750 557 10;
#X text 87 15 ADDITIVE SYNTHESIS;
#X text 32 73 This patch demonstrates using an abstraction \, "partial"
\, to make a simple additive synthesis instrument.;
#X text 28 114 Partial takes as arguments an amplitude \, a relative
frequency \, a detuning frequency \, and a relative duration. You set
absolute duration and pitch using the controls below. Hit hte trigger
to make sound.;
#N canvas 47 404 460 310 guts 0;
#X floatatom 59 226 0 0 0 0 - - -;
#N canvas 159 26 536 283 output 0;
#X obj 338 160 t b;
#X obj 338 110 f;
#X obj 338 60 inlet;
#X text 344 29 mute;
#X obj 338 185 f;
#X msg 425 178 0;
#X msg 338 85 bang;
#X obj 338 135 moses 1;
#X obj 397 117 moses 1;
#X obj 83 148 dbtorms;
#X obj 397 92 r master-lvl;
#X obj 83 42 r master-lvl;
#X obj 338 210 s master-lvl;
#X obj 22 181 inlet~;
#X obj 199 41 inlet;
#X text 199 18 level;
#X obj 199 100 s master-lvl;
#X msg 96 65 set \$1;
#X obj 96 89 outlet;
#X msg 214 64 \; pd dsp 1;
#X obj 83 194 line~;
#X obj 22 212 *~;
#X obj 22 241 dac~;
#X obj 83 171 pack 0 50;
#X text 20 158 audio;
#X text 93 110 show level;
#X obj 425 153 t b;
#X connect 0 0 4 0;
#X connect 1 0 7 0;
#X connect 2 0 6 0;
#X connect 4 0 12 0;
#X connect 5 0 12 0;
#X connect 6 0 1 0;
#X connect 7 0 0 0;
#X connect 7 1 26 0;
#X connect 8 1 4 1;
#X connect 9 0 23 0;
#X connect 10 0 1 1;
#X connect 10 0 8 0;
#X connect 11 0 9 0;
#X connect 11 0 17 0;
#X connect 13 0 21 0;
#X connect 14 0 16 0;
#X connect 14 0 19 0;
#X connect 17 0 18 0;
#X connect 20 0 21 1;
#X connect 21 0 22 0;
#X connect 21 0 22 1;
#X connect 23 0 20 0;
#X connect 26 0 5 0;
#X restore 21 253 pd output;
#X msg 97 226 MUTE;
#X text 131 225 <-- output amplitude;
#X obj 21 195 catch~ sum;
#X obj 23 112 ../../3.audio.examples/partial 1.8 0.94 0 0.55;
#X obj 22 87 ../../3.audio.examples/partial 1 0.92 0 0.65;
#X obj 23 63 ../../3.audio.examples/partial 1 0.56 1 0.9;
#X obj 23 39 ../../3.audio.examples/partial 0.67 0.56 0 1;
#X connect 0 0 1 1;
#X connect 1 0 0 0;
#X connect 2 0 1 2;
#X connect 4 0 1 0;
#X restore 433 21 pd guts;
#X obj 274 218 grid grid5 200 0 199 200 0 199 1 1 1 10 10 0 0;
#X obj 467 424 * 40;
#X obj 275 447 nbx 5 18 -1e+37 1e+37 0 0 frequency empty frequency
-8 26 1 12 -233017 -1 -1 0 256;
#X obj 467 447 nbx 5 18 -1e+37 1e+37 0 0 duration empty duration -2
26 1 12 -233017 -1 -1 7960 256;
#X obj 549 24 vsl 22 200 0 150 0 0 master-lvl empty volume -9 -8 1
8 -225271 -1 -1 0 1;
#X obj 63 404 bng 55 250 50 0 trigger empty trigger 0 -9 1 10 -24198
-1 -1;
#X text 72 370 click for one;
#X msg 79 271 stop;
#X obj 44 268 bng 25 250 50 0 empty empty empty 0 -6 0 8 -24198 -1
-1;
#X obj 63 306 metro 1500;
#X obj 192 212 vsl 25 128 30 3000 0 0 empty empty empty 0 -8 1 8 -262131
-1 -1 0 1;
#X text 44 241 click for many;
#X obj 275 423 * 20;
#X text 10 519 (C) Copyright 2004 Hans-Christoph Steiner <hans@at.or.at>
;
#X text 227 533 released under the GNU GPL;
#X text 421 520 $Revision: 1.1 $$Date: 2005-05-05 20:35:48 $;
#X text 422 533 $Author: eighthave $;
#X connect 4 0 16 0;
#X connect 4 1 5 0;
#X connect 5 0 7 0;
#X connect 11 0 13 0;
#X connect 12 0 13 0;
#X connect 13 0 9 0;
#X connect 14 0 13 1;
#X connect 16 0 6 0;