Batch process mp3 files


Have a bunch of mp3 files. For each, I’d want to add silence at the end, same time as length of track, and loop the playback for a number of times. The resulting audio file should be like this ::

(Track + silence)*(loop number)

Or sometimes, a different pattern.

(Track + Track + silence)*(loop number)

I read about Chains in Audacity, but the silence command is not available on the Chain menu. If this can’t be automated with audacity, any other suggestions?

Any ideas? Thanks.

You could do this using SoX
It’s a command line program so you would need to write a script to run it.

Thanks, my problem is that the Windows SOX binaries do not support mp3 format. Makes things a bit more difficult now that I have to convert to wav or ogg first.

If you’re writing a script, you could use LAME as a command line program to convert the MP3s, then use SoX for the other operations (in the same script).

the link for compiled lame.exe executable is wrong in the documentation here >>

From the lame homepage, i got this::

Thanks for the report somenick. I’ll pass that on to the maintainer of that page.

For standalone Lame, the rarewares always has good up to date builds as well as experimental alpha versions. However the rarewares builds are not recommended for use in Audacity for compatibility reasons.
Rarewares also hosts one of my favourite graphical MP3 batch encoders “LameDropXPd”

If you have the original files in wav format then you could use sox to batch process the files and add the silence and output to wav too.

Then you could use other app to batch convert the wav’s to mp3. I’m not a windows user, but I’d be surprised if there wasn’t some free graphical wav to mp3 encoder that works in batch mode…

Thanks. I’ve updated the link to provide a package for LAME 3.98.3.

The “Lame v3.98.3 for Audacity on Windows.exe” installer from does already include the command-line executable (lame.exe). You can use it in Audacity 1.3 if you export using (external program).

Next time we update the LAME installer we may as well include the USAGE.txt documentation for LAME then there will be no need for this separate package.


Thanks Gale.

That would be a good idea.

As in my previous post, one of my favourites (free) is LameDropXPd