[PD] directories in PD

Krzysztof Czaja czaja at chopin.edu.pl
Tue Apr 8 14:36:24 CEST 2003


hi,

or 'query glob <path>/*' -> [tot]

(of course, this could be: 'query lsort [glob *]', or
'query lindex [lsort [glob *]] 0', or anything...)

actually, no idea, if this is reliable on windows, no time to test...

Krzysztof

d.casal at uea.ac.uk wrote:
 > Josh Steiner wrote:
 >
 >>i'm not too sure if there are other easier ways, but you could get a
 >>directory listing using the [shell] object (i think from GGEE) if you
 >>happen to be running linux, im not sure it exists for windows (it may)
...
 > This is probably -not- the easiest way, but perhaps a good idea if you
 > want a lot a flexibility as to what you do with directory listings
 > later on...use Grill's pyext, write a python script:
 >
 > import pyext
 >
 > class dir(pyext._class):
 >
 >         _inlets=1
 >         _outlets=1
 >
 >         def bang_1(self):
 >                 import dircache
 >                 a=dircache.listdir('/usr/local/pd') #change to whatever
 > sound dir
 >                 self._outlet(1,a)
 >
 > Then load with [pyext nameofscript nameofclass] ...should work in





More information about the Pd-list mailing list