HOW TO: Setup DVD And Video Playback

January 23, 2006 on 4:20 pm | In Linux, Ubuntu, HOW TO |

Many Linux distributions don’t bring full support for movies and DVD’s due to legal issues, and this can be a serious bummer if you want to play your new copy of ‘Fight Club’. So, here’s how to set up the necessary files so that you’ll be watching it in no time!

 

Ubuntu 5.10 Breezy

First of all, add the extra repositories - this will add the repositories we need to download the packages from.

When you have done that, open up the terminal (either via the menu or ‘Alt + F2′ and ‘xterm’). Copy and paste the following:
# sudo apt-get install gstreamer0.8-plugins
# sudo apt-get install gstreamer0.8-lame
# sudo apt-get install gstreamer0.8-ffmpeg
# sudo apt-get install lame
# sudo apt-get install sox
# sudo apt-get install ffmpeg
# sudo apt-get install mjpegtools
# sudo apt-get install vorbis-tools
# sudo apt-get install w32codecs
# gst-register-0.8
# sudo apt-get install libdvdcss2
# sudo apt-get install xine-ui

That installed all the required packages (and some extras for music playback). Now, associate xine-ui so that it is the default player for multimedia files (if it follows onto the next line without a #, it is still in the same command):

# gconftool-2 –type string –set /desktop/gnome/volume_manager/autoplay_dvd_command “xine dvd://”
# sudo rm -f /usr/share/applnk/Multimedia/xine.desktop
# sudo ln -fs /usr/share/xine/desktop/xine.desktop /usr/share/applications/
# sudo cp /usr/share/applications/defaults.list /usr/share/applications/defaults.list_backup
# sudo sed -e ’s/totem.desktop/xine.desktop/g’ /usr/share/applications/defaults.list_backup > /tmp/defaults.list
# sudo mv /tmp/defaults.list /usr/share/applications/defaults.list

Finally, to make DVD playback be as smooth as possbile, we will turn on direct memory access for the DVD drive. But, first we need to verify what the DVD drive is. A simple way to do this is:
# dmesg | grep DVD , which should produce a result like:
[4294671.098000] hdc: Make IDE CDROM Drive, ATAPI CD/DVD-ROM drive

In my case, the DVD drive is “/dev/hdc”. So, here is what I would type:
# sudo hdparm -d1 /dev/hdc

We also need to make a symbolic link from your drive to /dev/cdrom, which is the one xine expects. So, type the following (remember to change ‘hdc’ to your device name):
# ln -s /dev/cdrom /dev/hdc

Good! Now just type ‘xine’ to start it up, or put your DVD into the drive!

RPM-based Distibutions

Download the following RPM’s: libxine1, xine-ui, w32codecs and libdvdcss2 from cambuca, and save them to your desktop.

Now, open up a terminal window (for example ‘xterm’ and ‘Konsole’) and type in the following:
# cd /home/user/Desktop — Note: Replace user with your username
# rpm -U libxine1* xine-ui* libdvdcss* w32codec*

Once this has finished, to make DVD playback be as smooth as possbile we must turn on direct memory access for the DVD drive. But, first we need to verify what the DVD drive is. A simple way to do this is:
# dmesg | grep DVD , which should produce a result like:
[4294671.098000] hdc: Make IDE CDROM Drive, ATAPI CD/DVD-ROM drive

In my case, the DVD drive is “/dev/hdc”. So, here is what I would type (remember to change ‘hdc’ to your device name):
# sudo hdparm -d1 /dev/hdc

We also need to make a symbolic link from your drive to /dev/cdrom, which is the one xine expects. So, type the following (remember to change ‘hdc’ to your device name):
# ln -s /dev/cdrom /dev/hdc

Any Other Distribution

The best method of installing the required packages (xine-ui, xine-lib, w32codecs, libdvdcss2) is to download the prebuilt packages using your distribution’s inbuilt package manager (you may need to add extra repositories).
If this isn’t possible, then go to the xine download page and download the latest versions of ‘xine-lib’ and ‘xine-ui’, and save them to your desktop. Then, visit MPlayer to download the latest version of w32codecs (’essential codecs’). You will also need libdvdcss2, for which you will have to Google for your distribution.

If you used the second method, then follow this guide from the xine documentation to help you install xine-lib and xine-ui. Use a similar method of unpacking the tarball (tar -xzf tarballname.tar.gz), changing into its directory (cd foldername/) and installing it (./configure && make && make install) for w32codecs and libdvdcss2.

Once they are all installed, to make DVD playback be as smooth as possbile we must turn on direct memory access for the DVD drive. But, first we need to verify what the DVD drive is. A simple way to do this is:
# dmesg | grep DVD , which should produce a result like:
[4294671.098000] hdc: Make IDE CDROM Drive, ATAPI CD/DVD-ROM drive

In my case, the DVD drive is “/dev/hdc”. So, here is what I would type (remember to change ‘hdc’ to your device name):
# sudo hdparm -d1 /dev/hdc

You’re good to go!

Note: Most distributions bring DVD read support. If yours doesn’t, then please install ‘libdvdread3′.

Add to:
del.icio.us  digg it

6 Comments »

RSS feed for comments on this post. TrackBack URI

  1. Ambien message board….

    Ambien….

    Trackback by Ambien cr addiction. — February 8, 2008 #
    Using Unknown browser

  2. gioochi di machine…

    falseness approximating deleter interrupt …

    Trackback by gioochi di machine — February 19, 2008 #
    Using Internet Explorer Internet Explorer 6.0 on Windows Windows XP

  3. No prescription needed vicodin….

    Vicodin. House fox vicodin. Dangers of vicodin. Vicodin detox. No prescription needed vicodin. Vicodin withdrawal….

    Trackback by Vicodin. — February 27, 2008 #
    Using Unknown browser

  4. islandcasino…

    puma adoptions hazard charcoal …

    Trackback by islandcasino — February 28, 2008 #
    Using Internet Explorer Internet Explorer 4.01 on Mac OS Mac OS

  5. apply online private loans…

    begrudges crimsoning:sonata gaseously castor fertile …

    Trackback by apply online private loans — March 2, 2008 #
    Using Internet Explorer Internet Explorer 6.0 on Windows Windows XP

  6. online life insurance…

    amplifier Brahms liters consists?enumerable hamburgers …

    Trackback by online life insurance — May 15, 2008 #
    Using Internet Explorer Internet Explorer 6.0 on Windows Windows Server 2003

Leave a comment

XHTML: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>

Powered by WordPress with Pool theme.
Entries and comments feeds. Valid XHTML and CSS. ^Top^
0.347 seconds.

Credit Counseling - Cheap Car Insurance - Loans - Loans