DVD-Playback-HOWTO.pdf

(52 KB) Pobierz
DVD Playback HOWTO
DVD Playback HOWTO
David Jao
2004−02−26
Revision History
Revision 1.0
2004−02−26
Revised by: DJ
Initial Release, reviewed by LDP
Revision 0.9
2004−02−07
Revised by: DJ
submitted to LDP
Revision 0.1
2004−01−26
Revised by: DJ
first public release
This document describes how to view DVD movies on a Linux computer with a DVD drive.
74605174.003.png
DVD Playback HOWTO
Table of Contents
1. Introduction. ....................................................................................................................................................1
1.1. Copyright and License. .....................................................................................................................1
1.2. Disclaimer. ........................................................................................................................................1
1.3. Feedback. ..........................................................................................................................................1
2. System Preparation. ........................................................................................................................................2
2.1. Hardware Prerequisites. ....................................................................................................................2
2.2. Creating the /dev/dvd symlink. .........................................................................................................2
2.3. Setting the DVD Region. ..................................................................................................................2
2.4. X Video Overlay. ..............................................................................................................................3
2.5. Enabling DMA. .................................................................................................................................3
3. Software Installation. ......................................................................................................................................4
3.1. Red Hat / Fedora. ..............................................................................................................................4
3.1.1. Special note about VideoLAN and Red Hat. ..........................................................................4
3.2. Debian. ..............................................................................................................................................4
3.3. Slackware. .........................................................................................................................................5
3.4. Mandrake. .........................................................................................................................................5
3.5. SuSE. .................................................................................................................................................6
3.6. Gentoo. ..............................................................................................................................................6
4. Software Usage. ...............................................................................................................................................7
4.1. General principles: deinterlacing, telecine, and framerates. .............................................................7
4.1.1. How to fix interlacing artifacts. ...............................................................................................7
4.1.2. Telecined video. ......................................................................................................................8
4.1.3. How come Windows users don't have to deal with all this?. ..................................................8
4.2. Specific usage instructions. ...............................................................................................................8
4.2.1. MPlayer. ..................................................................................................................................8
4.2.2. Xine. ........................................................................................................................................9
4.2.3. Ogle. ........................................................................................................................................9
4.2.4. VideoLAN. ..............................................................................................................................9
5. Troubleshooting. ...........................................................................................................................................10
6. Further Information. ....................................................................................................................................13
i
74605174.004.png
1. Introduction
In this document we describe how to view DVD movies and video on a Linux system. We give practical,
specific, and straightforward commands for getting DVD playback up and running quickly on most of the
popular Linux distributions. Special attention is given to the various little−known performance optimizations
that are needed for smooth DVD video playback.
1.1. Copyright and License
This document, DVD Playback HOWTO , is copyrighted © 2004 by David Jao . Permission is granted to copy,
distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2
or any later version published by the Free Software Foundation; with no Invariant Sections, with no
Front−Cover Texts, and with no Back−Cover Texts. A copy of the license is available at
Linux® is a registered trademark of Linus Torvalds.
1.2. Disclaimer
No liability for the contents of this document can be accepted. Use the concepts, examples and information at
your own risk. Although this is highly unlikely, there may be errors and inaccuracies herein that could be
damaging to your system. The author(s) do not take any responsibility for any damage that you incur through
your own actions.
The mere act of accessing or viewing DVD content, or dealing in software written for such purposes, may be
illegal in some localities. The author(s) cannot accept any responsibility for any actions of yours which violate
the laws of the jurisdictions to which you are subject.
All copyrights are held by their by their respective owners, unless specifically noted otherwise. Use of a term
in this document should not be regarded as affecting the validity of any trademark or service mark. Naming of
particular products or brands should not be seen as endorsements.
1.3. Feedback
Questions, comments, suggestions, and feedback are most certainly welcome and should be sent to the author
of this document at < djao@dominia.org> .
1. Introduction
1
74605174.005.png
2. System Preparation
2.1. Hardware Prerequisites
A certain level of processing power is necessary for smooth DVD playback. The system requirements in
Linux are somewhat higher than in Windows, because many of the techniques used for hardware acceleration
of video playback work only in Windows.
At a minimum, I recommend the following:
· video card with X Video Overlay support
700 MHz or higher CPU,
· DVD drive with DMA enabled
·
2.2. Creating the /dev/dvd symlink
If you don't already have a /dev/dvd symbolic link, then run (as root) the command
# ln −s /dev/hdc /dev/dvd
to create a symbolic link from /dev/dvd to the actual hardware device representing your DVD−ROM drive
(which in this example is /dev/hdc , but you should replace it with the actual device file used by your
drive). The /dev/dvd link is not merely a matter of convenience; almost all of the player software
mentioned in this HOWTO assumes that the link is there.
If you don't know which device name your DVD−ROM drive uses, you can usually find it with the command
dmesg | grep DVD in the console or a shell right after booting up the system.
2.3. Setting the DVD Region
All DVD drives (except for RPC Phase I drives made in 1999 or before) enforce region playback restrictions
in the drive firmware and consequently are supposed to be set to a specific region before they can play back
discs from that region (and only that region). In reality, most Linux DVD playback software can bypass the
DVD drive's built−in region locks, but it takes extra time for the software to break the region lock, and it is
better to avoid the complications of region locks if you can.
For the small minority of readers who own RPC−I drives, you do not need to do anything: your drive is
already capable of handling DVDs from all geographical regions. These drives are old enough by now that
everybody who has one of them probably knows already that they have one.
For the majority of readers who have RPC−II drives, there are several options available:
1.
If you only watch discs from one region, the easiest option is to use the regionset program to set your
DVD drive to the correct region.
2.
If you want to watch discs from multiple regions, you can try to find a firmware upgrade for your
DVD drive in the firmware−flash.com collection of unofficial firmware files. Note that most of these
files require you to boot to DOS or Windows to install.
2. System Preparation
2
74605174.006.png 74605174.001.png
DVD Playback HOWTO
3.
You can buy a separate DVD drive for each DVD region that you wish to use. The prices for
DVD−ROM drives have dropped low enough to make this strategy feasible.
4.
Of course, you can simply do nothing, and rely on the built−in ability of Linux software to bypass the
region restrictions. Note that even in this case you should use the regionset program to set the drive to
the region that you will be using the most, because an RPC−II drive without a region setting behaves
as if all the regions are locked out.
2.4. X Video Overlay
The XFree86 video overlay extension is a very poorly documented standard feature of XFree86 4.x and is
absolutely essential for high quality video playback under Linux. It is the only type of hardware playback
acceleration that is widely supported in Linux, and it is by far the single most important configuration element
for DVD playback on a Linux system.
To check if you have this extension, type xvinfo in an X terminal. If the command returns several screens full
of important−looking output, then congratulations, you have hardware video overlay and you need not worry
about it anymore.
If, on the other hand, xvinfo returns with a negative answer like:
# xvinfo
X−Video Extension version 2.2
screen #0
no adaptors present
then that means you don't have hardware overlay support. See Overlay Troubleshooting for tips on how to get
overlay support working.
2.5. Enabling DMA
DMA drive access is critical for DVD playback because it lowers the CPU overhead of disc reading and
leaves more of the CPU free for video playback. On most systems, enabling DMA support for the DVD drive
means the difference between choppy playback and smooth playback.
To see if you have DMA enabled, type (as root) the command
# hdparm −d /dev/hdc
(replacing /dev/hdc with your DVD drive's actual device name). If DMA is already on, then you're done.
Otherwise, you should turn it on by typing hdparm −d 1 /dev/hdc . You may want to add this command to a
startup script such as /etc/rc.d/rc.local to ensure that the DMA support is active every time your
computer boots.
See the DMA Troubleshooting section if DMA won't turn on even after you've typed the command to turn it
on.
2. System Preparation
3
74605174.002.png
Zgłoś jeśli naruszono regulamin