Multiple files loading into buffers / Triggering

Mar 11, 2008 at 7:13pm

Multiple files loading into buffers / Triggering

Hi all,

I need to automatically load 1.000 soundfiles into either a single or seperate buffers and then trigger each file by a footswitch controller….

I can create the control section of the patch, but I need a convenient way to load the samples into the buffer(s) with ques etc

Any suggestions?

D

#36302
Mar 11, 2008 at 8:16pm

On 11 Mar 2008, at 19:13, Dimitris Maronidis wrote:

> I need to automatically load 1.000 soundfiles into either a single
> or seperate buffers and then trigger each file by a footswitch
> controller….

Why not use a cue list in sfplay~ ?

– N.

Nick Rothwell – nick@cassiel.comhttp://www.cassiel.com
— open-source goodies for MaxMSP: Python, Groovy, Nixie Tubes,
— rotatable text bricks, databases: all at http://www.loadbang.net

#124468
Mar 11, 2008 at 8:21pm

I think it is preferable to load the files in buffers because I’ ll be able to process them and also pick up specific parts of them.

#124469
Mar 11, 2008 at 8:24pm

Also I might use some algorithms to trigger more than 100 files at once and i am afraid that my HD speed is not sufficient enough for this

#124470
Mar 11, 2008 at 8:54pm

On 11-mars-08, at 20:13, Dimitris Maronidis wrote:

>
> Hi all,
>
> I need to automatically load 1.000 soundfiles into either a single or
> seperate buffers and then trigger each file by a footswitch
> controller….

You can script that quite easily. Just create a buffer for each sound
file in a folder.

I don’t have a patch at hand tonight (it’s in my office), but this
thread may give you some hints:
http://www.cycling74.com/forums/index.php?
t=msg&goto=115066&rid=0&S=960b80586c63c962218fcada5ac70382&srch=delges+b
uffer#msg_115066

p

#124471
Mar 11, 2008 at 9:01pm

Thank you.

If you could send me your patch at some point that would be great.

#124472
Mar 11, 2008 at 9:18pm

Hi,

for “batch” tasks, I often use poly~, even for control-only ones.

Save this as “polybuffer~” :

#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P newex 27 54 51 196617 tosymbol;
#P newex 61 153 160 196617 sprintf loaded file %s in voice %i;
#P newex 61 132 36 196617 zl reg;
#P newex 61 175 88 196617 print polybuffer~;
#P newex 27 111 44 196617 buffer~;
#P newex 134 93 115 196617 sprintf name buffer-%i;
#P newex 134 71 52 196617 thispoly~;
#P newex 134 49 48 196617 loadbang;
#P newex 27 81 81 196617 prepend replace;
#N in 1;
#P newobj 27 30 25 196617 in 1;
#P connect 3 0 8 1;
#P connect 3 0 4 0;
#P connect 2 0 3 0;
#P connect 9 0 1 0;
#P connect 9 0 7 1;
#P connect 8 0 6 0;
#P connect 7 0 8 0;
#P connect 5 1 7 0;
#P connect 1 0 5 0;
#P connect 4 0 5 0;
#P connect 0 0 9 0;
#P window clipboard copycount 10;

Save this as “polybuffer~.help” or something :

#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P comment 250 229 56 196617 sound pool;
#P user waveform~ 426 158 170 54 3 9;
#W mode select;
#W mouseoutput continuous;
#W unit ms;
#W grid 1000.;
#W ticks 0;
#W labels 1;
#W vlabels 0;
#W vticks 1;
#W bpm 120. 4.;
#W frgb 33 0 0;
#W brgb 60 178 173;
#W rgb2 0 95 255;
#W rgb3 0 0 0;
#W rgb4 0 0 0;
#W rgb5 190 137 255;
#W rgb6 100 100 100;
#W rgb7 100 100 100;
#P newex 460 125 83 196617 groove~ abuffer;
#P number 460 68 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 460 88 106 196617 sprintf set buffer-%i;
#P message 207 48 76 196617 load soundfiles;
#P newex 207 70 27 196617 b;
#P message 237 163 53 196617 target $1;
#P newex 207 137 69 196617 route symbol;
#P message 207 94 33 196617 dump;
#N coll 1000-buffers 1;
#T flags 1 0;
#T 1 vibes-a1.aif;
#T 2 sho0630.aif;
#T 3 rainstick.aif;
#T 4 jongly.aif;
#T 5 drumLoop.aif;
#T 6 cherokee.aif;
#T 7 cello-f2.aif;
#T 8 anton.aif;
#P newobj 207 114 100 196617 coll 1000-buffers 1;
#P message 317 158 54 196617 voices $1;
#P number 317 138 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 317 88 37 196617 length;
#N coll 1000-buffers 1;
#T flags 1 0;
#T 1 vibes-a1.aif;
#T 2 sho0630.aif;
#T 3 rainstick.aif;
#T 4 jongly.aif;
#T 5 drumLoop.aif;
#T 6 cherokee.aif;
#T 7 cello-f2.aif;
#T 8 anton.aif;
#P newobj 317 115 100 196617 coll 1000-buffers 1;
#P newex 61 137 84 196617 prepend insert 1;
#P newex 61 114 67 196617 route append;
#P newex 61 91 119 196617 folder : AIFF WAVE sd2f;
#N coll 1000-buffers 1;
#T flags 1 0;
#T 1 vibes-a1.aif;
#T 2 sho0630.aif;
#T 3 rainstick.aif;
#T 4 jongly.aif;
#T 5 drumLoop.aif;
#T 6 cherokee.aif;
#T 7 cello-f2.aif;
#T 8 anton.aif;
#P newobj 61 162 100 196617 coll 1000-buffers 1;
#P newex 237 208 91 196617 poly~ polybuffer~;
#P window linecount 2;
#P comment 63 49 61 196617 drag & drop sound folder;
#P user dropfile 61 46 127 77 1;
#P window linecount 1;
#P comment 497 69 69 196617 recall sounds;
#P comment 68 185 81 196617 sound collection;
#P connect 19 0 22 0;
#P connect 19 0 21 0;
#P connect 20 0 19 0;
#P connect 11 0 12 0;
#P connect 9 0 11 0;
#P connect 10 0 9 0;
#P connect 17 1 10 0;
#P connect 12 0 4 0;
#P connect 16 0 4 0;
#P connect 15 0 4 0;
#P connect 13 1 16 0;
#P connect 13 0 15 0;
#P connect 14 0 13 0;
#P connect 17 0 14 0;
#P connect 18 0 17 0;
#P connect 7 1 5 0;
#P connect 8 0 5 0;
#P connect 7 0 8 0;
#P connect 6 0 7 0;
#P connect 2 0 6 0;
#P window clipboard copycount 24;

#124473
Mar 12, 2008 at 5:05pm

#124474
Mar 12, 2008 at 5:13pm

Have you tried aiff formatted files?

It works for me.

#124475
Mar 12, 2008 at 5:53pm

#124476
Mar 12, 2008 at 5:58pm

Hi Dimitris,

yes, I tried .aif files, but it does not work for me, hm.
Manually replacing the buffer with the Soundfile “xxx.wav” in the
“polybuffer~ (1..) give no error and loads fine.

Am 12.03.2008 um 18:13 schrieb Dimitris Maronidis:

>
> Have you tried aiff formatted files?
>
> It works for me.

#124477
Mar 12, 2008 at 8:00pm

#124478

You must be logged in to reply to this topic.