diff options
Diffstat (limited to 'pd/doc/7.stuff')
48 files changed, 4740 insertions, 0 deletions
diff --git a/pd/doc/7.stuff/audio-playpen/1_DSP_INTRO.pd b/pd/doc/7.stuff/audio-playpen/1_DSP_INTRO.pd new file mode 100644 index 00000000..17ee73c6 --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/1_DSP_INTRO.pd @@ -0,0 +1,84 @@ +#N canvas 10 10 551 484 10; +#X text 41 3 ABSTRACTIONS IN THIS DIRECTORY; +#X text 117 22 sampler; +#X text 117 36 gain control; +#X text 117 50 ring mod; +#X text 21 142 OTHER OBJECTS YOU WILL NEED; +#X obj 21 171 dac~; +#X text 54 173 output; +#X text 21 156 audio:; +#X obj 21 188 adc~; +#X text 54 187 input; +#X obj 21 205 +~; +#X obj 45 205 -~; +#X obj 21 222 *~; +#X obj 45 222 /~; +#X text 71 215 arithmetic; +#X obj 28 280 bp~; +#X text 56 278 bandpass filter; +#X text 58 293 bandpass with "audio"; +#X text 55 301 control for second input; +#X obj 28 297 vcf~; +#X obj 261 37 metro; +#X text 294 40 repeated message; +#X obj 253 157 float; +#X text 292 156 store numbers; +#X obj 252 398 random; +#X text 298 397 random; +#X obj 253 174 pack; +#X text 292 170 combines numbers; +#X obj 253 191 unpack; +#X text 297 196 opposite; +#X obj 253 208 trigger; +#X text 302 215 control order of execution; +#X text 261 22 TIME; +#X obj 261 54 del; +#X text 294 54 wait then bang; +#X obj 261 71 timer; +#X text 294 68 measure time intervals; +#X text 278 142 GLUE; +#X obj 253 225 select; +#X text 302 229 test values; +#X obj 253 259 moses; +#X text 302 257 parting the waters; +#X obj 253 242 route; +#X text 302 243 heavy select; +#X obj 252 415 line; +#X text 291 412 control ramp generator; +#X obj 23 324 delwrite~; +#X obj 23 341 delread~; +#X obj 23 359 vd~; +#X text 84 323 declare a delay line; +#X text 83 340 read a delay line; +#X text 282 303 UNIT CONVERSION; +#X obj 258 324 mtof; +#X obj 287 324 ftom; +#X obj 258 341 dbtorms; +#X obj 305 341 rmstodb; +#X obj 258 358 dbtopow; +#X obj 305 358 powtodb; +#X text 357 323 frequency to MIDI; +#X text 355 339 db to amplitude; +#X text 356 356 db to power; +#N canvas 0 0 600 400 /SUBPATCH/ 0; +#X restore 64 405 pd; +#X text 100 404 subpatch; +#X obj 64 422 inlet; +#X obj 100 419 inlet~; +#X obj 64 439 outlet; +#X obj 105 436 outlet~; +#X obj 28 246 hip~; +#X text 55 245 high pass filter; +#X obj 28 263 lop~; +#X text 55 263 low pass filter; +#X text 257 101 ARITHMETIC; +#X text 117 64 control-to-signal; +#X text 116 94 delay loop; +#X text 116 108 variable delay loop; +#X obj 41 36 qgain; +#X obj 41 53 qring; +#X obj 41 70 qslew; +#X obj 41 89 qdelay; +#X obj 41 18 qsample ...; +#X obj 42 108 qvd ...; +#X text 50 359 variable time delay read; diff --git a/pd/doc/7.stuff/audio-playpen/2_sampler.pd b/pd/doc/7.stuff/audio-playpen/2_sampler.pd new file mode 100644 index 00000000..327e4116 --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/2_sampler.pd @@ -0,0 +1,33 @@ +#N canvas 8 0 476 273 10; +#X floatatom 108 154; +#X floatatom 282 62; +#X floatatom 244 62; +#X obj 81 127 qsample ---------------; +#X msg 113 60 record; +#X msg 158 60 play; +#X text 184 42 transpose; +#X floatatom 197 60; +#X text 242 47 start; +#X text 280 48 length; +#X obj 81 203 dac~; +#X obj 81 176 qgain; +#X text 139 155 loudnesss; +#X text 225 151 TO USE ME:; +#X text 243 167 turn DSP on (ctrl + "/"); +#X text 244 192 turn loudness to 80 (say); +#X text 244 221 hit "play" button.; +#X obj 81 59 adc~; +#X msg 227 128 read; +#X text 242 179 read a sample; +#X text 244 207 set length to 2000; +#X connect 0 0 11 1; +#X connect 1 0 3 5; +#X connect 2 0 3 4; +#X connect 3 0 11 0; +#X connect 4 0 3 1; +#X connect 5 0 3 2; +#X connect 7 0 3 3; +#X connect 11 0 10 0; +#X connect 11 0 10 1; +#X connect 17 0 3 0; +#X connect 18 0 3 6; diff --git a/pd/doc/7.stuff/audio-playpen/3_filter_and_ring.pd b/pd/doc/7.stuff/audio-playpen/3_filter_and_ring.pd new file mode 100644 index 00000000..a994cc85 --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/3_filter_and_ring.pd @@ -0,0 +1,64 @@ +#N canvas 4 21 576 397 10; +#X floatatom 221 271; +#X floatatom 209 250; +#X floatatom 78 269; +#X floatatom 68 250; +#X floatatom 104 217; +#X floatatom 169 68; +#X floatatom 83 314; +#X floatatom 298 149; +#X floatatom 297 83; +#X obj 61 181 qsample ---------------; +#X msg 101 114 record; +#X msg 169 113 play; +#X text 339 63 transpose; +#X floatatom 297 62; +#X text 339 81 start; +#X text 339 152 length; +#X obj 58 371 dac~; +#X obj 58 334 qgain; +#X text 324 189 read a file; +#X text 335 241 TO USE ME:; +#X text 371 272 turn DSP on (ctrl + "/"); +#X text 370 297 read the sample; +#X text 373 322 turn loudness to 80 (say); +#X text 373 346 hit "play" button.; +#X obj 61 113 adc~; +#X obj 169 90 metro 50; +#X floatatom 212 67; +#X obj 63 213 qring; +#X obj 297 112 loadbang; +#X msg 298 131 2000; +#X obj 59 289 vcf~; +#X obj 200 296 vcf~; +#X text 118 315 amp 1; +#X floatatom 224 317; +#X obj 199 337 qgain; +#X text 259 318 amp 2; +#X msg 292 190 read; +#X connect 0 0 31 2; +#X connect 1 0 31 1; +#X connect 2 0 30 2; +#X connect 3 0 30 1; +#X connect 4 0 27 1; +#X connect 5 0 25 0; +#X connect 6 0 17 1; +#X connect 7 0 9 5; +#X connect 8 0 9 4; +#X connect 9 0 27 0; +#X connect 10 0 9 1; +#X connect 11 0 9 2; +#X connect 13 0 9 3; +#X connect 17 0 16 0; +#X connect 24 0 9 0; +#X connect 25 0 11 0; +#X connect 26 0 25 1; +#X connect 27 0 30 0; +#X connect 27 0 31 0; +#X connect 28 0 29 0; +#X connect 29 0 7 0; +#X connect 30 0 17 0; +#X connect 31 0 34 0; +#X connect 33 0 34 1; +#X connect 34 0 16 1; +#X connect 36 0 9 6; diff --git a/pd/doc/7.stuff/audio-playpen/4_more_filters.pd b/pd/doc/7.stuff/audio-playpen/4_more_filters.pd new file mode 100644 index 00000000..aaa81f34 --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/4_more_filters.pd @@ -0,0 +1,55 @@ +#N canvas 55 0 373 335 10; +#X floatatom 163 156; +#X floatatom 220 175; +#X floatatom 98 154; +#X floatatom 118 221; +#X floatatom 151 33; +#X floatatom 134 266; +#X floatatom 234 99; +#X floatatom 235 75; +#X obj 81 127 qsample ---------------; +#X msg 111 93 record; +#X msg 156 93 play; +#X text 279 49 transpose; +#X floatatom 234 51; +#X text 279 73 start; +#X text 280 97 length; +#X obj 92 292 dac~; +#X obj 94 264 qgain; +#X text 163 269 loudnesss; +#X obj 81 93 adc~; +#X obj 153 60 metro 50; +#X floatatom 194 29; +#X obj 93 243 qring; +#X obj 77 212 vcf~; +#X obj 282 23 random 2000; +#X msg 257 135 read; +#X obj 98 174 qring; +#X floatatom 130 155; +#X obj 163 175 sig~; +#X obj 252 241 env~ 16384; +#X floatatom 258 270; +#X connect 0 0 27 0; +#X connect 1 0 22 2; +#X connect 2 0 25 0; +#X connect 3 0 21 1; +#X connect 4 0 19 0; +#X connect 5 0 16 1; +#X connect 6 0 8 5; +#X connect 7 0 8 4; +#X connect 8 0 22 0; +#X connect 9 0 8 1; +#X connect 10 0 8 2; +#X connect 12 0 8 3; +#X connect 16 0 15 0; +#X connect 16 0 15 1; +#X connect 18 0 8 0; +#X connect 19 0 10 0; +#X connect 20 0 19 1; +#X connect 21 0 16 0; +#X connect 22 0 21 0; +#X connect 24 0 8 6; +#X connect 25 0 22 1; +#X connect 26 0 25 1; +#X connect 27 0 22 1; +#X connect 28 0 29 0; diff --git a/pd/doc/7.stuff/audio-playpen/5_delay.pd b/pd/doc/7.stuff/audio-playpen/5_delay.pd new file mode 100644 index 00000000..63006b8d --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/5_delay.pd @@ -0,0 +1,55 @@ +#N canvas 34 147 523 368 10; +#X floatatom 58 216; +#X obj 7 235 qgain; +#X floatatom 150 176; +#X floatatom 146 151; +#X floatatom 151 33; +#X floatatom 148 220; +#X floatatom 234 99; +#X floatatom 235 75; +#X obj 84 123 qsample ---------------; +#X msg 111 93 record; +#X msg 156 93 play; +#X text 279 49 transpose; +#X floatatom 234 51; +#X text 279 73 start; +#X text 280 97 length; +#X obj 23 272 dac~; +#X obj 97 239 qgain; +#X text 261 220 TO USE ME:; +#X text 279 236 turn DSP on (ctrl + "/"); +#X text 279 248 read the sample; +#X text 280 261 turn loudness to 80 (say); +#X text 280 273 hit "play" button.; +#X obj 81 93 adc~; +#X obj 153 60 metro 50; +#X floatatom 203 29; +#X obj 96 199 qdelay; +#X text 47 188 direct; +#X text 49 201 gain; +#X text 179 220 delay gain; +#X text 173 152 delay time; +#X text 177 176 recirculation (0-100); +#X text 255 294 the direct signal comes out; +#X text 255 304 channel 1 and the delays out; +#X text 255 315 channel 2; +#X msg 257 135 read; +#X connect 0 0 1 1; +#X connect 1 0 15 0; +#X connect 2 0 25 2; +#X connect 3 0 25 1; +#X connect 4 0 23 0; +#X connect 5 0 16 1; +#X connect 6 0 8 5; +#X connect 7 0 8 4; +#X connect 8 0 1 0; +#X connect 8 0 25 0; +#X connect 9 0 8 1; +#X connect 10 0 8 2; +#X connect 12 0 8 3; +#X connect 16 0 15 1; +#X connect 22 0 8 0; +#X connect 23 0 10 0; +#X connect 24 0 23 1; +#X connect 25 0 16 0; +#X connect 34 0 8 6; diff --git a/pd/doc/7.stuff/audio-playpen/6_flanger.pd b/pd/doc/7.stuff/audio-playpen/6_flanger.pd new file mode 100644 index 00000000..cf927c32 --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/6_flanger.pd @@ -0,0 +1,71 @@ +#N canvas 42 0 531 395 10; +#X floatatom 301 189; +#X floatatom 237 154; +#X floatatom 59 241; +#X obj 8 260 qgain; +#X floatatom 147 223; +#X floatatom 118 148; +#X floatatom 151 33; +#X floatatom 149 244; +#X floatatom 273 87; +#X floatatom 330 85; +#X obj 84 123 qsample ---------------; +#X msg 111 93 record; +#X msg 156 93 play; +#X text 192 72 transpose; +#X floatatom 193 86; +#X text 374 83 start; +#X text 268 73 length; +#X obj 24 297 dac~; +#X obj 98 263 qgain; +#X obj 81 93 adc~; +#X obj 153 60 metro 50; +#X floatatom 202 41; +#X text 48 213 direct; +#X text 50 225 gain; +#X text 180 244 delay gain; +#X text 156 147 delay time; +#X text 173 223 recirculation (0-100); +#X obj 97 223 qvd; +#X obj 116 170 qslew; +#X obj 237 190 qring; +#X obj 237 172 sig~; +#X text 266 154 osc depth; +#X text 327 188 osc speed; +#X obj 202 23 r metro-time; +#X msg 385 191 \; metro-on 0 \; metro-time 100; +#X obj 152 7 r metro-on; +#X msg 384 234 \; metro-on 1 \; metro-time 50; +#X obj 329 37 r start-time; +#X obj 330 61 line; +#X msg 374 280 \; start-time 0; +#X msg 288 317 \; start-time 0 \, 2000 10000; +#X msg 289 131 read; +#X connect 0 0 29 1; +#X connect 1 0 30 0; +#X connect 2 0 3 1; +#X connect 3 0 17 0; +#X connect 4 0 27 2; +#X connect 5 0 28 0; +#X connect 6 0 20 0; +#X connect 7 0 18 1; +#X connect 8 0 10 5; +#X connect 9 0 10 4; +#X connect 10 0 3 0; +#X connect 10 0 27 0; +#X connect 11 0 10 1; +#X connect 12 0 10 2; +#X connect 14 0 10 3; +#X connect 18 0 17 0; +#X connect 19 0 10 0; +#X connect 20 0 12 0; +#X connect 21 0 20 1; +#X connect 27 0 18 0; +#X connect 28 0 27 1; +#X connect 29 0 27 1; +#X connect 30 0 29 0; +#X connect 33 0 21 0; +#X connect 35 0 6 0; +#X connect 37 0 38 0; +#X connect 38 0 9 0; +#X connect 41 0 10 6; diff --git a/pd/doc/7.stuff/audio-playpen/README.txt b/pd/doc/7.stuff/audio-playpen/README.txt new file mode 100644 index 00000000..e6a94951 --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/README.txt @@ -0,0 +1,9 @@ +The "audio playpen" is intended as a collection of analog-style modules +for people who just want to patch stuff together without worrying much +about how Pd works. A fair amount of work would be needed to make this into +a more usable package than it is now. At the moment it's unclear what +should be the relationship between this collection, the "examples," and +the "tools". + +At the very least there should be oscillators and envelope generators here, +and audio-rate db/rms/dB, mtof, ftom conversion... diff --git a/pd/doc/7.stuff/audio-playpen/qdelay.pd b/pd/doc/7.stuff/audio-playpen/qdelay.pd new file mode 100644 index 00000000..c22edc3a --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/qdelay.pd @@ -0,0 +1,34 @@ +#N canvas 94 85 429 238 10; +#X floatatom 252 62; +#X obj 252 153 line~; +#X obj 252 134 pack 0 100; +#X obj 232 180 *~; +#X obj 252 44 inlet; +#X obj 106 52 inlet; +#X obj 26 78 inlet~; +#X floatatom 106 70; +#X obj 22 176 outlet~; +#X text 20 61 audio in; +#X text 22 193 audio out; +#X text 220 11 recirculation; +#X text 92 23 delay time; +#X obj 106 88 delread~ qdelay1; +#X obj 120 210 delwrite~ qdelay1 2000; +#X obj 252 116 * 0.01; +#X text 228 27 (0-100); +#X text 100 35 (msec); +#X obj 252 80 max 0; +#X obj 252 98 min 100; +#X connect 0 0 18 0; +#X connect 1 0 3 1; +#X connect 2 0 1 0; +#X connect 3 0 14 0; +#X connect 4 0 0 0; +#X connect 5 0 7 0; +#X connect 6 0 14 0; +#X connect 7 0 13 0; +#X connect 13 0 3 0; +#X connect 13 0 8 0; +#X connect 15 0 2 0; +#X connect 18 0 19 0; +#X connect 19 0 15 0; diff --git a/pd/doc/7.stuff/audio-playpen/qgain.pd b/pd/doc/7.stuff/audio-playpen/qgain.pd new file mode 100644 index 00000000..20f228e8 --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/qgain.pd @@ -0,0 +1,14 @@ +#N canvas 236 128 179 191 10; +#X obj 89 112 line~; +#X obj 89 93 pack 0 100; +#X obj 89 55 inlet; +#X obj 89 74 dbtorms; +#X obj 30 67 inlet~; +#X obj 30 118 outlet~; +#X obj 30 86 *~; +#X connect 0 0 6 1; +#X connect 1 0 0 0; +#X connect 2 0 3 0; +#X connect 3 0 1 0; +#X connect 4 0 6 0; +#X connect 6 0 5 0; diff --git a/pd/doc/7.stuff/audio-playpen/qring.pd b/pd/doc/7.stuff/audio-playpen/qring.pd new file mode 100644 index 00000000..25b99c2e --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/qring.pd @@ -0,0 +1,14 @@ +#N canvas 163 135 216 211 10; +#X obj 112 91 inlet; +#X obj 54 93 inlet~; +#X obj 55 117 *~; +#X obj 54 142 outlet~; +#X text 54 76 audio in; +#X text 49 173 audio out; +#X text 117 59 modulation; +#X text 117 72 frequency; +#X obj 112 112 osc~; +#X connect 0 0 8 0; +#X connect 1 0 2 0; +#X connect 2 0 3 0; +#X connect 8 0 2 1; diff --git a/pd/doc/7.stuff/audio-playpen/qsample.pd b/pd/doc/7.stuff/audio-playpen/qsample.pd new file mode 100644 index 00000000..bc4ebb2f --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/qsample.pd @@ -0,0 +1,114 @@ +#N canvas 0 9 731 358 10; +#X obj 483 52 inlet; +#X obj 386 66 inlet; +#X obj 314 78 inlet; +#X obj 223 42 inlet; +#X obj 152 63 inlet; +#X obj 75 38 inlet; +#X obj 19 48 inlet~; +#X text 11 33 audio in; +#X msg 250 268 0 5; +#X floatatom 299 217; +#X floatatom 386 87; +#X floatatom 223 60; +#X msg 152 81 bang; +#X text 152 47 button; +#X obj 39 354 outlet~; +#X graph sample1-graph 0 -1 88200 1 404 352 704 202; +#X array sample1 88200 float; +#X pop; +#X obj 19 91 tabwrite~ sample1; +#X msg 75 56 bang; +#X text 74 12 record; +#X text 75 22 button; +#X text 157 33 play; +#X obj 39 299 tabread4~ sample1; +#X obj 39 317 *~; +#X obj 174 313 line~; +#X obj 39 335 hip~ 5; +#X obj 199 235 del 5; +#X msg 169 266 0 5; +#X msg 199 266 1 5; +#X floatatom 316 116; +#X text 211 22 transpose; +#X obj 223 78 mtof; +#X text 386 50 length; +#X obj 223 96 t b f; +#X obj 223 114 8.1758; +#X obj 223 132 /; +#X obj 299 143 t b f; +#X obj 250 250 del 2000; +#X obj 299 179 * 1980; +#X obj 299 161 f 1; +#X text 304 52 beginning; +#X text 314 62 point; +#X obj 39 281 line~; +#X obj 73 205 f; +#X obj 22 243 + 88200; +#X obj 22 261 pack; +#X obj 110 261 * 2000; +#X text 482 26 read; +#X text 483 38 file; +#X obj 73 223 t f f b; +#X floatatom 110 280; +#X obj 110 243 f 1; +#X obj 89 182 * 44.1; +#X obj 483 91 openpanel; +#X msg 483 73 bang; +#X obj 386 110 min 1980; +#X obj 315 96 max 1; +#X obj 484 133 soundfiler; +#X msg 485 114 read \$1 sample1; +#X obj 299 198 max 6; +#X connect 0 0 53 0; +#X connect 1 0 10 0; +#X connect 2 0 55 0; +#X connect 3 0 11 0; +#X connect 4 0 12 0; +#X connect 5 0 17 0; +#X connect 6 0 16 0; +#X connect 8 0 23 0; +#X connect 9 0 36 1; +#X connect 10 0 54 0; +#X connect 11 0 30 0; +#X connect 12 0 26 0; +#X connect 12 0 25 0; +#X connect 12 0 36 0; +#X connect 17 0 16 0; +#X connect 21 0 22 0; +#X connect 22 0 24 0; +#X connect 23 0 22 1; +#X connect 24 0 14 0; +#X connect 25 0 27 0; +#X connect 25 0 42 0; +#X connect 26 0 23 0; +#X connect 27 0 23 0; +#X connect 28 0 51 0; +#X connect 30 0 32 0; +#X connect 32 0 33 0; +#X connect 32 1 34 1; +#X connect 33 0 34 0; +#X connect 34 0 38 0; +#X connect 34 0 50 1; +#X connect 35 0 38 0; +#X connect 35 1 37 1; +#X connect 36 0 8 0; +#X connect 37 0 58 0; +#X connect 38 0 37 0; +#X connect 41 0 21 0; +#X connect 42 0 48 0; +#X connect 43 0 44 0; +#X connect 44 0 41 0; +#X connect 45 0 44 1; +#X connect 45 0 49 0; +#X connect 48 0 43 0; +#X connect 48 1 41 0; +#X connect 48 2 50 0; +#X connect 50 0 45 0; +#X connect 51 0 42 1; +#X connect 52 0 57 0; +#X connect 53 0 52 0; +#X connect 54 0 35 0; +#X connect 55 0 28 0; +#X connect 57 0 56 0; +#X connect 58 0 9 0; diff --git a/pd/doc/7.stuff/audio-playpen/qslew.pd b/pd/doc/7.stuff/audio-playpen/qslew.pd new file mode 100644 index 00000000..d56bb90f --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/qslew.pd @@ -0,0 +1,8 @@ +#N canvas 236 128 164 154 10; +#X obj 47 79 line~; +#X obj 47 58 pack 0 100; +#X obj 47 38 inlet; +#X obj 47 100 outlet~; +#X connect 0 0 3 0; +#X connect 1 0 0 0; +#X connect 2 0 1 0; diff --git a/pd/doc/7.stuff/audio-playpen/qvd.pd b/pd/doc/7.stuff/audio-playpen/qvd.pd new file mode 100644 index 00000000..8a03d9c3 --- /dev/null +++ b/pd/doc/7.stuff/audio-playpen/qvd.pd @@ -0,0 +1,32 @@ +#N canvas 78 104 411 254 10; +#X obj 246 47 inlet; +#X floatatom 246 66; +#X obj 245 162 line~; +#X obj 245 143 pack 0 100; +#X obj 232 180 *~; +#X obj 104 66 inlet~; +#X obj 22 175 outlet~; +#X text 19 60 audio in; +#X text 18 193 audio out; +#X text 213 7 recirculation; +#X text 92 25 delay time; +#X obj 246 125 * 0.01; +#X text 212 23 (0-100); +#X text 100 37 (msec); +#X obj 105 94 vd~ qdel2; +#X obj 120 210 delwrite~ qdel2 2000; +#X obj 20 75 inlet~; +#X obj 246 84 max 0; +#X obj 246 104 min 100; +#X connect 0 0 1 0; +#X connect 1 0 17 0; +#X connect 2 0 4 1; +#X connect 3 0 2 0; +#X connect 4 0 15 0; +#X connect 5 0 14 0; +#X connect 11 0 3 0; +#X connect 14 0 4 0; +#X connect 14 0 6 0; +#X connect 16 0 15 0; +#X connect 17 0 18 0; +#X connect 18 0 11 0; diff --git a/pd/doc/7.stuff/data-structures/0.intro.txt b/pd/doc/7.stuff/data-structures/0.intro.txt new file mode 100644 index 00000000..a1df9a88 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/0.intro.txt @@ -0,0 +1,113 @@ +Pd release 0.23 and onward include objects for managing lists of data. The +objects allow you to describe data structures and how they are viewed +("template objects") and to traverse lists ("traversal objects.") + +The rest of this file gives a highly condensed summary of what's there; the +patches, starting with "1.scalars.pd", act as a tutorial. + +1. TEMPLATE OBJECTS. + +templates describe data structures. You can add an item to a data structure +using "field" or ask for a shape to be drawn using a "display command." + +1.1. "template" -- data structure. + +usage, "template <field1> <field2> ..." + +where the fields are either "float <name>", "symbol <name>", "list <name>" +(don't try that yet); or "array <name> <template-for-elements>. + +1.2. DISPLAY COMMANDS. + + +These are objects which ask Pd to draw a shape corresponding to some fields +of the datum. + +1.2.1. POLYGONS and CURVES. + +polygons: polygon <outline-color> <line-width> <x, y> ... +filled polygons: fpolygon <fill-color> <outline-color> <line-width> <x, y> ... +curves: curve <outline-color> <line-width> <x, y> ... +filled curves: fcurve <fill-color> <outline-color> <line-width> <x, y> ... + +Each argument can either be a number or a symbol. If a symbol, it's the +name of a field (which must be a "float) which specifies the vaiue. +So for instance in the "1.scalar.pd" example, in the template "template1", +the object "fpolygon 244 q 5 0 0 20 z 40 0" draws a filled polygon whose +interior color is 244 (red 2, green 4, blue 4) but whose outline color +depends on the value of the field "q". Its coordinates describe a triangle +whose altitude is given by "z." + +1.2.2 PLOT. + +The "plot" objects plots an array field as shown in 5_array.pd. + +2. TRAVERSAL. + +In this release of Pd, you can only traverse lists all of whose elements +belong to the same template; this restriction will be relaxed in a future +release. You "traverse" a list either to build it, to get its elements, +or to change their values. + +2.1. POINTER. + +The "pointer" object can be used to refer to an element of a list. Its +methods are: + +2.1.1. traverse <symbol>. + +Point to the "head" of a list. The symbol should match the name of a Pd +window holding the list. The pointer is output, but you can't set or get the +fields of the "head" pointer; you can only get the "next" element or "append" +to the list. + +2.1.2. next. Goes to the next element of the list. Either the pointer +is output on the left side, or else a "bang" at right tells you that no +more objects are forthcoming. + +2.1.3. bang. +outputs the current pointer. + +2.2. APPEND. Adds an element of the specified template to the list. You +specify what fields you want to supply and the last inlet takes a pointer to +the element you want to "append" after. + +2.3. GET. + + get <template> <field...> + +send it a pointer to an object belonging to the <template> and it outputs +the (floating-point) fields. + +2.4. SET. + + set <template> <field...> + +send it a pointer (at the rightmost inlet) and values for the specified +fields, and their values are changed accordingly. + +2.5. GETSIZE. + + getsize <template> <array-field> + +outputs the size of the named field, which must be an array, when it receives +a pointer to the owner as input. + +2.6. SETSIZE. + + setsize <template> <array-field> + +Send it a pointer to the owner (right inlet) and then the desired size +(left inlet) and the array is resized. If a template contains an array, +each scalar belonging to the template can have its own size for the array. + +2.7. ELEMENT. + + element <template> <array-field> + +Pass it an index and a pointer and it outputs a pointer to an element of the +array. + + + + diff --git a/pd/doc/7.stuff/data-structures/1.scalars.pd b/pd/doc/7.stuff/data-structures/1.scalars.pd new file mode 100644 index 00000000..c2c465bf --- /dev/null +++ b/pd/doc/7.stuff/data-structures/1.scalars.pd @@ -0,0 +1,60 @@ +#N canvas 363 11 579 461 12; +#N canvas 13 22 297 180 data 1; +#X restore 60 347 pd data; +#N canvas 10 274 550 324 template1 1; +#X obj 60 46 filledpolygon 244 q 5 0 0 20 z 40 0; +#X obj 60 21 template float x float y float z float q; +#X text 3 67 This subpatch acts as a template which describes the data +structure. The "template" specifies four floating point values named +x \, y \, z \, and q. The "filledpolygon" is a drawing instruction. +Templates should have only one template object but may have any number +of drawing instructions.; +#X text 4 164 The filledpolygon's arguments are interior color \, border +color \, border width \, and then the points of the polygon. Arguments +which are symbols ("q" and "z" in this case) mean to take the values +from the data structure. Other values are constant. The position of +the object is automatically controlled by fields named "x" and "y". +; +#X restore 60 371 pd template1; +#N canvas 0 0 440 292 stuff 0; +#X obj 235 185 pointer; +#X obj 28 187 append template1 x y z q; +#X msg 235 127 \; pd-data clear; +#X msg 235 163 traverse pd-data \, bang; +#X obj 125 128 t b b b; +#X msg 125 87 bang; +#X obj 125 56 loadbang; +#X text 159 87 click here to re-initialize; +#X text 25 243 This subpatch sets up the "data" window with two objects. +How this works will get explained later.; +#X msg 28 164 50 100 30 9 \, 150 100 -20 900; +#X connect 0 0 1 4; +#X connect 3 0 0 0; +#X connect 4 0 9 0; +#X connect 4 1 3 0; +#X connect 4 2 2 0; +#X connect 5 0 4 0; +#X connect 6 0 5 0; +#X connect 9 0 1 0; +#X restore 59 397 pd stuff; +#X text 37 72 The positions \, border color \, and altitude of each +triangle are numeric values which can control \, or be controlled by +\, other elements of the patch.; +#X text 37 124 When the data window is locked (not in edit mode) you +can drag the apex of either triangle up or down to change the altitude +(you should see the cursor change with dragging is meaningful.) In +edit (unlocked) mode \, you can move teh entire triangles around \, +or cut \, copy \, and paste them.; +#X text 47 325 subpatches:; +#X text 37 281 Data is not persistent. If you save a Pd patch and reopen +it \, the "data" isn't preserved.; +#X text 37 5 This patch shows a simple data window with two objects +in it. The objects' data structures and appearances are defined by +the "template1" subpatch. This kind of object is called a "scalar." +; +#X text 37 207 Scalars are described by "templates" \, which are subwindows. +The subwindows are found by their name \, in this case "template1." +The template describes what form the data take and how it is shown. +It's possible to mix data of many different templates in the same collection. +; +#X text 294 398 updated for Pd version 0.35.; diff --git a/pd/doc/7.stuff/data-structures/2.getting.data.pd b/pd/doc/7.stuff/data-structures/2.getting.data.pd new file mode 100644 index 00000000..bebd7371 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/2.getting.data.pd @@ -0,0 +1,73 @@ +#N canvas 363 11 630 603 12; +#X text 311 559 updated for Pd version 0.32.; +#N canvas 42 312 598 266 stuff 0; +#X obj 353 159 pointer; +#X obj 117 103 t b b b; +#X msg 117 62 bang; +#X obj 117 31 loadbang; +#X text 151 62 click here to re-initialize; +#X text 126 206 Explained later...; +#X msg 20 139 50 250 30 9 \, 200 200 -20 900 \, 100 200 -50 30; +#X obj 20 162 append template2 x y z q; +#X msg 353 101 \; pd-data2 clear; +#X msg 353 137 traverse pd-data2 \, bang; +#X connect 0 0 7 4; +#X connect 1 0 6 0; +#X connect 1 1 9 0; +#X connect 1 2 8 0; +#X connect 2 0 1 0; +#X connect 3 0 2 0; +#X connect 6 0 7 0; +#X connect 9 0 0 0; +#X restore 506 310 pd stuff; +#X text 506 242 subpatches:; +#X obj 15 303 pointer; +#X msg 27 271 next; +#X text 75 301 <- object that outputs pointers to scalars; +#N canvas 13 22 345 271 data2 1; +#X restore 506 265 pd data2; +#N canvas 15 278 427 138 template2 0; +#X obj 60 46 filledpolygon 244 q 5 0 0 20 z 40 0; +#X obj 60 21 template float x float y float z float q; +#X text 13 79 The template for the two scalars \, as in the last patch +; +#X restore 506 288 pd template2; +#X obj 15 355 get template2 x y z q; +#X floatatom 15 384 5 0 0; +#X floatatom 76 384 5 0 0; +#X floatatom 137 384 5 0 0; +#X floatatom 199 385 5 0 0; +#X msg 15 246 traverse pd-data2; +#X obj 59 330 print; +#X text 100 330 <- this gets a bang when we reach the end; +#X text 211 353 <- this takes incoming pointers; +#X text 214 367 and outputs the values of x \, y \, z \, and q.; +#X text 172 245 <- go to head of list (click first); +#X text 68 273 <- output next item (click 4 times); +#X text 14 5 The simplest thing you can do with a collection of scalars +(a list) is to traverse it \, getting the numbers back out. This is +done using two objects \, "pointer" which does the traversal \, and +"get" which \, given a pointer to a scalar \, extracts numeric quantities +from it.; +#X text 14 85 You can send the "pointer" object a "traverse" message +to point it to the head of the list. The argument "pd-data2" indicates +the Pd window named "data2." The head of the list means \, not the +first scalar in the list \, but the position before the first scalar +\, which is a valid pointer in Pd but has no data or template.; +#X text 14 180 The "next" message tells the "pointer" object to go +to the next scalar in the list and output it. If there are no more +\, "pointer" outputs a bang at right.; +#X text 19 424 The "get" object takes a pointer \, checks that its +template agrees with what "get" is expecting \, i.e. \, "template2" +\, and if so outputs the values of x \, y \, z \, and q in the usual +reverse order.; +#X text 18 492 The pointer sent from "pointer" to "get" is an elementary +Pd type on a level with "float" and "symbol".; +#X connect 3 0 8 0; +#X connect 3 1 14 0; +#X connect 4 0 3 0; +#X connect 8 0 9 0; +#X connect 8 1 10 0; +#X connect 8 2 11 0; +#X connect 8 3 12 0; +#X connect 13 0 3 0; diff --git a/pd/doc/7.stuff/data-structures/3.setting.data.pd b/pd/doc/7.stuff/data-structures/3.setting.data.pd new file mode 100644 index 00000000..d951a0a8 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/3.setting.data.pd @@ -0,0 +1,105 @@ +#N canvas 401 39 490 472 12; +#X floatatom 60 371 0 0 0; +#X floatatom 60 323 0 0 0; +#X floatatom 60 275 0 0 0; +#X floatatom 60 227 0 0 0; +#X floatatom 324 322 0 0 0; +#X floatatom 283 322 0 0 0; +#X floatatom 240 322 0 0 0; +#X obj 197 274 pointer; +#X msg 205 249 next; +#X floatatom 197 322 0 0 0; +#N canvas 19 29 363 341 data3 1; +#X restore 269 425 pd data3; +#N canvas 100 436 466 223 template3 0; +#X obj 25 68 filledpolygon q 0 1 0 0 w 0 w h 0 h; +#X obj 26 163 drawnumber q 0 0 0; +#X obj 24 19 template float x float y float w float h float q; +#X text 22 39 five numeric ("float") fields; +#X text 25 88 drawing a rectangle \, interior color q \, border black and one unit thick \, through the points (0 \, 0) \, (w \, 0) \, (w \, h) \, and (0 \, h). Note that the three points containing variables become hot spots for mouse dragging.; +#X text 26 184 Draw the value of q as an Araboc numeral \, at (0 \, 0) \, in black.; +#X restore 269 446 pd template3; +#N canvas 313 223 587 367 stuff 0; +#X obj 352 180 pointer; +#X obj 352 204 t b b p; +#X obj 222 333 append template3 x y w h q; +#X obj 288 9 loadbang; +#X obj 288 62 t b b b; +#X msg 331 138 traverse pd-data3; +#X msg 477 136 \; pd-data3 clear; +#X msg 240 110 0; +#X obj 187 136 f; +#X obj 220 136 + 1; +#X obj 189 112 until; +#X obj 201 159 sel 20; +#X obj 251 159 t b; +#X msg 290 32 bang; +#X obj 25 237 random 300; +#X obj 100 237 random 300; +#X obj 323 236 random 1000; +#X obj 177 237 random 80; +#X obj 252 237 random 80; +#X obj 101 263 - 30; +#X obj 354 11 inlet; +#X connect 0 0 1 0; +#X connect 1 0 14 0; +#X connect 1 1 15 0; +#X connect 1 1 16 0; +#X connect 1 1 17 0; +#X connect 1 1 18 0; +#X connect 1 2 2 5; +#X connect 3 0 13 0; +#X connect 4 0 10 0; +#X connect 4 1 5 0; +#X connect 4 1 7 0; +#X connect 4 2 6 0; +#X connect 5 0 0 0; +#X connect 7 0 8 1; +#X connect 8 0 11 0; +#X connect 8 0 9 0; +#X connect 9 0 8 1; +#X connect 10 0 8 0; +#X connect 11 0 10 1; +#X connect 11 1 12 0; +#X connect 12 0 0 0; +#X connect 13 0 4 0; +#X connect 14 0 2 0; +#X connect 15 0 19 0; +#X connect 16 0 2 4; +#X connect 17 0 2 2; +#X connect 18 0 2 3; +#X connect 19 0 2 1; +#X connect 20 0 13 0; +#X restore 269 404 pd stuff; +#X msg 269 379 remake; +#X obj 197 298 get template3 x y w h q; +#X floatatom 356 322 0 0 0; +#X obj 60 251 set template3 x; +#X obj 60 299 set template3 y; +#X obj 60 347 set template3 w; +#X obj 60 394 set template3 h; +#X floatatom 60 418 0 0 0; +#X obj 60 441 set template3 q; +#X msg 197 226 traverse pd-data3; +#X text 46 5 The "set" object allows you to change numeric values. In this example \, the template specifies five fields describing the (x \, y) location \, width \, height \, and color. A new feature is that the color is also getting printed out under the rectangles. This is done using the "drawnumber" object in the template.; +#X text 323 378 <- click to randomize; +#X text 46 87 Getting parameter values is as inthe previous patch \; however \, as you traverse the list with "next" messages the new pointers are also sent to the five "set" objects. These have as arguments the template name and the name of the field they will set. You can drag on the five number boxes (after selecting an object with "traverse" and "next" messages) to change its location \, shape \, and color.; +#X connect 0 0 19 0; +#X connect 1 0 18 0; +#X connect 2 0 17 0; +#X connect 3 0 16 0; +#X connect 7 0 14 0; +#X connect 7 0 16 1; +#X connect 7 0 17 1; +#X connect 7 0 18 1; +#X connect 7 0 19 1; +#X connect 7 0 21 1; +#X connect 8 0 7 0; +#X connect 13 0 12 0; +#X connect 14 0 9 0; +#X connect 14 1 6 0; +#X connect 14 2 5 0; +#X connect 14 3 4 0; +#X connect 14 4 15 0; +#X connect 20 0 21 0; +#X connect 22 0 7 0; diff --git a/pd/doc/7.stuff/data-structures/4.append.pd b/pd/doc/7.stuff/data-structures/4.append.pd new file mode 100644 index 00000000..2c1991d9 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/4.append.pd @@ -0,0 +1,36 @@ +#N canvas 308 71 688 415 12; +#X obj 421 332 pointer; +#X obj 108 277 t b b b; +#X msg 120 241 bang; +#X text 161 240 click here to re-initialize; +#X msg 11 313 50 250 30 9 \, 200 200 -20 900 \, 100 200 -50 30; +#X text 56 27 The objects below put three items in the data window. +First the window is cleared. Then a "pointer" object is instructed +to point to the beginning of the data window ("traverse pd-data") \, +and to output its value ("bang") to the "append" object. This object +is then given numeric values to create three items.; +#X obj 11 336 append template4 x y z q; +#X msg 421 269 \; pd-data4 clear; +#N canvas 0 0 318 188 data4 1; +#X restore 430 219 pd data4; +#N canvas 15 278 427 138 template4 0; +#X obj 60 46 filledpolygon 244 q 5 0 0 20 z 40 0; +#X obj 60 21 template float x float y float z float q; +#X text 13 79 The template for the two scalars \, as in the last patch +; +#X restore 428 243 pd template4; +#X msg 421 309 traverse pd-data4 \, bang; +#X text 57 165 The outlet of "append" is a pointer to the newly created +scalar. You can pass that on to other append objects if you want to +build heterogenous lists.; +#X text 363 375 Updated for Pd version 0.32; +#X text 57 121 The "append" object is given the argument "template4" +to specify what kind of data structure to append. The other arguments +are the names of variables we'll set.; +#X connect 0 0 6 4; +#X connect 1 0 4 0; +#X connect 1 1 10 0; +#X connect 1 2 7 0; +#X connect 2 0 1 0; +#X connect 4 0 6 0; +#X connect 10 0 0 0; diff --git a/pd/doc/7.stuff/data-structures/5.array.pd b/pd/doc/7.stuff/data-structures/5.array.pd new file mode 100644 index 00000000..9c1996a7 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/5.array.pd @@ -0,0 +1,112 @@ +#N canvas 67 294 709 456 12; +#X obj 235 323 pointer; +#X floatatom 232 183 0 0 0; +#X msg 235 300 bang; +#X floatatom 15 200 0 0 0; +#X floatatom 17 350 0 0 0; +#X floatatom 235 369 0 0 0; +#X floatatom 451 276 0 0 0; +#X obj 451 229 pointer; +#X obj 318 163 pointer; +#X msg 449 194 bang; +#N canvas 0 0 384 196 data5 1; +#X restore 508 314 pd data5; +#N canvas 5 272 431 226 template5 0; +#X obj 8 91 filledpolygon 244 q 3 0 0 20 z 40 0; +#X obj 6 8 template float x float y float z float q array bazoo template5-element +; +#X obj 8 113 plot bazoo 700 3 30 10 4; +#X text 6 44 this declares an array named "bazoo" whose elements are +described by "template5-element." Array declarations take three arguments +while "float" declarations take only two.; +#X text 6 136 Here we ask to plot the array \, color 700 \, line width +3 \, starting location (30 \, 10) relative to the scalar \, points +spaced 4 apart.; +#X text 7 186 You can also do (x \, y) plots and/or make the line thickness +variable---see the help window for "plot".; +#X restore 508 337 pd template5; +#N canvas 65 248 442 101 template5-element 0; +#X obj 35 11 template float y; +#X text 12 36 This says that array elements will have a single floating-point +number named "y". The variable name "y" is automatically assumed to +control screen height \; if you don't have at least that variable you +can't plot the array..; +#X restore 508 360 pd template5-element; +#N canvas 515 84 589 429 stuff 0; +#X obj 354 163 pointer; +#X obj 136 102 t b b b; +#X msg 136 61 bang; +#X text 170 61 click here to re-initialize; +#X obj 134 163 append template5 x y z q; +#X msg 354 100 \; pd-data5 clear; +#X msg 354 140 traverse pd-data5 \, bang; +#X msg 283 280 50; +#X obj 284 307 setsize template5 bazoo; +#X obj 137 23 loadbang; +#X msg 134 140 50 150 30 9; +#X obj 134 191 t b b p; +#X floatatom 68 327 0 0 0; +#X floatatom 14 332 0 0 0; +#X obj 14 376 set template5-element y; +#X obj 68 350 element template5 bazoo; +#X obj 20 303 unpack; +#X msg 12 258 3 5 \, 7 9 \, -30 10 \, 43 45; +#X connect 0 0 4 4; +#X connect 1 0 10 0; +#X connect 1 1 6 0; +#X connect 1 2 5 0; +#X connect 2 0 1 0; +#X connect 4 0 11 0; +#X connect 6 0 0 0; +#X connect 7 0 8 0; +#X connect 9 0 2 0; +#X connect 10 0 4 0; +#X connect 11 0 17 0; +#X connect 11 1 7 0; +#X connect 11 2 8 1; +#X connect 11 2 15 1; +#X connect 12 0 15 0; +#X connect 13 0 14 0; +#X connect 15 0 14 1; +#X connect 16 0 13 0; +#X connect 16 1 12 0; +#X connect 17 0 16 0; +#X restore 508 383 pd stuff; +#X msg 318 140 traverse pd-data5 \, next; +#X obj 451 252 getsize template5 bazoo; +#X obj 232 229 setsize template5 bazoo; +#X obj 17 373 set template5-element y; +#X obj 235 346 get template5-element y; +#X obj 15 223 element template5 bazoo; +#X text 38 15 Scalars may contain arrays \, and moreover the elements +of an array can be of any scalar type (and can have sub-arrays recursively.) +The type of the element of an array is fixed in the template. In this +case \, "template5" contains the definition of the top-level scalar +and "template5-element" is the template of each array element (see +the template subpatch.); +#X text 328 121 click to get pointer; +#X text 449 173 get size; +#X text 221 158 set size; +#X text 16 133 select an individual; +#X text 16 153 element \, which is a; +#X text 14 169 scalar with template; +#X text 104 189 template5; +#X text 12 413 work as before \, but on; +#X text 12 433 array elements...; +#X text 433 424 Updated for Pd version 0.35; +#X text 17 395 normal "set" amd "get"; +#X connect 0 0 18 0; +#X connect 1 0 16 0; +#X connect 2 0 0 0; +#X connect 3 0 19 0; +#X connect 4 0 17 0; +#X connect 7 0 15 0; +#X connect 8 0 16 1; +#X connect 8 0 19 1; +#X connect 8 0 7 0; +#X connect 9 0 7 0; +#X connect 14 0 8 0; +#X connect 15 0 6 0; +#X connect 18 0 5 0; +#X connect 19 0 0 0; +#X connect 19 0 17 1; diff --git a/pd/doc/7.stuff/data-structures/6.file.pd b/pd/doc/7.stuff/data-structures/6.file.pd new file mode 100644 index 00000000..1196d1a1 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/6.file.pd @@ -0,0 +1,68 @@ +#N canvas 405 27 291 318 12; +#N canvas 0 0 377 383 data 1; +#X restore 40 153 pd data; +#N canvas 50 470 523 157 template-toplevel 0; +#X obj 120 112 plot bazoo 700 3 10 20 20; +#X obj 120 48 template float x float y float z float q array bazoo template-element; +#X obj 120 86 drawpolygon q 4 0 0 20 z z -5 10 20; +#X restore 40 174 pd template-toplevel; +#N canvas 199 231 600 239 template-element 0; +#X obj 59 48 template float x float y float w; +#X obj 80 89 drawpolygon 10 2 5 0 0 -5 -5 0 0 5 5 0; +#X restore 40 197 pd template-element; +#X msg 45 16 \; pd-data clear; +#N canvas 125 240 709 410 traversal 0; +#X floatatom 212 353 0 0 0; +#X obj 212 376 set template-toplevel q; +#X floatatom 212 307 0 0 0; +#X floatatom 210 255 0 0 0; +#X floatatom 96 62 0 0 0; +#X floatatom 97 114 0 0 0; +#X floatatom 23 144 0 0 0; +#X floatatom 210 209 0 0 0; +#X floatatom 617 194 0 0 0; +#X floatatom 550 192 0 0 0; +#X floatatom 486 191 0 0 0; +#X obj 419 116 pointer; +#X obj 419 168 get template-toplevel x y z q; +#X msg 450 90 next; +#X floatatom 419 191 0 0 0; +#X obj 23 169 set template-element y; +#X obj 97 137 element template-toplevel bazoo; +#X obj 96 85 setsize template-toplevel bazoo; +#X obj 210 232 set template-toplevel x; +#X obj 210 278 set template-toplevel y; +#X obj 212 330 set template-toplevel z; +#X floatatom 22 200 0 0 0; +#X obj 22 225 set template-element x; +#X msg 419 67 traverse pd-data \, next; +#X floatatom 26 258 0 0 0; +#X obj 26 283 set template-element w; +#X connect 0 0 1 0; +#X connect 2 0 20 0; +#X connect 3 0 19 0; +#X connect 4 0 17 0; +#X connect 5 0 16 0; +#X connect 6 0 15 0; +#X connect 7 0 18 0; +#X connect 11 0 12 0; +#X connect 11 0 17 1; +#X connect 11 0 18 1; +#X connect 11 0 19 1; +#X connect 11 0 20 1; +#X connect 11 0 1 1; +#X connect 11 0 16 1; +#X connect 12 0 14 0; +#X connect 12 1 10 0; +#X connect 12 2 9 0; +#X connect 12 3 8 0; +#X connect 13 0 11 0; +#X connect 16 0 15 1; +#X connect 16 0 22 1; +#X connect 16 0 25 1; +#X connect 21 0 22 0; +#X connect 23 0 11 0; +#X connect 24 0 25 0; +#X restore 41 218 pd traversal; +#X msg 43 55 \; pd-data write xx.txt; +#X msg 41 102 \; pd-data read file.txt; diff --git a/pd/doc/7.stuff/data-structures/7.sequencer.pd b/pd/doc/7.stuff/data-structures/7.sequencer.pd new file mode 100644 index 00000000..6b815191 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/7.sequencer.pd @@ -0,0 +1,192 @@ +#N struct template-toplevel float x float y float voiceno array pitch +template-pitch array amp template-amp; +#N struct template-pitch float x float y float w; +#N struct template-amp float x float y float w; +#N canvas 467 44 543 446 12; +#N canvas 565 104 524 166 template-toplevel 0; +#X obj 25 86 plot pitch voiceno 3 10 0; +#X obj 25 113 plot amp 0 3 10 0; +#X obj 27 60 filledpolygon 9 9 0 0 -10 0 10 5 10 5 -10; +#X obj 25 21 struct template-toplevel float x float y float voiceno +array pitch template-pitch array amp template-amp; +#X restore 64 197 pd template-toplevel; +#N canvas 0 0 419 102 template-amp 0; +#X obj 15 41 struct template-amp float x float y float w; +#X restore 64 219 pd template-amp; +#N canvas 42 221 452 87 template-pitch 0; +#X obj 21 29 struct template-pitch float x float y float w; +#X restore 66 242 pd template-pitch; +#N canvas 282 38 522 569 synthesis 0; +#X msg 125 220 next; +#X msg 108 172 traverse pd-data \, next; +#X obj 108 250 pointer template-toplevel; +#X obj 108 273 t p p; +#X obj 108 296 get template-toplevel voiceno; +#X obj 108 325 pack 0 p; +#X obj 108 4 inlet; +#X obj 108 33 route start stop; +#X msg 161 54 \; reset bang; +#X obj 298 30 r reset; +#X obj 152 112 s reset; +#X obj 125 194 r next-evt; +#X obj 108 354 route 0 9 90 900 99 909 990; +#X obj 55 372 voice; +#X obj 55 536 outlet~; +#X obj 55 395 voice; +#X obj 55 418 voice; +#X obj 55 441 voice; +#X msg 298 58 \; reset-stop stop \; time-of-last-evt 0 \; pd-data sort +; +#X obj 55 465 voice; +#X obj 55 488 voice; +#X obj 55 511 voice; +#X obj 372 351 s delay-multiplier; +#X obj 375 276 t b f; +#X msg 372 303 1000; +#X obj 389 327 /; +#X obj 375 250 r tempo; +#X obj 108 90 t b b b; +#X msg 130 136 \; pd-data sort; +#X connect 0 0 2 0; +#X connect 1 0 2 0; +#X connect 2 0 3 0; +#X connect 3 0 4 0; +#X connect 3 1 5 1; +#X connect 4 0 5 0; +#X connect 5 0 12 0; +#X connect 6 0 7 0; +#X connect 7 0 27 0; +#X connect 7 1 8 0; +#X connect 9 0 18 0; +#X connect 11 0 0 0; +#X connect 12 0 13 1; +#X connect 12 1 15 1; +#X connect 12 2 16 1; +#X connect 12 3 17 1; +#X connect 12 4 19 1; +#X connect 12 5 20 1; +#X connect 12 6 21 1; +#X connect 13 0 15 0; +#X connect 15 0 16 0; +#X connect 16 0 17 0; +#X connect 17 0 19 0; +#X connect 19 0 20 0; +#X connect 20 0 21 0; +#X connect 21 0 14 0; +#X connect 23 0 24 0; +#X connect 23 1 25 1; +#X connect 24 0 25 0; +#X connect 25 0 22 0; +#X connect 26 0 23 0; +#X connect 27 0 1 0; +#X connect 27 1 28 0; +#X connect 27 2 10 0; +#X restore 64 323 pd synthesis; +#X floatatom 278 276 0 0 0; +#X floatatom 92 358 0 0 0; +#N canvas 159 26 495 270 output 0; +#X obj 345 163 t b; +#X obj 345 112 f; +#X obj 345 61 inlet; +#X text 351 30 mute; +#X obj 345 189 f; +#X msg 434 182 0; +#X msg 345 87 bang; +#X obj 345 138 moses 1; +#X obj 434 156 t b f; +#X obj 405 119 moses 1; +#X obj 85 151 dbtorms; +#X obj 405 94 r master-lvl; +#X obj 85 43 r master-lvl; +#X obj 345 214 s master-lvl; +#X obj 22 185 inlet~; +#X obj 203 42 inlet; +#X text 203 18 level; +#X obj 203 102 s master-lvl; +#X msg 98 67 set \$1; +#X obj 98 91 outlet; +#X msg 218 65 \; pd dsp 1; +#X obj 85 198 line~; +#X obj 22 216 *~; +#X obj 22 246 dac~; +#X obj 85 175 pack 0 50; +#X text 20 162 audio; +#X text 95 112 show level; +#X connect 0 0 4 0; +#X connect 1 0 7 0; +#X connect 2 0 6 0; +#X connect 4 0 13 0; +#X connect 5 0 13 0; +#X connect 6 0 1 0; +#X connect 7 0 0 0; +#X connect 7 1 8 0; +#X connect 8 0 5 0; +#X connect 9 1 4 1; +#X connect 10 0 24 0; +#X connect 11 0 1 1; +#X connect 11 0 9 0; +#X connect 12 0 10 0; +#X connect 12 0 18 0; +#X connect 14 0 22 0; +#X connect 15 0 17 0; +#X connect 15 0 20 0; +#X connect 18 0 19 0; +#X connect 21 0 22 1; +#X connect 22 0 23 0; +#X connect 22 0 23 1; +#X connect 24 0 21 0; +#X restore 64 380 pd output; +#X msg 122 358 MUTE; +#X msg 64 296 start; +#X msg 111 296 stop; +#N canvas 22 39 392 386 data 0; +#X scalar template-toplevel 2 246 900 \; 0 0 50 \; 10 0 50 \; \; 0 +0 0 \; 10 0 10 \; 11 0 0 \; \;; +#X scalar template-toplevel 13 220 990 \; 0 0 50 \; 10 0 50 \; \; 0 +0 10 \; 10 0 10 \; 11 0 0 \; \;; +#X scalar template-toplevel 34 73 90 \; 0 250 50 \; 100 50 0 \; 100 +50 50 \; 230 200 0 \; 230 50 10 \; 240 300 1 \; 240 100 50 \; 250 250 +1 \; 250 150 50 \; 260 250 1 \; 285 250 1 \; \; 0 0 2 \; 100 0 5 \; +200 0 6 \; 225 0 2 \; 230 0 5 \; 260 0 10 \; 261 0 5 \; 265 0 0 \; +266 0 6 \; 270 0 0 \; 271 0 8 \; 275 0 0 \; 276 0 10 \; 280 0 0 \; +281 0 12 \; 285 0 0 \; \;; +#X scalar template-toplevel 67 282 900 \; 0 20 1 \; 60 20 1 \; \; 0 +0 0 \; 30 0 14 \; 60 0 0 \; \;; +#X scalar template-toplevel 141 322 900 \; 0 0 50 \; 70 -70 50 \; \; +0 0 0 \; 10 0 10 \; 20 0 0 \; 30 0 0 \; 40 0 10 \; 50 0 0 \; 60 0 10 +\; 70 0 0 \; \;; +#X scalar template-toplevel 326 192 909 \; 0 0 50 \; 50 0 50 \; \; +0 0 15 \; 10 0 10 \; 50 0 0 \; \;; +#X restore 64 176 pd data; +#N canvas 82 467 332 145 stuff 0; +#X msg 1 101 \; pd-data write xx.txt; +#X msg -3 39 \; pd-data read score.txt; +#X obj 208 7 loadbang; +#X msg 208 34 \; tempo 60; +#X msg 198 101 \; pd-data sort; +#X connect 2 0 3 0; +#X restore 65 264 pd stuff; +#X obj 278 229 r tempo; +#X msg 278 252 set \$1; +#X obj 278 300 s tempo; +#X text 13 4 This patch shows an example of how to use data collections +as musical sequences (with apologies to Yuasa and Stockhausen). Here +the black traces show dynamics and the colored ones show pitch. The +fatness of the pitch traces give bandwidth. Any of the three can change +over the life of the event.; +#X text 160 357 <--- volume in dB; +#X text 13 96 To hear the result \, turn the volume up to 70 or so +(higher if it's not loud enough the first time) and hit "start". You +can set the tempo lower if that helps you follow the "score" the first +couple of times.; +#X text 311 276 <--- tempo; +#X text 256 416 Updated for Pd version 0.32; +#X connect 3 0 6 0; +#X connect 4 0 14 0; +#X connect 5 0 6 1; +#X connect 6 0 5 0; +#X connect 7 0 6 2; +#X connect 8 0 3 0; +#X connect 9 0 3 0; +#X connect 12 0 13 0; +#X connect 13 0 4 0; diff --git a/pd/doc/7.stuff/data-structures/data-array.pd b/pd/doc/7.stuff/data-structures/data-array.pd new file mode 100644 index 00000000..25cb1ec8 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/data-array.pd @@ -0,0 +1,64 @@ +#N canvas 230 71 587 465 12; +#X floatatom 179 207 0 0 0; +#X obj 53 199 f; +#X obj 89 194 + 1; +#X obj 53 232 sel; +#X msg 69 165 1; +#X msg 285 213 0; +#X obj 418 342 *; +#X obj 418 392 del; +#X obj 414 292 t f f; +#X obj 418 322 -; +#X msg 469 304 0; +#X obj 449 346 r delay-multiplier; +#X obj 432 369 r reset-stop; +#X obj 238 110 inlet; +#X obj 179 184 getsize \$1 \$2; +#X obj 285 233 element \$1 \$2; +#X obj 187 234 element \$1 \$2; +#X obj 208 408 outlet; +#X obj 349 408 outlet; +#X obj 187 254 get \$3 y w x; +#X obj 285 253 get \$3 y w; +#X obj 265 408 outlet; +#X obj 342 302 t f b; +#X obj 372 326 0; +#X obj 238 130 t b b p b; +#X text 229 93 pointer in; +#X text 20 12 This is an abstraction used in the sequencer example. Here we take a pointer and sequence an array belonging to it \, either the amplitude or the frequency \, depending on the value of argument 2 The template of the scalar is given by argument 1 and that of the array elements by argument 3; +#X text 90 431 Outlets: new y value \, new w value \, time to ramp to new values.; +#X connect 1 0 2 0; +#X connect 1 0 3 0; +#X connect 2 0 1 1; +#X connect 3 1 16 0; +#X connect 4 0 1 1; +#X connect 5 0 15 0; +#X connect 6 0 7 0; +#X connect 6 0 18 0; +#X connect 7 0 1 0; +#X connect 8 0 9 1; +#X connect 8 1 9 0; +#X connect 9 0 6 0; +#X connect 10 0 9 1; +#X connect 11 0 6 1; +#X connect 12 0 7 0; +#X connect 13 0 24 0; +#X connect 14 0 0 0; +#X connect 14 0 3 1; +#X connect 15 0 20 0; +#X connect 16 0 19 0; +#X connect 19 0 17 0; +#X connect 19 1 21 0; +#X connect 19 2 8 0; +#X connect 20 0 17 0; +#X connect 20 1 22 0; +#X connect 22 0 21 0; +#X connect 22 1 23 0; +#X connect 23 0 18 0; +#X connect 24 0 1 0; +#X connect 24 1 5 0; +#X connect 24 2 15 1; +#X connect 24 2 14 0; +#X connect 24 2 16 1; +#X connect 24 3 4 0; +#X connect 24 3 10 0; diff --git a/pd/doc/7.stuff/data-structures/data-start.pd b/pd/doc/7.stuff/data-structures/data-start.pd new file mode 100644 index 00000000..b0522fbf --- /dev/null +++ b/pd/doc/7.stuff/data-structures/data-start.pd @@ -0,0 +1,40 @@ +#N canvas 404 0 597 385 12; +#X obj 248 142 inlet; +#X obj 295 250 *; +#X obj 165 262 del; +#X obj 130 141 r reset-stop; +#X obj 195 339 outlet; +#X obj 375 172 outlet; +#X obj 310 145 get \$1 x y; +#X obj 195 312 pointer; +#X text 46 101 outlets: pointer (delayed) \, y-value.; +#X obj 248 167 t b p; +#X obj 165 288 t b b; +#X obj 335 224 r time-of-last-evt; +#X obj 295 223 -; +#X obj 310 167 t f f; +#X obj 97 339 s next-evt; +#X obj 335 201 s time-of-last-evt; +#X obj 329 251 r delay-multiplier; +#X text 49 10 This is an abstraction used by the sequencer example. +; +#X text 46 45 Here we carry out the actual sequencing. Argument is +template of the scalar. Note the sends and receives which must agree +with the rest of the patch.; +#X connect 0 0 9 0; +#X connect 1 0 2 1; +#X connect 2 0 10 0; +#X connect 3 0 2 0; +#X connect 6 0 13 0; +#X connect 6 1 5 0; +#X connect 7 0 4 0; +#X connect 9 0 2 0; +#X connect 9 1 7 1; +#X connect 9 1 6 0; +#X connect 10 0 14 0; +#X connect 10 1 7 0; +#X connect 11 0 12 1; +#X connect 12 0 1 0; +#X connect 13 0 15 0; +#X connect 13 1 12 0; +#X connect 16 0 1 1; diff --git a/pd/doc/7.stuff/data-structures/file.txt b/pd/doc/7.stuff/data-structures/file.txt new file mode 100644 index 00000000..62b6a167 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/file.txt @@ -0,0 +1,39 @@ +data; +template template-toplevel; +float x; +float y; +float z; +float q; +array bazoo template-element; +; +template template-element; +float x; +float y; +float w; +; +; +template-toplevel 76 177 -66 85; +0 0 0; +30 0 0; +0 111 8; +-47 22 0; +0 0 0; +0 70 0; +0 70 70; +70 70 0; +0 70 0; +; +template-toplevel 196 109 77 802; +-20 77 0; +0 0 4; +67 59 0; +0 76 12; +-45 -68 0; +; +template-toplevel 150 250 20 80; +0 0 0; +40 0 4; +60 50 0; +100 30 3; +200 0 0; +; diff --git a/pd/doc/7.stuff/data-structures/score.txt b/pd/doc/7.stuff/data-structures/score.txt new file mode 100644 index 00000000..84ef0376 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/score.txt @@ -0,0 +1,94 @@ +data; +template template-toplevel; +float x; +float y; +float voiceno; +array pitch template-pitch; +array amp template-amp; +; +template template-pitch; +float x; +float y; +float w; +; +template template-amp; +float x; +float y; +float w; +; +; +template-toplevel 2 246 900; +0 0 50; +10 0 50; +; +0 0 0; +10 0 10; +11 0 0; +; +template-toplevel 13 220 990; +0 0 50; +10 0 50; +; +0 0 10; +10 0 10; +11 0 0; +; +template-toplevel 34 73 90; +0 250 50; +100 50 0; +100 50 50; +230 200 0; +230 50 10; +240 300 1; +240 100 50; +250 250 1; +250 150 50; +260 250 1; +285 250 1; +; +0 0 2; +100 0 5; +200 0 6; +225 0 2; +230 0 5; +260 0 10; +261 0 5; +265 0 0; +266 0 6; +270 0 0; +271 0 8; +275 0 0; +276 0 10; +280 0 0; +281 0 12; +285 0 0; +; +template-toplevel 67 282 900; +0 20 1; +60 20 1; +; +0 0 0; +30 0 14; +60 0 0; +; +template-toplevel 141 322 900; +0 0 50; +70 -70 50; +; +0 0 0; +10 0 10; +20 0 0; +30 0 0; +40 0 10; +50 0 0; +60 0 10; +70 0 0; +; +template-toplevel 326 192 909; +0 0 50; +50 0 50; +; +0 0 15; +10 0 10; +50 0 0; +; diff --git a/pd/doc/7.stuff/data-structures/voice.pd b/pd/doc/7.stuff/data-structures/voice.pd new file mode 100644 index 00000000..2d124db7 --- /dev/null +++ b/pd/doc/7.stuff/data-structures/voice.pd @@ -0,0 +1,127 @@ +#N canvas 0 34 918 591 12; +#X obj 180 96 inlet; +#X obj 169 288 pack; +#X obj 169 395 line~; +#X obj 169 238 sqrt; +#X obj 169 262 sqrt; +#X obj 169 480 *~; +#X obj 169 419 *~; +#X obj 169 443 *~; +#X obj 92 478 inlet~; +#X obj 92 526 outlet~; +#X obj 92 502 +~; +#X obj 436 411 line~; +#X obj 436 435 *~; +#X obj 436 459 *~; +#X obj 436 283 mtof; +#X obj 394 187 +; +#X obj 436 307 sqrt; +#X obj 436 331 sqrt; +#X obj 436 387 pack; +#X obj 169 214 / 6; +#X obj 189 343 r reset; +#X msg 189 367 0 20; +#X obj 180 120 data-start template-toplevel; +#X obj 6 150 data-array template-toplevel amp template-amp; +#X obj 433 148 data-array template-toplevel pitch template-pitch; +#X obj 308 437 noise~; +#X obj 477 259 +; +#X obj 477 282 mtof; +#X obj 477 306 sqrt; +#X obj 477 330 sqrt; +#X obj 477 411 line~; +#X obj 477 435 *~; +#X obj 477 459 *~; +#X obj 477 387 pack; +#X obj 394 411 line~; +#X obj 394 435 *~; +#X obj 394 459 *~; +#X obj 394 387 pack; +#X obj 394 284 mtof; +#X obj 394 308 sqrt; +#X obj 394 332 sqrt; +#X obj 394 262 -; +#X obj 240 520 vcf~ 10; +#X obj 315 520 vcf~ 10; +#X obj 390 516 vcf~ 10; +#X text 13 7 This is an abstraction used in the sequencer example. +Here we take care of the audio synthesis \, according to timed controls +from the the "data-start" and "data-array" subpatches.; +#X text 505 458 calculate time-varying center frequencies; +#X text 470 512 ... for three VCFs acting on a noise source.; +#X text 92 394 Amplitude; +#X text 93 410 envelope; +#X text 117 508 summing bus; +#X text 346 62 Pitch is in eighth-tones (because 4 pixels per half +tone looks reasonable on the screen.) Hence the * 0.25 objects below. +; +#X obj 394 209 * 0.25; +#X obj 493 233 * 0.25; +#X obj 394 230 + 24; +#X connect 0 0 22 0; +#X connect 1 0 2 0; +#X connect 2 0 6 0; +#X connect 2 0 6 1; +#X connect 3 0 4 0; +#X connect 4 0 1 0; +#X connect 5 0 10 1; +#X connect 6 0 7 0; +#X connect 6 0 7 1; +#X connect 7 0 5 0; +#X connect 8 0 10 0; +#X connect 10 0 9 0; +#X connect 11 0 12 0; +#X connect 11 0 12 1; +#X connect 12 0 13 0; +#X connect 12 0 13 1; +#X connect 13 0 43 1; +#X connect 14 0 16 0; +#X connect 15 0 52 0; +#X connect 16 0 17 0; +#X connect 17 0 18 0; +#X connect 18 0 11 0; +#X connect 19 0 3 0; +#X connect 20 0 21 0; +#X connect 21 0 2 0; +#X connect 22 0 23 0; +#X connect 22 0 24 0; +#X connect 22 1 15 1; +#X connect 23 1 19 0; +#X connect 23 2 1 1; +#X connect 24 0 15 0; +#X connect 24 1 53 0; +#X connect 24 2 18 1; +#X connect 24 2 37 1; +#X connect 24 2 33 1; +#X connect 25 0 42 0; +#X connect 25 0 43 0; +#X connect 25 0 44 0; +#X connect 26 0 27 0; +#X connect 27 0 28 0; +#X connect 28 0 29 0; +#X connect 29 0 33 0; +#X connect 30 0 31 0; +#X connect 30 0 31 1; +#X connect 31 0 32 0; +#X connect 31 0 32 1; +#X connect 32 0 44 1; +#X connect 33 0 30 0; +#X connect 34 0 35 0; +#X connect 34 0 35 1; +#X connect 35 0 36 0; +#X connect 35 0 36 1; +#X connect 36 0 42 1; +#X connect 37 0 34 0; +#X connect 38 0 39 0; +#X connect 39 0 40 0; +#X connect 40 0 37 0; +#X connect 41 0 38 0; +#X connect 42 0 5 1; +#X connect 43 0 5 1; +#X connect 44 0 5 1; +#X connect 52 0 54 0; +#X connect 53 0 26 1; +#X connect 53 0 41 1; +#X connect 54 0 41 0; +#X connect 54 0 26 0; +#X connect 54 0 14 0; diff --git a/pd/doc/7.stuff/data-structures/z.txt b/pd/doc/7.stuff/data-structures/z.txt new file mode 100644 index 00000000..6cdd0a4a --- /dev/null +++ b/pd/doc/7.stuff/data-structures/z.txt @@ -0,0 +1,64 @@ +data; +template template5; +float x; +float y; +float z; +float q; +array bazoo template5-element; +; +template template5-element; +float y; +; +; +template5 50 150 30 9; +0; +0; +0; +0; +0; +3; +0; +0; +0; +7; +-30; +0; +0; +0; +0; +0; +-4; +-18; +-26; +-36; +-46; +-62; +-74; +-78; +-70; +-62; +-52; +-40; +-30; +-20; +-4; +1; +7; +11; +13; +0; +0; +0; +0; +0; +0; +0; +0; +0; +0; +43; +0; +0; +0; +0; +; diff --git a/pd/doc/7.stuff/soundfile-tools/1.ring-mod.pd b/pd/doc/7.stuff/soundfile-tools/1.ring-mod.pd new file mode 100644 index 00000000..72fb9c7f --- /dev/null +++ b/pd/doc/7.stuff/soundfile-tools/1.ring-mod.pd @@ -0,0 +1,189 @@ +#N canvas 73 28 687 421 12; +#N canvas 213 187 495 352 input-sample 0; +#N canvas 0 0 450 300 graph1 0; +#X array array1 91065 float 0; +#X coords 0 1 91065 -1 400 300 1; +#X restore 56 23 graph; +#X text 151 393 INPUT SAMPLE; +#X restore 179 299 pd input-sample; +#N canvas 192 180 507 343 output-sample 0; +#N canvas 0 0 450 300 graph2 0; +#X array array2 95475 float 0; +#X coords 0 1 95475 -1 400 300 1; +#X restore 60 13 graph; +#X text 161 388 OUTPUT SAMPLE; +#X restore 179 323 pd output-sample; +#N canvas 110 33 827 602 guts 0; +#X msg 25 133 bang; +#X obj 25 360 openpanel; +#X obj 144 31 inlet; +#X obj 441 403 dac~; +#X obj 441 342 *~; +#X obj 456 318 line~; +#X obj 456 296 r master-amp; +#X msg 597 130 bang; +#X obj 597 155 savepanel; +#X obj 231 164 spigot; +#X msg 233 132 0; +#X msg 265 132 1; +#X obj 497 427 outlet; +#X obj 299 132 r frequency; +#X obj 219 321 tabwrite~ array2; +#X msg 219 193 bang; +#X obj 420 289 +~; +#X msg 96 129 \; pd dsp 1; +#X obj 441 370 hip~ 7; +#X obj 231 223 tabplay~ array1; +#X msg 439 131 bang; +#X obj 439 160 tabplay~ array2; +#X msg 597 180 write \$1 array2; +#X obj 597 205 soundfiler; +#X obj 144 53 route read run start hear save; +#N canvas 0 0 368 263 audio-transformation 0; +#X obj 113 95 osc~; +#X obj 97 116 *~; +#X obj 97 138 hip~ 7; +#X obj 113 71 r frequency; +#X obj 97 22 inlet~; +#X obj 97 169 outlet~; +#X obj 97 47 hip~ 7; +#X connect 0 0 1 1; +#X connect 1 0 2 0; +#X connect 2 0 5 0; +#X connect 3 0 0 0; +#X connect 4 0 6 0; +#X connect 6 0 1 0; +#X restore 231 251 pd audio-transformation; +#X obj 497 402 env~ 16384; +#X obj 570 91 route normalized; +#X msg 571 300 write -normalize \$1 array2; +#X msg 571 250 bang; +#X obj 571 276 savepanel; +#X obj 571 325 soundfiler; +#X obj 25 413 soundfiler; +#X msg 25 390 read -resize -maxsize 1e+06 \$1 array1; +#X msg 25 460 \; array2 resize \$1; +#X obj 25 437 + 4410; +#X floatatom 96 436 0 0 0; +#X connect 0 0 1 0; +#X connect 1 0 33 0; +#X connect 2 0 24 0; +#X connect 4 0 18 0; +#X connect 5 0 4 1; +#X connect 6 0 5 0; +#X connect 7 0 8 0; +#X connect 8 0 22 0; +#X connect 9 0 10 0; +#X connect 9 0 15 0; +#X connect 10 0 9 1; +#X connect 11 0 9 1; +#X connect 13 0 9 0; +#X connect 15 0 14 0; +#X connect 15 0 19 0; +#X connect 16 0 4 0; +#X connect 18 0 3 0; +#X connect 18 0 3 1; +#X connect 18 0 26 0; +#X connect 19 0 25 0; +#X connect 20 0 21 0; +#X connect 21 0 16 1; +#X connect 22 0 23 0; +#X connect 24 0 0 0; +#X connect 24 1 15 0; +#X connect 24 1 10 0; +#X connect 24 1 17 0; +#X connect 24 2 11 0; +#X connect 24 2 17 0; +#X connect 24 3 20 0; +#X connect 24 4 27 0; +#X connect 25 0 14 0; +#X connect 25 0 16 0; +#X connect 26 0 12 0; +#X connect 27 0 29 0; +#X connect 27 1 7 0; +#X connect 28 0 31 0; +#X connect 29 0 30 0; +#X connect 30 0 28 0; +#X connect 32 0 35 0; +#X connect 32 0 36 0; +#X connect 33 0 32 0; +#X connect 35 0 34 0; +#X restore 28 265 pd guts; +#X msg 28 155 run the transformation; +#X msg 28 199 hear the output buffer again; +#X text 28 113 click below to:; +#X msg 28 221 save the output buffer; +#X floatatom 404 257 0 0 0; +#N canvas 194 37 397 591 output 0; +#X obj 66 203 t b; +#X obj 66 152 f; +#X obj 66 102 inlet; +#X text 71 81 mute; +#X obj 66 228 f; +#X msg 134 244 0; +#X msg 66 127 bang; +#X obj 66 178 moses 1; +#X obj 134 218 t b f; +#X obj 96 442 outlet; +#X msg 96 416 set \$1; +#X obj 186 163 moses 1; +#X obj 224 444 dbtorms; +#X obj 224 469 pack 0 100; +#X obj 186 138 r master-lvl; +#X obj 96 382 r master-lvl; +#X obj 83 286 s master-lvl; +#X obj 224 494 s master-amp; +#X obj 208 244 loadbang; +#X msg 208 269 \; master-lvl 90; +#X connect 0 0 4 0; +#X connect 1 0 7 0; +#X connect 2 0 6 0; +#X connect 4 0 16 0; +#X connect 5 0 16 0; +#X connect 6 0 1 0; +#X connect 7 0 0 0; +#X connect 7 1 8 0; +#X connect 8 0 5 0; +#X connect 10 0 9 0; +#X connect 11 1 4 1; +#X connect 12 0 13 0; +#X connect 13 0 17 0; +#X connect 14 0 1 1; +#X connect 14 0 11 0; +#X connect 15 0 10 0; +#X connect 15 0 12 0; +#X connect 18 0 19 0; +#X restore 404 235 pd output; +#X msg 404 213 mute; +#X obj 404 279 s master-lvl; +#X text 448 212 <-- mute button; +#X msg 28 177 start transformation when I change frequency; +#X floatatom 392 117 0 0 0; +#X obj 392 139 s frequency; +#X text 392 97 modulation frequency (Hz.); +#X floatatom 28 287 0 0 0; +#X text 10 330 100 maximum; +#X text 10 311 output meter; +#X text 429 115 <--set me; +#X text 443 255 <--set me; +#X msg 28 133 read an input file; +#X msg 28 243 save normalized to max amplitude; +#X text 29 8 Ring modulator. Read in a sample first \, then you can +either set a frequency and hit the "run" button or else hit the "start..." +button and start the transformation by dragging on the frequency control. +The output level should be "100" for unit gain.; +#X text 22 361 Outputs are saved as "wav" files \, although you can +edit the patch to make "aiff" or "nextstep" instead. Any of the three +are OK for source files.; +#X text 397 302 LINE OUT LEVEL in dB (100 max); +#X connect 2 0 16 0; +#X connect 3 0 2 0; +#X connect 4 0 2 0; +#X connect 6 0 2 0; +#X connect 7 0 10 0; +#X connect 8 0 7 0; +#X connect 9 0 8 0; +#X connect 12 0 2 0; +#X connect 13 0 14 0; +#X connect 21 0 2 0; +#X connect 22 0 2 0; diff --git a/pd/doc/7.stuff/soundfile-tools/2.bandpass.pd b/pd/doc/7.stuff/soundfile-tools/2.bandpass.pd new file mode 100644 index 00000000..c75335eb --- /dev/null +++ b/pd/doc/7.stuff/soundfile-tools/2.bandpass.pd @@ -0,0 +1,202 @@ +#N canvas 73 28 846 432 12; +#N canvas 213 187 495 352 input-sample 0; +#N canvas 0 0 450 300 graph1 0; +#X array array1 155948 float 0; +#X coords 0 1 155948 -1 400 300 1; +#X restore 55 22 graph; +#X text 149 386 INPUT SAMPLE; +#X restore 238 282 pd input-sample; +#N canvas 192 180 507 343 output-sample 0; +#N canvas 0 0 450 300 graph2 0; +#X array array2 160358 float 0; +#X coords 0 1 160358 -1 400 300 1; +#X restore 59 13 graph; +#X text 158 381 OUTPUT SAMPLE; +#X restore 237 305 pd output-sample; +#N canvas 116 150 735 425 guts 0; +#X msg 25 131 bang; +#X obj 25 354 openpanel; +#X obj 142 31 inlet; +#X obj 458 378 dac~; +#X obj 458 335 *~; +#X obj 473 312 line~; +#X obj 473 290 r master-amp; +#X msg 726 87 bang; +#X obj 726 109 savepanel; +#X obj 275 165 spigot; +#X msg 260 131 0; +#X msg 291 131 1; +#X obj 513 408 outlet; +#X obj 324 131 r frequency; +#X obj 263 320 tabwrite~ array2; +#X msg 263 194 bang; +#X obj 438 283 +~; +#X msg 143 131 \; pd dsp 1; +#X obj 458 356 hip~ 7; +#X obj 275 223 tabplay~ array1; +#X msg 453 127 bang; +#X obj 453 149 tabplay~ array2; +#X msg 726 130 write \$1 array2; +#X obj 726 151 soundfiler; +#X obj 142 52 route read run start hear save; +#N canvas 0 0 368 259 audio-transformation 0; +#X obj 111 70 r frequency; +#X obj 96 21 inlet~; +#X obj 96 178 outlet~; +#X obj 179 123 r q; +#X obj 111 94 pack 0 100; +#X obj 110 119 line~; +#X obj 96 153 vcf~; +#X connect 0 0 4 0; +#X connect 1 0 6 0; +#X connect 3 0 6 2; +#X connect 4 0 5 0; +#X connect 5 0 6 1; +#X connect 6 0 2 0; +#X restore 275 244 pd audio-transformation; +#X obj 513 387 env~ 16384; +#X obj 585 88 route normalized; +#X msg 585 184 write -normalize \$1 array2; +#X msg 585 142 bang; +#X obj 585 163 savepanel; +#X obj 585 209 soundfiler; +#X obj 25 406 soundfiler; +#X msg 25 383 read -resize -maxsize 1e+06 \$1 array1; +#X msg 25 452 \; array2 resize \$1; +#X obj 25 430 + 4410; +#X floatatom 94 428 0 0 0; +#X obj 413 132 r q; +#X connect 0 0 1 0; +#X connect 1 0 33 0; +#X connect 2 0 24 0; +#X connect 4 0 18 0; +#X connect 5 0 4 1; +#X connect 6 0 5 0; +#X connect 7 0 8 0; +#X connect 8 0 22 0; +#X connect 9 0 10 0; +#X connect 9 0 15 0; +#X connect 10 0 9 1; +#X connect 11 0 9 1; +#X connect 13 0 9 0; +#X connect 15 0 14 0; +#X connect 15 0 19 0; +#X connect 16 0 4 0; +#X connect 18 0 3 0; +#X connect 18 0 3 1; +#X connect 18 0 26 0; +#X connect 19 0 25 0; +#X connect 20 0 21 0; +#X connect 21 0 16 1; +#X connect 22 0 23 0; +#X connect 24 0 0 0; +#X connect 24 1 15 0; +#X connect 24 1 10 0; +#X connect 24 1 17 0; +#X connect 24 2 11 0; +#X connect 24 2 17 0; +#X connect 24 3 20 0; +#X connect 24 4 27 0; +#X connect 25 0 14 0; +#X connect 25 0 16 0; +#X connect 26 0 12 0; +#X connect 27 0 29 0; +#X connect 27 1 7 0; +#X connect 28 0 31 0; +#X connect 29 0 30 0; +#X connect 30 0 28 0; +#X connect 32 0 35 0; +#X connect 32 0 36 0; +#X connect 33 0 32 0; +#X connect 35 0 34 0; +#X connect 37 0 9 0; +#X restore 34 236 pd guts; +#X msg 34 131 run the transformation; +#X msg 34 173 hear the output buffer again; +#X text 34 91 click below to:; +#X msg 34 194 save the output buffer; +#X floatatom 562 334 0 0 120; +#N canvas 194 37 397 591 output 0; +#X obj 65 199 t b; +#X obj 65 150 f; +#X obj 65 100 inlet; +#X text 70 79 mute; +#X obj 65 224 f; +#X msg 132 240 0; +#X msg 65 125 bang; +#X obj 65 175 moses 1; +#X obj 132 215 t b f; +#X obj 94 434 outlet; +#X msg 94 409 set \$1; +#X obj 183 160 moses 1; +#X obj 221 437 dbtorms; +#X obj 221 461 pack 0 100; +#X obj 183 136 r master-lvl; +#X obj 94 375 r master-lvl; +#X obj 81 281 s master-lvl; +#X obj 221 486 s master-amp; +#X obj 204 240 loadbang; +#X msg 204 264 \; master-lvl 90; +#X connect 0 0 4 0; +#X connect 1 0 7 0; +#X connect 2 0 6 0; +#X connect 4 0 16 0; +#X connect 5 0 16 0; +#X connect 6 0 1 0; +#X connect 7 0 0 0; +#X connect 7 1 8 0; +#X connect 8 0 5 0; +#X connect 10 0 9 0; +#X connect 11 1 4 1; +#X connect 12 0 13 0; +#X connect 13 0 17 0; +#X connect 14 0 1 1; +#X connect 14 0 11 0; +#X connect 15 0 10 0; +#X connect 15 0 12 0; +#X connect 18 0 19 0; +#X restore 562 313 pd output; +#X msg 562 292 mute; +#X obj 562 355 s master-lvl; +#X text 604 291 <-- mute button; +#X floatatom 34 257 0 0 0; +#X text 35 300 100 maximum; +#X text 35 282 output meter; +#X text 600 335 <--set me; +#X msg 34 110 read an input file; +#X msg 34 215 save normalized to max amplitude; +#X msg 34 152 start transformation when I change f or q; +#X floatatom 479 164 0 0 0; +#X obj 479 185 s frequency; +#X text 479 85 center; +#X floatatom 482 229 0 0 10000; +#X text 482 210 "q"; +#X obj 482 252 s q; +#X obj 479 143 mtof; +#X floatatom 479 122 0 0 128; +#X text 536 163 <- set in Hz; +#X text 533 230 <--set selectivity; +#X text 479 103 frequency; +#X text 534 123 <- set in MIDI units; +#X text 31 341 Note -- you can shift-click on the controls to change +them in hundredths. You can also click and type numbers in \, followed +by the "enter" key.; +#X text 16 5 Bandpass filter. Read in a sample first \, then you can +either set a frequency and hit the "run" button or else hit the "start..." +button and start the transformation by dragging on the frequency or +q control.; +#X text 552 377 OUTPUT LEVEL in dB (100 norm); +#X connect 2 0 12 0; +#X connect 3 0 2 0; +#X connect 4 0 2 0; +#X connect 6 0 2 0; +#X connect 7 0 10 0; +#X connect 8 0 7 0; +#X connect 9 0 8 0; +#X connect 16 0 2 0; +#X connect 17 0 2 0; +#X connect 18 0 2 0; +#X connect 19 0 20 0; +#X connect 22 0 24 0; +#X connect 25 0 19 0; +#X connect 26 0 25 0; diff --git a/pd/doc/7.stuff/soundfile-tools/3.phase.vocoder.pd b/pd/doc/7.stuff/soundfile-tools/3.phase.vocoder.pd new file mode 100644 index 00000000..b69d5e86 --- /dev/null +++ b/pd/doc/7.stuff/soundfile-tools/3.phase.vocoder.pd @@ -0,0 +1,551 @@ +#N canvas 223 113 913 495 12; +#X floatatom 457 258 0 0 0; +#X floatatom 793 114 0 0 0; +#X floatatom 654 114 0 0 0; +#N canvas 249 280 600 398 loc&precess 0; +#X floatatom 218 312 0 0 0; +#X msg 369 239 set \$1; +#X obj 367 282 outlet; +#X obj 114 364 outlet; +#X obj 233 96 r location; +#X msg 113 321 set \$1; +#X obj 368 203 r speed; +#X obj 75 95 r see-location; +#X obj 92 139 t b f; +#X obj 113 292 f; +#X obj 73 173 int; +#X obj 73 206 sel 0; +#X msg 209 139 1; +#X msg 275 138 0; +#X obj 150 245 del 300; +#X connect 1 0 2 0; +#X connect 4 0 8 0; +#X connect 5 0 3 0; +#X connect 6 0 1 0; +#X connect 7 0 8 0; +#X connect 8 0 10 0; +#X connect 8 1 9 1; +#X connect 9 0 5 0; +#X connect 10 0 11 0; +#X connect 11 0 12 0; +#X connect 11 0 14 0; +#X connect 12 0 10 1; +#X connect 13 0 10 1; +#X connect 14 0 13 0; +#X connect 14 0 9 0; +#X restore 654 91 pd loc&precess; +#N canvas 0 0 600 400 setlocprecess 0; +#X obj 235 113 inlet; +#X obj 100 109 inlet; +#X obj 231 144 s speed; +#X obj 101 144 s location; +#X connect 0 0 2 0; +#X connect 1 0 3 0; +#X restore 654 138 pd setlocprecess; +#X obj 457 279 s transpo; +#X obj 457 216 r transpo; +#X msg 457 237 set \$1; +#X msg 673 387 \; location 0 \; speed 200; +#X text 200 8 PHASE VOCODER; +#X text 609 18 set location; +#X text 609 36 and stop; +#X text 609 54 precession; +#X text 785 53 precession; +#X text 785 71 speed in; +#X text 785 89 hundredths; +#X text 457 179 transposition; +#X text 457 197 in cents; +#X text 666 360 contraction; +#X text 784 360 expansion; +#X msg 776 387 \; location 0 \; speed 10; +#X text 30 349 100 maximum; +#X text 30 331 output meter; +#X floatatom 610 218 0 5 60; +#X text 645 218 <--set me to change length; +#N canvas 0 0 265 196 length 0; +#X obj 46 23 inlet; +#X obj 48 101 * 44100; +#X msg 84 125 \; array2 resize \$1; +#X obj 46 48 min 60; +#X obj 60 75 s output-length; +#X obj 46 159 s maxoutsize; +#X connect 0 0 3 0; +#X connect 1 0 2 0; +#X connect 1 0 5 0; +#X connect 3 0 1 0; +#X connect 3 0 4 0; +#X restore 610 239 pd length; +#N canvas 219 38 198 151 /SUBPATCH/ 0; +#X obj 77 118 outlet; +#X obj 77 72 loadbang; +#X msg 77 95 10; +#X connect 1 0 2 0; +#X connect 2 0 0 0; +#X restore 610 197 pd; +#X text 610 259 length in seconds of the output; +#X text 610 277 buffer... maximum 60; +#N canvas 42 0 1083 546 guts 0; +#X msg 24 129 bang; +#X obj 24 405 openpanel; +#X obj 139 30 inlet; +#X obj 450 385 dac~; +#X obj 450 329 *~; +#X obj 465 306 line~; +#X obj 465 283 r master-amp; +#X msg 728 129 bang; +#X obj 728 150 savepanel; +#X obj 219 164 spigot; +#X msg 206 102 0; +#X msg 238 102 1; +#X obj 503 444 outlet; +#X obj 292 251 tabwrite~ array2; +#X obj 449 246 +~; +#X obj 450 356 hip~ 7; +#X msg 446 97 bang; +#X obj 446 118 tabplay~ array2; +#X msg 728 175 write \$1 array2; +#X obj 728 200 soundfiler; +#X obj 505 386 env~ 16384; +#X obj 591 101 route normalized; +#X msg 591 284 write -normalize \$1 array2; +#X msg 591 242 bang; +#X obj 591 263 savepanel; +#X obj 591 308 soundfiler; +#X obj 24 450 soundfiler; +#X msg 24 428 read -resize -maxsize 1e+06 \$1 array1; +#X floatatom 24 473 0 0 0; +#X obj 680 345 loadbang; +#X msg 680 368 \; window-size 2048 \; transpo 0; +#N canvas 9 7 835 599 fft-analysis 0; +#X obj 267 304 *~; +#X obj 235 304 *~; +#X obj 235 326 -~; +#X obj 333 305 *~; +#X obj 302 305 *~; +#X obj 302 328 +~; +#X obj 348 131 *~; +#X obj 317 131 *~; +#X obj 288 131 *~; +#X obj 256 131 *~; +#X obj 256 153 +~; +#X obj 225 183 *~; +#X obj 88 570 *~; +#X obj 375 256 rfft~; +#X obj 396 55 rfft~; +#X obj 488 652 *~; +#X obj 702 295 r window-size; +#X obj 770 211 r sample-rate; +#X obj 624 239 f; +#X obj 617 53 r sample-rate; +#X obj 592 30 r window-size; +#X obj 615 100 t b f; +#X obj 592 124 /; +#X obj 519 652 *~; +#X obj 89 549 *~; +#X obj 106 525 rifft~; +#X obj 89 596 outlet~; +#X obj 639 457 print~; +#X msg 639 428 bang; +#X text 155 526 inverse real FFT; +#X obj 603 215 bang~; +#X obj 528 434 line~; +#X obj 592 146 * 1000; +#X text 645 139 window size (msec); +#X obj 617 78 * 4; +#X obj 647 162 r speed; +#X obj 726 164 r location; +#X obj 655 240 +; +#X obj 648 204 *; +#X msg 726 193 0; +#X obj 624 349 +; +#X obj 615 305 t f f; +#X msg 528 406 \$1 \, \$2 \$3; +#X obj 528 378 pack 0 0 0; +#X obj 770 234 / 1000; +#X obj 624 276 *; +#X text 654 276 reading location (samples); +#X obj 652 390 / 4; +#X text 684 395 hop size (samples); +#X obj 578 476 sig~; +#X obj 546 474 +~; +#X text 653 85 (overlap times parent SR); +#X text 653 71 local sample rate; +#X obj 23 52 tabreceive~ phase-real; +#X obj 194 183 *~; +#X obj 194 205 +~; +#X obj 194 231 rsqrt~; +#X obj 317 153 -~; +#X obj 237 261 *~; +#X obj 298 261 *~; +#X obj 203 52 tabreceive~ phase-imag; +#X obj 108 390 sig~; +#X obj 90 319 t b f; +#X msg 90 340 1; +#X obj 104 364 /; +#X obj 232 447 tabsend~ phase-real; +#X obj 262 418 tabsend~ phase-imag; +#X obj 107 136 sig~ 1.5e-20; +#X obj 647 184 * 0.01; +#X obj 708 217 s speed; +#X obj 479 256 s see-location; +#X floatatom 688 368 0 0 0; +#X obj 686 347 *; +#X obj 848 245 r transpo; +#X obj 848 264 * 0.01; +#X obj 849 285 + 69; +#X obj 851 307 mtof; +#X obj 851 327 / 440; +#X obj 705 324 t b f; +#X obj 90 297 r window-size; +#X floatatom 855 361 0 0 0; +#X obj 564 556 tabreceive~ hanning; +#X obj 549 500 tabread4~ array1; +#X obj 514 524 tabread4~ array1; +#X obj 612 608 r running; +#X obj 612 632 switch~ 2048 4; +#X connect 0 0 2 1; +#X connect 1 0 2 0; +#X connect 2 0 65 0; +#X connect 2 0 25 0; +#X connect 3 0 5 1; +#X connect 4 0 5 0; +#X connect 5 0 66 0; +#X connect 5 0 25 1; +#X connect 6 0 57 1; +#X connect 7 0 57 0; +#X connect 8 0 10 1; +#X connect 9 0 10 0; +#X connect 10 0 58 1; +#X connect 10 0 54 0; +#X connect 10 0 54 1; +#X connect 11 0 55 1; +#X connect 12 0 26 0; +#X connect 13 0 1 1; +#X connect 13 0 3 1; +#X connect 13 1 0 1; +#X connect 13 1 4 1; +#X connect 14 0 9 1; +#X connect 14 0 7 1; +#X connect 14 1 6 1; +#X connect 14 1 8 1; +#X connect 15 0 14 0; +#X connect 16 0 72 0; +#X connect 17 0 44 0; +#X connect 18 0 37 0; +#X connect 18 0 45 0; +#X connect 18 0 70 0; +#X connect 19 0 34 0; +#X connect 20 0 22 0; +#X connect 21 0 22 0; +#X connect 21 1 22 1; +#X connect 22 0 32 0; +#X connect 23 0 13 0; +#X connect 24 0 12 0; +#X connect 25 0 24 1; +#X connect 28 0 27 0; +#X connect 30 0 18 0; +#X connect 31 0 27 0; +#X connect 31 0 50 0; +#X connect 31 0 83 0; +#X connect 32 0 43 2; +#X connect 32 0 38 1; +#X connect 34 0 21 0; +#X connect 35 0 68 0; +#X connect 36 0 39 0; +#X connect 36 0 18 1; +#X connect 37 0 18 1; +#X connect 38 0 37 1; +#X connect 39 0 69 0; +#X connect 40 0 43 1; +#X connect 41 0 43 0; +#X connect 41 1 40 0; +#X connect 42 0 31 0; +#X connect 43 0 42 0; +#X connect 44 0 45 1; +#X connect 45 0 41 0; +#X connect 47 0 49 0; +#X connect 49 0 50 1; +#X connect 50 0 82 0; +#X connect 53 0 9 0; +#X connect 53 0 6 0; +#X connect 54 0 55 0; +#X connect 55 0 56 0; +#X connect 56 0 58 0; +#X connect 56 0 59 0; +#X connect 57 0 59 1; +#X connect 57 0 11 0; +#X connect 57 0 11 1; +#X connect 58 0 1 0; +#X connect 58 0 4 0; +#X connect 59 0 0 0; +#X connect 59 0 3 0; +#X connect 60 0 7 0; +#X connect 60 0 8 0; +#X connect 61 0 24 0; +#X connect 62 0 63 0; +#X connect 62 1 64 1; +#X connect 63 0 64 0; +#X connect 64 0 61 0; +#X connect 67 0 10 0; +#X connect 68 0 38 0; +#X connect 71 0 47 0; +#X connect 71 0 40 1; +#X connect 72 0 71 0; +#X connect 73 0 74 0; +#X connect 74 0 75 0; +#X connect 75 0 76 0; +#X connect 76 0 77 0; +#X connect 77 0 78 0; +#X connect 77 0 80 0; +#X connect 78 0 72 0; +#X connect 78 1 72 1; +#X connect 79 0 62 0; +#X connect 81 0 23 1; +#X connect 81 0 15 1; +#X connect 81 0 12 1; +#X connect 82 0 23 0; +#X connect 83 0 15 0; +#X connect 84 0 85 0; +#X restore 291 222 pd fft-analysis; +#X msg 203 187 bang; +#X obj 38 225 samplerate~; +#X obj 38 247 s sample-rate; +#N canvas 260 23 647 768 phase-tables 0; +#N canvas 0 0 450 300 graph2 0; +#X array phase-imag 4096 float 0; +#X coords 0 1 4096 -1 400 300 1; +#X restore 234 396 graph; +#N canvas 0 0 450 300 graph3 0; +#X array phase-real 4096 float 0; +#X coords 0 1 4096 -1 400 300 1; +#X restore 232 23 graph; +#X msg 229 769 \; phase-real resize 4096 \; phase-imag resize 4096 +; +#X restore 681 423 pd phase-tables; +#N canvas 138 111 767 761 hanning-window 0; +#X obj 125 281 phasor~; +#X obj 125 319 cos~; +#X obj 31 448 tabwrite~ hanning; +#X obj 41 345 -~; +#X obj 38 298 sig~ 1; +#X msg 51 246 0; +#X text 193 19 CALCULATE HANNING; +#X text 193 37 WINDOW TABLE; +#N canvas 0 0 450 300 graph1 0; +#X array hanning 4096 float 0; +#X coords 0 1 4096 -1 400 300 1; +#X restore 375 384 graph; +#X obj 126 233 sig~; +#X text 239 202 sample rate / window size; +#X msg 31 196 bang; +#X obj 90 367 sig~ 0.5; +#X obj 67 409 *~; +#X obj 128 109 samplerate~; +#X obj 34 31 r window-size; +#X obj 34 72 t b f; +#X msg 375 746 \; hanning resize 4096; +#X obj 126 180 /; +#X connect 0 0 1 0; +#X connect 1 0 3 1; +#X connect 3 0 13 0; +#X connect 4 0 3 0; +#X connect 5 0 0 1; +#X connect 9 0 0 0; +#X connect 11 0 2 0; +#X connect 11 0 5 0; +#X connect 12 0 13 1; +#X connect 13 0 2 0; +#X connect 14 0 18 0; +#X connect 15 0 16 0; +#X connect 16 0 14 0; +#X connect 16 0 11 0; +#X connect 16 1 18 1; +#X connect 18 0 9 0; +#X restore 681 447 pd hanning-window; +#X obj 100 335 delay; +#X obj 160 332 + 100; +#X obj 139 51 route read run start hear save stop; +#X obj 895 245 timer; +#X obj 895 269 * 44.1; +#X obj 232 314 r maxoutsize; +#X obj 217 338 f; +#X msg 217 360 \; array2 resize \$1; +#X msg 100 358 \; action stop; +#X obj 186 30 r action; +#X obj 910 172 r running; +#X obj 894 195 f; +#X obj 894 219 sel 1; +#X obj 895 344 moses; +#X obj 946 345 r maxoutsize; +#X msg 895 366 \; array2 resize \$1; +#X msg 918 293 \; running 0; +#X msg 293 277 \; running 1; +#X obj 160 310 / 44.1; +#X msg 751 10 bang; +#X obj 277 92 r location; +#X obj 277 115 r speed; +#X obj 278 137 r transpo; +#X msg 43 283 \; pd dsp 1; +#X obj 503 414 int; +#X connect 0 0 1 0; +#X connect 1 0 27 0; +#X connect 2 0 39 0; +#X connect 4 0 15 0; +#X connect 5 0 4 1; +#X connect 6 0 5 0; +#X connect 7 0 8 0; +#X connect 8 0 18 0; +#X connect 9 0 10 0; +#X connect 9 0 32 0; +#X connect 10 0 9 1; +#X connect 11 0 9 1; +#X connect 14 0 4 0; +#X connect 15 0 3 0; +#X connect 15 0 3 1; +#X connect 15 0 20 0; +#X connect 16 0 17 0; +#X connect 17 0 14 1; +#X connect 18 0 19 0; +#X connect 20 0 61 0; +#X connect 21 0 23 0; +#X connect 21 1 7 0; +#X connect 22 0 25 0; +#X connect 23 0 24 0; +#X connect 24 0 22 0; +#X connect 26 0 28 0; +#X connect 27 0 26 0; +#X connect 29 0 30 0; +#X connect 31 0 13 0; +#X connect 31 0 14 0; +#X connect 32 0 33 0; +#X connect 32 0 37 0; +#X connect 32 0 40 0; +#X connect 32 0 43 0; +#X connect 32 0 13 0; +#X connect 32 0 54 0; +#X connect 32 0 60 0; +#X connect 33 0 34 0; +#X connect 37 0 45 0; +#X connect 38 0 37 1; +#X connect 39 0 0 0; +#X connect 39 1 10 0; +#X connect 39 1 32 0; +#X connect 39 2 11 0; +#X connect 39 3 16 0; +#X connect 39 4 21 0; +#X connect 39 5 56 0; +#X connect 40 0 41 0; +#X connect 41 0 53 0; +#X connect 41 0 50 0; +#X connect 42 0 43 1; +#X connect 42 0 55 0; +#X connect 43 0 44 0; +#X connect 46 0 39 0; +#X connect 47 0 48 1; +#X connect 48 0 49 0; +#X connect 49 0 40 1; +#X connect 50 0 52 0; +#X connect 51 0 50 1; +#X connect 55 0 38 0; +#X connect 56 0 48 0; +#X connect 57 0 9 0; +#X connect 58 0 9 0; +#X connect 59 0 9 0; +#X connect 61 0 12 0; +#X restore 30 290 pd guts; +#X msg 30 164 run the transformation; +#X msg 30 227 hear the output buffer again; +#X text 30 124 click below to:; +#X msg 30 248 save the output buffer; +#X floatatom 30 311 0 0 0; +#X msg 30 143 read an input file; +#X msg 30 269 save normalized to max amplitude; +#N canvas 213 187 495 352 input-sample 0; +#N canvas 0 0 450 300 graph1 0; +#X array array1 63024 float 0; +#X coords 0 1 63023 -1 400 300 1; +#X restore 55 22 graph; +#X text 146 379 INPUT SAMPLE; +#X restore 41 401 pd input-sample; +#N canvas 192 180 507 343 output-sample 0; +#N canvas 0 0 450 300 graph2 0; +#X array array2 2.646e+06 float 0; +#X coords 0 1 2.646e+06 -1 400 300 1; +#X restore 58 13 graph; +#X text 155 375 OUTPUT SAMPLE; +#X restore 41 426 pd output-sample; +#X floatatom 385 382 0 0 120; +#N canvas 194 37 397 591 output 0; +#X obj 64 196 t b; +#X obj 64 147 f; +#X obj 64 99 inlet; +#X text 68 78 mute; +#X obj 64 220 f; +#X msg 130 235 0; +#X msg 64 123 bang; +#X obj 64 172 moses 1; +#X obj 130 211 t b f; +#X obj 93 427 outlet; +#X msg 93 403 set \$1; +#X obj 180 158 moses 1; +#X obj 217 429 dbtorms; +#X obj 217 454 pack 0 100; +#X obj 180 133 r master-lvl; +#X obj 93 369 r master-lvl; +#X obj 80 276 s master-lvl; +#X obj 217 478 s master-amp; +#X obj 201 235 loadbang; +#X msg 201 260 \; master-lvl 90; +#X connect 0 0 4 0; +#X connect 1 0 7 0; +#X connect 2 0 6 0; +#X connect 4 0 16 0; +#X connect 5 0 16 0; +#X connect 6 0 1 0; +#X connect 7 0 0 0; +#X connect 7 1 8 0; +#X connect 8 0 5 0; +#X connect 10 0 9 0; +#X connect 11 1 4 1; +#X connect 12 0 13 0; +#X connect 13 0 17 0; +#X connect 14 0 1 1; +#X connect 14 0 11 0; +#X connect 15 0 10 0; +#X connect 15 0 12 0; +#X connect 18 0 19 0; +#X restore 385 361 pd output; +#X msg 385 340 mute; +#X obj 385 403 s master-lvl; +#X text 427 339 <-- mute button; +#X text 422 381 <--set me; +#X text 385 423 LINE OUT LEVEL in dB (100 norm); +#X text 14 25 This is a Fourier-based analysis/resynthesis tool.; +#X text 22 45 You can move forward or backward in the sample \, or +"freeze" at any point using the "precession" and "location" controls. +Transposition is in hundredths of a half-tone.; +#X msg 30 185 start transformation when I change controls; +#X msg 30 206 stop the transformation; +#X text 731 329 examples:; +#X msg 614 94 -40; +#X connect 0 0 5 0; +#X connect 1 0 4 1; +#X connect 2 0 4 0; +#X connect 3 0 2 0; +#X connect 3 1 1 0; +#X connect 6 0 7 0; +#X connect 7 0 0 0; +#X connect 23 0 25 0; +#X connect 26 0 23 0; +#X connect 29 0 34 0; +#X connect 30 0 29 0; +#X connect 31 0 29 0; +#X connect 33 0 29 0; +#X connect 35 0 29 0; +#X connect 36 0 29 0; +#X connect 39 0 42 0; +#X connect 40 0 39 0; +#X connect 41 0 40 0; +#X connect 48 0 29 0; +#X connect 49 0 29 0; +#X connect 51 0 2 0; diff --git a/pd/doc/7.stuff/soundfile-tools/4.looper.pd b/pd/doc/7.stuff/soundfile-tools/4.looper.pd new file mode 100644 index 00000000..0b969a42 --- /dev/null +++ b/pd/doc/7.stuff/soundfile-tools/4.looper.pd @@ -0,0 +1,338 @@ +#N canvas 0 16 878 417 12; +#N canvas 213 187 495 352 input-sample 0; +#N canvas 0 0 450 300 graph1 0; +#X array array1 63024 float 0; +#X coords 0 1 63023 -1 400 300 1; +#X restore 56 23 graph; +#X text 151 393 INPUT SAMPLE; +#X restore 143 301 pd input-sample; +#N canvas 192 180 507 343 output-sample 0; +#N canvas 0 0 450 300 graph2 0; +#X array array2 441000 float 0; +#X coords 0 1 440999 -1 400 300 1; +#X restore 60 13 graph; +#X text 161 388 OUTPUT SAMPLE; +#X restore 143 325 pd output-sample; +#N canvas 41 102 912 552 guts 0; +#X msg 25 133 bang; +#X obj 15 468 openpanel; +#X obj 144 28 inlet; +#X obj 478 392 dac~; +#X obj 478 342 *~; +#X obj 494 301 line~; +#X obj 494 276 r master-amp; +#X msg 759 352 bang; +#X obj 759 377 savepanel; +#X obj 274 203 spigot; +#X msg 248 133 0; +#X msg 281 133 1; +#X obj 555 384 outlet; +#X obj 268 325 tabwrite~ array2; +#X msg 262 232 bang; +#X obj 456 312 +~; +#X obj 478 367 hip~ 7; +#X msg 480 228 bang; +#X obj 480 253 tabplay~ array2; +#X msg 759 402 write \$1 array2; +#X obj 759 427 soundfiler; +#N canvas 92 118 921 631 audio-transformation 0; +#X obj 320 509 outlet~; +#X obj 221 41 r transposition; +#X obj 287 175 r looplength; +#X obj 221 66 / 120; +#X obj 235 139 pow; +#X obj 221 91 t b f; +#X msg 221 115 2; +#X text 305 107 2 to the power (octaves); +#X text 304 123 gives speed change for the; +#X text 305 141 desired transposition; +#X text 280 65 transposition in octaves; +#X obj 470 264 * 441; +#X floatatom 470 234 0 0 0; +#X obj 426 352 samphold~; +#X obj 545 335 -~ 0.5; +#X obj 545 461 clip~ -0.5 0.5; +#X obj 545 437 *~ 1; +#X obj 545 486 cos~; +#X obj 545 365 wrap~; +#X obj 545 400 -~ 0.5; +#X obj 545 532 *~ -0.5; +#X obj 545 508 -~ 1; +#X floatatom 617 406 0 0 0; +#X obj 601 254 r smoothing; +#X obj 470 208 r startpoint; +#X obj 617 431 max 1; +#X obj 602 308 max 0.001; +#X obj 602 334 t b f; +#X obj 602 358 1; +#X obj 617 382 /; +#X obj 320 482 *~; +#X obj 320 456 tabread4~ array1; +#X obj 320 430 +~; +#X obj 227 472 print~; +#X msg 227 443 bang; +#X obj 601 61 loadbang; +#X msg 598 91 \; transposition 0 \; looplength 0 \; startpoint 0 \; +smoothing 0; +#X obj 236 263 ../../../extra/loop~; +#X obj 285 233 * 441; +#X obj 284 307 *~; +#X obj 133 41 loadbang; +#X obj 78 174 r running; +#X obj 78 203 sel 1; +#X obj 602 282 * 0.01; +#X obj 286 202 max 0.01; +#X connect 1 0 3 0; +#X connect 2 0 44 0; +#X connect 3 0 5 0; +#X connect 4 0 37 0; +#X connect 5 0 6 0; +#X connect 5 1 4 1; +#X connect 6 0 4 0; +#X connect 11 0 13 0; +#X connect 12 0 11 0; +#X connect 13 0 32 1; +#X connect 14 0 18 0; +#X connect 15 0 17 0; +#X connect 16 0 15 0; +#X connect 17 0 21 0; +#X connect 18 0 19 0; +#X connect 19 0 16 0; +#X connect 20 0 30 1; +#X connect 21 0 20 0; +#X connect 22 0 25 0; +#X connect 23 0 43 0; +#X connect 24 0 12 0; +#X connect 25 0 16 1; +#X connect 26 0 27 0; +#X connect 27 0 28 0; +#X connect 27 1 29 1; +#X connect 28 0 29 0; +#X connect 29 0 22 0; +#X connect 30 0 0 0; +#X connect 31 0 30 0; +#X connect 32 0 31 0; +#X connect 32 0 33 0; +#X connect 34 0 33 0; +#X connect 35 0 36 0; +#X connect 37 0 13 1; +#X connect 37 0 39 0; +#X connect 37 0 14 0; +#X connect 37 1 39 1; +#X connect 38 0 37 1; +#X connect 39 0 32 0; +#X connect 40 0 3 0; +#X connect 41 0 42 0; +#X connect 42 0 37 0; +#X connect 43 0 26 0; +#X connect 44 0 38 0; +#X restore 274 283 pd audio-transformation; +#X obj 553 331 env~ 16384; +#X obj 665 317 route normalized; +#X msg 667 457 write -normalize \$1 array2; +#X msg 667 407 bang; +#X obj 667 432 savepanel; +#X obj 667 482 soundfiler; +#X obj 15 518 soundfiler; +#X msg 15 493 read -resize -maxsize 1e+06 \$1 array1; +#X obj 330 100 r transposition; +#X obj 330 125 r looplength; +#X obj 330 175 r smoothing; +#X obj 708 110 timer; +#X obj 708 135 * 44.1; +#X obj 724 37 r running; +#X obj 708 60 f; +#X obj 708 85 sel 1; +#X obj 708 227 moses; +#X obj 753 227 r maxoutsize; +#X msg 708 252 \; array2 resize \$1; +#X msg 685 37 bang; +#X obj 144 53 route read run start hear save stop; +#X obj 312 427 delay; +#X obj 331 404 + 100; +#X obj 145 329 r maxoutsize; +#X obj 86 329 f; +#X msg 86 354 \; array2 resize \$1; +#X msg 312 452 \; action stop; +#X obj 331 379 / 44.1; +#X msg 62 271 \; pd dsp 1; +#X msg 334 240 \; running 1; +#X obj 202 28 r action; +#X msg 733 160 \; running 0 \; pd dsp 0; +#X obj 330 150 r startpoint; +#X obj 553 357 int; +#X connect 0 0 1 0; +#X connect 1 0 29 0; +#X connect 2 0 42 0; +#X connect 4 0 16 0; +#X connect 5 0 4 1; +#X connect 6 0 5 0; +#X connect 7 0 8 0; +#X connect 8 0 19 0; +#X connect 9 0 10 0; +#X connect 9 0 14 0; +#X connect 10 0 9 1; +#X connect 11 0 9 1; +#X connect 14 0 13 0; +#X connect 14 0 46 0; +#X connect 14 0 43 0; +#X connect 14 0 50 0; +#X connect 14 0 51 0; +#X connect 14 0 33 0; +#X connect 15 0 4 0; +#X connect 15 0 22 0; +#X connect 16 0 3 0; +#X connect 16 0 3 1; +#X connect 17 0 18 0; +#X connect 18 0 15 1; +#X connect 19 0 20 0; +#X connect 21 0 13 0; +#X connect 21 0 15 0; +#X connect 22 0 55 0; +#X connect 23 0 25 0; +#X connect 23 1 7 0; +#X connect 24 0 27 0; +#X connect 25 0 26 0; +#X connect 26 0 24 0; +#X connect 29 0 28 0; +#X connect 30 0 9 0; +#X connect 31 0 9 0; +#X connect 32 0 9 0; +#X connect 33 0 34 0; +#X connect 34 0 53 0; +#X connect 34 0 38 0; +#X connect 35 0 36 1; +#X connect 36 0 37 0; +#X connect 37 0 33 1; +#X connect 38 0 40 0; +#X connect 39 0 38 1; +#X connect 41 0 36 0; +#X connect 42 0 0 0; +#X connect 42 1 14 0; +#X connect 42 1 10 0; +#X connect 42 2 11 0; +#X connect 42 3 17 0; +#X connect 42 4 23 0; +#X connect 42 5 41 0; +#X connect 43 0 48 0; +#X connect 44 0 43 1; +#X connect 45 0 46 1; +#X connect 45 0 49 0; +#X connect 46 0 47 0; +#X connect 49 0 44 0; +#X connect 52 0 42 0; +#X connect 54 0 9 0; +#X connect 55 0 12 0; +#X restore 19 228 pd guts; +#X msg 19 96 run the transformation; +#X msg 19 163 hear the output buffer again; +#X text 19 55 click below to:; +#X msg 19 185 save the output buffer; +#X floatatom 367 337 0 0 120; +#N canvas 194 37 397 591 output 0; +#X obj 66 203 t b; +#X obj 66 152 f; +#X obj 66 102 inlet; +#X text 71 81 mute; +#X obj 66 228 f; +#X msg 134 244 0; +#X msg 66 127 bang; +#X obj 66 178 moses 1; +#X obj 134 218 t b f; +#X obj 96 442 outlet; +#X msg 96 416 set \$1; +#X obj 186 163 moses 1; +#X obj 224 444 dbtorms; +#X obj 224 469 pack 0 100; +#X obj 186 138 r master-lvl; +#X obj 96 382 r master-lvl; +#X obj 83 286 s master-lvl; +#X obj 224 494 s master-amp; +#X obj 208 244 loadbang; +#X msg 208 269 \; master-lvl 90; +#X connect 0 0 4 0; +#X connect 1 0 7 0; +#X connect 2 0 6 0; +#X connect 4 0 16 0; +#X connect 5 0 16 0; +#X connect 6 0 1 0; +#X connect 7 0 0 0; +#X connect 7 1 8 0; +#X connect 8 0 5 0; +#X connect 10 0 9 0; +#X connect 11 1 4 1; +#X connect 12 0 13 0; +#X connect 13 0 17 0; +#X connect 14 0 1 1; +#X connect 14 0 11 0; +#X connect 15 0 10 0; +#X connect 15 0 12 0; +#X connect 18 0 19 0; +#X restore 367 316 pd output; +#X msg 367 294 mute; +#X obj 367 359 s master-lvl; +#X text 410 293 <-- mute button; +#X floatatom 19 250 0 0 0; +#X text 20 294 100 maximum; +#X text 20 276 output meter; +#X text 405 336 <--set me; +#X msg 19 74 read an input file; +#X text 367 379 LINE OUT LEVEL in dB (100 norm); +#X msg 19 206 save normalized to max amplitude; +#X floatatom 368 73 0 0 1000; +#X floatatom 369 19 0 0 0; +#X obj 369 47 s transposition; +#X floatatom 369 170 0 0 100; +#X obj 369 192 s smoothing; +#X obj 368 95 s looplength; +#X text 418 73 <- loop length \, hundredths of a second; +#X floatatom 369 122 0 0 60000; +#X obj 369 144 s startpoint; +#X text 420 123 <- start point \, hundredths of a second; +#X text 419 171 <- envelope smoothing \, 0-100; +#X text 38 9 looping sample player.; +#X msg 19 118 start looping when I change something; +#X msg 19 140 stop looping; +#X floatatom 368 239 0 0 60; +#N canvas 0 0 265 196 length 0; +#X obj 48 24 inlet; +#X obj 49 104 * 44100; +#X msg 86 130 \; array2 resize \$1; +#X obj 48 49 min 60; +#X obj 62 78 s output-length; +#X obj 48 164 s maxoutsize; +#X connect 0 0 3 0; +#X connect 1 0 2 0; +#X connect 1 0 5 0; +#X connect 3 0 1 0; +#X connect 3 0 4 0; +#X restore 368 260 pd length; +#N canvas 219 38 198 151 /SUBPATCH/ 0; +#X obj 79 122 outlet; +#X obj 79 74 loadbang; +#X msg 79 98 10; +#X connect 1 0 2 0; +#X connect 2 0 0 0; +#X restore 368 217 pd; +#X text 455 241 length in seconds of the output; +#X text 453 259 buffer... maximum 60; +#X text 404 241 <- set; +#X text 408 20 <- transposition up or down \, 10ths of a half step +; +#X connect 2 0 12 0; +#X connect 3 0 2 0; +#X connect 4 0 2 0; +#X connect 6 0 2 0; +#X connect 7 0 10 0; +#X connect 8 0 7 0; +#X connect 9 0 8 0; +#X connect 16 0 2 0; +#X connect 18 0 2 0; +#X connect 19 0 24 0; +#X connect 20 0 21 0; +#X connect 22 0 23 0; +#X connect 26 0 27 0; +#X connect 31 0 2 0; +#X connect 32 0 2 0; +#X connect 33 0 34 0; +#X connect 35 0 33 0; diff --git a/pd/doc/7.stuff/soundfile-tools/5.reverb.pd b/pd/doc/7.stuff/soundfile-tools/5.reverb.pd new file mode 100644 index 00000000..0b0cdb11 --- /dev/null +++ b/pd/doc/7.stuff/soundfile-tools/5.reverb.pd @@ -0,0 +1,214 @@ +#N canvas 186 43 739 364 12; +#N canvas 213 187 495 352 input-sample 0; +#N canvas 0 0 450 300 graph1 0; +#X array array1 63024 float 0; +#X coords 0 1 63023 -1 400 300 1; +#X restore 54 22 graph; +#X text 145 376 INPUT SAMPLE; +#X restore 154 226 pd input-sample; +#N canvas 192 180 507 343 output-sample 0; +#N canvas 0 0 450 300 graph2 0; +#X array array2 504024 float 0; +#X coords 0 1 504023 -1 400 300 1; +#X restore 57 13 graph; +#X text 154 372 OUTPUT SAMPLE; +#X restore 155 249 pd output-sample; +#N canvas 116 150 735 421 guts 0; +#X msg 24 128 bang; +#X obj 24 345 openpanel; +#X obj 138 30 inlet; +#X obj 446 368 dac~; +#X obj 446 327 *~; +#X obj 461 304 line~; +#X obj 461 283 r master-amp; +#X msg 707 85 bang; +#X obj 707 106 savepanel; +#X obj 268 161 spigot; +#X msg 253 128 0; +#X msg 284 128 1; +#X obj 500 398 outlet; +#X obj 316 128 r frequency; +#X obj 256 312 tabwrite~ array2; +#X msg 256 189 bang; +#X obj 427 276 +~; +#X msg 139 128 \; pd dsp 1; +#X obj 446 347 hip~ 7; +#X obj 268 217 tabplay~ array1; +#X msg 442 124 bang; +#X obj 442 145 tabplay~ array2; +#X msg 707 126 write \$1 array2; +#X obj 707 147 soundfiler; +#X obj 138 51 route read run start hear save; +#N canvas 0 0 632 395 audio-transformation 0; +#X obj 101 49 inlet~; +#X obj 105 268 outlet~; +#X obj 101 148 ../../../extra/rev1~ xxx; +#X obj 339 79 r revgain; +#X obj 338 102 dbtorms; +#X obj 338 130 pack 0 50; +#X obj 338 154 line~; +#X obj 103 204 *~; +#X obj 181 51 r revtime; +#X obj 213 236 *~; +#X obj 340 209 dbtorms; +#X obj 340 237 pack 0 50; +#X obj 340 261 line~; +#X obj 294 37 inlet; +#X msg 293 61 bang; +#X obj 342 186 r drygain; +#X connect 0 0 2 0; +#X connect 0 0 9 0; +#X connect 2 0 7 0; +#X connect 3 0 4 0; +#X connect 4 0 5 0; +#X connect 5 0 6 0; +#X connect 6 0 7 1; +#X connect 7 0 1 0; +#X connect 8 0 2 1; +#X connect 9 0 1 0; +#X connect 10 0 11 0; +#X connect 11 0 12 0; +#X connect 12 0 9 1; +#X connect 13 0 14 0; +#X connect 14 0 2 2; +#X connect 15 0 10 0; +#X restore 268 238 pd audio-transformation; +#X obj 500 377 env~ 16384; +#X obj 570 86 route normalized; +#X msg 570 179 write -normalize \$1 array2; +#X msg 570 138 bang; +#X obj 570 159 savepanel; +#X obj 570 204 soundfiler; +#X obj 24 396 soundfiler; +#X msg 24 374 read -resize -maxsize 1e+06 \$1 array1; +#X msg 24 440 \; array2 resize \$1; +#X obj 402 129 r q; +#X obj 24 419 + 441000; +#X connect 0 0 1 0; +#X connect 1 0 33 0; +#X connect 2 0 24 0; +#X connect 4 0 18 0; +#X connect 5 0 4 1; +#X connect 6 0 5 0; +#X connect 7 0 8 0; +#X connect 8 0 22 0; +#X connect 9 0 10 0; +#X connect 9 0 15 0; +#X connect 10 0 9 1; +#X connect 11 0 9 1; +#X connect 13 0 9 0; +#X connect 15 0 14 0; +#X connect 15 0 19 0; +#X connect 15 0 25 1; +#X connect 16 0 4 0; +#X connect 18 0 3 0; +#X connect 18 0 3 1; +#X connect 18 0 26 0; +#X connect 19 0 25 0; +#X connect 20 0 21 0; +#X connect 21 0 16 1; +#X connect 22 0 23 0; +#X connect 24 0 0 0; +#X connect 24 1 15 0; +#X connect 24 1 10 0; +#X connect 24 1 17 0; +#X connect 24 2 11 0; +#X connect 24 2 17 0; +#X connect 24 3 20 0; +#X connect 24 4 27 0; +#X connect 25 0 14 0; +#X connect 25 0 16 0; +#X connect 26 0 12 0; +#X connect 27 0 29 0; +#X connect 27 1 7 0; +#X connect 28 0 31 0; +#X connect 29 0 30 0; +#X connect 30 0 28 0; +#X connect 32 0 36 0; +#X connect 33 0 32 0; +#X connect 35 0 9 0; +#X connect 36 0 34 0; +#X restore 35 190 pd guts; +#X msg 35 85 run the transformation; +#X msg 35 127 hear the output buffer again; +#X text 35 45 click below to:; +#X msg 35 148 save the output buffer; +#X floatatom 445 285 0 0 120; +#N canvas 194 37 397 591 output 0; +#X obj 63 194 t b; +#X obj 63 146 f; +#X obj 63 98 inlet; +#X text 68 77 mute; +#X obj 63 218 f; +#X msg 129 233 0; +#X msg 63 122 bang; +#X obj 63 170 moses 1; +#X obj 129 209 t b f; +#X obj 92 423 outlet; +#X msg 92 399 set \$1; +#X obj 178 156 moses 1; +#X obj 215 425 dbtorms; +#X obj 215 450 pack 0 100; +#X obj 178 132 r master-lvl; +#X obj 92 366 r master-lvl; +#X obj 79 274 s master-lvl; +#X obj 215 474 s master-amp; +#X obj 199 233 loadbang; +#X msg 199 258 \; master-lvl 90; +#X connect 0 0 4 0; +#X connect 1 0 7 0; +#X connect 2 0 6 0; +#X connect 4 0 16 0; +#X connect 5 0 16 0; +#X connect 6 0 1 0; +#X connect 7 0 0 0; +#X connect 7 1 8 0; +#X connect 8 0 5 0; +#X connect 10 0 9 0; +#X connect 11 1 4 1; +#X connect 12 0 13 0; +#X connect 13 0 17 0; +#X connect 14 0 1 1; +#X connect 14 0 11 0; +#X connect 15 0 10 0; +#X connect 15 0 12 0; +#X connect 18 0 19 0; +#X restore 445 264 pd output; +#X msg 445 243 mute; +#X obj 445 306 s master-lvl; +#X text 486 242 <-- mute button; +#X floatatom 35 211 0 0 0; +#X text 13 251 100 maximum; +#X text 13 233 output meter; +#X text 482 284 <--set me; +#X msg 35 64 read an input file; +#X text 445 326 LINE OUT LEVEL in dB (100 norm); +#X msg 35 169 save normalized to max amplitude; +#X msg 35 106 start transformation when I change f or q; +#X floatatom 445 82 0 0 120; +#X floatatom 445 40 0 0 100; +#X obj 445 61 s revtime; +#X obj 445 103 s revgain; +#X floatatom 446 184 0 0 120; +#X text 494 84 <-- reverb gain; +#X text 482 185 <-- dry gain; +#X obj 446 205 s drygain; +#X obj 446 142 loadbang; +#X msg 446 163 100; +#X text 486 39 <- reverb time 0-100; +#X text 23 15 Reverberator. Read in a sample first.; +#X connect 2 0 12 0; +#X connect 3 0 2 0; +#X connect 4 0 2 0; +#X connect 6 0 2 0; +#X connect 7 0 10 0; +#X connect 8 0 7 0; +#X connect 9 0 8 0; +#X connect 16 0 2 0; +#X connect 18 0 2 0; +#X connect 19 0 2 0; +#X connect 20 0 23 0; +#X connect 21 0 22 0; +#X connect 24 0 27 0; +#X connect 28 0 29 0; +#X connect 29 0 24 0; diff --git a/pd/doc/7.stuff/soundfile-tools/6.vocoder.pd b/pd/doc/7.stuff/soundfile-tools/6.vocoder.pd new file mode 100644 index 00000000..ce822ef4 --- /dev/null +++ b/pd/doc/7.stuff/soundfile-tools/6.vocoder.pd @@ -0,0 +1,314 @@ +#N canvas 73 102 706 428 12; +#X floatatom 462 162 0 0 100; +#X msg 462 137 set \$1; +#X text 29 322 100 maximum; +#X text 29 304 output meter; +#N canvas 145 136 937 540 guts 0; +#X msg 5 296 bang; +#X obj 5 321 openpanel; +#X obj 136 29 inlet; +#X obj 452 375 dac~; +#X obj 452 323 *~; +#X obj 467 300 line~; +#X obj 467 280 r master-amp; +#X msg 689 157 bang; +#X obj 689 177 savepanel; +#X obj 506 393 outlet; +#X obj 297 238 tabwrite~ array2; +#X obj 454 238 +~; +#X obj 452 343 hip~ 7; +#X msg 446 108 bang; +#X obj 446 133 tabplay~ array2; +#X msg 689 197 write \$1 array2; +#X obj 689 218 soundfiler; +#X obj 506 373 env~ 16384; +#X obj 587 129 route normalized; +#X msg 587 250 write -normalize \$1 array2; +#X msg 587 209 bang; +#X obj 587 230 savepanel; +#X obj 587 274 soundfiler; +#X obj 5 365 soundfiler; +#X msg 5 343 read -resize -maxsize 1e+06 \$1 array1; +#X obj 676 338 loadbang; +#N canvas 0 0 690 470 fft-analysis 0; +#X obj 275 314 *~; +#X obj 257 348 *~; +#X obj 218 348 *~; +#X obj 105 163 *~; +#X obj 66 156 *~; +#X obj 66 182 +~; +#X obj 216 104 *~; +#X obj 253 104 inlet~; +#X obj 216 130 rfft~; +#X obj 42 371 *~; +#X floatatom 458 208 0 0 0; +#X obj 334 177 *~; +#X obj 66 104 *~; +#X obj 103 104 inlet~; +#X obj 45 65 tabreceive~ hanning; +#X obj 66 130 rfft~; +#X obj 218 374 rifft~; +#X obj 42 397 outlet~; +#X obj 297 177 *~; +#X obj 297 203 +~; +#X obj 307 314 sig~ 0.001; +#X text 122 214 modulus; +#X obj 66 208 sqrt~; +#X obj 275 288 *~; +#X obj 457 58 r squelch; +#X obj 329 418 block~ 1024 4; +#X obj 297 229 rsqrt~; +#X obj 341 203 sig~ 1e-20; +#X obj 297 255 clip~; +#X obj 458 130 t f f; +#X obj 458 156 *; +#X obj 458 182 * 0.01; +#X obj 456 94 max 1; +#X obj 559 58 loadbang; +#X obj 458 234 max 0; +#X connect 0 0 1 1; +#X connect 0 0 2 1; +#X connect 1 0 16 1; +#X connect 2 0 16 0; +#X connect 3 0 5 1; +#X connect 4 0 5 0; +#X connect 5 0 22 0; +#X connect 6 0 8 0; +#X connect 7 0 6 1; +#X connect 8 0 18 0; +#X connect 8 0 18 1; +#X connect 8 0 2 0; +#X connect 8 1 11 0; +#X connect 8 1 11 1; +#X connect 8 1 1 0; +#X connect 9 0 17 0; +#X connect 10 0 34 0; +#X connect 11 0 19 1; +#X connect 12 0 15 0; +#X connect 13 0 12 1; +#X connect 14 0 12 0; +#X connect 14 0 6 0; +#X connect 14 0 9 0; +#X connect 15 0 4 0; +#X connect 15 0 4 1; +#X connect 15 1 3 0; +#X connect 15 1 3 1; +#X connect 16 0 9 1; +#X connect 18 0 19 0; +#X connect 19 0 26 0; +#X connect 20 0 0 1; +#X connect 22 0 23 0; +#X connect 23 0 0 0; +#X connect 24 0 32 0; +#X connect 26 0 28 0; +#X connect 27 0 26 0; +#X connect 28 0 23 1; +#X connect 29 0 30 0; +#X connect 29 0 30 1; +#X connect 30 0 31 0; +#X connect 31 0 10 0; +#X connect 32 0 29 0; +#X connect 33 0 32 0; +#X connect 34 0 28 2; +#X restore 296 194 pd fft-analysis; +#X msg 202 86 bang; +#N canvas 46 0 723 534 hanning-window 0; +#X obj 122 273 phasor~; +#X obj 122 311 cos~; +#X obj 31 436 tabwrite~ hanning; +#X obj 40 336 -~; +#X obj 37 290 sig~ 1; +#X msg 50 240 0; +#X text 188 18 CALCULATE HANNING; +#X text 188 36 WINDOW TABLE; +#N canvas 0 0 450 300 graph1 0; +#X array hanning 1024 float 0; +#X coords 0 1 1023 -1 400 300 1; +#X restore 342 235 graph; +#X obj 123 227 sig~; +#X text 156 173 sample rate / window size; +#X msg 31 191 bang; +#X obj 88 357 sig~ 0.5; +#X obj 66 399 *~; +#X obj 124 106 samplerate~; +#X obj 33 31 r window-size; +#X obj 123 175 /; +#X msg 262 106 \; hanning resize \$1; +#X obj 31 70 t b f f; +#X connect 0 0 1 0; +#X connect 1 0 3 1; +#X connect 3 0 13 0; +#X connect 4 0 3 0; +#X connect 5 0 0 1; +#X connect 9 0 0 0; +#X connect 11 0 2 0; +#X connect 11 0 5 0; +#X connect 12 0 13 1; +#X connect 13 0 2 0; +#X connect 14 0 16 0; +#X connect 15 0 18 0; +#X connect 16 0 9 0; +#X connect 18 0 14 0; +#X connect 18 0 11 0; +#X connect 18 1 16 1; +#X connect 18 2 17 0; +#X restore 673 403 pd hanning-window; +#X obj 181 29 r action; +#X msg 150 163 \; pd dsp 1; +#X msg 389 106 stop; +#X msg 58 455 \; array2 resize \$1; +#X obj 58 434 + 4410; +#X obj 136 50 route read AND run hear save stop; +#X obj 58 412 min; +#X obj 107 380 t b f; +#X obj 107 270 openpanel; +#X obj 107 314 soundfiler; +#X msg 107 293 read -resize -maxsize 1e+06 \$1 array3; +#X msg 106 239 bang; +#X msg 676 360 \; window-size 1024 \;; +#X obj 296 145 tabplay~ array1; +#X obj 314 167 tabplay~ array3; +#X connect 0 0 1 0; +#X connect 1 0 24 0; +#X connect 2 0 34 0; +#X connect 4 0 12 0; +#X connect 5 0 4 1; +#X connect 6 0 5 0; +#X connect 7 0 8 0; +#X connect 8 0 15 0; +#X connect 11 0 4 0; +#X connect 12 0 3 0; +#X connect 12 0 3 1; +#X connect 12 0 17 0; +#X connect 13 0 14 0; +#X connect 14 0 11 1; +#X connect 15 0 16 0; +#X connect 17 0 9 0; +#X connect 18 0 20 0; +#X connect 18 1 7 0; +#X connect 19 0 22 0; +#X connect 20 0 21 0; +#X connect 21 0 19 0; +#X connect 23 0 35 0; +#X connect 24 0 23 0; +#X connect 25 0 41 0; +#X connect 26 0 10 0; +#X connect 26 0 11 0; +#X connect 27 0 10 0; +#X connect 27 0 30 0; +#X connect 27 0 42 0; +#X connect 27 0 43 0; +#X connect 29 0 34 0; +#X connect 31 0 14 0; +#X connect 33 0 32 0; +#X connect 34 0 0 0; +#X connect 34 1 40 0; +#X connect 34 2 27 0; +#X connect 34 3 13 0; +#X connect 34 4 18 0; +#X connect 34 5 31 0; +#X connect 35 0 33 0; +#X connect 36 0 35 0; +#X connect 36 1 35 1; +#X connect 37 0 39 0; +#X connect 38 0 36 0; +#X connect 39 0 38 0; +#X connect 40 0 37 0; +#X connect 42 0 26 0; +#X connect 43 0 26 1; +#X restore 29 263 pd guts; +#X msg 29 158 run the transformation; +#X msg 29 200 hear the output buffer again; +#X text 29 97 click below to:; +#X msg 29 221 save the output buffer; +#X floatatom 29 284 0 0 0; +#X msg 29 242 save normalized to max amplitude; +#N canvas 130 10 488 287 input-sample 0; +#N canvas 0 0 450 300 graph1 0; +#X array array1 188955 float 0; +#X coords 0 1 188954 -1 400 100 1; +#X restore 53 21 graph; +#N canvas 0 0 450 300 graph3 0; +#X array array3 225280 float 0; +#X coords 0 1 225279 -1 400 100 1; +#X restore 54 146 graph; +#X text 227 279 INPUT SAMPLES; +#X restore 169 368 pd input-sample; +#N canvas 192 180 507 343 output-sample 0; +#N canvas 0 0 450 300 graph2 0; +#X array array2 193365 float 0; +#X coords 0 1 193364 -1 400 300 1; +#X restore 56 12 graph; +#X text 151 365 OUTPUT SAMPLE; +#X restore 168 393 pd output-sample; +#X floatatom 408 365 0 0 0; +#N canvas 194 37 397 591 output 0; +#X obj 62 191 t b; +#X obj 62 144 f; +#X obj 62 96 inlet; +#X text 67 76 mute; +#X obj 62 215 f; +#X msg 127 229 0; +#X msg 62 120 bang; +#X obj 62 167 moses 1; +#X obj 127 206 t b f; +#X obj 90 416 outlet; +#X msg 90 392 set \$1; +#X obj 175 154 moses 1; +#X obj 211 418 dbtorms; +#X obj 211 442 pack 0 100; +#X obj 175 130 r master-lvl; +#X obj 90 359 r master-lvl; +#X obj 78 269 s master-lvl; +#X obj 211 466 s master-amp; +#X obj 195 229 loadbang; +#X msg 195 253 \; master-lvl 90; +#X connect 0 0 4 0; +#X connect 1 0 7 0; +#X connect 2 0 6 0; +#X connect 4 0 16 0; +#X connect 5 0 16 0; +#X connect 6 0 1 0; +#X connect 7 0 0 0; +#X connect 7 1 8 0; +#X connect 8 0 5 0; +#X connect 10 0 9 0; +#X connect 11 1 4 1; +#X connect 12 0 13 0; +#X connect 13 0 17 0; +#X connect 14 0 1 1; +#X connect 14 0 11 0; +#X connect 15 0 10 0; +#X connect 15 0 12 0; +#X connect 18 0 19 0; +#X restore 408 344 pd output; +#X msg 408 323 mute; +#X obj 408 386 s master-lvl; +#X text 449 322 <-- mute button; +#X text 444 363 <--set me; +#X text 408 406 LINE OUT LEVEL in dB (100 norm); +#X msg 29 179 stop the transformation; +#X text 193 9 (old-fashioned) VOCODER; +#X text 28 31 This takes in two soundfiles and uses the first to "vocode" +the second. THe resulting sound is as long as the shorter of the two +inputs.; +#X msg 29 116 read the analysis sound from file; +#X msg 29 137 AND read the sound to be processed from file; +#X text 462 97 SQUELCH; +#X obj 462 116 r squelch; +#X obj 462 187 s squelch; +#X text 526 161 1-100 or so; +#X connect 0 0 27 0; +#X connect 1 0 0 0; +#X connect 4 0 9 0; +#X connect 5 0 4 0; +#X connect 6 0 4 0; +#X connect 8 0 4 0; +#X connect 10 0 4 0; +#X connect 13 0 16 0; +#X connect 14 0 13 0; +#X connect 15 0 14 0; +#X connect 20 0 4 0; +#X connect 23 0 4 0; +#X connect 24 0 4 0; +#X connect 26 0 1 0; diff --git a/pd/doc/7.stuff/soundfile-tools/README.txt b/pd/doc/7.stuff/soundfile-tools/README.txt new file mode 100644 index 00000000..1670af3f --- /dev/null +++ b/pd/doc/7.stuff/soundfile-tools/README.txt @@ -0,0 +1,2 @@ +Here are some standard audio transformations packaged to work with mono
+soundfiles.
diff --git a/pd/doc/7.stuff/synth/1.poly.synth.pd b/pd/doc/7.stuff/synth/1.poly.synth.pd new file mode 100644 index 00000000..bd2a95a8 --- /dev/null +++ b/pd/doc/7.stuff/synth/1.poly.synth.pd @@ -0,0 +1,311 @@ +#N canvas 232 162 657 719 12; +#X floatatom 424 666 0 0 100; +#N canvas 269 205 698 344 output 0; +#X obj 388 156 t b; +#X obj 388 105 f; +#X obj 388 54 inlet; +#X obj 388 181 f; +#X msg 482 174 0; +#X msg 388 79 bang; +#X obj 388 130 moses 1; +#X obj 482 149 t b f; +#X obj 444 111 moses 1; +#X obj 91 148 dbtorms; +#X obj 444 86 r master-lvl; +#X obj 91 48 r master-lvl; +#X obj 388 207 s master-lvl; +#X obj 28 169 inlet~; +#X obj 213 195 inlet; +#X obj 229 218 s master-lvl; +#X msg 101 72 set \$1; +#X obj 101 98 outlet; +#X msg 213 241 \; pd dsp 1; +#X obj 91 201 line~; +#X obj 31 219 *~; +#X obj 31 247 dac~; +#X obj 91 173 pack 0 50; +#X text 17 149 audio in; +#X obj 28 194 hip~ 1; +#X connect 0 0 3 0; +#X connect 1 0 6 0; +#X connect 2 0 5 0; +#X connect 3 0 12 0; +#X connect 4 0 12 0; +#X connect 5 0 1 0; +#X connect 6 0 0 0; +#X connect 6 1 7 0; +#X connect 7 0 4 0; +#X connect 8 1 3 1; +#X connect 9 0 22 0; +#X connect 10 0 1 1; +#X connect 10 0 8 0; +#X connect 11 0 9 0; +#X connect 11 0 16 0; +#X connect 13 0 24 0; +#X connect 14 0 15 0; +#X connect 14 0 18 0; +#X connect 16 0 17 0; +#X connect 19 0 20 1; +#X connect 20 0 21 0; +#X connect 20 0 21 1; +#X connect 22 0 19 0; +#X connect 24 0 20 0; +#X restore 386 690 pd output; +#X msg 462 666 MUTE; +#X obj 16 382 unpack; +#X obj 16 299 notein; +#X obj 16 327 pack; +#X obj 329 213 numset amp x; +#X obj 329 242 numset aa x; +#X obj 329 329 numset ar x; +#X obj 329 271 numset ad x; +#X obj 329 300 numset as x; +#N canvas 248 85 884 761 synth 0; +#X obj 114 588 synthvoice; +#X obj 114 561 synthvoice; +#X obj 114 534 synthvoice; +#X obj 114 507 synthvoice; +#X obj 114 480 synthvoice; +#X obj 114 453 synthvoice; +#X obj 114 426 synthvoice; +#X obj 114 399 synthvoice; +#X obj 40 91 t b f; +#X obj 22 185 f; +#X obj 44 130 + 1; +#X obj 44 158 mod 1e+06; +#X obj 317 670 outlet~; +#X obj 45 24 r syn-note; +#X obj 454 25 r syn-noteon; +#X text 445 652 todo: field to stamp note for later messages; +#X obj 22 212 + 1e+06; +#X obj 55 239 makenote; +#X obj 109 309 moses 1e+06; +#X obj 26 352 r all-off; +#X msg 26 377 stop; +#X obj 196 368 route 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16; +#X obj 317 644 synthvoice; +#X obj 317 617 synthvoice; +#X obj 317 590 synthvoice; +#X obj 317 563 synthvoice; +#X obj 317 536 synthvoice; +#X obj 317 509 synthvoice; +#X obj 317 482 synthvoice; +#X obj 317 455 synthvoice; +#X obj 55 279 poly 16 1; +#X obj 45 54 unpack 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0; +#X obj 455 51 unpack 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0; +#X obj 196 339 pack 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0; +#X connect 0 0 29 0; +#X connect 1 0 0 0; +#X connect 2 0 1 0; +#X connect 3 0 2 0; +#X connect 4 0 3 0; +#X connect 5 0 4 0; +#X connect 6 0 5 0; +#X connect 7 0 6 0; +#X connect 8 0 9 0; +#X connect 8 1 33 2; +#X connect 9 0 10 0; +#X connect 9 0 16 0; +#X connect 10 0 11 0; +#X connect 11 0 9 1; +#X connect 13 0 31 0; +#X connect 14 0 32 0; +#X connect 16 0 17 0; +#X connect 17 0 30 0; +#X connect 17 1 30 1; +#X connect 18 0 33 2; +#X connect 19 0 20 0; +#X connect 20 0 30 0; +#X connect 21 0 7 1; +#X connect 21 1 6 1; +#X connect 21 2 5 1; +#X connect 21 3 4 1; +#X connect 21 4 3 1; +#X connect 21 5 2 1; +#X connect 21 6 1 1; +#X connect 21 7 0 1; +#X connect 21 8 29 1; +#X connect 21 9 28 1; +#X connect 21 10 27 1; +#X connect 21 11 26 1; +#X connect 21 12 25 1; +#X connect 21 13 24 1; +#X connect 21 14 23 1; +#X connect 21 15 22 1; +#X connect 22 0 12 0; +#X connect 23 0 22 0; +#X connect 24 0 23 0; +#X connect 25 0 24 0; +#X connect 26 0 25 0; +#X connect 27 0 26 0; +#X connect 28 0 27 0; +#X connect 29 0 28 0; +#X connect 30 0 33 0; +#X connect 30 1 18 0; +#X connect 30 2 33 1; +#X connect 31 0 8 0; +#X connect 31 1 17 1; +#X connect 31 2 17 2; +#X connect 31 3 33 3; +#X connect 31 4 33 4; +#X connect 31 5 33 5; +#X connect 31 6 33 6; +#X connect 31 7 33 7; +#X connect 31 8 33 8; +#X connect 31 9 33 9; +#X connect 31 10 33 10; +#X connect 31 11 33 11; +#X connect 31 12 33 12; +#X connect 31 13 33 13; +#X connect 31 14 33 14; +#X connect 31 15 33 15; +#X connect 31 16 33 16; +#X connect 32 0 30 0; +#X connect 32 1 30 1; +#X connect 32 2 33 3; +#X connect 32 3 33 4; +#X connect 32 4 33 5; +#X connect 32 5 33 6; +#X connect 32 6 33 7; +#X connect 32 7 33 8; +#X connect 32 8 33 9; +#X connect 32 9 33 10; +#X connect 32 10 33 11; +#X connect 32 11 33 12; +#X connect 32 12 33 13; +#X connect 32 13 33 14; +#X connect 32 14 33 15; +#X connect 32 15 33 16; +#X connect 33 0 21 0; +#X restore 386 640 pd synth; +#X obj 24 351 r syn-midinoteon; +#X obj 16 649 s syn-noteon; +#N canvas 0 0 690 415 tables 0; +#X msg 107 49 bang; +#X obj 107 78 t b b; +#X obj 159 142 f; +#X obj 197 142 + 1; +#X msg 181 115 0; +#X obj 107 107 until; +#X obj 161 177 t f f; +#X obj 109 210 mtof; +#X obj 90 177 sel 129; +#X obj 109 237 tabwrite mtof; +#X text 48 15 patch to regenerate the mtof table; +#N canvas 0 0 450 300 graph2 0; +#X array mtof 130 float 1; +#A 0 8.1758 8.66196 9.17702 9.72272 10.3009 10.9134 11.5623 12.2499 +12.9783 13.75 14.5676 15.4339 16.3516 17.3239 18.354 19.4454 20.6017 +21.8268 23.1247 24.4997 25.9565 27.5 29.1352 30.8677 32.7032 34.6478 +36.7081 38.8909 41.2034 43.6535 46.2493 48.9994 51.9131 55 58.2705 +61.7354 65.4064 69.2957 73.4162 77.7817 82.4069 87.3071 92.4986 97.9989 +103.826 110 116.541 123.471 130.813 138.591 146.832 155.563 164.814 +174.614 184.997 195.998 207.652 220 233.082 246.942 261.626 277.183 +293.665 311.127 329.628 349.228 369.994 391.995 415.305 440 466.164 +493.883 523.251 554.365 587.33 622.254 659.255 698.456 739.989 783.991 +830.609 880 932.328 987.767 1046.5 1108.73 1174.66 1244.51 1318.51 +1396.91 1479.98 1567.98 1661.22 1760 1864.66 1975.53 2093 2217.46 2349.32 +2489.02 2637.02 2793.83 2959.96 3135.96 3322.44 3520 3729.31 3951.07 +4186.01 4434.92 4698.64 4978.03 5274.04 5587.65 5919.91 6271.93 6644.88 +7040 7458.62 7902.13 8372.02 8869.84 9397.27 9956.06 10548.1 11175.3 +11839.8 12543.9 13289.8 14080; +#X coords 0 12000 130 0 200 100 1; +#X restore 381 116 graph; +#X text 391 224 ------ 130 samples ------; +#X text 590 209 0; +#X text 592 109 12000; +#X connect 0 0 1 0; +#X connect 1 0 5 0; +#X connect 1 1 4 0; +#X connect 2 0 3 0; +#X connect 2 0 6 0; +#X connect 2 0 8 0; +#X connect 3 0 2 1; +#X connect 4 0 2 1; +#X connect 5 0 2 0; +#X connect 6 0 7 0; +#X connect 6 1 9 1; +#X connect 7 0 9 0; +#X connect 8 0 5 1; +#X restore 186 132 pd tables; +#X obj 25 117 metro 500; +#X floatatom 67 178 5 0 0; +#X obj 25 203 makenote 64 250; +#X obj 27 229 pack; +#X obj 27 253 s syn-midinoteon; +#X obj 25 98 tgl 15 0 empty empty empty 0 -6 0 8 -262144 -1 -1 0 1 +; +#X obj 329 358 numset fil x; +#X obj 329 387 numset fb x; +#X obj 329 416 numset fa x; +#X obj 329 445 numset fd x; +#X obj 329 474 numset fs x; +#X obj 329 503 numset fr x; +#X obj 329 532 numset q x; +#X floatatom 101 96 5 0 0; +#X floatatom 155 176 5 0 0; +#X floatatom 115 149 5 0 0; +#X obj 25 178 + 24; +#X obj 25 149 random 48; +#X obj 329 15 preset preset1 x; +#X obj 329 62 preset preset2 x; +#X obj 329 108 preset preset3 x; +#X obj 329 155 preset preset4 x; +#X obj 330 561 numset 2nd x; +#X obj 330 590 numset 2pc; +#X obj 16 626 pack 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0; +#X text 451 219 amplitude; +#X text 440 246 amp attack time; +#X text 445 279 amp decay time; +#X text 448 305 amp sustain level (%); +#X text 448 331 amp release time; +#X text 454 362 filter sweep; +#X text 445 392 filter base pitch; +#X text 444 424 filter attack time; +#X text 444 450 filter decay time; +#X text 448 480 filter sustain; +#X text 448 507 filter release time; +#X text 453 535 q; +#X text 450 566 2nd osc detune; +#X text 432 596 2nd osc amp (%); +#X text 508 666 OUTPUT LEVEL; +#X text 41 14 polyphonic synth with; +#X text 40 37 voice presets; +#X text 21 74 random-note tester; +#X connect 0 0 1 1; +#X connect 1 0 0 0; +#X connect 2 0 1 2; +#X connect 3 0 39 0; +#X connect 3 1 39 1; +#X connect 4 0 5 0; +#X connect 4 1 5 1; +#X connect 5 0 3 0; +#X connect 6 0 39 2; +#X connect 7 0 39 3; +#X connect 8 0 39 6; +#X connect 9 0 39 4; +#X connect 10 0 39 5; +#X connect 11 0 1 0; +#X connect 12 0 3 0; +#X connect 15 0 32 0; +#X connect 16 0 31 1; +#X connect 17 0 18 0; +#X connect 17 1 18 1; +#X connect 18 0 19 0; +#X connect 20 0 15 0; +#X connect 21 0 39 7; +#X connect 22 0 39 8; +#X connect 23 0 39 9; +#X connect 24 0 39 10; +#X connect 25 0 39 11; +#X connect 26 0 39 12; +#X connect 27 0 39 13; +#X connect 28 0 15 1; +#X connect 29 0 17 2; +#X connect 30 0 32 1; +#X connect 31 0 17 0; +#X connect 32 0 31 0; +#X connect 37 0 39 14; +#X connect 38 0 39 15; +#X connect 39 0 13 0; diff --git a/pd/doc/7.stuff/synth/README.txt b/pd/doc/7.stuff/synth/README.txt new file mode 100644 index 00000000..b6e6c994 --- /dev/null +++ b/pd/doc/7.stuff/synth/README.txt @@ -0,0 +1,7 @@ +This patch (1.poly.synth) is a polyphonic subtractive synthesizer with +a dozen or so voice parameters you can control live or via presets. Four +presets are defined. To test, recall a preset (you should see numbers pop up +in all the parameter controls) start the metronome and turn up the output +volume to around 100. + + diff --git a/pd/doc/7.stuff/synth/gadsr.pd b/pd/doc/7.stuff/synth/gadsr.pd new file mode 100644 index 00000000..242ec877 --- /dev/null +++ b/pd/doc/7.stuff/synth/gadsr.pd @@ -0,0 +1,146 @@ +#N canvas 71 56 698 578 12; +#X obj 9 412 inlet; +#X obj 24 314 inlet; +#X text 21 437 trigger; +#X obj 154 314 inlet; +#X obj 156 477 line~; +#X obj 289 316 inlet; +#X obj 426 321 inlet; +#X obj 566 321 inlet; +#X text 26 366 level; +#X obj 156 512 outlet~; +#X text 148 365 attack; +#X text 284 366 decay; +#X text 390 366 sustain; +#X text 536 374 release; +#X obj 460 480 snapshot~; +#X obj 460 452 metro 200; +#X msg 460 508 set \$1; +#X floatatom 475 13 5 0 0; +#X obj 15 286 f \$1; +#X obj 460 426 loadbang; +#X obj 13 233 loadbang; +#X obj 273 58 bng 15 250 50 0 empty empty empty 0 -6 0 8 -262144 -1 +-1; +#X obj 346 63 bng 15 250 50 0 empty empty empty 0 -6 0 8 -262144 -1 +-1; +#X msg 346 85 0; +#X obj 206 60 bng 15 250 50 0 empty empty empty 0 -6 0 8 -262144 -1 +-1; +#X msg 206 81 1; +#X msg 273 83 -1; +#X obj 143 288 f \$2; +#X floatatom 143 342 4 0 0; +#N canvas 110 169 840 732 control 0; +#X obj 368 662 outlet; +#X obj 37 46 inlet; +#X obj 170 120 inlet; +#X obj 256 121 inlet; +#X text 74 12 trigger; +#X text 167 82 level; +#X text 392 640 to line~; +#X obj 42 332 pack; +#X obj 22 152 moses; +#X text 76 168 from; +#X text 78 180 here; +#X obj 13 199 t b b; +#X text 21 170 from; +#X text 23 182 zero; +#X msg 206 336 0; +#X obj 36 302 f; +#X text 245 84 attack time; +#X obj 373 120 inlet; +#X text 362 83 decay time; +#X obj 494 119 inlet; +#X text 478 85 sustain level; +#X obj 617 117 inlet; +#X text 610 86 release time; +#X text 471 472 DECAY; +#X obj 401 423 * 0.01; +#X obj 415 329 del; +#X obj 401 397 *; +#X obj 420 358 f; +#X obj 464 454 pack; +#X obj 624 346 pack; +#X obj 50 81 sel 0; +#X msg 80 120 stop; +#X obj 68 197 t b; +#X connect 1 0 30 0; +#X connect 2 0 15 1; +#X connect 2 0 26 1; +#X connect 3 0 7 1; +#X connect 3 0 25 0; +#X connect 7 0 0 0; +#X connect 8 0 11 0; +#X connect 8 1 32 0; +#X connect 11 0 15 0; +#X connect 11 1 14 0; +#X connect 14 0 0 0; +#X connect 15 0 7 0; +#X connect 17 0 28 1; +#X connect 19 0 27 1; +#X connect 21 0 29 1; +#X connect 24 0 28 0; +#X connect 25 0 27 0; +#X connect 26 0 24 0; +#X connect 27 0 26 0; +#X connect 28 0 0 0; +#X connect 29 0 0 0; +#X connect 30 0 31 0; +#X connect 30 0 29 0; +#X connect 30 1 8 0; +#X connect 31 0 25 0; +#X connect 32 0 15 0; +#X restore 135 395 pd control; +#X obj 280 288 f \$2; +#X obj 410 286 f \$2; +#X obj 543 286 f \$2; +#X floatatom 280 345 4 0 0; +#X floatatom 410 345 4 0 0; +#X floatatom 543 346 4 0 0; +#X obj 489 74 pack 0 20; +#X msg 495 110 0; +#X obj 489 47 t f b; +#X text 104 541 gadsr - arguments: level \, attack time \, decay time +\, sustain percentage \, release time; +#X floatatom 15 341 4 0 0; +#X connect 0 0 29 0; +#X connect 1 0 40 0; +#X connect 3 0 28 0; +#X connect 4 0 9 0; +#X connect 4 0 14 0; +#X connect 5 0 33 0; +#X connect 6 0 34 0; +#X connect 7 0 35 0; +#X connect 14 0 16 0; +#X connect 15 0 14 0; +#X connect 16 0 17 0; +#X connect 17 0 38 0; +#X connect 18 0 40 0; +#X connect 19 0 15 0; +#X connect 20 0 18 0; +#X connect 20 0 27 0; +#X connect 20 0 30 0; +#X connect 20 0 31 0; +#X connect 20 0 32 0; +#X connect 21 0 26 0; +#X connect 22 0 23 0; +#X connect 23 0 29 0; +#X connect 24 0 25 0; +#X connect 25 0 29 0; +#X connect 26 0 29 0; +#X connect 27 0 28 0; +#X connect 28 0 29 2; +#X connect 29 0 4 0; +#X connect 30 0 33 0; +#X connect 31 0 34 0; +#X connect 32 0 35 0; +#X connect 33 0 29 3; +#X connect 34 0 29 4; +#X connect 35 0 29 5; +#X connect 36 0 4 0; +#X connect 37 0 29 0; +#X connect 38 0 36 0; +#X connect 38 1 37 0; +#X connect 40 0 29 1; +#X coords 0 0 1 1 200 40 1; diff --git a/pd/doc/7.stuff/synth/numset.pd b/pd/doc/7.stuff/synth/numset.pd new file mode 100644 index 00000000..fcbeb159 --- /dev/null +++ b/pd/doc/7.stuff/synth/numset.pd @@ -0,0 +1,27 @@ +#N canvas 672 25 448 396 10; +#X obj 11 240 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 0 0 10 +-262144 -1 -1 0 256; +#X obj 11 262 outlet; +#X obj 78 267 s \$1-out; +#X obj 189 49 r \$1-in; +#X obj 191 130 r \$2-in; +#X obj 191 177 route \$1 -record-; +#X obj 191 205 f; +#X obj 245 289 pack s 0; +#X obj 248 203 b; +#X obj 245 340 s \$2-out; +#X msg 245 315 add list \$1 \$2; +#X obj 248 228 symbol \$1-in; +#X connect 0 0 1 0; +#X connect 0 0 2 0; +#X connect 0 0 7 1; +#X connect 3 0 0 0; +#X connect 4 0 5 0; +#X connect 5 0 6 0; +#X connect 5 1 8 0; +#X connect 6 0 0 0; +#X connect 7 0 10 0; +#X connect 8 0 11 0; +#X connect 10 0 9 0; +#X connect 11 0 7 0; +#X coords 0 0 1 1 80 24 1; diff --git a/pd/doc/7.stuff/synth/preset.pd b/pd/doc/7.stuff/synth/preset.pd new file mode 100644 index 00000000..8148f3b0 --- /dev/null +++ b/pd/doc/7.stuff/synth/preset.pd @@ -0,0 +1,54 @@ +#N canvas 69 59 443 360 12; +#X obj 210 286 textfile; +#X obj 8 174 bng 15 250 50 0 empty empty store 16 7 0 10 -262144 -1 +-1; +#X obj 8 320 bng 15 250 50 0 empty empty recall 15 7 0 10 -262144 -1 +-1; +#X obj 408 330 tgl 10 0 empty empty empty 0 -6 0 8 -262144 -1 -1 0 +1; +#X obj 104 59 t b b b; +#X msg 219 121 clear; +#X msg 114 149 -record-; +#X obj 61 207 symbol \$1.txt; +#X obj 363 115 1; +#X obj 310 191 symbol \$1.txt; +#X obj 312 165 loadbang; +#X msg 310 216 read \$1 cr; +#X msg 62 234 write \$1 cr; +#X obj 75 299 until; +#X msg 210 322 \; \$1 \$2; +#X obj 112 175 s \$2-in; +#X obj 224 187 r \$2-out; +#X obj 77 265 t b b; +#X msg 140 268 rewind; +#X obj 308 295 print; +#X obj 224 220 spigot; +#X obj 311 126 1; +#X obj 278 124 0; +#X connect 0 0 14 0; +#X connect 0 1 13 1; +#X connect 1 0 4 0; +#X connect 2 0 17 0; +#X connect 4 0 7 0; +#X connect 4 0 8 0; +#X connect 4 0 22 0; +#X connect 4 1 6 0; +#X connect 4 2 5 0; +#X connect 4 2 21 0; +#X connect 5 0 0 0; +#X connect 6 0 15 0; +#X connect 7 0 12 0; +#X connect 8 0 3 0; +#X connect 9 0 11 0; +#X connect 10 0 9 0; +#X connect 11 0 0 0; +#X connect 12 0 0 0; +#X connect 13 0 0 0; +#X connect 16 0 20 0; +#X connect 17 0 13 0; +#X connect 17 1 18 0; +#X connect 18 0 0 0; +#X connect 20 0 0 0; +#X connect 21 0 20 1; +#X connect 22 0 20 1; +#X coords 0 0 1 1 90 35 1; diff --git a/pd/doc/7.stuff/synth/preset1.txt b/pd/doc/7.stuff/synth/preset1.txt new file mode 100644 index 00000000..38e342fc --- /dev/null +++ b/pd/doc/7.stuff/synth/preset1.txt @@ -0,0 +1,13 @@ +list 2nd-in 1200 +list q-in 0.48 +list fr-in 200 +list fs-in 37 +list fd-in 509 +list fa-in 2 +list fb-in 15 +list fil-in 51 +list as-in 81 +list ad-in 11 +list ar-in 207 +list aa-in 6 +list amp-in 94 diff --git a/pd/doc/7.stuff/synth/preset2.txt b/pd/doc/7.stuff/synth/preset2.txt new file mode 100644 index 00000000..ce0352fb --- /dev/null +++ b/pd/doc/7.stuff/synth/preset2.txt @@ -0,0 +1,13 @@ +list 2nd-in 1200 +list q-in 0.87 +list fr-in 200 +list fs-in 37 +list fd-in 509 +list fa-in 2 +list fb-in 39 +list fil-in 51 +list as-in 63 +list ad-in 1631 +list ar-in 207 +list aa-in 6 +list amp-in 90 diff --git a/pd/doc/7.stuff/synth/preset3.txt b/pd/doc/7.stuff/synth/preset3.txt new file mode 100644 index 00000000..a53f57df --- /dev/null +++ b/pd/doc/7.stuff/synth/preset3.txt @@ -0,0 +1,13 @@ +list 2nd-in 1200 +list q-in 10 +list fr-in 200 +list fs-in 46 +list fd-in 360 +list fa-in 2 +list fb-in 30 +list fil-in 73 +list as-in 63 +list ad-in 1631 +list ar-in 207 +list aa-in 6 +list amp-in 95 diff --git a/pd/doc/7.stuff/synth/preset4.txt b/pd/doc/7.stuff/synth/preset4.txt new file mode 100644 index 00000000..f9ce0b38 --- /dev/null +++ b/pd/doc/7.stuff/synth/preset4.txt @@ -0,0 +1,13 @@ +list 2nd-in 0 +list q-in 3.01 +list fr-in 200 +list fs-in 18 +list fd-in 323 +list fa-in 2 +list fb-in 6 +list fil-in 50 +list as-in 88 +list ad-in 72 +list ar-in 207 +list aa-in 6 +list amp-in 100 diff --git a/pd/doc/7.stuff/synth/synthvoice.pd b/pd/doc/7.stuff/synth/synthvoice.pd new file mode 100644 index 00000000..e43fe42d --- /dev/null +++ b/pd/doc/7.stuff/synth/synthvoice.pd @@ -0,0 +1,73 @@ +#N canvas 218 43 728 639 12; +#X obj 61 616 outlet~; +#X obj 363 475 *~; +#X obj 166 328 *~; +#X obj 166 351 *~; +#X obj 40 325 mtof; +#X obj 180 52 inlet; +#X obj 61 565 inlet~; +#X obj 61 592 +~; +#X obj 473 266 gadsr; +#X obj 166 265 gadsr; +#X obj 106 115 dbtorms; +#X obj 106 141 sqrt; +#X obj 106 166 sqrt; +#X obj 461 322 +~; +#X obj 461 348 tabread4~ mtof; +#X obj 405 464 vcf~; +#X obj 42 416 phasor~; +#X obj 106 349 + 0.3; +#X obj 106 377 phasor~; +#X obj 42 455 +~; +#X obj 180 75 unpack 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0; +#X text 173 19 on/off pitch amp a d s r filt filt-bias a d s r filt-q +2nd-interval 2nd-percentage; +#X obj 106 281 +; +#X obj 106 319 mtof; +#X obj 120 414 *~ 1; +#X obj 345 391 * 0.01; +#X obj 133 241 * 0.01; +#X connect 1 0 7 1; +#X connect 2 0 3 0; +#X connect 2 0 3 1; +#X connect 3 0 1 0; +#X connect 4 0 16 0; +#X connect 5 0 20 0; +#X connect 6 0 7 0; +#X connect 7 0 0 0; +#X connect 8 0 13 1; +#X connect 9 0 2 0; +#X connect 9 0 2 1; +#X connect 10 0 11 0; +#X connect 11 0 12 0; +#X connect 12 0 9 1; +#X connect 13 0 14 0; +#X connect 14 0 15 1; +#X connect 15 0 1 1; +#X connect 16 0 19 0; +#X connect 17 0 18 0; +#X connect 18 0 24 0; +#X connect 19 0 15 0; +#X connect 20 0 9 0; +#X connect 20 0 8 0; +#X connect 20 1 4 0; +#X connect 20 1 22 0; +#X connect 20 2 10 0; +#X connect 20 3 9 2; +#X connect 20 4 9 3; +#X connect 20 5 9 4; +#X connect 20 6 9 5; +#X connect 20 7 8 1; +#X connect 20 8 13 0; +#X connect 20 9 8 2; +#X connect 20 10 8 3; +#X connect 20 11 8 4; +#X connect 20 12 8 5; +#X connect 20 13 15 2; +#X connect 20 14 26 0; +#X connect 20 15 25 0; +#X connect 22 0 23 0; +#X connect 23 0 17 0; +#X connect 24 0 19 1; +#X connect 25 0 24 1; +#X connect 26 0 22 1; diff --git a/pd/doc/7.stuff/synth/test-gadsr.pd b/pd/doc/7.stuff/synth/test-gadsr.pd new file mode 100644 index 00000000..ea26fe46 --- /dev/null +++ b/pd/doc/7.stuff/synth/test-gadsr.pd @@ -0,0 +1,2 @@ +#N canvas 45 88 785 525 10; +#X obj 208 171 gadsr; diff --git a/pd/doc/7.stuff/tools/latency.pd b/pd/doc/7.stuff/tools/latency.pd new file mode 100644 index 00000000..ce6db34d --- /dev/null +++ b/pd/doc/7.stuff/tools/latency.pd @@ -0,0 +1,97 @@ +#N canvas 37 -7 825 630 12;
+#X obj 98 184 metro 500;
+#X obj 60 296 sig~;
+#X msg 60 267 0.5;
+#X obj 96 245 del 3;
+#X msg 96 270 0;
+#X obj 33 325 dac~;
+#X obj 286 216 adc~;
+#X obj 290 312 timer;
+#X obj 92 335 env~ 65536;
+#X floatatom 92 362 4 0 0;
+#X floatatom 339 170 4 0 0;
+#X obj 339 193 + 100;
+#X obj 339 218 dbtorms;
+#X obj 180 335 env~ 65536;
+#X floatatom 180 364 4 0 0;
+#X floatatom 290 349 4 0 0;
+#X obj 312 245 *~ 1;
+#X obj 312 282 threshold~ 0.1 5 0.05 5;
+#X obj 634 160 bonk~;
+#X obj 634 188 bng 15 250 50 0 empty empty empty 0 -6 0 8 -262144 -1
+-1;
+#X obj 508 188 osc~ 440;
+#X obj 530 214 *~ 0;
+#X obj 582 189 tgl 15 0 empty empty empty 0 -6 0 8 -262144 -1 -1 0
+1;
+#X obj 571 211 * 0.1;
+#X obj 80 25 vdl 15 1 0 3 empty empty empty 0 -6 0 8 -262144 -1 -1
+0;
+#X msg 17 138 \; pd dsp 1;
+#X obj 634 132 *~;
+#X obj 16 113 sel 0;
+#X text 100 20 off;
+#X obj 96 156 == 1;
+#X obj 80 78 t f;
+#X text 102 36 measure latency;
+#X text 100 53 test continuity;
+#X obj 582 97 == 2;
+#X text 89 381 level out;
+#X text 181 382 level in;
+#X obj 530 244 dac~;
+#X text 291 370 latency in;
+#X text 292 386 msec;
+#X text 656 188 this flashes when;
+#X text 656 207 a discontinuity is;
+#X text 657 226 detected;
+#X obj 642 105 adc~;
+#X text 328 131 you can;
+#X text 324 147 adjust gain here;
+#X text 538 66 --- continuity check ---;
+#X text 169 105 --- latency measurement ---;
+#X text 63 410 To use this patch \, connect your audio output back
+to the audio input (channel 1 should suffice.) The latency measurement
+assumes the feedback gain is at least about -14 dB - you can increase
+the input sensitivity if need be.;
+#X text 66 481 If you select "measure latency" a series of pulses are
+timed using the "threshold~" object - note that it has an uncertainty
+of 1.45 msec (at 44K1) \, so you might see the number jitter even if
+the latency is constant.;
+#X text 66 554 Select "test continuity' to see if there are interruptions
+in the sound \, either at the input or output stage. If there are \,
+the button will flash.;
+#X connect 0 0 2 0;
+#X connect 0 0 3 0;
+#X connect 0 0 7 0;
+#X connect 1 0 8 0;
+#X connect 1 0 5 0;
+#X connect 1 0 5 1;
+#X connect 2 0 1 0;
+#X connect 3 0 4 0;
+#X connect 4 0 1 0;
+#X connect 6 0 16 0;
+#X connect 7 0 15 0;
+#X connect 8 0 9 0;
+#X connect 10 0 11 0;
+#X connect 11 0 12 0;
+#X connect 12 0 16 1;
+#X connect 13 0 14 0;
+#X connect 16 0 13 0;
+#X connect 16 0 17 0;
+#X connect 17 0 7 1;
+#X connect 18 0 19 0;
+#X connect 20 0 21 0;
+#X connect 21 0 36 0;
+#X connect 21 0 36 1;
+#X connect 22 0 23 0;
+#X connect 23 0 21 1;
+#X connect 24 0 30 0;
+#X connect 26 0 18 0;
+#X connect 27 1 25 0;
+#X connect 29 0 0 0;
+#X connect 30 0 27 0;
+#X connect 30 0 29 0;
+#X connect 30 0 33 0;
+#X connect 33 0 22 0;
+#X connect 33 0 26 1;
+#X connect 42 0 26 0;
diff --git a/pd/doc/7.stuff/tools/load-meter.pd b/pd/doc/7.stuff/tools/load-meter.pd new file mode 100644 index 00000000..6a73b5a4 --- /dev/null +++ b/pd/doc/7.stuff/tools/load-meter.pd @@ -0,0 +1,21 @@ +#N canvas 161 261 299 317 12; +#X floatatom 118 256; +#X obj 118 168 cputime; +#X obj 118 28 loadbang; +#X obj 118 112 metro 1000; +#X msg 118 56 1; +#X floatatom 118 84; +#X obj 118 140 t b b; +#X obj 118 228 * 0.1; +#X obj 118 197 int; +#X text 163 84 <-- on/off; +#X text 51 284 CPU load in percent; +#X connect 1 0 8 0; +#X connect 2 0 4 0; +#X connect 3 0 6 0; +#X connect 4 0 5 0; +#X connect 5 0 3 0; +#X connect 6 0 1 0; +#X connect 6 1 1 1; +#X connect 7 0 0 0; +#X connect 8 0 7 0; diff --git a/pd/doc/7.stuff/tools/testtone.pd b/pd/doc/7.stuff/tools/testtone.pd new file mode 100644 index 00000000..965859c7 --- /dev/null +++ b/pd/doc/7.stuff/tools/testtone.pd @@ -0,0 +1,366 @@ +#N canvas 36 16 581 402 12; +#X floatatom 83 307 3 0 0; +#X obj 33 257 notein; +#X obj 33 283 stripnote; +#X floatatom 32 308 3 0 0; +#X text 35 5 Welcome to Pd ("Pure Data"). This window can test your +audio and MIDI connections. To see Pd's DOCUMENTATION select "getting +started" in the Help menu.; +#X text 236 258 MIDI OUT; +#X text 33 233 MIDI IN; +#X floatatom 175 305 3 0 0; +#X floatatom 136 304 3 0 0; +#X obj 136 279 ctlin; +#N canvas 0 0 484 446 midi 0; +#X obj 95 61 inlet; +#X obj 96 262 noteout; +#X floatatom 96 92 0 0 0; +#X obj 107 120 outlet; +#X obj 338 113 loadbang; +#X obj 96 184 metro; +#X obj 96 236 makenote; +#X floatatom 189 166 0 0 0; +#X obj 96 210 f; +#X floatatom 145 166 0 0 0; +#X floatatom 233 166 0 0 0; +#X floatatom 276 166 0 0 0; +#X msg 338 148 500; +#X msg 370 148 60; +#X msg 399 148 64; +#X msg 427 148 250; +#X text 144 145 rate; +#X text 187 145 pitch; +#X text 232 145 vel; +#X text 268 146 length; +#X obj 230 257 ctlout 1; +#X floatatom 231 228 0 0 0; +#X connect 0 0 2 0; +#X connect 2 0 3 0; +#X connect 2 0 5 0; +#X connect 4 0 12 0; +#X connect 4 0 13 0; +#X connect 4 0 14 0; +#X connect 4 0 15 0; +#X connect 5 0 8 0; +#X connect 6 0 1 0; +#X connect 6 1 1 1; +#X connect 7 0 8 1; +#X connect 8 0 6 0; +#X connect 9 0 5 1; +#X connect 10 0 6 1; +#X connect 11 0 6 2; +#X connect 12 0 9 0; +#X connect 13 0 7 0; +#X connect 14 0 10 0; +#X connect 15 0 11 0; +#X connect 21 0 20 0; +#X restore 236 308 pd midi; +#X floatatom 149 183 3 0 0; +#X floatatom 182 183 3 0 0; +#X text 24 341 PD is COPYRIGHT 1997-2002 by Miller Puckette and others +but is free for you to use for any reasonable purpose. See the file +\, LICENSE.txt in the distribution.; +#X obj 145 115 tgl 20 0 tone-ch1 tone-ch1 1 5 -8 192 12 -262144 -1 +-1 1 1; +#X obj 170 115 tgl 20 0 tone-ch2 tone-ch2 2 5 -8 192 12 -262144 -1 +-1 1 1; +#X obj 236 282 tgl 20 0 empty empty empty 20 8 0 8 -262144 -1 -1 0 +1; +#X obj 394 110 tgl 20 0 tone-monitor set-tone-monitor monitor 25 10 +192 12 -262144 -1 -1 0 1; +#X obj 36 132 vdl 20 1 0 3 tone-radio set-tone-radio empty 20 8 192 +8 -262144 -1 -1 2; +#X text 62 177 OFF; +#X text 62 154 -40; +#X text 62 131 -20; +#N canvas 0 0 536 251 more 0; +#X floatatom 42 209 0 0 0; +#X obj 42 183 f; +#X obj 79 183 + 1; +#X obj 42 150 metro 1000; +#X obj 42 123 tgl 20 0 empty empty empty 20 8 0 8 -262144 -1 -1 0 1 +; +#X msg 264 142 \; pd restart-audio; +#X text 24 30 this window has various wierd debugging stuff...; +#X text 218 97 ALSA gets twisted after a few; +#X text 216 118 hours sometimes... use this to fix:; +#X text 22 74 see if Pd's time; +#X text 22 93 measurement works:; +#X connect 1 0 2 0; +#X connect 1 0 0 0; +#X connect 2 0 1 1; +#X connect 3 0 1 0; +#X connect 4 0 3 0; +#X restore 459 298 pd more; +#X obj 393 148 tgl 20 0 tone-hipass set-tone-hipass input-hipass 25 +10 192 12 -262144 -1 -1 0 1; +#X obj 195 115 tgl 20 0 tone-ch3 tone-ch3 3 5 -8 192 12 -262144 -1 +-1 1 1; +#X obj 220 115 tgl 20 0 tone-ch4 tone-ch4 4 5 -8 192 12 -262144 -1 +-1 1 1; +#X obj 245 115 tgl 20 0 tone-ch5 tone-ch5 5 5 -8 192 12 -262144 -1 +-1 1 1; +#X obj 270 115 tgl 20 0 tone-ch6 tone-ch6 6 5 -8 192 12 -262144 -1 +-1 1 1; +#X obj 304 106 bng 15 250 50 0 tone-all empty ALL 20 8 128 12 -262144 +-1 -1; +#X obj 304 127 bng 15 250 50 0 tone-none empty NONE 20 8 128 12 -262144 +-1 -1; +#X floatatom 215 183 3 0 0; +#X floatatom 248 183 3 0 0; +#X floatatom 281 184 3 0 0; +#X floatatom 315 184 3 0 0; +#X text 164 208 AUDIO INPUT (RMS dB); +#X text 41 83 TEST; +#X text 40 103 TONE; +#X text 152 76 test tone channels:; +#N canvas 29 216 908 548 -------audio---- 0; +#X obj 182 92 hip~ 5; +#X obj 23 351 *~; +#X obj 45 324 line~; +#X obj 190 169 outlet; +#X obj 45 297 pack 0 50; +#X obj 22 134 osc~; +#X floatatom 45 245 0 0 0; +#X obj 45 270 dbtorms; +#X obj 190 143 int; +#X obj 22 66 mtof; +#X floatatom 22 43 0 0 0; +#X floatatom 22 88 0 0 0; +#X obj 22 110 sig~; +#X obj 190 117 env~ 8192; +#X obj 182 39 adc~ 1; +#X obj 23 377 s~ tone-osc; +#X obj 45 162 r tone-radio; +#X obj 22 18 r tone-pitch; +#X obj 45 190 sel 0 1 2; +#X msg 114 213 0; +#X msg 45 215 80; +#X msg 78 215 60; +#X obj 192 192 r~ tone-mon; +#X obj 201 327 line~; +#X obj 182 217 *~; +#X obj 201 300 pack 0 50; +#X obj 201 274 r tone-ch1; +#X obj 192 247 r~ tone-osc; +#X obj 192 352 *~; +#X obj 182 407 dac~ 1; +#X obj 182 382 +~; +#X obj 190 65 r tone-hip; +#X obj 16 487 s~ tone-mon; +#X obj 16 461 line~; +#X obj 17 433 pack 0 50; +#X obj 17 407 r tone-monitor; +#X obj 302 91 hip~ 5; +#X obj 310 168 outlet; +#X obj 310 142 int; +#X obj 310 116 env~ 8192; +#X obj 312 191 r~ tone-mon; +#X obj 321 326 line~; +#X obj 302 216 *~; +#X obj 321 299 pack 0 50; +#X obj 312 246 r~ tone-osc; +#X obj 312 351 *~; +#X obj 302 381 +~; +#X obj 310 64 r tone-hip; +#X obj 302 38 adc~ 2; +#X obj 302 406 dac~ 2; +#X obj 321 273 r tone-ch2; +#X obj 177 485 * 5; +#X obj 177 510 s tone-hip; +#X obj 179 459 r tone-hipass; +#N canvas 499 63 548 519 glue+loadbang 0; +#X obj 171 21 loadbang; +#X msg 171 49 \; pd dsp 1 \; tone-pitch 69 \; tone-radio 2 \; set-tone-radio +2 \; tone-all 1 \;; +#X obj 171 176 r tone-all; +#X msg 171 204 \; tone-ch1 1 \; tone-ch2 1 \; tone-ch3 1 \; tone-ch4 +1 \; tone-ch5 1 \; tone-ch6 1; +#X obj 168 323 r tone-none; +#X msg 168 352 \; tone-ch1 0 \; tone-ch2 0 \; tone-ch3 0 \; tone-ch4 +0 \; tone-ch5 0 \; tone-ch6 0; +#X connect 0 0 1 0; +#X connect 2 0 3 0; +#X connect 4 0 5 0; +#X restore 14 516 pd glue+loadbang; +#X obj 424 93 hip~ 5; +#X obj 432 170 outlet; +#X obj 432 144 int; +#X obj 432 118 env~ 8192; +#X obj 434 193 r~ tone-mon; +#X obj 443 328 line~; +#X obj 424 218 *~; +#X obj 443 301 pack 0 50; +#X obj 434 248 r~ tone-osc; +#X obj 434 353 *~; +#X obj 424 383 +~; +#X obj 432 66 r tone-hip; +#X obj 544 92 hip~ 5; +#X obj 552 169 outlet; +#X obj 552 143 int; +#X obj 552 117 env~ 8192; +#X obj 554 192 r~ tone-mon; +#X obj 563 327 line~; +#X obj 544 217 *~; +#X obj 563 300 pack 0 50; +#X obj 554 247 r~ tone-osc; +#X obj 554 352 *~; +#X obj 544 382 +~; +#X obj 552 65 r tone-hip; +#X obj 661 92 hip~ 5; +#X obj 669 169 outlet; +#X obj 669 143 int; +#X obj 669 117 env~ 8192; +#X obj 671 192 r~ tone-mon; +#X obj 680 327 line~; +#X obj 661 217 *~; +#X obj 680 300 pack 0 50; +#X obj 671 247 r~ tone-osc; +#X obj 671 352 *~; +#X obj 661 382 +~; +#X obj 669 65 r tone-hip; +#X obj 781 91 hip~ 5; +#X obj 789 168 outlet; +#X obj 789 142 int; +#X obj 789 116 env~ 8192; +#X obj 791 191 r~ tone-mon; +#X obj 800 326 line~; +#X obj 781 216 *~; +#X obj 800 299 pack 0 50; +#X obj 791 246 r~ tone-osc; +#X obj 791 351 *~; +#X obj 781 381 +~; +#X obj 789 64 r tone-hip; +#X obj 424 40 adc~ 3; +#X obj 544 39 adc~ 4; +#X obj 661 39 adc~ 5; +#X obj 781 38 adc~ 6; +#X obj 443 275 r tone-ch3; +#X obj 563 273 r tone-ch4; +#X obj 680 274 r tone-ch5; +#X obj 800 273 r tone-ch6; +#X obj 424 408 dac~ 3; +#X obj 543 406 dac~ 4; +#X obj 661 407 dac~ 5; +#X obj 781 406 dac~ 6; +#X connect 0 0 24 0; +#X connect 0 0 13 0; +#X connect 1 0 15 0; +#X connect 2 0 1 1; +#X connect 4 0 2 0; +#X connect 5 0 1 0; +#X connect 6 0 7 0; +#X connect 7 0 4 0; +#X connect 8 0 3 0; +#X connect 9 0 11 0; +#X connect 10 0 9 0; +#X connect 11 0 12 0; +#X connect 12 0 5 0; +#X connect 13 0 8 0; +#X connect 14 0 0 0; +#X connect 16 0 18 0; +#X connect 17 0 10 0; +#X connect 18 0 20 0; +#X connect 18 1 21 0; +#X connect 18 2 19 0; +#X connect 19 0 6 0; +#X connect 20 0 6 0; +#X connect 21 0 6 0; +#X connect 22 0 24 1; +#X connect 23 0 28 1; +#X connect 24 0 30 0; +#X connect 25 0 23 0; +#X connect 26 0 25 0; +#X connect 27 0 28 0; +#X connect 28 0 30 1; +#X connect 30 0 29 0; +#X connect 31 0 0 1; +#X connect 33 0 32 0; +#X connect 34 0 33 0; +#X connect 35 0 34 0; +#X connect 36 0 42 0; +#X connect 36 0 39 0; +#X connect 38 0 37 0; +#X connect 39 0 38 0; +#X connect 40 0 42 1; +#X connect 41 0 45 1; +#X connect 42 0 46 0; +#X connect 43 0 41 0; +#X connect 44 0 45 0; +#X connect 45 0 46 1; +#X connect 46 0 49 0; +#X connect 47 0 36 1; +#X connect 48 0 36 0; +#X connect 50 0 43 0; +#X connect 51 0 52 0; +#X connect 53 0 51 0; +#X connect 55 0 61 0; +#X connect 55 0 58 0; +#X connect 57 0 56 0; +#X connect 58 0 57 0; +#X connect 59 0 61 1; +#X connect 60 0 64 1; +#X connect 61 0 65 0; +#X connect 62 0 60 0; +#X connect 63 0 64 0; +#X connect 64 0 65 1; +#X connect 65 0 111 0; +#X connect 66 0 55 1; +#X connect 67 0 73 0; +#X connect 67 0 70 0; +#X connect 69 0 68 0; +#X connect 70 0 69 0; +#X connect 71 0 73 1; +#X connect 72 0 76 1; +#X connect 73 0 77 0; +#X connect 74 0 72 0; +#X connect 75 0 76 0; +#X connect 76 0 77 1; +#X connect 77 0 112 0; +#X connect 78 0 67 1; +#X connect 79 0 85 0; +#X connect 79 0 82 0; +#X connect 81 0 80 0; +#X connect 82 0 81 0; +#X connect 83 0 85 1; +#X connect 84 0 88 1; +#X connect 85 0 89 0; +#X connect 86 0 84 0; +#X connect 87 0 88 0; +#X connect 88 0 89 1; +#X connect 89 0 113 0; +#X connect 90 0 79 1; +#X connect 91 0 97 0; +#X connect 91 0 94 0; +#X connect 93 0 92 0; +#X connect 94 0 93 0; +#X connect 95 0 97 1; +#X connect 96 0 100 1; +#X connect 97 0 101 0; +#X connect 98 0 96 0; +#X connect 99 0 100 0; +#X connect 100 0 101 1; +#X connect 101 0 114 0; +#X connect 102 0 91 1; +#X connect 103 0 55 0; +#X connect 104 0 67 0; +#X connect 105 0 79 0; +#X connect 106 0 91 0; +#X connect 107 0 62 0; +#X connect 108 0 74 0; +#X connect 109 0 86 0; +#X connect 110 0 98 0; +#X restore 149 157 pd -------audio----; +#X connect 1 0 2 0; +#X connect 1 1 2 1; +#X connect 2 0 3 0; +#X connect 2 1 0 0; +#X connect 9 0 8 0; +#X connect 9 1 7 0; +#X connect 16 0 10 0; +#X connect 38 0 11 0; +#X connect 38 1 12 0; +#X connect 38 2 30 0; +#X connect 38 3 31 0; +#X connect 38 4 32 0; +#X connect 38 5 33 0; |