[PD] pyext help, related to my other [netreceive]->[route] question

Frank Barknecht fbar at footils.org
Thu Jul 6 22:23:25 CEST 2006


Hallo,
David Merrill hat gesagt: // David Merrill wrote:

> You might wonder why I'm bothering with sockets at all if I got pyext to 
> compile - the answer is that I am having a hard time finding examples of 
> doing some basic things with pyext. 

There are some examples in the pyext docs, but I'm attaching an IMO
very useful "catch all" pyexternal. It basically is a wrapper around
(m)any python modules and makes their methods and attributes directly
useable inside Pd. It's simple but immensely powerful.

You soundfile problem could be solved with the "listdir" example on
the left side and a [list-drip] connected to the pyext-outlet.

Ciao
-- 
 Frank Barknecht                 _ ______footils.org_ __goto10.org__
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pycall.py
Type: text/x-python
Size: 999 bytes
Desc: not available
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20060706/5aa5786c/attachment.py>
-------------- next part --------------
#N canvas 103 11 985 619 10;
#X obj 41 363 pyext pycall pymod os;
#X msg 41 331 reload;
#X msg 281 227 listdir /tmp;
#X msg 279 458 bogus;
#X msg 283 270 listdir .;
#X msg 280 324 __doc__;
#X msg 280 346 name;
#X msg 280 367 curdir;
#X msg 281 387 pardir;
#X msg 281 407 path;
#X msg 279 183 mkdir /tmp/python-test;
#X msg 280 205 rmdir /tmp/python-test;
#X msg 282 248 getcwd;
#X msg 278 160 getloadavg;
#X msg 276 138 getpid;
#X msg 275 116 getenv HOME;
#X msg 276 92 system gvim;
#X obj 520 175 pyext pycall pymod string;
#X msg 721 102 letters;
#X obj 524 450 print REGEX;
#X obj 520 200 print STRING;
#X obj 41 392 print OS;
#X msg 721 81 replace 12345 3 -THREE-;
#X msg 524 400 reload;
#X obj 524 425 pyext pycall pymod sre;
#X text 494 336 "[BS]" internally gets replaced by a backslash. Yes
\, I know it's a hack.;
#X msg 721 123 count iiiiiiiiiiiieeeehhh i;
#X msg 722 169 lower ABC;
#X msg 722 146 split X---Y---Z ---;
#X msg 673 388 sub [BS]d _NUM_ 12a3b4c5;
#X connect 0 0 21 0;
#X connect 1 0 0 0;
#X connect 2 0 0 1;
#X connect 3 0 0 1;
#X connect 4 0 0 1;
#X connect 5 0 0 1;
#X connect 6 0 0 1;
#X connect 7 0 0 1;
#X connect 8 0 0 1;
#X connect 9 0 0 1;
#X connect 10 0 0 1;
#X connect 11 0 0 1;
#X connect 12 0 0 1;
#X connect 13 0 0 1;
#X connect 14 0 0 1;
#X connect 15 0 0 1;
#X connect 16 0 0 1;
#X connect 17 0 20 0;
#X connect 18 0 17 1;
#X connect 22 0 17 1;
#X connect 23 0 24 0;
#X connect 24 0 19 0;
#X connect 26 0 17 1;
#X connect 27 0 17 1;
#X connect 28 0 17 1;
#X connect 29 0 24 1;


More information about the Pd-list mailing list