All pastes #13617 Raw Edit

Untitled

public text v1 · immutable
#13617 ·published 2005-06-06 22:59 UTC
rendered paste body
VLC Streaming Setup

Author's Website: http://www.videolan.org
Current Version: 0.8.2-svn

Updated: 5-1-05
Updated with new patch needed for current CVS and re-verified.

VLC isn't quite as user and CPU friendly as running VDR with a FF card. It is in need of a lot more CPU power than just running VDR. So if you experience problems, that might be the area to check. I have an Athlon 2600+ and stream no problem and cpu runs about 50% while streaming. I have tested this on a PIII 800 for a short while and it peaks at 80+% streaming and video can get choppy. So it definately requires a little more power than the norm. Good Luck.

Also I installed this AFTER installing packages for like MPLAYER etc, so my dependency list might be off due to that, I tried to include dependencies I knew it needed even though I had them already, but if you run into one that I don't have listed, please do let me know so that I can add it. I highly recommend you do the MPLAYER howto before doing this one.

Descriptions from website: VLC (initially VideoLAN Client) is a highly portable multimedia player for various audio and video formats (MPEG-1, MPEG-2, MPEG-4, DivX, mp3, ogg, ...) as well as DVDs, VCDs, and various streaming protocols. It can also be used as a server to stream in unicast or multicast in IPv4 or IPv6 on a high-bandwidth network.

Also, I highly recommend you upgrading your sources to SID, there is a seperate Howto on this. But for an advanced application like this, it is recommended to have some of the latest tools available. So you might check out that howto first before starting on this one. This is a Debian thing of course.

A requirement to make full use of VLC which is LIVE streaming to another pc from your VDR system. You will need to have Streamdev-Server installed and running. I suggest checking out that Howto in this forum also.

Now enough of all that, let's get started!

Install the appropriate packages to support VLC and VDR Streaming.
sudo apt-get install libfaad2-0
sudo apt-get install libfaad2-dev
sudo apt-get install libdvdread3
sudo apt-get install libdvdread3-dev
sudo apt-get install liba52-0.7.4
sudo apt-get install liba52-0.7.4-dev
sudo apt-get install libmpeg2-4
sudo apt-get install libmpeg2-4-dev
sudo apt-get install libdvdcss2
sudo apt-get install libdvdcss2-dev
sudo apt-get install libmad0
sudo apt-get install libmad0-dev
sudo apt-get install libasound2
sudo apt-get install libasound2-dev
sudo apt-get install liblame0
sudo apt-get install liblame-dev
sudo apt-get install subversion
sudo apt-get install subversion-tools
sudo apt-get install libquicktime1
sudo apt-get install libquicktime-dev
sudo apt-get install libjasper-1.701-1
sudo apt-get install libjasper-1.701-dev
sudo apt-get install libsvga1
sudo apt-get install libsvga1-dev
sudo apt-get install transcode
sudo apt-get install automake1.9

All this is kinda hokey but it is the fastest way to get you up and running and when I made this howto. This sets the paths right for where the files are trying to be found. So make the following directories and make sym links to the files in question.

sudo mkdir /usr/lib/libfaad
sudo mkdir /usr/lib/libfaad/.libs
sudo ln -s /usr/lib/libfaad.a /usr/lib/libfaad/.libs/libfaad.a
sudo ln -s /usr/include/a52dec /usr/include/a52dec/include

Get and install CVS of FFMPEG. Again, I repeat that I installed this application AFTER installing MPLAYER. And my package dependencies were already met. So you might run into some issues compiling FFMPEG due to that. Again if you find a package that is missing from above because you didn't install MPLAYER first, then please do let me know, and I will update the howto.

mkdir /usr/local/src/ffmpeg.cvs
cd /usr/local/src/ffmpeg.cvs
cvs -z9 -d:pserver:anonymous@mplayerhq.hu:/cvsroot/ffmpeg co ffmpeg
cd ffmpeg
make clean
./configure --prefix=/usr --enable-shared --enable-mp3lame --enable-gpl --enable-vorbis --enable-faadbin --enable-faad --enable-a52 --enable-pthreads --enable-faac --enable-xvid --enable-dts --enable-pp
make
sudo make install

Get SVN of VLC. Currently, we recommend getting the 0.8.2 branch of CVS due to stability until the current 0.8.3 branch reaches a little more maturity. I have given both commands in case you want to be adventurous.

0.8.2 CVS Branch - STABLE
mkdir /usr/local/src/vlc.cvs
cd /usr/local/src/vlc.cvs
svn co svn://svn.videolan.org/vlc/branches/0.8.2
cd 0.8.2

Current CVS - NON-STABLE - Only install this one if you didn't do the one above. And it is unaware of what patches work etc.

mkdir /usr/local/src/vlc.cvs
cd /usr/local/src/vlc.cvs
svn co svn://svn.videolan.org/vlc/trunk vlc-trunk
cd vlc-trunk

Now apply a patch for compiling.

wget http://www.hoochvdr.info/files/ffmpeg.cvs.diff
patch -p1 < ffmpeg.cvs.diff

Now configure VLC. To do this we first need to create our Makefile and Configure scripts.

./bootstrap

Now once that has completed we are ready to configure VDR for compiling.

./configure --enable-release --enable-livedotcom --enable-dvdread --enable-dshow --disable-x11 --enable-alsa --enable-ncurses --with-ffmpeg-mp3lame --with-ffmpeg-tree=/usr/local/src/ffmpeg.cvs/ffmpeg --with-a52-tree=/usr/include/a52dec --enable-faad --with-faad-tree=/usr/lib --disable-skins --disable-skins2 --disable-speex --enable-flac --enable-theora --disable-wxwindows --disable-visual --enable-sout

Compile and install.

make
sudo make install

Here is a sample script to run VLC. The example shown is just one of many ways to set the compression etc. Refer to http://www.videolan.org and any README's for exact types you can perform.

cd /usr/local/bin
sudo nano vlcstart
#!/bin/sh
vlc -vvv http://127.0.0.1:3000/PS/$1 --sout '#transcode{vcodec=DIV3,vb=512,acodec=mp3,ab=128,channels=2,deinterlace}:std{access=mmsh,mux=asfh,url=:1234}'

Now make it executable.

sudo chmod 755 vlcstart

To run script, broadcasting a particular channel.

sudo vlcstart ###

Where ### is channel to broadcast.

Now you should be able to use either VLC player or another type of program like Windows Media player to connect to the URL of the VDR box. Just open a URL to http://xxx.xxx.xxx.xxx:1234 and you are set!