#N canvas 113 52 638 844 12;
#X msg 31 406 foo bar baz;
#X obj 189 466 osc~ 440;
#X obj 114 614 env~ 8192;
#X floatatom 114 663 5 0 0 0 - - -, f 5;
#X msg 535 750 \; pd dsp 1;
#X msg 24 332 pd~ stop;
#X obj 114 639 i;
#X obj 228 612 env~ 8192;
#X floatatom 228 662 5 0 0 0 - - -, f 5;
#X obj 228 638 i;
#X obj 123 489 *~;
#X obj 158 490 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
1;
#X obj 189 490 *~;
#X obj 224 491 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
1;
#X obj 535 724 loadbang;
#X obj 12 643 print x;
#X msg 15 309 pd~ start pd~-subprocess.pd;
#X obj 14 532 pd~ -ninsig 2 -noutsig 2 -fifo 20;
#X obj 37 20 pd~;
#X text 69 22 - run a pd sub-process;
#X text 27 52 The pd~ object starts and manages a Pd sub-process that
can communicate with the super-process (this one) via audio channels
and/or Pd messages. In this way you can take advantage of multi-core
CPUs \, and/or use Pd features from within Max (if you're using the
Max version of pd~).;
#X text 24 246 Sending a new "start" message will stop the sub-process
and start a new one. If you just want to stop the sub-process \, send
"stop".;
#X text 33 353 Any message besides "pd~" is sent to the sub-process.
For instance \, the message below sends "bar baz" to any object in
the sub-process named "foo" \, such as a "receive" object.;
#X text 43 430 Audio signals appear in adc~ objects in the sub-process.
The sub-process doesn't open real audio devices.;
#X text 302 469 Creation args:;
#X text 286 486 -insig <n> sets input audio channels;
#X text 287 504 -outsig <n> sets output channels;
#X text 290 538 -fifo <n> sets round-trip delay in blocks;
#X text 293 555 -pddir <s> sets Pd directory \, e.g. \,;
#X text 320 570 .../Pd-0.42.app/Contents/Resources;
#X text 293 586 -scheddir <s> sets scheduler dir \, e.g. \,;
#X text 318 603 .../.../Resources/extra/pd~;
#X text 288 520 -sr <n> sets sample rate;
#X text 28 699 The first outlet reports messages the sub-process sends
us via "stdout" objects. Any other outlets are signals corresponding
to "dac~" objects in the sub-process.;
#X text 21 756 ATTENTION: DSP must be running in this process for the
sub-process to run. This is because its clock is slaved to audio I/O
it gets from us!;
#X text 393 802 Updated for Pd version 0.42.;
#X text 24 132 Messages with "pd~" selector control the sub-process.
"pd~ start" takes as arguments any startup arguments you wish to send
the sub-process. For example \, specify "-nogui" to stop the sub-process's
GUI from appearing. You don't have to specify the number of channels
in and out \, since that's set by creation arguments below. Audio config
arguments arguments (-audiobuf \, -audiodev \, etc.) are ignored.;
#X connect 0 0 17 0;
#X connect 1 0 10 0;
#X connect 1 0 12 0;
#X connect 2 0 6 0;
#X connect 5 0 17 0;
#X connect 6 0 3 0;
#X connect 7 0 9 0;
#X connect 9 0 8 0;
#X connect 10 0 17 0;
#X connect 11 0 10 1;
#X connect 12 0 17 1;
#X connect 13 0 12 1;
#X connect 14 0 4 0;
#X connect 16 0 17 0;
#X connect 17 0 15 0;
#X connect 17 1 2 0;
#X connect 17 2 7 0;
