[PD] dynamic-named arrays

Frank Barknecht fbar at footils.org
Fri Oct 3 00:29:05 CEST 2003


Hallo,

0 hat gesagt: // 0 wrote:

> I did it just fine, using $1 and passing a parameter "one" then
> "two" "three" etc. for the various instances, then invoking the
> subpatch in each instance with "pd patchname $1" to pass the unique
> name parameter on to the subpatch. 

This is a common misunderstanding: argument passing *does not work*
for subpatches ("pd something"), it only works for abstractions (file
abstr.pd used as [abstr] in a patch). See attached proof. So it's
useless to use anything after the subpatch's name in [pd subpatch].

ciao
-- 
 Frank Barknecht                               _ ______footils.org__
-------------- next part --------------
#N canvas 479 310 450 300 10;
#X text 150 91 Click to open!;
#X obj 151 130 test-abstr absarg;
-------------- next part --------------
#N canvas 374 203 450 300 10;
#X symbolatom 198 220 10 0 0 0 - - -;
#N canvas 376 258 450 300 test-subpatch 0;
#X obj 115 78 symbol \$1;
#X obj 115 37 inlet;
#X obj 115 159 outlet;
#X connect 0 0 2 0;
#X connect 1 0 0 0;
#X restore 198 136 pd test-subpatch subarg;
#X obj 119 135 symbol \$1;
#X msg 173 78 bang;
#X symbolatom 119 219 10 0 0 0 - - -;
#X text 163 47 bang here!;
#X text 285 221 See: No subarg here!!;
#X connect 1 0 0 0;
#X connect 2 0 4 0;
#X connect 3 0 2 0;
#X connect 3 0 1 0;


More information about the Pd-list mailing list