diff options
author | Thomas O Fredericks <mrtof@users.sourceforge.net> | 2009-10-28 13:28:46 +0000 |
---|---|---|
committer | Thomas O Fredericks <mrtof@users.sourceforge.net> | 2009-10-28 13:28:46 +0000 |
commit | 89db37262cee46814540edef54a6db96096e1ee1 (patch) | |
tree | 97ffaae5116bda012c2cea8ca1641ded089b2872 /ambiSfRead4~.pd | |
parent | f18d063d9312c95e25294e0777bc135ee9a3fd8a (diff) |
Updated mtl abstractions
svn path=/trunk/abstractions/mtl/; revision=12691
Diffstat (limited to 'ambiSfRead4~.pd')
-rw-r--r-- | ambiSfRead4~.pd | 144 |
1 files changed, 144 insertions, 0 deletions
diff --git a/ambiSfRead4~.pd b/ambiSfRead4~.pd new file mode 100644 index 0000000..d2d4a80 --- /dev/null +++ b/ambiSfRead4~.pd @@ -0,0 +1,144 @@ +#N canvas 352 57 1087 783 10; +#X obj 30 642 readsf~ 4; +#X msg 149 302 1; +#X msg 181 300 0; +#X msg 49 273 print; +#X obj 388 216 openpanel; +#X text 607 546 Send it "1" to play once a file is opened.; +#X obj 31 681 *~ 1.414; +#X obj 24 711 outlet~; +#X obj 79 713 outlet~; +#X obj 134 713 outlet~; +#X obj 189 715 outlet~; +#X obj 188 230 t b; +#X obj 389 191 t b; +#X obj 337 6 loadbang; +#X obj 339 34 t b b; +#X obj 260 332 spigot; +#X obj 348 289 symbol; +#X obj 523 415 spigot; +#X text 602 559 todo: append more args?; +#X obj 822 92 inlet readsf; +#X obj 47 29 inlet attr; +#N canvas 224 201 628 639 wav_info 0; +#X msg 31 92 read \$1; +#X text 40 146 "read"-message needs a symbol (soundfile in wave format) +; +#X text 50 184 "list"-message output with 7 items; +#X text 91 224 4.item: <float> header-size in bytes; +#X text 91 194 1.item: <float> samplerate in Hz; +#X text 91 204 2.item: <symbol> file-name; +#X text 91 234 5.item: <float> number of channels; +#X text 91 254 7.item: <symbol> endianness ("l" for little); +#X text 260 264 ("b" for big); +#X text 262 276 (eg. little endian "wav" is natural format on Intel-machines) +; +#X text 91 214 3.item: <float> sound-data-length in samples; +#X text 91 244 6.item: <float> sample-resolution in bytes; +#X obj 33 49 inlet; +#X obj 31 302 unpack f s f f f f s; +#X obj 26 489 outlet duration_ms; +#X text 132 49 NOTE: we could also use the wavinfo object.; +#X msg 32 459 duration \$1; +#X msg 161 434 bytes \$1; +#X msg 21 393 samplerate \$1; +#X obj 37 434 ./smpToMs; +#X obj 31 166 iemlib/soundfile_info; +#X connect 0 0 20 0; +#X connect 12 0 0 0; +#X connect 13 0 18 0; +#X connect 13 2 19 0; +#X connect 13 5 17 0; +#X connect 16 0 14 0; +#X connect 17 0 14 0; +#X connect 18 0 14 0; +#X connect 19 0 16 0; +#X connect 20 0 13 0; +#X restore 326 588 pd wav_info; +#X obj 390 711 outlet info; +#X msg 261 651 done bang; +#X obj 418 643 timer; +#X obj 452 616 metro 50; +#X obj 147 347 f; +#X obj 456 559 sel 1; +#X msg 456 589 1; +#X obj 501 571 t b; +#X msg 500 592 0; +#X msg 416 666 elapsed \$1; +#X obj 824 148 s \$0-readsf; +#X obj 91 607 r \$0-readsf; +#X text 174 350 Playing; +#X text 154 212 Play stop; +#X obj 148 249 t b b; +#X msg 147 381 playing \$1; +#X obj 562 391 f; +#X msg 384 58 autostart 1 \, loop 0; +#X text 395 39 Default values; +#X obj 347 266 t s s; +#X obj 349 311 t b s; +#X text 259 351 autostart; +#X text 591 390 loop; +#X obj 523 440 delay 100; +#X text 590 441 avoids infinite loop; +#X obj 344 138 route file play stop openpanel open autostart loop loop_interval +; +#X obj 486 107 tof/arguments comma; +#X obj 347 243 zexy/list2symbol; +#X obj 376 336 cyclone/prepend open; +#X connect 0 0 6 0; +#X connect 0 1 8 0; +#X connect 0 2 9 0; +#X connect 0 3 10 0; +#X connect 0 4 17 0; +#X connect 0 4 23 0; +#X connect 1 0 26 0; +#X connect 2 0 26 0; +#X connect 3 0 0 0; +#X connect 4 0 49 0; +#X connect 6 0 7 0; +#X connect 11 0 2 0; +#X connect 12 0 4 0; +#X connect 13 0 14 0; +#X connect 14 0 48 0; +#X connect 14 1 39 0; +#X connect 15 0 1 0; +#X connect 16 0 42 0; +#X connect 17 0 45 0; +#X connect 19 0 32 0; +#X connect 20 0 47 0; +#X connect 21 0 22 0; +#X connect 23 0 22 0; +#X connect 24 0 31 0; +#X connect 25 0 24 1; +#X connect 26 0 0 0; +#X connect 26 0 27 0; +#X connect 26 0 37 0; +#X connect 27 0 24 0; +#X connect 27 0 28 0; +#X connect 27 1 29 0; +#X connect 28 0 25 0; +#X connect 29 0 30 0; +#X connect 30 0 25 0; +#X connect 31 0 22 0; +#X connect 33 0 0 0; +#X connect 36 0 1 0; +#X connect 36 1 16 0; +#X connect 37 0 22 0; +#X connect 38 0 17 1; +#X connect 39 0 47 0; +#X connect 41 0 16 0; +#X connect 41 1 21 0; +#X connect 42 0 15 0; +#X connect 42 1 50 0; +#X connect 45 0 16 0; +#X connect 47 0 49 0; +#X connect 47 1 36 0; +#X connect 47 2 11 0; +#X connect 47 3 12 0; +#X connect 47 4 16 0; +#X connect 47 5 15 1; +#X connect 47 6 38 0; +#X connect 47 8 45 1; +#X connect 48 0 47 0; +#X connect 49 0 41 0; +#X connect 50 0 0 0; |