Monday, August 23, 2010

Split Flac audio file

I recently downloaded some rips of audio CD's. In each CD folder, I found one huge .flac file and a .cue file. Professor Google told me that Flac is a lossless audio codec, and that I could split the .flac file into individual tracks using a command-line tool and the .cue file.
I installed flac, shntool and cuetools from the Debian repository and ran the following command:
shntool split -f *.cue -o flac *.flac
This splits the one big flac file, whatever its name, into separate flac files, according to the information in the .cue file, whatever its name. (It is of course possible to specify the file names if there's more than one in the directory.)
I didn't have any luck trying to change the output format to MP3, or trying to add file tags using the .cue file, and simply used Sound Converter instead.
Users of Ubuntu and Debian Unstable can get this good looking GUI application to split audio files. It's called gCue2tracks. The screenshot I found here.

Update: If you experience the following error message, see this post:
shntool [split]: error: m:ss.ff format can only be used with CD-quality files

No comments:

Post a Comment