readfolder message problem with polybuffer~

Mar 20, 2013 at 11:22am

readfolder message problem with polybuffer~

Hi,

so I have that 12 slots sampler working quite ok: sampling, playing sounds perfectly.

My only problem is when I use writetofolder and readfolder:

let me explain: that sampler is the engine powering a 4 x 3 midi carpet. You record 12 samples, then you can replay them walking on the carpet.

WHen I save a samples set with writetofolder, the files are stored in a folder with no problem at all, but when I reload them with “readfolder”, they’re loaded but in the opposite order of what I want: Instead of having my samples from 1 to 12 assigned to my carpet slots 1 to 12, they’re loaded from 12 to 1.

I’ve noticed that clearing twice the polybuffer~ could improve that, but it’s still very random… and I need it to be perfect.

any advice ?

#67209
Mar 20, 2013 at 11:31am

here is my messy patch, if it can help

Attachments:
  1. tapisrecres.maxpat
#241861
Mar 20, 2013 at 10:47pm

Thanks for the example. The problem is that the polybuffer~ gets the name ordered alphabetically so tapis.1.aif is followed by tapis.11.aif, not tapis.2.aif. I attached a way to fix it in the patcher by loading each file individually in the alpha numerical order.

#241862
Mar 21, 2013 at 11:36am

ok thanks a lot !

so I guess if I rename my buffer like this: 01, 02, 03, and so on, it will fix the problem as well ? am I wrong ?

Thanks for the trick !

#241863
Mar 21, 2013 at 2:04pm

You’re correct, but writefolder doesn’t write the files with this format. It might actually be easier to save the files directly in the correct format.

#241864
May 16, 2013 at 2:20am

oh ok I get it.
crazy you need to make such a subpatch just to get the files in the right order… max/msp is really disappointing sometimes, especially when you’re more a musician than a programmer.

#249508

You must be logged in to reply to this topic.