Skip to content

Commit

Permalink
batch.rec~ and tabplayer~
Browse files Browse the repository at this point in the history
  • Loading branch information
porres committed Aug 18, 2020
1 parent 1beb20c commit 2aa502a
Show file tree
Hide file tree
Showing 5 changed files with 82 additions and 65 deletions.
Binary file modified Examples/README.pdf
Binary file not shown.
Binary file not shown.
@@ -1,20 +1,7 @@
#N canvas 578 68 580 606 12;
#N canvas 578 68 586 691 12;
#X declare -lib else;
#X obj 265 490 tabplay~ \$0-sample;
#X obj 265 391 bng 18 250 50 0 empty empty empty 17 7 0 10 -228856
-1 -1;
#X obj 284 443 nbx 7 14 0 1e+37 0 0 empty empty empty 0 -8 0 10 -228856
-1 -1 0 256;
#X obj 374 382 metro 1000;
#X obj 374 410 random;
#X obj 374 360 tgl 15 0 empty empty empty 17 7 0 10 -228856 -1 -1 0
1;
#X text 230 390 play;
#X floatatom 374 435 0 0 0 0 - - -;
#X msg 374 459 \$1 44100;
#X msg 226 442 stop;
#X obj 265 526 out~;
#X obj 430 409 r \$0-size;
#X msg 338 448 stop;
#X obj 313 576 out~;
#X msg 118 279 show;
#X msg 70 279 hide;
#X floatatom 118 347 0 0 0 0 - - -;
Expand All @@ -32,17 +19,21 @@ load multi channel files. Check its help file for more details. Below
outlet also outputs the table size in samples (the output is actually
a list with size \, sample rate and number of channels) \, so we have
basically the same thing as the last example.;
#X connect 0 0 10 0;
#X connect 1 0 0 0;
#X connect 2 0 0 0;
#X connect 3 0 4 0;
#X connect 4 0 7 0;
#X connect 5 0 3 0;
#X connect 7 0 8 0;
#X connect 8 0 0 0;
#X connect 9 0 0 0;
#X connect 11 0 4 1;
#X connect 12 0 19 0;
#X connect 13 0 19 0;
#X connect 14 0 16 0;
#X connect 19 0 14 0;
#X obj 313 540 tabplayer~ \$0-sample;
#X msg 314 394 start 4000 2000;
#X msg 330 422 start;
#X msg 345 474 pause;
#X msg 352 500 resume;
#X text 86 462 The [tabplayer~] object from ELSE is also a much more
powerful alternative to [tabplay~] and also offers multi-channel support.
Check its help file., f 27;
#X connect 0 0 11 0;
#X connect 2 0 9 0;
#X connect 3 0 9 0;
#X connect 4 0 6 0;
#X connect 9 0 4 0;
#X connect 11 0 1 0;
#X connect 12 0 11 0;
#X connect 13 0 11 0;
#X connect 14 0 11 0;
#X connect 15 0 11 0;
@@ -1,4 +1,4 @@
#N canvas 367 42 923 676 12;
#N canvas 435 112 1064 677 12;
#X declare -lib else;
#X obj 129 252 bng 20 250 50 0 empty empty empty 17 7 0 10 -228856
-1 -1;
Expand All @@ -8,18 +8,18 @@
-1 -1;
#X obj 316 137 savepanel;
#X msg 132 172 stop;
#X obj 147 609 soundfiler;
#X obj 147 510 bng 15 250 50 0 empty empty empty 17 7 0 10 -228856
#X obj 113 609 soundfiler;
#X obj 113 510 bng 15 250 50 0 empty empty empty 17 7 0 10 -228856
-1 -1;
#X obj 147 532 savepanel;
#X obj 113 532 savepanel;
#X obj 129 361 tabwrite~ \$0-sample;
#X msg 222 321 stop;
#X msg 147 317 start \$1;
#X obj 147 295 nbx 6 14 0 1e+37 0 0 empty empty empty 0 -8 0 10 -228856
-1 -1 0 256;
#X obj 82 115 adc~ 1;
#X msg 147 584 write \$1 \$2;
#X obj 147 558 list append \$0-sample;
#X msg 113 584 write \$1 \$2;
#X obj 113 558 list append \$0-sample;
#X obj 117 204 writesf~;
#X obj 316 357 send \$0-sample;
#X floatatom 316 308 0 0 0 0 - - -;
Expand All @@ -37,35 +37,53 @@
#X text 148 277 index to record;
#X text 62 450 You can also export an array into a sound file with
the [soundfiler] object as below., f 45;
#X text 167 508 <= choose where to save;
#X text 133 508 <= choose where to save;
#X text 48 23 Similarly to [readsf~] \, the native [writesf~] object
records directly to your hard drive. The native [tabwrite~] object
records into an array - check help files for more info.;
#X obj 209 405 table \$0-sample 4410;
#X text 473 104 The [rec.file~] object \, from the ELSE library \,
is an abstraction based on [writesf~] and makes some things more convenient.
One nice feature is that it includes an [autofade~] object to avoid
clicks when sampling live input - check its help file., f 56;
#X obj 718 207 brown~;
#X obj 581 209 tgl 20 0 empty empty empty 17 7 0 10 -228856 -1 -1 0
#X obj 739 180 brown~;
#X obj 602 182 tgl 20 0 empty empty empty 17 7 0 10 -228856 -1 -1 0
1;
#X obj 581 242 rec.file~ ./Test.wav;
#X obj 598 391 sample~ \$0-record -ms 2000;
#X msg 593 562 rec;
#X msg 632 562 stop;
#X obj 727 562 adc~ 1;
#X obj 632 610 rec~ \$0-record;
#X obj 673 46 declare -lib else;
#X text 468 290 The [sample~] object can be used to load files recorded
with [writesf~] or [rec.file~] \, but it can also be used as a memory
buffer to record audio into by using something like [tabwrite~] or
the [rec~] object presented below. Below we set a buffer size of 2000
ms., f 58;
#X text 474 439 The [rec~] object (from the ELSE library) can also
be used to record into arrays. One advantage is that you can start
a recording with sample accuracy and it can record up to 64 signal
channels into arrays simultaneously. This object goes well with [sample~]
\, see its help file for more details., f 58;
#X obj 602 215 rec.file~ ./Test.wav;
#X msg 571 526 rec;
#X msg 610 526 stop;
#X obj 866 32 declare -lib else;
#X obj 564 319 batch.rec~ ./Test.wav;
#X msg 583 289 rec 1000;
#X obj 610 594 display~;
#X obj 347 548 setdsp~ 1;
#X obj 610 564 rec~ \$0-record;
#X text 650 288 <= record 1 second;
#X obj 564 258 cusp~ 500;
#X obj 839 266 else/out~;
#X text 522 182 record =>;
#X obj 839 192 bng 20 250 50 0 empty empty empty 17 7 0 10 -228856
-1 -1;
#X obj 839 230 play.file~ ./Test.wav;
#X obj 564 347 bng 15 250 50 0 empty empty empty 17 7 0 10 -228856
-1 -1;
#X text 585 345 <= finished;
#X text 506 60 The [rec.file~] object \, from the ELSE library \, is
an abstraction based on [writesf~] and makes some things more convenient.
One nice feature is that it includes an [autofade~] object to avoid
clicks when sampling live input - use the toggle to start and stop
recording and check its help file. You can also perform batch recordnig
(as in rendering offline) with [batch.rec~] \, also from ELSE \, check
its help file also. Use [play.file~] to play back the result., f 71
;
#X text 739 475 <= click;
#X obj 863 551 else/out~;
#X obj 705 524 standard~ 300;
#X obj 553 475 sample~ \$0-record -ms 500;
#X obj 863 510 tabplay~ \$0-record;
#X obj 863 475 bng 20 250 50 0 empty empty empty 17 7 0 10 -228856
-1 -1;
#X text 506 385 The [sample~] object can also be used to record into
by using something like [tabwrite~] or the [rec~] object presented
below \, where we have a buffer size of 2000 ms. An advantage of [rec~]
is that it provides sample accuracy and multi-channel support \, check
its help file., f 71;
#X connect 0 0 9 0;
#X connect 1 0 9 0;
#X connect 2 0 16 0;
Expand All @@ -86,8 +104,16 @@ channels into arrays simultaneously. This object goes well with [sample~]
#X connect 22 0 16 0;
#X connect 23 0 18 0;
#X connect 23 0 21 0;
#X connect 35 0 37 1;
#X connect 36 0 37 0;
#X connect 39 0 42 0;
#X connect 40 0 42 0;
#X connect 41 0 42 1;
#X connect 34 0 36 1;
#X connect 35 0 36 0;
#X connect 37 0 44 0;
#X connect 38 0 44 0;
#X connect 40 0 51 0;
#X connect 41 0 40 0;
#X connect 44 0 42 0;
#X connect 46 0 40 0;
#X connect 49 0 50 0;
#X connect 50 0 47 0;
#X connect 56 0 44 1;
#X connect 58 0 55 0;
#X connect 59 0 58 0;
Binary file not shown.

0 comments on commit 2aa502a

Please sign in to comment.