#N canvas 693 148 742 582 12;
#X obj 514 36 loadbang;
#X obj 122 230 bng 25 250 50 0 empty empty Pick_Sample -45 -12 2 20
-4032 -1 -1;
#X obj 156 273 nbx 6 19 0 100 0 0 empty sr Sample_Rate_in_KHz 1 -13
1 15 -4034 -91543 -1 44.1 256;
#N canvas 602 610 981 475 sampler 0;
#X obj 164 -65 cnv 15 100 60 empty empty empty 20 12 0 14 -233017 -66577
0;
#X obj 370 68 /;
#X obj 370 111 * 1000;
#X obj 170 -26 nbx 8 14 -1e+37 1e+37 0 0 empty empty empty 0 -6 0 10
-203904 -1 -1 0 256;
#X obj 370 92 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -6 0 10
-232576 -1 -1 0 256;
#X obj 370 135 nbx 5 14 -1e+37 1e+37 0 0 empty empty empty 0 -6 0 10
-204786 -1 -1 0 256;
#X obj 261 265 line~;
#X msg 261 242 0 \, \$1 \$2;
#X obj 261 182 float;
#X obj 170 116 metro;
#X obj 170 96 tgl 15 0 empty empty empty 0 -6 0 10 -155649 -262130
-1 0 1;
#X msg 170 67 1;
#X obj 170 -97 inlet;
#X obj 261 340 outlet~;
#X obj 369 -96 inlet;
#X obj 401 44 * 1000;
#X obj 261 291 tabread4~ \$0-sampler;
#N canvas 0 22 450 300 (subpatch) 0;
#X coords 0 1 100 -1 615 95 1;
#X restore 242 232 graph;
#X obj 245 131 f;
#X obj 370 44 f;
#X obj 94 -96 inlet;
#X obj 369 -51 t b f;
#X obj 170 17 trigger bang float;
#N canvas 54 51 783 393 openpanel 0;
#X obj 152 254 soundfiler;
#X obj 152 84 openpanel;
#X symbolatom 152 112 80 0 0 0 - - -;
#X obj 152 199 pack symbol symbol;
#X obj 275 172 symbol \$0-sampler;
#X obj 152 283 outlet;
#X obj 152 51 inlet;
#X obj 152 144 trigger symbol bang;
#X msg 152 226 read -maxsize 1e+09 -resize \$1 \$2;
#X text 57 83 Opens File;
#X text 39 166 Creates list of;
#X text 44 182 file and array;
#X text 64 198 names ====>;
#X text 243 261 [soundfiler] gets the flag "-resize + (filename) +
(array name)" and puts the sound file into an array as it resizes the
array to fit it! The outlet gives us array size (number of samples).
;
#X connect 0 0 5 0;
#X connect 1 0 2 0;
#X connect 2 0 7 0;
#X connect 3 0 8 0;
#X connect 4 0 3 1;
#X connect 6 0 1 0;
#X connect 7 0 3 0;
#X connect 7 1 4 0;
#X connect 8 0 0 0;
#X restore 170 -56 pd openpanel;
#X obj 293 156 nbx 6 14 -1e+37 1e+37 0 0 empty empty empty 0 -6 0 10
-203904 -1 -1 0 256;
#X obj 261 208 pack float float;
#X obj 170 143 t b b;
#X text 455 44 Sample Rate in Hz.;
#X text 282 43 # of samples;
#X text 428 89 File size in seconds;
#X text 427 131 in ms (miliseconds);
#X text 385 207 List (# of samples + length in ms);
#X text 39 -98 restart;
#X text 414 -96 SR in Khz;
#X text 178 -2 # of samples;
#X text 2 105 tempo of [metro] is;
#X text -10 124 the same as file length;
#X text 1 145 this plays the file;
#X text 35 164 in loop;
#X text 426 244 At every bang/loop \, [line~] gets 2 mensagens: First
(Zero) makes [line~] jump imediately to zero. Second is a list (number
of samples + length in ms) that makes line generate data to read the
sample from [tabread4~].;
#X connect 1 0 4 0;
#X connect 2 0 5 0;
#X connect 3 0 22 0;
#X connect 4 0 2 0;
#X connect 5 0 18 1;
#X connect 5 0 25 1;
#X connect 6 0 16 0;
#X connect 7 0 6 0;
#X connect 8 0 25 0;
#X connect 9 0 26 0;
#X connect 10 0 9 0;
#X connect 11 0 10 0;
#X connect 12 0 23 0;
#X connect 14 0 21 0;
#X connect 15 0 1 1;
#X connect 16 0 13 0;
#X connect 18 0 9 1;
#X connect 19 0 1 0;
#X connect 20 0 11 0;
#X connect 21 0 19 0;
#X connect 21 1 15 0;
#X connect 22 0 11 0;
#X connect 22 1 19 0;
#X connect 22 1 24 0;
#X connect 23 0 3 0;
#X connect 24 0 8 1;
#X connect 25 0 7 0;
#X connect 26 0 8 0;
#X connect 26 1 18 0;
#X restore 89 304 pd sampler;
#X obj 203 351 cnv 15 398 148 empty empty empty 20 12 0 14 -233017
-66577 0;
#N canvas 0 22 454 304 (subpatch) 0;
#X array \$0-sampler 1.63332e+06 float 4;
#X coords 0 1 1.63332e+06 -1 400 150 1;
#X restore 202 350 graph;
#X obj 81 336 dac~;
#X obj 31 27 cnv 15 315 40 empty empty Sampler-Looper: 20 12 0 24 -262144
-66577 0;
#X obj 89 274 bng 15 250 50 0 empty empty empty 17 7 0 10 -204800 -1
-1;
#X text 59 253 restart;
#X msg 514 60 \; pd dsp 1 \; sr 44.1;
#X text 45 86 This plays a sample in loop \, but can also play the
sample at a different speed and tempo if you put a sample rate that's
different from the file's. A smaller sample rate plays it slower and
at a lower pitch \, whereas it'll play faster and at a higher pitch
if the sample rate is higher.;
#X connect 0 0 10 0;
#X connect 1 0 3 1;
#X connect 2 0 3 2;
#X connect 3 0 6 0;
#X connect 3 0 6 1;
#X connect 8 0 3 0;
