Friday, November 09, 2007

Record internet stream with VLC

To use vlc to record an Internet audio stream and save the file as an mp3.
I created a script, made it executable and created a cron entry to record at specific times
Command is one line

vlc -I dummy http://path/to/stream --sout '#transcode{acodec=mp3,ab=128,channels=2}:duplicate{dst=display,dst=standard{access=file,mux=raw,dst="/home/user/vlcout.mp3"}}

vlc -I dummy :runs vlc without starting the vlc gui. This is needed if you are running vlc from cron

http:/path/to/stream: location to internet stream

encodes the stream to mp3 and creates the file vlcout.mp3 in the users home directory

--sout '#transcode{acodec=mp3,ab=128,channels=2}:duplicate{dst=display,dst=standard{access=file,mux=raw,

ab=128 is the bitrate, this can be changed for your needs


Post a Comment

<< Home