auto-edit audio via scripting

Aug 15, 2010 at 8:07am

auto-edit audio via scripting

Hi all.
I have a folder full of 3sec audio tracks.
I need to (auto)make one track with a random order of these tracks.
Is there a solution via scripting to do this ?

(mac 10.5)

Aug 15, 2010 at 12:31pm

You need to describe what you want to do in detail. “(auto)make one track with a random order of these tracks.” doesn’t help much.

In general, scripting is not what you need. editing audio files is not max’s forte. MXJ might be able to do the job but you’re better off loading all three files and using [mxj buf.Op]

Aug 15, 2010 at 1:22pm

I want to make one audio file of one hour, which contains 3 sec files I have in my folder, and the order must be chose by random.
I know max is not the best to do that, but maybe something like ffmpeg for audio for instance, I don’t know…
That’s why I talk about script and not max.

Hope this is clear.

Aug 16, 2010 at 4:52am

there might be an easier way to do this, and you might want to do it in java (take a look at mxj buf.Op for an example on buffer operations), but here is one possible way to do it:

– Pasted Max Patch, click to expand. –
Aug 16, 2010 at 12:02pm

Thx !!
I’m going to check the buf.Op, my files won’t be always 3sec long.

Aug 16, 2010 at 12:07pm

you could just do it in realtime using half a dozen play~ and buffer~

Aug 16, 2010 at 1:24pm

Nope because I have to make some loop with the new track, would have been too simple.

Aug 16, 2010 at 4:15pm

Here’s my final patch: it does take by random every entire files of one folder to make one audio track stored in one buffer:
Thx to Ben, who does almost the whole patch !

– Pasted Max Patch, click to expand. –



You must be logged in to reply to this topic.