Rockbox General > Rockbox General Discussion

How do I batch convert mp3 or wav files to OPUS?

(1/2) > >>

IDK5:
I have a bunch of audio books that I would like to convert over to OPUS from MP3 but right now i have to type in "opusenc --vbr --bitrate 8 input.wav output.opus" which works fine but I have over 50,000 of these cause they are split by the chapter and I have to type that in every time for every file, so I am asking how I could convert them all in one go or even per folder.

saratoga:
Use a program like foobar or dbpoweramp to convert them.

IDK5:
I forgot to mention i am using openSUSE do they run on linux?

saratoga:
Check google.

bluebrother:

--- Code: ---for i in *.wav; do opusenc --vbr --bitrate 8 "$i" "$(basename "$i".wav)".opus; done
--- End code ---

Or use any other scripting language -- your question pretty much gives the answer. To batch convert files either use a tool that can do it or write a small batch script in any scripting language you like.

Edit: forgot the done part.

Navigation

[0] Message Index

[#] Next page

Go to full version