Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

add pd samples

  • Loading branch information...
commit 1d8169dfd7c615532b22cffb6862b7a3d2c0084a 1 parent 7ea4881
@tado authored
View
BIN  week2/pd/.DS_Store
Binary file not shown
View
2  week2/pd/04_params.pd
@@ -1,4 +1,4 @@
-#N canvas 148 22 513 382 10;
+#N canvas 65 22 513 382 10;
#X obj 89 299 output~;
#X obj 89 110 mtof;
#X obj 89 77 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10
View
43 week2/pd/05_additive.pd
@@ -0,0 +1,43 @@
+#N canvas 227 36 554 508 12;
+#X obj 43 397 catch~ sum;
+#X obj 291 215 s frequency;
+#X obj 405 215 s duration;
+#X floatatom 405 165 0 0 0 0 - - -;
+#X obj 405 190 * 100;
+#X obj 291 190 mtof;
+#X floatatom 291 165 0 0 0 0 - - -;
+#X text 329 164 pitch;
+#X obj 43 436 output~;
+#X obj 42 112 partial 1 1 0.56 0;
+#X obj 291 110 loadbang;
+#X msg 291 133 72;
+#X msg 405 135 40;
+#X obj 294 263 bng 25 250 50 0 empty empty empty 0 -6 0 8 -262144 -1
+-1;
+#X text 327 265 <-- click to play a note;
+#X obj 294 299 s trigger;
+#X obj 42 137 partial 0.67 0.9 0.56 1;
+#X obj 42 162 partial 1 0.65 0.92 0;
+#X obj 42 187 partial 1.8 0.55 0.92 1.7;
+#X obj 42 212 partial 2.67 0.325 1.19 0;
+#X obj 42 237 partial 1.67 0.35 1.7 0;
+#X obj 42 262 partial 1.46 0.25 2 0;
+#X obj 42 287 partial 1.33 0.2 2.74 0;
+#X obj 42 312 partial 1.33 0.15 3 0;
+#X obj 42 337 partial 1 0.1 3.76 0;
+#X obj 42 362 partial 1.33 0.075 4.07 0;
+#X text 444 165 duration;
+#X text 39 30 ADDITIVE SYNTHESIS;
+#X text 445 171;
+#X text 40 86 partial amp dur freq dtune;
+#X connect 0 0 8 0;
+#X connect 0 0 8 1;
+#X connect 3 0 4 0;
+#X connect 4 0 2 0;
+#X connect 5 0 1 0;
+#X connect 6 0 5 0;
+#X connect 10 0 11 0;
+#X connect 10 0 12 0;
+#X connect 11 0 6 0;
+#X connect 12 0 3 0;
+#X connect 13 0 15 0;
View
166 week2/pd/06_fm.pd
@@ -0,0 +1,166 @@
+#N canvas 130 47 714 434 10;
+#X obj 100 281 *~;
+#X obj 115 257 line~;
+#X obj 24 213 cos~;
+#X obj 24 188 +~;
+#X obj 115 234 pack 0 50;
+#X floatatom 115 186 0 0 300 0 - - -;
+#X obj 115 210 / 100;
+#X obj 24 163 phasor~;
+#X obj 26 374 output~;
+#X obj 25 343 hip~;
+#N canvas 62 299 558 609 fft 0;
+#X obj 19 61 inlet~;
+#X obj 208 212 inlet;
+#X obj 29 92 rfft~;
+#X obj 29 125 *~;
+#X obj 60 125 *~;
+#X obj 29 155 sqrt~;
+#X obj 332 109 block~ 4096 1;
+#X obj 29 181 biquad~ 0 0 0 0 1;
+#X text 93 93 Fourier series;
+#X text 98 146 magnitude;
+#X text 96 131 calculate;
+#X text 21 3 This subpatch computes the spectrum of the incoming signal
+with a (rectangular windowed) FFT. FFTs aren't properly introduced
+until much later.;
+#X text 83 61 signal to analyze;
+#X text 193 164 delay two samples;
+#X text 191 182 for better graphing;
+#X obj 16 425 samplerate~;
+#X obj 16 402 bng 18 250 50 0 empty empty empty 0 -6 0 8 -262144 -1
+-1;
+#X floatatom 16 472 5 0 0 0 - - -;
+#X obj 16 448 / 256;
+#X obj 16 378 loadbang;
+#X obj 72 494 s fundamental;
+#X text 14 319 At load time \, calculate a good choice of fundamental
+frequency for showing spectra: the 16th bin in a 4096-point spectrum
+\, so SR*16/4096 or SR/256.;
+#X obj 220 257 metro 500;
+#X obj 220 234 inlet;
+#X text 273 232 toggle to graph repeatedly;
+#X text 262 212 bang to graph once;
+#X obj 16 494 t b f;
+#X obj 19 295 tabwrite~ E10-signal;
+#X obj 208 295 tabwrite~ E10-spectrum;
+#X text 72 536 set carrier multiplier and modulation multipliers after
+fundamental;
+#X msg 16 516 \; cm 8 \; m1 2 \; m2 3;
+#X connect 0 0 2 0;
+#X connect 0 0 27 0;
+#X connect 1 0 27 0;
+#X connect 1 0 28 0;
+#X connect 2 0 3 0;
+#X connect 2 0 3 1;
+#X connect 2 1 4 0;
+#X connect 2 1 4 1;
+#X connect 3 0 5 0;
+#X connect 4 0 5 0;
+#X connect 5 0 7 0;
+#X connect 7 0 28 0;
+#X connect 15 0 18 0;
+#X connect 16 0 15 0;
+#X connect 17 0 26 0;
+#X connect 18 0 17 0;
+#X connect 19 0 16 0;
+#X connect 22 0 27 0;
+#X connect 22 0 28 0;
+#X connect 23 0 22 0;
+#X connect 26 0 30 0;
+#X connect 26 1 20 0;
+#X restore 71 345 pd fft;
+#X obj 131 324 bng 18 250 50 0 empty empty empty 0 -6 0 8 -262144 -1
+-1;
+#X obj 131 345 tgl 18 0 empty empty empty 0 -6 0 8 -262144 -1 -1 1
+1;
+#X text 152 344 <-- repeatedly;
+#X text 153 324 <-- graph once;
+#N canvas 0 22 450 300 (subpatch) 0;
+#X array E10-spectrum 259 float 0;
+#X coords 0 2100 258 -20 259 130 1;
+#X restore 365 240 graph;
+#X text 395 371 2;
+#X text 426 371 4;
+#X text 365 371 0;
+#X text 403 386 -- partial number --;
+#X text 459 222 SPECTRUM;
+#X text 625 356 0;
+#X text 626 238 0.5;
+#X obj 99 162 osc~;
+#X obj 273 71 r fundamental;
+#X text 458 371 6;
+#X text 491 371 8;
+#X text 519 371 10;
+#X text 551 371 12;
+#X text 583 371 14;
+#X floatatom 24 92 6 0 15 0 - - -;
+#X obj 24 139 *;
+#X obj 24 67 r cm;
+#X text 29 107 carrier;
+#X obj 99 141 *;
+#X floatatom 99 94 6 0 15 0 - - -;
+#X text 105 108 mod 1;
+#X obj 99 69 r m1;
+#X text 144 188 index1;
+#X obj 203 283 *~;
+#X obj 218 259 line~;
+#X obj 218 236 pack 0 50;
+#X floatatom 218 188 0 0 300 0 - - -;
+#X obj 218 212 / 100;
+#X obj 202 164 osc~;
+#X obj 202 143 *;
+#X floatatom 202 96 6 0 0 0 - - -;
+#X text 208 110 mod 2;
+#X text 252 188 index2;
+#X obj 202 71 r m2;
+#X obj 141 160 r i1;
+#X obj 239 163 r i2;
+#X floatatom 273 94 5 0 0 0 - - -;
+#X obj 273 118 t b f;
+#X text 316 94 fundamental frequency;
+#X text 393 50 preset;
+#X text 25 12 FM SYNTHESIS;
+#X msg 397 71 \; cm 1 \; m1 2 \; m2 3 \; i1 10 \; i2 40 \; fundamental
+80 \;;
+#X msg 519 72 \; cm 1 \; m1 2.4 \; m2 4.9 \; i1 25 \; i2 40 \; fundamental
+50 \;;
+#X connect 0 0 3 1;
+#X connect 1 0 0 1;
+#X connect 2 0 9 0;
+#X connect 2 0 10 0;
+#X connect 3 0 2 0;
+#X connect 4 0 1 0;
+#X connect 5 0 6 0;
+#X connect 6 0 4 0;
+#X connect 7 0 3 0;
+#X connect 9 0 8 0;
+#X connect 9 0 8 1;
+#X connect 11 0 10 1;
+#X connect 12 0 10 2;
+#X connect 23 0 0 0;
+#X connect 24 0 52 0;
+#X connect 30 0 31 0;
+#X connect 31 0 7 0;
+#X connect 32 0 30 0;
+#X connect 34 0 23 0;
+#X connect 35 0 34 0;
+#X connect 37 0 35 0;
+#X connect 39 0 3 1;
+#X connect 40 0 39 1;
+#X connect 41 0 40 0;
+#X connect 42 0 43 0;
+#X connect 43 0 41 0;
+#X connect 44 0 39 0;
+#X connect 45 0 44 0;
+#X connect 46 0 45 0;
+#X connect 49 0 46 0;
+#X connect 50 0 5 0;
+#X connect 51 0 42 0;
+#X connect 52 0 53 0;
+#X connect 53 0 31 0;
+#X connect 53 0 34 0;
+#X connect 53 0 45 0;
+#X connect 53 1 45 1;
+#X connect 53 1 34 1;
+#X connect 53 1 31 1;
View
76 week2/pd/partial.pd
@@ -0,0 +1,76 @@
+#N canvas 18 78 880 448 12;
+#X obj 465 234 sqrt;
+#X text 17 88 trigger;
+#X text 33 175 relative frequency;
+#X obj 17 341 *~;
+#X obj 227 322 line~;
+#X obj 227 349 *~;
+#X obj 227 376 *~;
+#X msg 227 285 0 \$1;
+#X obj 465 261 sqrt;
+#X obj 17 113 r trigger;
+#X obj 465 180 float \$1;
+#X obj 249 235 r duration;
+#X obj 39 226 r frequency;
+#X obj 227 158 t b b;
+#X text 303 209 relative duration;
+#X obj 17 368 throw~ sum;
+#X obj 17 140 bng 15 250 50 0 empty empty empty 0 -6 0 8 -262144 -1
+-1;
+#X msg 465 288 \$1 5;
+#X obj 227 185 del 5;
+#X obj 465 207 * 0.1;
+#X obj 17 279 + \$4;
+#X text 550 178 get amplitude from argument 1;
+#X text 524 206 normalize to 0.1;
+#X text 516 233 take fourth root (square root twice);
+#X text 544 250 because we'll raise line~ output to;
+#X text 543 267 fourth power;
+#X text 515 292 attack time 5 msec;
+#X text 280 184 decay after 5 msec;
+#X text 469 157 attack;
+#X obj 226 211 float \$2;
+#X obj 227 258 *;
+#X text 264 258 actual duration;
+#X obj 17 200 float \$3;
+#X obj 17 252 *;
+#X obj 17 314 osc~;
+#X text 49 252 times global freq.;
+#X text 60 279 plus detune;
+#X text 271 285 decay msg to line~;
+#X text 266 350 raise to fourth power for;
+#X text 267 368 natural-sounding decay shape;
+#X text 20 396 add to global;
+#X text 19 415 summing bus;
+#X text 21 45 This patch is used as an abstraction in the additive
+synthesis example \, D06.additive.pd;
+#X text 25 4 partial -- sinusoidal partial for additive synthesis;
+#X text 631 12 arguments:;
+#X text 605 37 1 amplitude \; 2 relative duration \; 3 relative frequency
+\; 4 detune;
+#X connect 0 0 8 0;
+#X connect 3 0 15 0;
+#X connect 4 0 5 0;
+#X connect 4 0 5 1;
+#X connect 5 0 6 0;
+#X connect 5 0 6 1;
+#X connect 6 0 3 1;
+#X connect 7 0 4 0;
+#X connect 8 0 17 0;
+#X connect 9 0 16 0;
+#X connect 10 0 19 0;
+#X connect 11 0 30 1;
+#X connect 12 0 33 1;
+#X connect 13 0 18 0;
+#X connect 13 1 10 0;
+#X connect 16 0 13 0;
+#X connect 16 0 32 0;
+#X connect 17 0 4 0;
+#X connect 18 0 29 0;
+#X connect 19 0 0 0;
+#X connect 20 0 34 0;
+#X connect 29 0 30 0;
+#X connect 30 0 7 0;
+#X connect 32 0 33 0;
+#X connect 33 0 20 0;
+#X connect 34 0 3 0;
Please sign in to comment.
Something went wrong with that request. Please try again.