Playing DVDs in linux console. (mplayer installation)

Johan Bergström johbe at linux.se
Wed Mar 6 13:51:49 EST 2002


Alright, first off you need a working compiler and the make program and
all the standard development libraries. I'm not going into detail how to
get that, I'm going to assume you have it all working and concentrate on
getting the movies rolling. Oh, and you also need X developement
libraries. If you run debian, you can just run,

apt-get install xlib6g xlib6g-dev

If you have apt setup, which you should have if you run debian. :-)

Otherwise, you'll have to search through your CD's or something for X
libraries and the X developement enviroment. Its only needed for the
compilation, you wont need to run X to run mplayer to watch movies.

You need to download quite a few files, here are some URL's stright to the
files you need, you can use wget <url> or lynx or whatever you wish to
save them.

http://www.dtek.chalmers.se/groups/dvd/dist/libdvdcss-0.0.3.ogle3.tar.gz
http://www.dtek.chalmers.se/groups/dvd/dist/libdvdread-0.9.2.tar.gz
http://www2.mplayerhq.hu/MPlayer/releases/w32codec-0.60.tar.bz2
http://www2.mplayerhq.hu/MPlayer/cvs/MPlayer-current.tar.bz2

Now, start by uncompressing the libdvdcss and libdvdread files and install
them in the standard way, something like this,

tar xzf libdvdcss-0.0.3.ogle3.tar.gz
cd libdvdcss-0.0.3.ogle3
./configure
make
make install
cd ..
tar xzf libdvdread-0.9.2.tar.gz
cd libdvdread-0.9.2
./configure
make
make install

Both those make install commands has to be run as root, since they install
in /usr/local/lib.

Next, uncompress w23codecs-0.60.tar.bz2,

tar xIf w32codec-0.60.tar.bz2

Then create the directory /usr/lib/win32 and move the files under
w32codec-0.60 into that dir.

Now make sure you have a link in the /dev directory called dvd that points
to your dvd player device. Usually its the /dev/hdc or /dev/hdd device
thats the dvd player. Create if if it doesnt exist,

ln -s /dev/hdc /dev/dvd

Now its time for mplayer, uncompress it in the usual manor, and do the
standard commands.

tar xIf MPlayer-current.tar.bz2
cd MPlayer-20020303
./configure

Here, in the output of the configure script, make sure you see these
lines, or something similar to it,

Checking for DVD support (libdvdread - new style) ... yes
Checking for Win32 DLL support ... yes (using /usr/lib/win32)

And either one of these,

Checking for OSS Audio ... yes

Checking for ALSA audio ... yes (using alsa 0.9.x)

Preferably OSS Audio since Alsa audio is still very bad and distorted and
under developement in mplayer.

If everything looks good, run make and make install as usual.

Now we're almost done, just a few tricks more. First move the files
MPlayer-20020303/etc/codecs.conf and MPlayer-20020303/etc/input.conf into
a directory called .mplayer (obs, the dot) which should reside in your
homedir.

The input.conf is a file where you can bind keys to features in mplayer
such as fastforward, volume controls and similar. The standard keys are
rightarrow equals fastforward 10 seconds, uparrow fastforward 1 minute and
pageup fastforward 10 minutes. Volume controls are 0 and 9 or, numpad /
and *. (Which I think speakup has already bound for other stuff.) P is for
pause/play and Q is for quit. Check input.conf for more.

Create a file called config in the .mplayer dir and write this in it,

vc=null
ao=oss

alternativly

ao=alsa9

If you only have alsa sound. vc is short for VideoCodec, and since we
dont want to use that we just use the null device. ao is the Audio Output
driver.

Now you are ready.

To play standard mpg/avi/divx or whatever, just run mplayer /path/to/file
and to play DVDs put disc into the player and run the command,

mplayer -dvd 1

Thats all. Hope you all get it working.

Bye,

Johan





More information about the Speakup mailing list