Hi Everyone,
this patch is work in progress, i'm quite satisfied of the results but i have a problem that i can't manage so here i am asking your expert advices.
As you can see now i use just one array, 16 audio files are randomly chosen and sent into the array to be played.
The result is the one i want but i'd like files to be loaded randomly from a folder because it seems easyer to reorder, add and organize my samples and than i could have different instaces of the external fishing from different folders.
But i'm using win so i cannot use playlist and the only place where i see the solution is the wonderful Hardoff's a_gig_in_tokyo patch but i'm something of a newbie so i'm not able to borrow (and acquire by prescription) the right pieces from there...
Anyway try the patch, i put the sound files as well. The midi cc are for my control but you can easily change them if you want to play and choose the files without the random.
Thank for your advices and feedback.
-
Random file from folder
-
you have to assemble your filelist manually on windoze
run attached bat file in the top dir of your samples. It will give you a textfile withthe full path for the files.
now open txt file in a texteditorsearch and replace
- \ with /
- .wav with .wav;
save file.
attached is also an example on howto use the filelist.
if it not clear dont hesitate to ask
mvh
OK couldnt attach the *.bat file.
so now its wav_filelist.txt rename to wav_filelist.bat -
Hi pulsed,
thank you very much.
Your example works great and i'm beginning to understand what you've done.
I try to develop my patch in that way but i keep on studing a way to do that without txt. files.
I'll let you know.
ab -
if you can name your files things like sound154.wav,
then [makefilename] can come in real handy.any technology distinguishable from magic
is insufficiently advanced. -
Hey alistair,
I came up with a patch to do this a while ago using [folder_list], which is included in Pd-extended and works on Windows. I haven't looked at how hardoff did it, so I don't know if this way is more convoluted, but it works. It basically makes [folder_list] output all files within a folder, filters unwanted files using some list processing and [select], and puts them in [msgfile]. I use [msgfile] instead of [textfile] because it allows you to go directly to a specific line in the text file, so you can easily randomize which one to load.
Edit: updated patch with [import tof] so [folderpanel] should work right away.
-
thank you Maelstorm,
but the object [folderpanel] is missing, what library is it from?
folderpanel ... couldn't createouch... it seems an interesting stuff to study for my purposes
-
it's in the "tof" folder in pd extended.
-
ok thank you, i've found it...
done, no errors now.
let's study it...
bye -
Your patch gave me some good insight & help Maelstorm, thanks!
-
Hello, I am a novice slowly making his way through various tutorials online. Maelstorm's patch seems very interesting to me; however, I get an error for the following objects: [folder_list], [symbol2list /], [list-idx], [list2symbol/] and [msgfile]. I'm sorry for reviving an old thread but this patch is very interesting to me and I would like to study it. What can I do to make this work? I have the latest version of PD Extended.