[RDD] Utility for converting from wav to mpeg L2

James Harrison james at talkunafraid.co.uk
Sun Oct 14 08:10:04 EDT 2012


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
 
sudo apt-get install ffmpeg (or yum, whichever)
Replace .ext with the original extension here (in both places):

for i in *.ext;do ffmpeg -i "$i" -acodec mp2 -ab 256k -ar 48000
"${i%.ext}.mp2"; done

This will use ffmpeg to make a new file next to each .ext file in MPEG
Layer 2 audio at 256k with a 48kHz sample rate. Tweak numbers to suit.
Anything ffmpeg can read, it'll work. You should also be able to compile
ffmpeg with TwoLAME support for even better encoding quality - if you
don't fancy recompiling, use ffmpeg to export WAV (just change .mp2 to
.wav above and remove the -acodec and -ab parameters) and after the
second semicolon, add this: twolame -s 48000 -b 256 "${i%.ext}.wav"
"${i%.ext}.mp2";

for i in *.ext;do ffmpeg -i "$i" -ar 48000 "${i%.ext}.wav"; twolame -s
48000 -b 256 "${i%.ext}.wav" "${i%.ext}.mp2";rm -rf "${i%.ext}.wav";done

Once you've done the conversion you can go ahead and verify the files
work, move the old .ext files to offline storage in case you ever need
them and you should have an MP2 library.

Cheers,
James Harrison

On 13/10/2012 17:19, Daniel & Lucinda Kahn wrote:
> Fred,
>
> We have been running Rivendell for almost three years. When we started
> we used a compressed format patch to Rivendell since at the time we
> didn't have the hard drive space to run the library using wav format.
>
> You said in the past it wouldn't be hard to make a converter utility for
> converting a library to mpeg L2. We are in desperate need of that now
> so we can update to Rivendell 2.x.
>
> What is the possibility in the near future that you could make such an
> utility available?
>
> Thanks,
> Daniel
>
> Ondas de Esperanza 94.1 FM 1340 AM
> Loja, Ecuador
> _______________________________________________
> Rivendell-dev mailing list
> Rivendell-dev at lists.rivendellaudio.org
> http://lists.rivendellaudio.org/mailman/listinfo/rivendell-dev

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/
 
iEYEARECAAYFAlB6q5wACgkQ22kkGnnJQAxjjgCfX7BlOg84QSGeTNR6I1pf8Gog
kkgAoJxaDErOu8Kf/O5eXManNhFyZLoB
=mFIZ
-----END PGP SIGNATURE-----

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.rivendellaudio.org/pipermail/rivendell-dev/attachments/20121014/2d1bc235/attachment.htm 


More information about the Rivendell-dev mailing list