extracting audio from a DVD

It’s pretty easy to extract just the audio from a DVD in Linux, using Mplayer, sox, and either Audacity or split.

  1. First you need to get the audio from the DVD into a WAV file:
    mplayer -vo null -ao pcm -aofile FILE_TO_CREATE.wav dvd://
    This step will take a while.
  2. Next you need to convert that huge WAV file (around 1Gb for 1.5 hours) into a format that’s more compact. I prefer OGG myself:
    sox -t wav THE_WAV_FILE.wav -t ogg FILE_TO_CREATE.ogg
    This step will also take a while.
  3. Now all that’s left is breaking that long .ogg file into separate songs. I recommend Audacity for this, as it has a GUI and has some useful features, such as being able to amplify sounds that are too soft. However, you can also use the command-line tool split, as follows:
    split -b SIZE THE_OGG_FILE.ogg NAME_TO_BEGIN_EACH_CHUNK_WITH

    This method is much less convenient as it only breaks your .ogg into separate files of size SIZE, ignoring the content. With Audacity, you can use your mouse to select sections and then export them to their own files.

I’m using Mplayer 1.0pre5-3.3.4, Audacity 1.2.3, sox 12.17.7, and split 5.2.1.

This entry was posted in Linux and tagged , , , | Current music No Doubt - Underneath it All. Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

3 Comments

  1. Posted 25 December 2005 at 9:59 PM | Permalink

    Ohh! It works, it works! This is too spiffy!

  2. Steven
    Posted 18 March 2006 at 12:26 PM | Permalink

    I find it works better if you split up the wav file. Since the wav file is uncompressed, you can break it up with command-line tools (man split). Then you can encode each of the small wav files into ogg files. I have a bash script that does exactly this; very handy for listening to Futurama in the car.

  3. Rob
    Posted 20 October 2009 at 5:12 PM | Permalink

    something i often do to rip audio/live concert dvd audio is to use the track divisions that are often already on the dvd. something like:

    for n in `seq -w 1 $MAXTRACKNUMBER`; do;
    mplayer -ao pcm:file=$n.wav -vo null -chapter $n-$n dvd://$TITLENUMBER
    done

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>