CD Ripping and encoding

cdparanoia, cddb, mp3, ogg and flac

Cdparanoia - Digital audio extraction

What it does:

What it doesn't do:

Here's a screenshot of Cdparanoia ripping a CD in batch mode (-B switch), which puts audio from each track in a seperate file.

Cdparanoia in action

Copy protection

Copy protections are deliberate countermeasures against programs like Cdparanoia. Some only work on Windows, which won't affect Cdparanoi on Linux, but others rely on tiny changes to the CD-ROM format that cd players ignore, but CD-ROMs in computers will see as an invalid disk. In the end, there is no copy protection that can't be broken, but it will take time for the functionality to make its way into programs like Cdparanoia. Also at issue is the DMCA, which makes it illegal to circumvent copy protections (even from media you bought and own).

Read more here.

CDDB - Track name, genre, artist database

CDDB is an online database of compact disc information. Ripping programs can use this to get track names for filenames and to give as much information to the encoder as possible. All data in the database is user-submitted, as very new or obscure CDs won't have track listings. The good news is, if you take the time to submit these listings, others with this CD will have this information. Also, there can be errors in the data, some people make 20 typos per track name and don't bother to fix them before submitting, so look over the names if this bothers you. CDDB works by taking the length and number of tracks and making a unique ID from them. This is slightly error prone, so more than one potential match might be returned from the server.

More info here.

Encoders - Audio compression

Raw digital audio is large, a typical 2 1/2 minute track will be about 30 megs. Here are three popular encoding and compression formats available for Linux:

mp3
This is by far the most popular, mp3 is everywhere. If you need portability, mp3 would be the way to go, but ogg produces smaller file sizes and FLAC doesn't lose audio quality. There are a number of mp3 encoders for Linux, including Lame and BladeEnc.
OGG Vorbis
OGG Vorbis uses similar technology to mp3, but isn't restricted by patents. Arguably better than mp3 in quality and file size, but not portable; most mp3 players cannot play ogg vorbis files.
FLAC
The Free Lossless Audio Codec uses lossless compression, as opposed to lossy compression as with ogg or mp3. For audiophiles, this is the best codec out of the three, it's smaller than raw audio and sounds no different. For the rest of us, there's no harm in using it, and would be best for archival purposes, but there's not much point to it if you can't tell the difference between FLAC and ogg/mp3 yourself.

Here is a quick screenshot of batch encoding with FLAC. I won't go deeply into encoding as there are many frontends that put all this together. If you're interested in learning more, see the manpages for lame/bladeenc, oggenc or flac

FLAC encoding

All-in-one solutions

Now that you know what these tools do behind the scenes, the GUI tools should be easy to use. These tools combine all the components above; a ripper (like cdparanoia), CDDB and an encoder. Here are shots of KAudioCreator for KDE and Sound Juicer for Gnome. You can find a directory of related programs at Freshmeat here.

KAudioCreatorSound Juicer