{title:}

Tue, 09. July 2013 – 16:13

I knew there was a way to get this job done; needing to extract the audio track from a (music) video, I have been looking at various tools to help me with the task. The first stop – the Streaming Wizard which comes as part of the VLC Player – failed to deliver, not even starting up on the conversion. After a hand full of attempts to tweak the control parameters, I decided that probably it was better to go for a command line tool (which of course also would have the advantage of being scriptable to process multiple input files quite easily). Obvious choice here would be MPlayer, which not only is capable of reading/playing quite a long list of formats, but also through is countless options can be fine-tuned to act as a swiss-army-knife when dealing with all of these multimedia formats; a companion program, MEncoder, can take an input stream or file and transcode it into several different output formats, optionally applying various transforms along the way. The latter provided exactly the type of functionality I was looking for to extract the audio track:

mencoder <video file> -oac mp3lame -ovc frameno -o <audio file>

Applying this to the video I have been downloading from YouTube I now finally have the mp3 file, which can be integrated into the playlist.