DOCS/xml/en: remove various outdated documentation

The XML documentation was badly outdated, with various obsolete,
useless and and sometimes actively harmful advice. Delete a lot of the
obsolete stuff, without spending much effort to replace it for now.

In the FAQ section I removed some questions completely; in other cases
I only removed the answer if I thought the entry might be worth
keeping but the answer would need to be updated.
This commit is contained in:
Uoti Urpala 2011-02-15 12:08:16 +02:00
parent 0321f6ce3c
commit 685bbb5734
9 changed files with 43 additions and 10952 deletions

View File

@ -41,13 +41,7 @@ send that one with another mail.
<title>How to fix bugs</title>
<para>
If you feel have the necessary skills you are invited to have a go at fixing the
bug yourself. Or maybe you already did that? Please read
<ulink url="../../tech/patches.txt">this short document</ulink> to find out how
to get your code included in <application>MPlayer</application>. The people on
the
<ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-dev-eng">MPlayer-dev-eng</ulink>
mailing list will assist you if you have questions.
OUTDATED CONTENT REMOVED
</para>
</sect1>
@ -59,84 +53,7 @@ mailing list will assist you if you have questions.
<title>How to do regression testing using Subversion</title>
<para>
A problem that can happen sometimes is 'it used to work before, now it
doesn't anymore...'.
Here is a step by step procedure to try to pinpoint when the problem
occurred. This is <emphasis role="bold">not</emphasis> for casual users.
</para>
<para>
First, you'd need to fetch MPlayer's source tree from Subversion.
Instructions can be found in the
<ulink url="http://www.mplayerhq.hu/design7/dload.html#svn">Subversion section of the download page</ulink>.
</para>
<para>
You will have now in the mplayer/ directory an image of the Subversion tree, on
the client side.
Now update this image to the date you want:
<screen>
cd mplayer/
svn update -r {"2004-08-23"}
</screen>
The date format is YYYY-MM-DD HH:MM:SS.
Using this date format ensure that you will be able to extract patches
according to the date at which they were committed, as in the
<ulink url="http://lists.mplayerhq.hu/pipermail/mplayer-cvslog/">MPlayer-cvslog archive</ulink>.
</para>
<para>
Now proceed as for a normal update:
<screen>
./configure
make
</screen>
</para>
<para>
If any non-programmer reads this, the fastest method to get at the point
where the problem occurred is to use a binary search &mdash; that is,
search the date of the breakage by repeatedly dividing the search
interval in half.
For example, if the problem occurred in 2003, start at mid-year, then ask
"Is the problem already here?".
If yes, go back to the first of April; if not, go to the first of October,
and so on.
</para>
<para>
If you have lot of free hard disk space (a full compile currently takes
100 MB, and around 300-350 MB if debugging symbols are enabled), copy the
oldest known working version before updating it; this will save time if
you need to go back.
(It is usually necessary to run 'make distclean' before recompiling an
earlier version, so if you do not make a backup copy of your original
source tree, you will have to recompile everything in it when you come
back to the present.)
Alternatively you may use <ulink url="http://ccache.samba.org/">ccache</ulink>
to speed up compilation.
</para>
<para>
When you have found the day where the problem happened, continue the search
using the mplayer-cvslog archive (sorted by date) and a more precise svn
update including hour, minute and second:
<screen>
svn update -r {"2004-08-23 15:17:25"}
</screen>
This will allow you to easily find the exact patch that did it.
</para>
<para>
If you find the patch that is the cause of the problem, you have almost won;
report about it to the
<ulink url="http://bugzilla.mplayerhq.hu/">MPlayer Bugzilla</ulink> or
subscribe to
<ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-users">MPlayer-users</ulink>
and post it there.
There is a chance that the author will jump in to suggest a fix.
You may also look hard at the patch until it is coerced to reveal where
the bug is :-).
OUTDATED CONTENT REMOVED
</para>
</sect1>
@ -148,49 +65,7 @@ the bug is :-).
<title>How to report bugs</title>
<para>
First of all please try the latest Subversion version of
<application>MPlayer</application>
as your bug might already be fixed there. Development moves extremely fast,
most problems in official releases are reported within days or even hours,
so please use <emphasis role="bold">only Subversion</emphasis> to report bugs.
This includes binary packages of <application>MPlayer</application>.
Subversion instructions can be found at the bottom of
<ulink url="http://www.mplayerhq.hu/dload.html">this page</ulink> or in
the README. If this did not help please refer to the rest of the documentation.
If your problem is not known or not solvable by our instructions,
then please report the bug.
</para>
<para>
Please do not send bug reports privately to individual developers. This is
community work and thus there might be several people interested in it.
Sometimes other users already experienced your troubles and know how to
circumvent a problem even if it is a bug in <application>MPlayer</application>
code.
</para>
<para>
Please describe your problem in as much detail as possible. Do a little
detective work to narrow down the circumstances under which the problem occurs.
Does the bug only show up in certain situations? Is it specific to certain
files or file types? Does it occur with only one codec or is it codec
independent? Can you reproduce it with all output drivers? The more information
you provide the better are our chances at fixing your problem. Please do not
forget to also include the valuable information requested below, we will be
unable to properly diagnose your problem otherwise.
</para>
<para>
An excellent and well written guide to asking questions in public forums is
<ulink url="http://www.catb.org/~esr/faqs/smart-questions.html">How To Ask Questions The Smart Way</ulink>
by <ulink url="http://www.catb.org/~esr/">Eric S. Raymond</ulink>.
There is another called
<ulink url="http://www.chiark.greenend.org.uk/~sgtatham/bugs.html">How to Report Bugs Effectively</ulink>
by <ulink url="http://www.chiark.greenend.org.uk/~sgtatham/">Simon Tatham</ulink>.
If you follow these guidelines you should be able to get help. But please
understand that we all follow the mailing lists voluntarily in our free time. We
are very busy and cannot guarantee that you will get a solution for your problem
or even an answer.
OUTDATED CONTENT REMOVED
</para>
</sect1>
@ -202,15 +77,7 @@ or even an answer.
<title>Where to report bugs</title>
<para>
Subscribe to the MPlayer-users mailing list:
<ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-users"/>
and send your bug report to
<ulink url="mailto:mplayer-users@mplayerhq.hu"/> where you can discuss it.
</para>
<para>
If you prefer, you can use our brand-new
<ulink url="http://bugzilla.mplayerhq.hu/">Bugzilla</ulink> instead.
OUTDATED CONTENT REMOVED
</para>
<para>
@ -235,12 +102,7 @@ to subscribe to actually receive your answer.
<title>What to report</title>
<para>
You may need to include log, configuration or sample files in your bug report.
If some of them are quite big then it is better to upload them to our
<ulink url="ftp://upload.mplayerhq.hu/MPlayer/incoming/">FTP server</ulink> in a
compressed format (gzip and bzip2 preferred) and include only the path and file
name in your bug report. Our mailing lists have a message size limit of 80k, if
you have something bigger you have to compress or upload it.
OUTDATED CONTENT REMOVED
</para>
<!-- ********** -->
@ -249,57 +111,7 @@ you have something bigger you have to compress or upload it.
<title>System Information</title>
<para>
<itemizedlist>
<listitem><para>
Your Linux distribution or operating system and version e.g.:
<itemizedlist>
<listitem><para>Red Hat 7.1</para></listitem>
<listitem><para>Slackware 7.0 + devel packs from 7.1 ...</para></listitem>
</itemizedlist>
</para></listitem>
<listitem><para>
kernel version:
<screen>uname -a</screen>
</para></listitem>
<listitem><para>
libc version:
<screen>ls -l /lib/libc[.-]*</screen>
</para></listitem>
<listitem><para>
gcc and ld versions:
<screen>
gcc -v
ld -v<!--
--></screen>
</para></listitem>
<listitem><para>
binutils version:
<screen>as --version</screen>
</para></listitem>
<listitem><para>
If you have problems with fullscreen mode:
<itemizedlist>
<listitem><para>Window manager type and version</para></listitem>
</itemizedlist>
</para></listitem>
<listitem><para>
If you have problems with XVIDIX:
<itemizedlist>
<listitem><para>
X colour depth:
<screen>xdpyinfo | grep "depth of root"</screen>
</para></listitem>
</itemizedlist>
</para></listitem>
<listitem><para>
If only the GUI is buggy:
<itemizedlist>
<listitem><para>GTK version</para></listitem>
<listitem><para>GLIB version</para></listitem>
<listitem><para>GUI situation in which the bug occurs</para></listitem>
</itemizedlist>
</para></listitem>
</itemizedlist>
OUTDATED CONTENT REMOVED
</para>
</sect2>
@ -309,39 +121,7 @@ ld -v<!--
<title>Hardware and drivers</title>
<para>
<itemizedlist>
<listitem><para>
CPU info (this works on Linux only):
<screen>cat /proc/cpuinfo</screen>
</para></listitem>
<listitem><para>
Video card manufacturer and model, e.g.:
<itemizedlist>
<listitem><para>ASUS V3800U chip: nVidia TNT2 Ultra pro 32MB SDRAM</para></listitem>
<listitem><para>Matrox G400 DH 32MB SGRAM</para></listitem>
</itemizedlist>
</para></listitem>
<listitem><para>
Video driver type &amp; version, e.g.:
<itemizedlist>
<listitem><para>X built-in driver</para></listitem>
<listitem><para>nVidia 0.9.623</para></listitem>
<listitem><para>Utah-GLX CVS 2001-02-17</para></listitem>
<listitem><para>DRI from X 4.0.3</para></listitem>
</itemizedlist>
</para></listitem>
<listitem><para>
Sound card type &amp; driver, e.g.:
<itemizedlist>
<listitem><para>Creative SBLive! Gold with OSS driver from oss.creative.com</para></listitem>
<listitem><para>Creative SB16 with kernel OSS drivers</para></listitem>
<listitem><para>GUS PnP with ALSA OSS emulation</para></listitem>
</itemizedlist>
</para></listitem>
<listitem><para>
If in doubt include <command>lspci -vv</command> output on Linux systems.
</para></listitem>
</itemizedlist>
OUTDATED CONTENT REMOVED
</para>
</sect2>
@ -472,30 +252,4 @@ gdb mplayer --core=core -batch --command=command_file &gt; mplayer.bug
</sect2>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="bugreports_advusers">
<title>I know what I am doing...</title>
<para>
If you created a proper bug report following the steps above and you are
confident it is a bug in <application>MPlayer</application>, not a compiler
problem or broken file, you have already read the documentation and you could
not find a solution, your sound drivers are OK, then you might want to
subscribe to the MPlayer-advusers list and send your bug report there to get
a better and faster answer.
</para>
<para>
Please be advised that if you post newbie questions or questions answered in the
manual there, you will be ignored or flamed instead of getting an appropriate
answer. So do not flame us and subscribe to -advusers only if you really know
what you are doing and feel like being an advanced
<application>MPlayer</application> user or developer. If you meet these
criteria it should not be difficult to find out how to subscribe...
</para>
</sect1>
</appendix>

View File

@ -3,7 +3,7 @@
<bookinfo id="toc">
<title><application>MPlayer</application> - The Movie Player</title>
<subtitle><ulink url="http://www.mplayerhq.hu"></ulink></subtitle>
<subtitle><ulink url="http://www.mplayer2.org/"></ulink></subtitle>
<date>March 24, 2003</date>
<copyright>
<year>2000</year>
@ -17,6 +17,7 @@
<year>2008</year>
<year>2009</year>
<year>2010</year>
<year>2011</year>
<holder>MPlayer team</holder>
</copyright>
<legalnotice>
@ -45,116 +46,17 @@ If you are a first-time installer: be sure to read everything from here to
the end of the Installation section, and follow the links you will find. If
you have any other questions, return to the <link linkend="toc">Table of
Contents</link> and search for the topic, read the <xref linkend="faq"/>,
or try grepping through the files. Most questions should be answered somewhere
here and the rest has probably already been asked on our
<ulink url="http://www.mplayerhq.hu/design7/mailing_lists.html">mailing lists</ulink>.
Check the
<ulink url="https://lists.mplayerhq.hu/mailman/listinfo">archives</ulink>, there
is a lot of valuable information to be found there.
or try grepping through the files.
</para>
</preface>
<chapter id="intro">
<title>Introduction</title>
OUTDATED CONTENT REMOVED
<para>
<application>MPlayer</application> is a movie player for Linux (runs on
many other Unices, and non-x86 CPUs, see <xref linkend="ports"/>).
It plays most MPEG, VOB, AVI, Ogg/OGM, VIVO, ASF/WMA/WMV, QT/MOV/MP4, FLI, RM,
NuppelVideo, yuv4mpeg, FILM, RoQ, PVA, Matroska files, supported by
many native, XAnim, RealPlayer, and Win32 DLL codecs. You can watch
Video CD, SVCD, DVD, 3ivx, RealMedia, Sorenson, Theora,
and MPEG-4 (DivX) movies, too. Another big
feature of <application>MPlayer</application> is the wide range of
supported output drivers. It works with X11, Xv, DGA, OpenGL, SVGAlib,
fbdev, AAlib, libcaca, DirectFB, but you can use GGI and SDL (and this way all
their drivers) and some low level card-specific drivers (for Matrox, 3Dfx and
Radeon, Mach64, Permedia3) too! Most of them support software or hardware
scaling, so you can enjoy movies in fullscreen.
<application>MPlayer</application> supports displaying through some
hardware MPEG decoder boards, such as the <link linkend="dvb">DVB</link> and
<link linkend="dxr3">DXR3/Hollywood+</link>. And what about the nice big
antialiased shaded subtitles (14 supported types)
with European/ISO 8859-1,2 (Hungarian, English, Czech, etc), Cyrillic, Korean
fonts, and the onscreen display (OSD)?
</para>
<para>
The player is rock solid playing damaged MPEG files (useful for some VCDs),
and it plays bad AVI files which are unplayable with the famous
<application>Windows Media Player</application>.
Even AVI files without index chunk are playable, and you can
temporarily rebuild their indexes with the <option>-idx</option> option, or
permanently with <application>MEncoder</application>, thus enabling
seeking! As you see, stability and quality are the most important things,
but the speed is also amazing. There is also a powerful filter system for
video and audio manipulation.
</para>
<para>
<application>MEncoder</application> (<application>MPlayer</application>'s Movie
Encoder) is a simple movie encoder, designed to encode
<application>MPlayer</application>-playable movies
AVI/ASF/OGG/DVD/VCD/VOB/MPG/MOV/VIV/FLI/RM/NUV/NET/PVA
to other <application>MPlayer</application>-playable formats (see below).
It can encode with various codecs, like MPEG-4 (DivX4)
(one or two passes), <systemitem class="library">libavcodec</systemitem>,
PCM/MP3/VBR MP3 audio.
</para>
<itemizedlist>
<title><application>MEncoder</application> features</title>
<listitem><para>
Encoding from the wide range of file formats and decoders of
<application>MPlayer</application>
</para></listitem>
<listitem><para>
Encoding to all the codecs of FFmpeg's
<systemitem class="library">libavcodec</systemitem>
</para></listitem>
<listitem><para>
Video encoding from V4L compatible TV tuners
</para></listitem>
<listitem><para>
Encoding/multiplexing to interleaved AVI files with proper index
</para></listitem>
<listitem><para>
Creating files from external audio stream
</para></listitem>
<listitem><para>
1, 2 or 3 pass encoding
</para></listitem>
<listitem><para>
VBR MP3 audio
</para></listitem>
<listitem><para>
PCM audio
</para></listitem>
<listitem><para>
Stream copying
</para></listitem>
<listitem><para>
Input A/V synchronizing (pts-based, can be disabled with
<option>-mc 0</option> option)
</para></listitem>
<listitem><para>
fps correction with <option>-ofps</option> option (useful when encoding
30000/1001 fps VOB to 24000/1001 fps AVI)
</para></listitem>
<listitem><para>
Using our very powerful filter system (crop, expand, flip, postprocess,
rotate, scale, RGB/YUV conversion)
</para></listitem>
<listitem><para>
Can encode DVD/VOBsub and text subtitles
into the output file
</para></listitem>
<listitem><para>
Can rip DVD subtitles to VOBsub format
</para></listitem>
</itemizedlist>
<!-- FIXME: the license should be in bookinfo -->
<para>
<application>MPlayer</application> and <application>MEncoder</application>

File diff suppressed because it is too large Load Diff

View File

@ -13,8 +13,7 @@
How do I create a proper patch for <application>MPlayer</application>?
</para></question>
<answer><para>
We made a <ulink url="../../tech/patches.txt">short document</ulink>
describing all the necessary details. Please follow the instructions.
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -23,10 +22,7 @@ describing all the necessary details. Please follow the instructions.
How do I translate <application>MPlayer</application> to a new language?
</para></question>
<answer><para>
Read the <ulink url="../../tech/translations.txt">translation HOWTO</ulink>,
it should explain everything. You can get further help on the
<ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-translations">MPlayer-translations</ulink>
mailing list.
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -35,9 +31,7 @@ mailing list.
How can I support <application>MPlayer</application> development?
</para></question>
<answer><para>
We are more than happy to accept your hardware and software
<ulink url="http://www.mplayerhq.hu/donations.html">donations</ulink>.
They help us in continuously improving <application>MPlayer</application>.
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -46,14 +40,7 @@ They help us in continuously improving <application>MPlayer</application>.
How can I become an <application>MPlayer</application> developer?
</para></question>
<answer><para>
We always welcome coders and documenters. Read the
<ulink url="../../tech/">technical documentation</ulink>
to get a first grasp. Then you should subscribe to the
<ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-dev-eng">MPlayer-dev-eng</ulink>
mailing list and start coding. If you want to help out with the documentation,
join the
<ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-docs">MPlayer-docs</ulink>
mailing list.
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -99,8 +86,7 @@ stable, or upgrade frequently.
Are there binary (RPM/Debian) packages of <application>MPlayer</application>?
</para></question>
<answer><para>
See the <link linkend="debian">Debian</link> and <link linkend="rpm">RPM</link>
section for details.
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -109,31 +95,7 @@ section for details.
How can I build a 32 bit <application>MPlayer</application> on a 64 bit Athlon?
</para></question>
<answer><para>
Try the following configure options:
<screen>
./configure --target=i386-linux --cc="gcc -m32" --as="as --32" --with-extralibdir=/usr/lib
</screen>
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
Configure ends with this text, and <application>MPlayer</application> won't compile!
<screen>Your gcc does not support even i386 for '-march' and '-mcpu'</screen>
</para></question>
<answer><para>
Your gcc isn't installed correctly, check the <filename>config.log</filename>
file for details.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
I have a Matrox G200/G400/G450/G550, how do I compile/use the
<systemitem>mga_vid</systemitem> driver?
</para></question>
<answer><para>
Read the <link linkend="mga_vid">mga_vid</link> section.
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -153,52 +115,6 @@ It's called <filename>XFree86-devel*</filename> under Red Hat,
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
Building on Mac OS 10.3 leads to several link errors.
</para></question>
<answer>
<para>
The link error you're experiencing most likely looks like this:
<screen>
ld: Undefined symbols:
_LLCStyleInfoCheckForOpenTypeTables referenced from QuartzCore expected to be defined in ApplicationServices
_LLCStyleInfoGetUserRunFeatures referenced from QuartzCore expected to be defined in ApplicationServices
</screen>
This problem is the result of Apple developers using 10.4 to compile
their software and distributing the binaries to 10.3 users via
Software Update.
The undefined symbols are present in Mac OS 10.4,
but not 10.3.
One solution can be to downgrade to QuickTime 7.0.1.
Here is a better solution.
</para>
<para>
Get an
<ulink url="http://rapidshare.de/files/20281171/CompatFrameworks.tgz.html">older copy of the frameworks</ulink>.
This will give you a compressed file that contains the QuickTime
7.0.1 Framework and a 10.3.9 QuartzCore Framework.
</para>
<para>
Uncompress the files somewhere that is not in your System folder.
(i.e. do not install these frameworks into your
<filename class="directory">/System/Library/Frameworks</filename>!
Using this older copy is only meant to get around link errors!)
<screen>gunzip &lt; CompatFrameworks.tgz | tar xvf -</screen>
In config.mak, you should append
<systemitem>-F/path/to/where/you/extracted</systemitem>
to the <systemitem>OPTFLAGS</systemitem> variable.
If you use <application>X-Code</application>, you can just select these
frameworks instead of the system ones.
</para>
<para>
The resulting <application>MPlayer</application> binary will actually
use the framework that is installed on your system via dynamic links that
are resolved at run-time.
(You can verify this using <systemitem>otool -l</systemitem>).
</para>
</answer>
</qandaentry>
</qandadiv>
<!-- ********** -->
@ -211,9 +127,7 @@ are resolved at run-time.
Are there any mailing lists on <application>MPlayer</application>?
</para></question>
<answer><para>
Yes. Look at the
<ulink url="http://www.mplayerhq.hu/design7/mailing_lists.html">mailing lists section</ulink>
of our homepage.
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -223,31 +137,7 @@ I've found a nasty bug when I tried to play my favorite video!
Who should I inform?
</para></question>
<answer><para>
Please read the <link linkend="bugreports">bug reporting guidelines</link>
and follow the instructions.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
I get a core dump when trying to dump streams, what's wrong?
</para></question>
<answer><para>
Don't panic. Make sure you know where your towel is.</para>
<para>
Seriously, notice the smiley and start looking for files that end in
<filename>.dump</filename>.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
When I start playing, I get this message but everything seems fine:
<screen>Linux RTC init: ioctl (rtc_pie_on): Permission denied</screen>
</para></question>
<answer><para>
You need a specially set up kernel to use the RTC timing code.
For details see the <link linkend="rtc">RTC</link> section of the documentation.
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -352,8 +242,7 @@ There are error messages about file not found
<filename>/usr/local/lib/codecs/</filename> ...
</para></question>
<answer><para>
Download and install the binary codecs from our
<ulink url="http://www.mplayerhq.hu/design7/dload.html">download page</ulink>.
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -364,21 +253,8 @@ use for a particular file, e.g. <filename>movie.avi</filename>?
</para></question>
<answer><para>
Create a file named <filename>movie.avi.conf</filename> with the file-specific
options in it and put it in <filename class="directory">~/.mplayer</filename>
or in the same directory as the file.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
Subtitles are very nice, the most beautiful I've ever seen, but they
slow down playing! I know it's unlikely ...
</para></question>
<answer><para>
After running <filename>./configure</filename>,
edit <filename>config.h</filename> and replace
<systemitem>#undef FAST_OSD</systemitem> with
<systemitem>#define FAST_OSD</systemitem>. Then recompile.
options in it and put it in <filename class="directory">~/.mplayer</filename>.
Also see the manpage about <option>-use-filedir-conf</option>.
</para></answer>
</qandaentry>
@ -389,7 +265,7 @@ How can I run <application>MPlayer</application> in the background?
<answer><para>
Use:
<screen>
mplayer <replaceable>options</replaceable> <replaceable>filename</replaceable> &lt; /dev/null &amp;
OUTDATED CONTENT REMOVED
</screen>
</para></answer>
</qandaentry>
@ -424,10 +300,7 @@ system, you should remove it now.
How can I get subtitles to appear on the black margins around a movie?
</para></question>
<answer><para>
Use the <systemitem>expand</systemitem> video filter to increase the
area onto which the movie is rendered vertically and place the movie
at the top border, for example:
<screen>mplayer -vf expand=0:-100:0:0 -slang de dvd://1</screen>
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -451,15 +324,6 @@ mplayer -vo null -ao null -frames 0 -v <replaceable>filename</replaceable> | gre
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
I'm trying to play a random stream off the internet but it fails.
</para></question>
<answer><para>
Try playing the stream with the <option>-playlist</option> option.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
I downloaded a movie off a P2P network and it doesn't work!
@ -476,68 +340,7 @@ a friend, and he says it works, try comparing
I'm having trouble getting my subtitles to display, help!!
</para></question>
<answer><para>
Make sure you have installed fonts properly. Run through the steps in the
<link linkend="fonts-osd">Fonts and OSD</link> part of the installation
section again. If you are using TrueType fonts, verify that you have the
<systemitem class="library">FreeType</systemitem> library installed.
Other things include checking your subtitles in a text editor or with other
players. Also try converting them to another format.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
Why doesn't <application>MPlayer</application> work on Fedora Core?
</para></question>
<answer><para>
There is a bad interaction on Fedora between exec-shield,
prelink, and any applications which use Windows DLLs
(such as <application>MPlayer</application>).
</para>
<para>
The problem is that exec-shield randomizes the load addresses of all the
system libraries. This randomization happens at prelink time (once every
two weeks).
</para>
<para>
When <application>MPlayer</application> tries to load a Windows DLL it
wants to put it at a specific address (0x400000). If an important system
library happens to be there already, <application>MPlayer</application>
will crash.
(A typical symptom would be a segmentation fault when trying
to play Windows Media 9 files.)
</para>
<para>
If you run into this problem you have two options:
<itemizedlist>
<listitem><para>
Wait two weeks. It might start working again.
</para></listitem>
<listitem><para>
Relink all the binaries on the system with different
prelink options. Here are step by step instructions:
</para>
<procedure>
<step><para>
Edit <filename>/etc/syconfig/prelink</filename> and change
<programlisting>PRELINK_OPTS=-mR</programlisting> to
<programlisting>PRELINK_OPTS="-mR --no-exec-shield"</programlisting>
</para></step>
<step><para>
<command>touch /var/lib/misc/prelink.force</command>
</para></step>
<step><para>
<command>/etc/cron.daily/prelink</command>
(This relinks all the applications, and it takes quite a while.)
</para></step>
<step><para>
<command>execstack -s <replaceable>/path/to/</replaceable>mplayer</command>
(This turns off exec-shield for the
<application>MPlayer</application> binary.)
</para></step>
</procedure>
</listitem>
</itemizedlist>
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -549,7 +352,7 @@ If you run into this problem you have two options:
<answer><para>
Don't use <application>MPlayer</application> on a CPU different from the one
it was compiled on or recompile with runtime CPU detection
(<command>./configure --enable-runtime-cpudetection</command>).
OUTDATED CONTENT REMOVED
</para></answer>
</qandaentry>
@ -565,35 +368,6 @@ default YV12 (see the <link linkend="tv-input">TV</link> section).
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
I get very strange percentage values (way too big)
while playing files on my notebook.
</para></question>
<answer><para>
It's an effect of the power management / power saving system of your notebook
(BIOS, not kernel). Plug the external power connector in
<emphasis role="bold">before</emphasis> you power on your notebook. You can
also try whether
<ulink url="http://www.kernel.org/pub/linux/utils/kernel/cpufreq/cpufreq.html">cpufreq</ulink>
(a SpeedStep interface for Linux) helps you.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
The audio/video gets totally out of sync when I run
<application>MPlayer</application> as
<systemitem class="username">root</systemitem> on my notebook.
It works normal when i run it as a user.
</para></question>
<answer><para>
This is again a power management effect (see above). Plug the external power
connector in <emphasis role="bold">before</emphasis> you power on your notebook
or make sure you do not use the <option>-rtc</option> option.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
While playing a movie it suddenly gets jerky and I get the following message:
@ -660,18 +434,6 @@ Also try experimenting with the <option>-fstype</option> option.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
Audio goes out of sync playing an AVI file.
</para></question>
<answer><para>
Try the <option>-bps</option> or <option>-nobps</option> option. If it does not
improve, read the
<link linkend="bugreports">bug reporting guidelines</link>
and upload the file to FTP.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I use <application>dmix</application> with
@ -733,41 +495,6 @@ try to play a file which has 22050Hz audio. Try the
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
When I play this movie I get video-audio desync and/or
<application>MPlayer</application> crashes with the following message:
<screen>
Too many (945 in 8390980 bytes) video packets in the buffer!
</screen>
</para></question>
<answer><para>
This can have multiple reasons.
<itemizedlist>
<listitem><para>
Your CPU <emphasis>and/or</emphasis> video card <emphasis>and/or</emphasis>
bus is too slow. <application>MPlayer</application> displays a message if
this is the case (and the dropped frames counter goes up fast).
</para></listitem>
<listitem><para>
If it is an AVI, maybe it has bad interleaving, try the
<option>-ni</option> option to work around this.
Or it may have a bad header, in this case <option>-nobps</option>
and/or <option>-mc 0</option> can help.
</para></listitem>
<listitem><para>
Many FLV files will only play correctly with <option>-correct-pts</option>.
Unfortunately <application>MEncoder</application> does not have this option,
but you can try setting <option>-fps</option> to the correct value manually
if you know it.
</para></listitem>
<listitem><para>
Your sound driver is buggy.
</para></listitem>
</itemizedlist>
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I get rid of A/V desynchronization
@ -870,18 +597,6 @@ mplayer dvd://1 -dvd-device <replaceable>/path/to/directory</replaceable>
<qandadiv id="faq-features">
<title>Feature requests</title>
<qandaentry>
<question><para>
If <application>MPlayer</application> is paused and I try to seek or press any
key at all, <application>MPlayer</application> ceases to be paused.
I would like to be able to seek in the paused movie.
</para></question>
<answer><para>
This is very tricky to implement without losing A/V synchronization.
All attempts have failed so far, but patches are welcome.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
I'd like to seek +/- 1 frame instead of 10 seconds.
@ -890,7 +605,8 @@ I'd like to seek +/- 1 frame instead of 10 seconds.
You can step forward one frame by pressing <keycap>.</keycap>.
If the movie was not paused it will be paused afterwards
(see the man page for details).
Stepping backwards is unlikely to be implemented anytime soon.
Stepping backwards is not currently implemented, but note that you can make
small seeks using the <option>-hr-seek</option> functionality.
</para></answer>
</qandaentry>
</qandadiv>
@ -900,332 +616,9 @@ Stepping backwards is unlikely to be implemented anytime soon.
<qandadiv id="faq-encoding">
<title>Encoding</title>
<qandaentry>
<question><para>
How can I encode?
</para></question>
<answer><para>
Read the <link linkend="mencoder"><application>MEncoder</application></link>
section.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I dump a full DVD title into a file?
</para></question>
<answer><para>
Once you have selected your title, and made sure it plays fine with
<application>MPlayer</application>, use the option <option>-dumpstream</option>.
For example:
<screen>
mplayer dvd://5 -dumpstream -dumpfile <replaceable>dvd_dump.vob</replaceable>
</screen>
will dump the 5th title of the DVD into the file
<replaceable>dvd_dump.vob</replaceable>
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I create (S)VCDs automatically?
</para></question>
<answer><para>
Try the <filename>mencvcd.sh</filename> script from the
<filename class="directory">TOOLS</filename> subdirectory.
With it you can encode DVDs or other movies to VCD or SVCD format
and even burn them directly to CD.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I create (S)VCDs?
</para></question>
<answer><para>
Newer versions of <application>MEncoder</application> can directly
generate MPEG-2 files that can be used as a base to create a VCD or SVCD and
are likely to be playable out of the box on all platforms (for example,
to share a video from a digital camcorder with your computer-illiterate
friends).
Please read
<link linkend="menc-feat-vcd-dvd">Using MEncoder to create VCD/SVCD/DVD-compliant files</link>
for more details.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I join two video files?
</para></question>
<answer><para>
MPEG files can be concatenated into a single file with luck.
For AVI files, you can use <application>MEncoder</application>'s
multiple file support like this:
<screen>
mencoder -ovc copy -oac copy -o <replaceable>out.avi</replaceable> <replaceable>file1.avi</replaceable> <replaceable>file2.avi</replaceable>
</screen>
This will only work if the files are of the same resolution
and use the same codec.
You can also try
<ulink url="http://fixounet.free.fr/avidemux/">avidemux</ulink> and
<application>avimerge</application> (part of the
<ulink url="http://www.transcoding.org/">transcode</ulink>
tool set).
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I fix AVI files with a broken index or bad interleaving?
</para></question>
<answer><para>
To avoid having to use <option>-idx</option> to be able to seek in
AVI files with a broken index or <option>-ni</option> to play AVI
files with bad interleaving, use the command
<screen>
mencoder <replaceable>input.avi</replaceable> -idx -ovc copy -oac copy -o <replaceable>output.avi</replaceable>
</screen>
to copy the video and audio streams into a new AVI file while
regenerating the index and correctly interleaving the data.
Of course this cannot fix possible bugs in the video and/or audio streams.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I fix the aspect ratio of an AVI file?
</para></question>
<answer><para>
You can do such a thing thanks to <application>MEncoder</application>'s
<option>-force-avi-aspect</option> option, which overrides the aspect
stored in the AVI OpenDML vprp header option. For example:
<screen>
mencoder <replaceable>input.avi</replaceable> -ovc copy -oac copy -o <replaceable>output.avi</replaceable> -force-avi-aspect 4/3
</screen>
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I backup and encode a VOB file with a broken beginning?
</para></question>
<answer><para>
The main problem when you want to encode a VOB file which is corrupted
<footnote id='fn-corrupted-files-or-copy-protection'><para>
To some extent, some forms of copy protection used in DVDs can be
assumed to be content corruption.
</para></footnote>
is that it will be hard to get an encode with perfect A/V sync.
One workaround is to just shave off the corrupted part and encode just the
clean part.
First you need to find where the clean part starts:
<screen>
mplayer <replaceable>input.vob</replaceable> -sb <replaceable>nb_of_bytes_to_skip</replaceable>
</screen>
Then you can create a new file which contains just the clean part:
<screen>
dd if=<replaceable>input.vob</replaceable> of=<replaceable>output_cut.vob</replaceable> skip=1 ibs=<replaceable>nb_of_bytes_to_skip</replaceable>
</screen>
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
I can't encode DVD subtitles into the AVI!
</para></question>
<answer><para>
You have to properly specify the <option>-sid</option> option.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I encode only selected chapters from a DVD?
</para></question>
<answer><para>
Use the <option>-chapter</option> option correctly,
like: <option>-chapter 5-7</option>.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
I'm trying to work with 2GB+ files on a VFAT file system. Does it work?
</para></question>
<answer><para>
No, VFAT doesn't support 2GB+ files.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
What is the meaning of the numbers on the status line
during the encoding process?
</para></question>
<answer><para>
Example:
<screen>
Pos: 264.5s 6612f ( 2%) 7.12fps Trem: 576min 2856mb A-V:0.065 [2126:192]
</screen>
<variablelist>
<varlistentry>
<term><systemitem>Pos: 264.5s</systemitem></term>
<listitem><para>time position in the encoded stream</para></listitem>
</varlistentry>
<varlistentry>
<term><systemitem>6612f</systemitem></term>
<listitem><para>number of video frames encoded</para></listitem>
</varlistentry>
<varlistentry>
<term><systemitem>( 2%)</systemitem></term>
<listitem><para>portion of the input stream encoded</para></listitem>
</varlistentry>
<varlistentry>
<term><systemitem>7.12fps</systemitem></term>
<listitem><para>encoding speed</para></listitem>
</varlistentry>
<varlistentry>
<term><systemitem>Trem: 576min</systemitem></term>
<listitem><para>estimated remaining encoding time</para></listitem>
</varlistentry>
<varlistentry>
<term><systemitem>2856mb</systemitem></term>
<listitem><para>estimated size of the final encode</para></listitem>
</varlistentry>
<varlistentry>
<term><systemitem>A-V:0.065</systemitem></term>
<listitem><para>current delay between audio and video streams</para></listitem>
</varlistentry>
<varlistentry>
<term><systemitem>[2126:192]</systemitem></term>
<listitem><para>
average video bitrate (in kb/s) and average audio bitrate (in kb/s)
</para></listitem>
</varlistentry>
</variablelist>
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
Why is the recommended bitrate printed by <application>MEncoder</application>
negative?
</para></question>
<answer><para>
Because the bitrate you encoded the audio with is too large to fit the
movie on any CD. Check if you have libmp3lame installed properly.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
I can't encode an ASF file to AVI/MPEG-4 (DivX) because it uses 1000 fps.
</para></question>
<answer><para>
Since ASF uses variable framerate but AVI uses a fixed one, you
have to set it by hand with the <option>-ofps</option> option.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I put subtitles in the output file?
</para></question>
<answer><para>
Just pass the <option>-sub &lt;filename&gt;</option> (or <option>-sid</option>,
respectively) option to <application>MEncoder</application>.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How do I encode only sound from a music video?
</para></question>
<answer><para>
It's not possible directly, but you can try this (note the
<emphasis role="bold">&amp;</emphasis> at the end of
<command>mplayer</command> command):
<screen>
mkfifo <replaceable>encode</replaceable>
mplayer -ao pcm -aofile <replaceable>encode</replaceable> dvd://1 &amp;
lame <replaceable>your_opts</replaceable> <replaceable>encode</replaceable> <replaceable>music.mp3</replaceable>
rm <replaceable>encode</replaceable>
</screen>
This allows you to use any encoder, not only <application>LAME</application>,
just replace <command>lame</command> with your favorite audio encoder in the
above command.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
Why do third-party players fail to play MPEG-4 movies encoded by
<application>MEncoder</application> versions later than 1.0pre7?
</para></question>
<answer><para>
<systemitem class="library">libavcodec</systemitem>, the native MPEG-4
encoding library usually shipped with <application>MEncoder</application>,
used to set the FourCC to 'DIVX' when encoding MPEG-4 videos
(the FourCC is an AVI tag to identify the software used to encode and
the intended software to use for decoding the video).
This led many people to think that
<systemitem class="library">libavcodec</systemitem>
was a DivX encoding library, when in fact it is a completely different
MPEG-4 encoding library which implements the MPEG-4 standard much
better than DivX does.
Therefore, the new default FourCC used by
<systemitem class="library">libavcodec</systemitem> is 'FMP4', but you
may override this behavior using <application>MEncoder</application>'s
<option>-ffourcc</option> option.
You may also change the FourCC of existing files in the same way:
<screen>
mencoder <replaceable>input.avi</replaceable> -o <replaceable>output.avi</replaceable> -ffourcc XVID
</screen>
Note that this will set the FourCC to XVID rather than DIVX.
This is recommended as DIVX FourCC means DivX4, which is a very basic
MPEG-4 codec, whereas DX50 and XVID both mean full MPEG-4 (ASP).
Therefore, if you change the FourCC to DIVX, some bad software or
hardware players may choke on some advanced features that
<systemitem class="library">libavcodec</systemitem> supports, but DivX
doesn't; on the other hand <systemitem class="library">Xvid</systemitem>
is closer to <systemitem class="library">libavcodec</systemitem> in
terms of functionality, and is supported by all decent players.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I encode an audio only file?
</para></question>
<answer><para>
Use <filename>aconvert.sh</filename> from the
<filename class="directory">TOOLS</filename>
subdirectory in the MPlayer source tree.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
How can I play subtitles embedded in AVI?
</para></question>
<answer><para>
Use <filename>avisubdump.c</filename> from the
<filename class="directory">TOOLS</filename> subdirectory or read
<ulink url="http://xlife.zuavra.net/curse/0012/">this document about extracting/demultiplexing subtitles embedded in OpenDML AVI files</ulink>.
</para></answer>
</qandaentry>
<qandaentry>
<question><para>
MEncoder won't...
</para></question>
<answer><para>
Have a look at the <filename class="directory">TOOLS</filename>
subdirectory for a collection of random scripts and hacks.
<filename>TOOLS/README</filename> contains documentation.
</para></answer>
</qandaentry>
<para>
OUTDATED CONTENT REMOVED
</para>
</qandadiv>
</qandaset>

View File

@ -24,77 +24,9 @@ answers.
<sect1 id="softreq">
<title>Software requirements</title>
<itemizedlist>
<listitem><para>
<emphasis role="bold">POSIX system</emphasis> - You need a POSIX-compatible
shell and POSIX-compatible system tools like grep, sed, awk, etc. in your
path.
</para></listitem>
<listitem><para>
<emphasis role="bold">GNU make</emphasis> 3.81 or later
</para></listitem>
<listitem><para>
<emphasis role="bold">binutils</emphasis> - GNU binutils 2.11 or later
is known to work.
</para></listitem>
<listitem><para>
<emphasis role="bold">compiler</emphasis> - We mostly use gcc, the
recommended versions on x86 are 2.95 and 3.4+. On PowerPC, use 4.x+.
icc 10.1+ is also known to work.
</para></listitem>
<listitem><para>
<emphasis role="bold">Xorg/XFree86</emphasis> - recommended version is
4.3 or later. Make sure the
<emphasis role="bold">development packages</emphasis> are installed,
too, otherwise it won't work.
You don't absolutely need X, some video output drivers work without it.
</para></listitem>
<listitem><para>
<emphasis role="bold">FreeType</emphasis> - 2.0.9 or later is required
for the OSD and subtitles
</para></listitem>
<listitem><para>
<emphasis role="bold">ALSA</emphasis> - optional, for ALSA audio output
support. At least 0.9.0rc4 is required.
</para></listitem>
<listitem><para>
<emphasis role="bold">libjpeg</emphasis> -
required for the optional JPEG video output driver
</para></listitem>
<listitem><para>
<emphasis role="bold">libpng</emphasis> -
required for the optional PNG video output driver
</para></listitem>
<listitem><para>
<emphasis role="bold">directfb</emphasis> - optional, 0.9.22 or later
required for the directfb/dfbmga video output drivers
</para></listitem>
<listitem><para>
<emphasis role="bold">lame</emphasis> - 3.90 or later is recommended,
necessary for encoding MP3 audio with <application>MEncoder</application>.
</para></listitem>
<listitem><para>
<emphasis role="bold">zlib</emphasis> - recommended, many codecs use it.
</para></listitem>
<listitem><para>
<emphasis role="bold"><ulink url="http://www.live555.com/mplayer/">LIVE555 Streaming Media</ulink></emphasis>
- optional, needed for some RTSP/RTP streams
</para></listitem>
<listitem><para>
<emphasis role="bold">cdparanoia</emphasis> - optional, for CDDA support
</para></listitem>
<listitem><para>
<emphasis role="bold">libxmms</emphasis> - optional, for XMMS input plugin
support. At least 1.2.7 is required.
</para></listitem>
<listitem><para>
<emphasis role="bold">libsmb</emphasis> - optional, for SMB networking support
</para></listitem>
<listitem><para>
<emphasis role="bold"><ulink url="http://www.underbit.com/products/mad/">libmad</ulink></emphasis>
- optional, for fast integer-only MP3 decoding on FPU-less platforms
</para></listitem>
</itemizedlist>
<para>
OUTDATED CONTENT REMOVED
</para>
</sect1>
@ -104,71 +36,8 @@ answers.
<sect1 id="features">
<title>Features</title>
<itemizedlist>
<listitem><para>
If you want to install <application>MEncoder</application> (our great
all-purpose encoder), see the
<link linkend="mencoder"><application>MEncoder</application></link> section.
</para></listitem>
<listitem><para>
If you have a V4L compatible <emphasis role="bold">TV tuner</emphasis> card,
and wish to watch/grab and encode movies with
<application>MPlayer</application>,
read the <link linkend="tv-input">TV input</link> section.
</para></listitem>
<listitem><para>
If you have a V4L compatible <emphasis role="bold">radio tuner</emphasis>
card, and wish to listen and capture sound with
<application>MPlayer</application>,
read the <link linkend="radio">radio</link> section.
</para></listitem>
<listitem><para>
There is a neat <emphasis role="bold">OSD Menu</emphasis> support ready to be
used. Check the <link linkend="subosd">OSD menu</link> section.
</para></listitem>
</itemizedlist>
<para>
Then build <application>MPlayer</application>:
<screen>
./configure
make
make install
</screen>
</para>
<para>
At this point, <application>MPlayer</application> is ready to use.
Check if you have a <filename>codecs.conf</filename> file in your home
directory at (<filename>~/.mplayer/codecs.conf</filename>) left from old
<application>MPlayer</application> versions. If you find one, remove it.
</para>
<para>
Debian users can build a .deb package for themselves, it's very simple.
Just exec
<screen>fakeroot debian/rules binary</screen>
in <application>MPlayer</application>'s root directory. See
<link linkend="debian">Debian packaging</link> for detailed instructions.
</para>
<para>
<emphasis role="bold">Always browse the output of</emphasis>
<filename>./configure</filename>, and the
<filename>config.log</filename> file, they contain information about
what will be built, and what will not. You may also want to view
<filename>config.h</filename> and <filename>config.mak</filename> files.
If you have some libraries installed, but not detected by
<filename>./configure</filename>, then check if you also have the proper
header files (usually the -dev packages) and their version matches. The
<filename>config.log</filename> file usually tells you what is missing.
</para>
<para>
Though not mandatory, the fonts should be installed in order to gain OSD,
and subtitle functionality. The recommended method is installing a TTF
font file and telling <application>MPlayer</application> to use it.
See the <link linkend="subosd">Subtitles and OSD</link> section for details.
OUTDATED CONTENT REMOVED
</para>
</sect1>
@ -195,136 +64,9 @@ frontends page</ulink> for a list of existing GUIs.
<title>Fonts and OSD</title>
<para>
You need to tell <application>MPlayer</application> which font to use to
enjoy OSD and subtitles. Any TrueType font or special bitmap fonts will
work. However, TrueType fonts are recommended as they look far better,
can be properly scaled to the movie size and cope better with different
encodings.
OUTDATED CONTENT REMOVED
</para>
<!-- ********** -->
<sect2 id="truetype-fonts">
<title>TrueType fonts</title>
<para>
There are two ways to get TrueType fonts to work. The first is to pass
the <option>-font</option> option to specify a TrueType font file on
the command line. This option will be a good candidate to put in your
configuration file (see the manual page for details).
The second is to create a symlink called <filename>subfont.ttf</filename>
to the font file of your choice. Either
<screen>
ln -s <replaceable>/path/to/sample_font.ttf</replaceable> ~/.mplayer/subfont.ttf
</screen>
for each user individually or a system-wide one:
<screen>
ln -s <replaceable>/path/to/sample_font.ttf</replaceable> $PREFIX/share/mplayer/subfont.ttf
</screen>
</para>
<para>
If <application>MPlayer</application> was compiled with
<systemitem class="library">fontconfig</systemitem> support, the above methods
won't work, instead <option>-font</option> expects a
<systemitem class="library">fontconfig</systemitem> font name
and defaults to the sans-serif font. Example:
<screen>
mplayer -font <replaceable>'Bitstream Vera Sans'</replaceable> <replaceable>anime.mkv</replaceable>
</screen>
</para>
<para>
To get a list of fonts known to
<systemitem class="library">fontconfig</systemitem>,
use <command>fc-list</command>.
</para>
</sect2>
<!-- ********** -->
<sect2 id="bitmap-fonts">
<title>bitmap fonts</title>
<para>
If for some reason you wish or need to employ bitmap fonts, download a set
from our homepage. You can choose between various
<ulink url="http://www.mplayerhq.hu/MPlayer/releases/fonts/">ISO fonts</ulink>
and some sets of fonts
<ulink url="http://www.mplayerhq.hu/MPlayer/contrib/fonts/">contributed by users</ulink>
in various encodings.
</para>
<para>
Uncompress the file you downloaded to
<filename class="directory">~/.mplayer</filename> or
<filename class="directory">$PREFIX/share/mplayer</filename>.
Then rename or symlink one of the extracted directories to
<filename class="directory">font</filename>, for example:
<screen>
ln -s <replaceable>~/.mplayer/arial-24</replaceable> ~/.mplayer/font
</screen>
<screen>
ln -s <replaceable>$PREFIX/share/mplayer/arial-24</replaceable> $PREFIX/share/mplayer/font
</screen>
</para>
<para>
Fonts should have an appropriate <filename>font.desc</filename> file
which maps Unicode font positions to the actual code page of the
subtitle text. Another solution is to have UTF-8-encoded subtitles
and use the <option>-utf8</option> option or give the subtitles
file the same name as your video file with a <filename>.utf</filename>
extension and have it in the same directory as the video file.
</para>
</sect2>
<!-- ********** -->
<sect2 id="osdmenu">
<title>OSD menu</title>
<para>
<application>MPlayer</application> has a completely user-definable
OSD Menu interface.
</para>
<note><para>
the Preferences menu is currently UNIMPLEMENTED!
</para></note>
<orderedlist>
<title>Installation</title>
<listitem><para>
compile <application>MPlayer</application> by passing the
<option>--enable-menu</option> to <filename>./configure</filename>
</para></listitem>
<listitem><para>
make sure you have an OSD font installed
</para></listitem>
<listitem><para>
copy <filename>etc/menu.conf</filename> to your
<filename class="directory">.mplayer</filename> directory
</para></listitem>
<listitem><para>
copy <filename>etc/input.conf</filename> to your
<filename class="directory">.mplayer</filename> directory, or to the
system-wide <application>MPlayer</application> config dir (default:
<filename class="directory">/usr/local/etc/mplayer</filename>)
</para></listitem>
<listitem><para>
check and edit <filename>input.conf</filename> to enable menu movement keys
(it is described there).
</para></listitem>
<listitem><para>
start <application>MPlayer</application> by the following example:
<screen>mplayer -menu <replaceable>file.avi</replaceable></screen>
</para></listitem>
<listitem><para>
push any menu key you defined
</para></listitem>
</orderedlist>
</sect2>
</sect1>
@ -334,111 +76,9 @@ the Preferences menu is currently UNIMPLEMENTED!
<sect1 id="codec-installation">
<title>Codec installation</title>
<!-- ********** -->
<sect2 id="xvid">
<title>Xvid</title>
<para>
<ulink url="http://www.xvid.org">Xvid</ulink> is a free software MPEG-4 ASP
compliant video codec. Note that Xvid is not necessary to decode Xvid-encoded
video. <systemitem class="library">libavcodec</systemitem> is used by
default as it offers better speed.
OUTDATED CONTENT REMOVED
</para>
<procedure>
<title>Installing <systemitem class="library">Xvid</systemitem></title>
<para>
Like most open source software, it is available in two flavors:
<ulink url="http://www.xvid.org/downloads.html">official releases</ulink>
and the CVS version.
The CVS version is usually stable enough to use, as most of the time it
features fixes for bugs that exist in releases.
Here is what to do to make <systemitem class="library">Xvid</systemitem>
CVS work with <application>MEncoder</application>:
</para>
<step><para>
<screen>cvs -z3 -d:pserver:anonymous@cvs.xvid.org:/xvid login</screen>
</para></step>
<step><para>
<screen>cvs -z3 -d:pserver:anonymous@cvs.xvid.org:/xvid co xvidcore</screen>
</para></step>
<step><para>
<screen>cd xvidcore/build/generic</screen>
</para></step>
<step><para>
<screen>./bootstrap.sh &amp;&amp; ./configure</screen>
You may have to add some options (examine the output of
<command>./configure --help</command>).
</para></step>
<step><para>
<screen>make &amp;&amp; make install</screen>
</para></step>
<step><para>
Recompile <application>MPlayer</application>.
</para></step>
</procedure>
</sect2>
<!-- ********** -->
<sect2 id="x264">
<title><systemitem class="library">x264</systemitem></title>
<para>
<ulink url="http://developers.videolan.org/x264.html"><systemitem class="library">x264</systemitem></ulink>
is a library for creating H.264 video.
<application>MPlayer</application> sources are updated whenever
an <systemitem class="library">x264</systemitem> API change
occurs, so it is always suggested to use
<application>MPlayer</application> from Subversion.
</para>
<para>
If you have a GIT client installed, the latest x264
sources can be gotten with this command:
<screen>git clone git://git.videolan.org/x264.git</screen>
Then build and install in the standard way:
<screen>./configure &amp;&amp; make &amp;&amp; make install</screen>
Now rerun <filename>./configure</filename> for
<application>MPlayer</application> to pick up
<systemitem class="library">x264</systemitem> support.
</para>
</sect2>
<!-- ********** -->
<sect2 id="amr">
<title>AMR</title>
<para>
MPlayer can use the OpenCORE AMR libraries through FFmpeg.
Download the libraries for AMR-NB and AMR-WB from the
<ulink url="http://sourceforge.net/projects/opencore-amr/">opencore-amr</ulink>
project and install them according to the instructions on that page.
</para>
</sect2>
<sect2 id="xmms">
<title>XMMS</title>
<para>
<application>MPlayer</application> can use <application>XMMS</application> input
plugins to play many file formats. There are plugins for SNES game tunes, SID
tunes (from Commodore 64), many Amiga formats, .xm, .it, VQF, Musepack, Bonk,
shorten and many others. You can find them at the
<ulink url="http://www.xmms.org/plugins.php?category=input">XMMS input plugin page</ulink>.
</para>
<para>
For this feature you need to have <application>XMMS</application> and compile
<application>MPlayer</application> with
<filename>./configure --enable-xmms</filename>.
</para>
</sect2>
</sect1>
@ -449,46 +89,7 @@ For this feature you need to have <application>XMMS</application> and compile
<title>RTC</title>
<para>
There are three timing methods in <application>MPlayer</application>.
<itemizedlist>
<listitem><para>
<emphasis role="bold">To use the old method</emphasis>, you don't have to do
anything. It uses <systemitem>usleep()</systemitem> to tune
A/V sync, with +/- 10ms accuracy. However sometimes the sync has to be
tuned even finer.
</para></listitem>
<listitem>
<para>
<emphasis role="bold">The new timer</emphasis> code uses the RTC (RealTime
Clock) for this task, because it has precise 1ms timers.
The <option>-rtc</option> option enables it,
but a properly set up kernel is required.
If you are running kernel 2.4.19pre8 or later you can adjust the maximum RTC
frequency for normal users through the <systemitem class="systemname">/proc
</systemitem> file system. Use one of the following two commands to
enable RTC for normal users:
<screen>echo 1024 &gt; /proc/sys/dev/rtc/max-user-freq</screen>
<screen>sysctl dev/rtc/max-user-freq=1024</screen>
You can make this setting permanent by adding the latter to
<filename>/etc/sysctl.conf</filename>.
</para>
<para>
You can see the new timer's efficiency in the status line.
The power management functions of some notebook BIOSes with speedstep CPUs
interact badly with RTC. Audio and video may get out of sync. Plugging the
external power connector in before you power up your notebook seems to help.
In some hardware combinations (confirmed during usage of non-DMA DVD drive
on an ALi1541 board) usage of the RTC timer causes skippy playback. It's
recommended to use the third method in these cases.
</para>
</listitem>
<listitem><para>
<emphasis role="bold">The third timer code</emphasis> is turned on with the
<option>-softsleep</option> option. It has the efficiency of the RTC, but it
doesn't use RTC. On the other hand, it requires more CPU.
</para></listitem>
</itemizedlist>
OUTDATED CONTENT REMOVED
</para>
</sect1>

View File

@ -4,776 +4,7 @@
<title>Basic usage of <application>MEncoder</application></title>
<para>
For the complete list of available <application>MEncoder</application> options
and examples, please see the man page. For a series of hands-on examples and
detailed guides on using several encoding parameters, read the
<ulink url="../../tech/encoding-tips.txt">encoding-tips</ulink> that were
collected from several mailing list threads on MPlayer-users. Search the archives
<ulink url="http://lists.mplayerhq.hu/pipermail/mencoder-users/">here</ulink>
and especially for older things also
<ulink url="http://lists.mplayerhq.hu/pipermail/mplayer-users/">here</ulink>
for a wealth of discussions about all aspects of and problems related to
encoding with <application>MEncoder</application>.
OUTDATED CONTENT REMOVED
</para>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="menc-feat-selecting-codec">
<title>Selecting codecs and container formats</title>
<para>
Audio and video codecs for encoding are selected with the
<option>-oac</option> and <option>-ovc</option> options, respectively.
Type for instance:
<screen>mencoder -ovc help</screen>
to list all video codecs supported by the version of
<application>MEncoder</application> on your machine.
The following choices are available:
</para>
<para>
Audio Codecs:
<informaltable frame="all">
<tgroup cols="2">
<thead>
<row><entry>Audio codec name</entry><entry>Description</entry></row>
</thead>
<tbody>
<row>
<entry>mp3lame</entry>
<entry>encode to VBR, ABR or CBR MP3 with LAME</entry>
</row>
<row>
<entry>lavc</entry>
<entry>use one of <link linkend="menc-feat-enc-libavcodec-audio-codecs"><systemitem class="library">libavcodec</systemitem>'s audio codecs</link></entry>
</row>
<row>
<entry>faac</entry>
<entry>FAAC AAC audio encoder</entry>
</row>
<row>
<entry>toolame</entry>
<entry>MPEG Audio Layer 2 encoder</entry>
</row>
<row>
<entry>twolame</entry>
<entry>MPEG Audio Layer 2 encoder based on tooLAME</entry>
</row>
<row>
<entry>pcm</entry>
<entry>uncompressed PCM audio</entry>
</row>
<row>
<entry>copy</entry>
<entry>do not reencode, just copy compressed frames</entry>
</row>
</tbody>
</tgroup>
</informaltable>
</para>
<para>
Video codecs:
<informaltable frame="all">
<tgroup cols="2">
<thead>
<row><entry>Video codec name</entry><entry>Description</entry></row>
</thead>
<tbody>
<row>
<entry>lavc</entry>
<entry>use one of <link linkend="menc-feat-enc-libavcodec-video-codecs"><systemitem class="library">libavcodec</systemitem>'s video codecs</link></entry>
</row>
<row>
<entry>xvid</entry>
<entry>Xvid, MPEG-4 Advanced Simple Profile (ASP) codec</entry>
</row>
<row>
<entry>x264</entry>
<entry>x264, MPEG-4 Advanced Video Coding (AVC), AKA H.264 codec</entry>
</row>
<row>
<entry>nuv</entry>
<entry>nuppel video, used by some realtime applications</entry>
</row>
<row>
<entry>raw</entry>
<entry>uncompressed video frames</entry>
</row>
<row>
<entry>copy</entry>
<entry>do not reencode, just copy compressed frames</entry>
</row>
<row>
<entry>frameno</entry>
<entry>used for 3-pass encoding (not recommended)</entry>
</row>
</tbody>
</tgroup>
</informaltable>
</para>
<para>
Output container formats are selected with the <option>-of</option>
option.
Type:
<screen>mencoder -of help</screen>
to list all containers supported by the version of
<application>MEncoder</application> on your machine.
The following choices are available:
</para>
<para>
Container formats:
<informaltable frame="all">
<tgroup cols="2">
<thead>
<row><entry>Container format name</entry><entry>Description</entry></row>
</thead>
<tbody>
<row>
<entry>lavf</entry>
<entry>one of the containers supported by
<systemitem class="library">libavformat</systemitem></entry>
</row>
<row>
<entry>avi</entry>
<entry>Audio-Video Interleaved</entry>
</row>
<row>
<entry>mpeg</entry>
<entry>MPEG-1 and MPEG-2 PS</entry>
</row>
<row>
<entry>rawvideo</entry>
<entry>raw video stream (no muxing - one video stream only)</entry>
</row>
<row>
<entry>rawaudio</entry>
<entry>raw audio stream (no muxing - one audio stream only)</entry>
</row>
</tbody>
</tgroup>
</informaltable>
The AVI container is the native container format for
<application>MEncoder</application>, which means that it's the one that
is best handled, and the one for which <application>MEncoder</application>
was designed.
As noted above, other container formats are usable, but you may
experience problems when using them.
</para>
<para>
<systemitem class="library">libavformat</systemitem> containers:
</para>
<para>
If you selected <systemitem class="library">libavformat</systemitem>
to do the muxing of the output file (by using the <option>-of lavf</option>),
the appropriate container format will be determined by the file extension
of the output file.
You may force a particular container format with
<systemitem class="library">libavformat</systemitem>'s
<option>format</option> option.
<informaltable frame="all">
<tgroup cols="2">
<thead><row>
<entry><systemitem class="library">libavformat</systemitem> container name</entry>
<entry>Description</entry>
</row></thead>
<tbody>
<row>
<entry>mpg</entry>
<entry>MPEG-1 and MPEG-2 PS</entry>
</row>
<row>
<entry>asf</entry>
<entry>Advanced Streaming Format</entry>
</row>
<row>
<entry>avi</entry>
<entry>Audio-Video Interleaved</entry>
</row>
<row>
<entry>wav</entry>
<entry>Waveform Audio</entry>
</row>
<row>
<entry>swf</entry>
<entry>Macromedia Flash</entry>
</row>
<row>
<entry>flv</entry>
<entry>Macromedia Flash video</entry>
</row>
<row>
<entry>rm</entry>
<entry>RealMedia</entry>
</row>
<row>
<entry>au</entry>
<entry>SUN AU</entry>
</row>
<row>
<entry>nut</entry>
<entry>NUT open container (experimental and not yet spec-compliant)</entry>
</row>
<row>
<entry>mov</entry>
<entry>QuickTime</entry>
</row>
<row>
<entry>mp4</entry>
<entry>MPEG-4 format</entry>
</row>
<row>
<entry>dv</entry>
<entry>Sony Digital Video container</entry>
</row>
<row>
<entry>mkv</entry>
<entry>Matroska open audio/video container</entry>
</row>
</tbody>
</tgroup>
</informaltable>
As you can see, <systemitem class="library">libavformat</systemitem>
allows <application>MEncoder</application> to mux into a considerable
variety of containers.
Unfortunately, as <application>MEncoder</application> was not designed
from the beginning to support container formats other than AVI,
your should really be paranoid about the resulting file.
Please check to be sure that the audio/video synchronization is OK
and that the file can be played correctly by players other than
<application>MPlayer</application>.
</para>
<example id="encode_to_macromedia_flash_format">
<title>encode to Macromedia Flash format</title>
<para>
Creating a Macromedia Flash video suitable for playback in a web browser
with the Macromedia Flash plugin:
<screen>
mencoder <replaceable>input.avi</replaceable> -o <replaceable>output.flv</replaceable> -of lavf \
-oac mp3lame -lameopts abr:br=56 -srate 22050 -ovc lavc \
-lavcopts vcodec=flv:vbitrate=500:mbd=2:mv0:trell:v4mv:cbp:last_pred=3
</screen>
</para>
</example>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="menc-feat-selecting-input">
<title>Selecting input file or device</title>
<para>
<application>MEncoder</application> can encode from files or directly
from a DVD or VCD disc.
Simply include the filename on the command line to encode from a file,
or <option>dvd://</option><replaceable>titlenumber</replaceable> or
<option>vcd://</option><replaceable>tracknumber</replaceable> to encode
from a DVD title or VCD track.
If you have already copied a DVD to your hard drive (you can use a tool
such as <application>dvdbackup</application>, available on most systems),
and wish to encode from the copy, you should still use the
<option>dvd://</option> syntax, along with <option>-dvd-device</option>
followed by the path to the copied DVD root.
The <option>-dvd-device</option> and <option>-cdrom-device</option>
options can also be used to override the paths to the device nodes
for reading directly from disc, if the defaults of
<filename>/dev/dvd</filename> and <filename>/dev/cdrom</filename> do
not work on your system.
</para>
<para>
When encoding from DVD, it is often desirable to select a chapter or
range of chapters to encode.
You can use the <option>-chapter</option> option for this purpose.
For example, <option>-chapter</option> <replaceable>1-4</replaceable>
will only encode chapters 1 through 4 from the DVD.
This is especially useful if you will be making a 1400 MB encode
targeted for two CDs, since you can ensure the split occurs exactly
at a chapter boundary rather than in the middle of a scene.
</para>
<para>
If you have a supported TV capture card, you can also encode from the
TV-in device.
Use <option>tv://</option><replaceable>channelnumber</replaceable> as
the filename, and <option>-tv</option> to configure various capture
settings.
DVB input works similarly.
</para>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="menc-feat-mpeg4">
<title>Encoding two pass MPEG-4 ("DivX")</title>
<para>
The name comes from the fact that this method encodes the file
<emphasis>twice</emphasis>. The first encoding (dubbed pass) creates some
temporary files (<filename>*.log</filename>) with a size of few megabytes, do
not delete them yet (you can delete the AVI or rather just not create any video
by redirecting it into <filename>/dev/null</filename>
or on Windows into <filename>NUL</filename>).
In the second pass, the two pass output
file is created, using the bitrate data from the temporary files. The
resulting file will have much better image quality. If this is the first
time you heard about this, you should consult some guides available on the
net.
</para>
<example id="copy_audio_track">
<title>copy audio track</title>
<para>
Two pass encode of the second track a DVD to an MPEG-4 ("DivX")
AVI while copying the audio track.
<screen>
mencoder dvd://2 -ovc lavc -lavcopts vcodec=mpeg4:vpass=1 -oac copy -o /dev/null
mencoder dvd://2 -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell:vpass=2 \
-oac copy -o <replaceable>output.avi</replaceable>
</screen>
</para>
</example>
<example id="encode_audio_track">
<title>encode audio track</title>
<para>
Two pass encode of a DVD to an MPEG-4 ("DivX") AVI while encoding
the audio track to MP3.
Be careful using this method as it may lead to audio/video desync in
some cases.
<screen>
mencoder dvd://2 -ovc lavc -lavcopts vcodec=mpeg4:vpass=1 \
-oac mp3lame -lameopts vbr=3 -o /dev/null
mencoder dvd://2 -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell:vpass=2 \
-oac mp3lame -lameopts vbr=3 -o <replaceable>output.avi</replaceable>
</screen>
</para>
</example>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="menc-feat-handheld-psp">
<title>Encoding to Sony PSP video format</title>
<para>
<application>MEncoder</application> supports encoding to Sony PSP's video
format, but, depending on the revision of the PSP software, the constraints
may differ.
You should be safe if you respect the following constraints:
<itemizedlist>
<listitem><para>
<emphasis role="bold">Bitrate</emphasis>: it should not exceed 1500kbps,
however, past versions supported pretty much any bitrate as long as the
header claimed it was not too high.
</para></listitem>
<listitem><para>
<emphasis role="bold">Dimensions</emphasis>: the width and height of the
PSP video should be multiples of 16, and the product width * height must
be &lt;= 64000.
Under some circumstances, it may be possible for the PSP to play higher
resolutions.
</para></listitem>
<listitem><para>
<emphasis role="bold">Audio</emphasis>: its samplerate should be 24kHz
for MPEG-4 videos, and 48kHz for H.264.
</para></listitem>
</itemizedlist>
</para>
<example id="encode_for_psp">
<title>encode for PSP</title>
<para>
<screen>
mencoder -ofps 30000/1001 -af lavcresample=24000 -vf harddup -oac lavc \
-ovc lavc -lavcopts aglobal=1:vglobal=1:vcodec=mpeg4:acodec=libfaac \
-of lavf -lavfopts format=psp \
<replaceable>input.video</replaceable> -o <replaceable>output.psp</replaceable>
</screen>
Note that you can set the title of the video with
<option>-info name=<replaceable>MovieTitle</replaceable></option>.
</para>
</example>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="menc-feat-mpeg">
<title>Encoding to MPEG format</title>
<para>
<application>MEncoder</application> can create MPEG (MPEG-PS) format output
files.
Usually, when you are using MPEG-1 or MPEG-2 video, it is because you are
encoding for a constrained format such as SVCD, VCD, or DVD.
The specific requirements for these formats are explained in the
<link linkend="menc-feat-vcd-dvd"> VCD and DVD creation guide</link>
section.
</para>
<para>
To change <application>MEncoder</application>'s output file format,
use the <option>-of mpeg</option> option.
</para>
<informalexample>
<para>
Example:
<screen>
mencoder <replaceable>input.avi</replaceable> -of mpeg -ovc lavc -lavcopts vcodec=mpeg1video \
-oac copy <replaceable>other_options</replaceable> -o <replaceable>output.mpg</replaceable>
</screen>
Creating an MPEG-1 file suitable to be played on systems with minimal
multimedia support, such as default Windows installs:
<screen>
mencoder <replaceable>input.avi</replaceable> -of mpeg -mpegopts format=mpeg1:tsaf:muxrate=2000 \
-o <replaceable>output.mpg</replaceable> -oac lavc -lavcopts acodec=mp2:abitrate=224 -ovc lavc \
-lavcopts vcodec=mpeg1video:vbitrate=1152:keyint=15:mbd=2:aspect=4/3
</screen>
Same, but using <systemitem class="library">libavformat</systemitem> MPEG muxer:
<screen>
mencoder <replaceable>input.avi</replaceable> -o <replaceable>VCD.mpg</replaceable> -ofps 25 -vf scale=352:288,harddup -of lavf \
-lavfopts format=mpg -oac lavc -lavcopts acodec=mp2:abitrate=224 -ovc lavc \
-lavcopts vcodec=mpeg1video:vrc_buf_size=327:keyint=15:vrc_maxrate=1152:vbitrate=1152:vmax_b_frames=0
</screen>
</para>
</informalexample>
<note><title>Hint:</title>
<para>
If for some reason the video quality of the second pass did not
satisfy you, you may re-run your video encode with a different target
bitrate, provided that you saved the statistics file of the previous
pass.
This is possible because the statistics file's primary goal is to
record the complexity of each frame, which doesn't depend heavily on
bitrate. You should note, though, that you'll get the best results if
all passes are run with target bitrates that do not differ very much.
</para>
</note>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="menc-feat-rescale">
<title>Rescaling movies</title>
<para>
Often the need to resize movie images emerges. The reasons can be
many: decreasing file size, network bandwidth, etc. Most people even do
rescaling when converting DVDs or SVCDs to DivX AVI. If you wish to rescale,
read the <link linkend="aspect">Preserving aspect ratio</link> section.
</para>
<para>
The scaling process is handled by the <literal>scale</literal> video filter:
<option>-vf scale=<replaceable>width</replaceable>:<replaceable>height</replaceable></option>.
Its quality can be set with the <option>-sws</option> option.
If it is not specified, <application>MEncoder</application> will use 2: bicubic.
</para>
<para>
Usage:
<screen>
mencoder <replaceable>input.mpg</replaceable> -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell \
-vf scale=640:480 -o <replaceable>output.avi</replaceable>
</screen>
</para>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="menc-feat-streamcopy">
<title>Stream copying</title>
<para>
<application>MEncoder</application> can handle input streams in two ways:
<emphasis role="bold">encode</emphasis> or <emphasis role="bold">copy</emphasis>
them. This section is about <emphasis role="bold">copying</emphasis>.
</para>
<itemizedlist>
<listitem><para>
<emphasis role="bold">Video stream</emphasis> (option <option>-ovc copy</option>):
nice stuff can be done :) Like, putting (not converting!) FLI or VIVO or
MPEG-1 video into an AVI file! Of course only
<application>MPlayer</application> can play such files :) And it probably
has no real life value at all. Rationally: video stream copying can be
useful for example when only the audio stream has to be encoded (like,
uncompressed PCM to MP3).
</para></listitem>
<listitem><para>
<emphasis role="bold">Audio stream</emphasis> (option <option>-oac copy</option>):
straightforward. It is possible to take an external audio file (MP3,
WAV) and mux it into the output stream. Use the
<option>-audiofile <replaceable>filename</replaceable></option> option
for this.
</para></listitem>
</itemizedlist>
<para>
Using <option>-oac copy</option> to copy from one container format to
another may require the use of <option>-fafmttag</option> to keep the
audio format tag of the original file.
For example, if you are converting an NSV file with AAC audio to an AVI
container, the audio format tag will be incorrect and it will have to
be changed. For a list of audio format tags, check
<filename>codecs.conf</filename>.
</para>
<para>
Example:
<screen>
mencoder <replaceable>input.nsv</replaceable> -oac copy -fafmttag 0x706D \
-ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell -o <replaceable>output.avi</replaceable>
</screen>
</para>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="menc-feat-enc-images">
<title>Encoding from multiple input image files (JPEG, PNG, TGA, etc.)</title>
<para>
<application>MEncoder</application> is capable of creating movies from one
or more JPEG, PNG, TGA, or other image files. With simple framecopy it can
create MJPEG (Motion JPEG), MPNG (Motion PNG) or MTGA (Motion TGA) files.
</para>
<orderedlist>
<title>Explanation of the process:</title>
<listitem><para>
<application>MEncoder</application> <emphasis>decodes</emphasis> the input
image(s) with <systemitem class="library">libjpeg</systemitem> (when decoding
PNGs, it will use <systemitem class="library">libpng</systemitem>).
</para></listitem>
<listitem><para>
<application>MEncoder</application> then feeds the decoded image to the
chosen video compressor (DivX4, Xvid, FFmpeg msmpeg4, etc.).
</para></listitem>
</orderedlist>
<formalpara>
<title>Examples</title>
<para>
The explanation of the <option>-mf</option> option is in the man page.
<informalexample>
<para>
Creating an MPEG-4 file from all the JPEG files in the current directory:
<screen>
mencoder mf://*.jpg -mf w=800:h=600:fps=25:type=jpg -ovc lavc \
-lavcopts vcodec=mpeg4:mbd=2:trell -oac copy -o <replaceable>output.avi</replaceable>
</screen>
</para>
</informalexample>
<informalexample>
<para>
Creating an MPEG-4 file from some JPEG files in the current directory:
<screen>
mencoder mf://<replaceable>frame001.jpg,frame002.jpg</replaceable> -mf w=800:h=600:fps=25:type=jpg \
-ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell -oac copy -o <replaceable>output.avi</replaceable>
</screen>
</para>
</informalexample>
<informalexample>
<para>
Creating an MPEG-4 file from explicit list of JPEG files (list.txt in current
directory contains the list of files to use as source, one per line):
<screen>
mencoder mf://<replaceable>@list.txt</replaceable> -mf w=800:h=600:fps=25:type=jpg \
-ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell -oac copy -o <replaceable>output.avi</replaceable>
</screen>
</para>
</informalexample>
You can mix different types of images, regardless of the method you use
&mdash; individual filenames, wildcard or file with list &mdash; provided of
course they have the same dimensions.
So you can e.g. take title frame from PNG file,
and then put a slideshow of your JPEG photos.
<informalexample>
<para>
Creating a Motion JPEG (MJPEG) file from all the JPEG files in the current
directory:
<screen>
mencoder mf://*.jpg -mf w=800:h=600:fps=25:type=jpg -ovc copy -oac copy -o <replaceable>output.avi</replaceable>
</screen>
</para>
</informalexample>
<informalexample>
<para>
Creating an uncompressed file from all the PNG files in the current directory:
<screen>
mencoder mf://*.png -mf w=800:h=600:fps=25:type=png -ovc raw -oac copy -o <replaceable>output.avi</replaceable>
</screen>
</para>
</informalexample>
<note><para>
Width must be integer multiple of 4, it is a limitation of the RAW RGB AVI
format.
</para></note>
<informalexample>
<para>
Creating a Motion PNG (MPNG) file from all the PNG files in the current
directory:
<screen>
mencoder mf://*.png -mf w=800:h=600:fps=25:type=png -ovc copy -oac copy -o <replaceable>output.avi</replaceable><!--
--></screen>
</para>
</informalexample>
<informalexample>
<para>
Creating a Motion TGA (MTGA) file from all the TGA files in the current
directory:
<screen>
mencoder mf://*.tga -mf w=800:h=600:fps=25:type=tga -ovc copy -oac copy -o <replaceable>output.avi</replaceable><!--
--></screen>
</para>
</informalexample>
</para>
</formalpara>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="menc-feat-extractsub">
<title>Extracting DVD subtitles to VOBsub file</title>
<para>
<application>MEncoder</application> is capable of extracting subtitles from
a DVD into VOBsub formatted files. They consist of a pair of files ending in
<filename>.idx</filename> and <filename>.sub</filename> and are usually
packaged in a single <filename>.rar</filename> archive.
<application>MPlayer</application> can play these with the
<option>-vobsub</option> and <option>-vobsubid</option> options.
</para>
<para>
You specify the basename (i.e without the <filename>.idx</filename> or
<filename>.sub</filename> extension) of the output files with
<option>-vobsubout</option> and the index for this subtitle in the
resulting files with <option>-vobsuboutindex</option>.
</para>
<para>
If the input is not from a DVD you should use <option>-ifo</option> to
indicate the <filename>.ifo</filename> file needed to construct the
resulting <filename>.idx</filename> file.
</para>
<para>
If the input is not from a DVD and you do not have the
<filename>.ifo</filename> file you will need to use the
<option>-vobsubid</option> option to let it know what language id to put in
the <filename>.idx</filename> file.
</para>
<para>
Each run will append the running subtitle if the <filename>.idx</filename>
and <filename>.sub</filename> files already exist. So you should remove any
before starting.
</para>
<example id="copying_two_subtitles_from_a_dvd_while_doing_two_pass_encoding">
<title>Copying two subtitles from a DVD while doing two pass encoding</title>
<screen>
rm <replaceable>subtitles.idx</replaceable> <replaceable>subtitles.sub</replaceable>
mencoder dvd://1 -oac copy -ovc lavc -lavcopts vcodec=mpeg4:vpass=1 \
-vobsubout <replaceable>subtitles</replaceable> -vobsuboutindex 0 -sid 2
mencoder dvd://1 -oac copy -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell:vpass=2 \
-vobsubout <replaceable>subtitles</replaceable> -vobsuboutindex 1 -sid 5<!--
--></screen>
</example>
<example id="copying_a_french_subtitle_from_an_mpeg_file">
<title>Copying a French subtitle from an MPEG file</title>
<screen>
rm <replaceable>subtitles.idx</replaceable> <replaceable>subtitles.sub</replaceable>
mencoder <replaceable>movie.mpg</replaceable> -ifo <replaceable>movie.ifo</replaceable> -vobsubout <replaceable>subtitles</replaceable> -vobsuboutindex 0 \
-vobsuboutid fr -sid 1 -nosound -ovc copy
</screen>
</example>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="aspect">
<title>Preserving aspect ratio</title>
<para>
DVDs and SVCDs (i.e. MPEG-1/2) files contain an aspect ratio value, which
describes how the player should scale the video stream, so humans will not
have egg heads (ex.: 480x480 + 4:3 = 640x480). However when encoding to AVI
(DivX) files, you have to be aware that AVI headers do not store this value.
Rescaling the movie is disgusting and time consuming, there has to be a better
way!
</para>
<para>There is</para>
<para>
MPEG-4 has a unique feature: the video stream can contain its needed aspect
ratio. Yes, just like MPEG-1/2 (DVD, SVCD) and H.263 files. Regretfully, there
are few video players apart from <application>MPlayer</application> that
support this MPEG-4 attribute.
</para>
<para>
This feature can be used only with
<systemitem class="library">libavcodec</systemitem>'s
<systemitem>mpeg4</systemitem> codec. Keep in mind: although
<application>MPlayer</application> will correctly play the created file,
other players may use the wrong aspect ratio.
</para>
<para>
You seriously should crop the black bands over and below the movie image.
See the man page for the usage of the <systemitem>cropdetect</systemitem> and
<systemitem>crop</systemitem> filters.
</para>
<para>
Usage
<screen>mencoder <replaceable>sample-svcd.mpg</replaceable> -vf crop=714:548:0:14 -oac copy -ovc lavc \
-lavcopts vcodec=mpeg4:mbd=2:trell:autoaspect -o <replaceable>output.avi</replaceable></screen>
</para>
</sect1>
</chapter>

View File

@ -4,838 +4,7 @@
<title>Ports</title>
<para>
Binary packages of <application>MPlayer</application> are available from several
sources. We have a list of places to get
<ulink url="http://www.mplayerhq.hu/design7/projects.html#unofficial_packages">unofficial packages</ulink>
for various systems on our homepage.
However, <emphasis role="bold">none of these packages are supported</emphasis>.
Report problems to the authors, not to us.
OUTDATED CONTENT REMOVED
</para>
<sect1 id="linux">
<title>Linux</title>
<!-- ********** -->
<sect2 id="debian">
<title>Debian packaging</title>
<para>
To build a Debian package, run the following command in the
<application>MPlayer</application> source directory:
<screen>fakeroot debian/rules binary</screen>
If you want to pass custom options to configure, you can set up the
<envar>DEB_BUILD_OPTIONS</envar> environment variable. For instance,
if you want GUI and OSD menu support you would use:
<screen>DEB_BUILD_OPTIONS="--enable-gui --enable-menu" fakeroot debian/rules binary</screen>
You can also pass some variables to the Makefile. For example, if you want
to compile with gcc 3.4 even if it's not the default compiler:
<screen>CC=gcc-3.4 DEB_BUILD_OPTIONS="--enable-gui" fakeroot debian/rules binary</screen>
To clean up the source tree run the following command:
<screen>fakeroot debian/rules clean</screen>
As root you can then install the <filename>.deb</filename> package as usual:
<screen>dpkg -i ../mplayer_<replaceable>version</replaceable>.deb</screen>
</para>
</sect2>
<!-- ********** -->
<sect2 id="rpm">
<title>RPM packaging</title>
<para>
To build an RPM package, run the following command in the
<application>MPlayer</application> source directory:
<screen>FIXME: insert proper commands here</screen>
</para>
</sect2>
<!-- ********** -->
<sect2 id="arm_linux">
<title>ARM Linux</title>
<para>
<application>MPlayer</application> works on Linux PDAs with ARM CPU e.g. Sharp
Zaurus, Compaq Ipaq. The easiest way to obtain
<application>MPlayer</application> is to get it from one of the
<ulink url="http://www.openzaurus.org">OpenZaurus</ulink> package feeds.
If you want to compile it yourself, you should look at the
<ulink url="http://openzaurus.bkbits.net:8080/buildroot/src/packages/mplayer?nav=index.html|src/.|src/packages">mplayer</ulink>
and the
<ulink url="http://openzaurus.bkbits.net:8080/buildroot/src/packages/libavcodec?nav=index.html|src/.|src/packages">libavcodec</ulink>
directory in the OpenZaurus distribution buildroot. These always have the latest
Makefile and patches used for building a SVN <application>MPlayer</application>.
If you need a GUI frontend, you can use xmms-embedded.
</para>
</sect2>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="bsd">
<title>*BSD</title>
<para>
<application>MPlayer</application> runs on all known BSD flavors.
There are ports/pkgsrc/fink/etc versions of <application>MPlayer</application>
available that are probably easier to use than our raw sources.
</para>
<para>
If <application>MPlayer</application> complains about not finding
<filename>/dev/cdrom</filename> or <filename>/dev/dvd</filename>,
create an appropriate symbolic link:
<screen>ln -s /dev/<replaceable>your_cdrom_device</replaceable> /dev/cdrom</screen>
</para>
<para>
To use Win32 DLLs with <application>MPlayer</application> you will need to
re-compile the kernel with "<envar>option USER_LDT</envar>"
(unless you run FreeBSD-CURRENT,
where this is the default).
</para>
<!-- ********** -->
<sect2 id="freebsd">
<title>FreeBSD</title>
<para>
If your CPU has SSE, recompile your kernel with
"<envar>options CPU_ENABLE_SSE</envar>" (FreeBSD-STABLE or kernel
patches required).
</para>
</sect2>
<!-- ********** -->
<sect2 id="openbsd">
<title>OpenBSD</title>
<para>
Due to limitations in different versions of gas (relocation vs MMX), you
will need to compile in two steps: First make sure that the non-native as
is first in your <envar>$PATH</envar> and do a <command>gmake -k</command>, then
make sure that the native version is used and do <command>gmake</command>.
</para>
<para>
As of OpenBSD 3.4 the hack above is no longer needed.
</para>
</sect2>
<!-- ********** -->
<sect2 id="darwin">
<title>Darwin</title>
<para>
See the <link linkend="macos">Mac OS</link> section.
</para>
</sect2>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="unix">
<title>Commercial Unix</title>
<para>
<application>MPlayer</application> has been ported to a number of commercial
Unix variants. Since the development environments on these systems tend to be
different from those found on free Unixes, you may have to make some manual
adjustments to make the build work.
</para>
<!-- ********** -->
<sect2 id="solaris">
<title>Solaris</title>
<para>
Solaris still has broken, POSIX-incompatible system tools and shell in default
locations. Until a bold step out of the computing stone age is made, you will
have to add <filename>/usr/xpg4/bin</filename> to your
<systemitem>PATH</systemitem>.
</para>
<para>
<application>MPlayer</application> should work on Solaris 2.6 or newer.
Use the SUN audio driver with the <option>-ao sun</option> option for sound.
</para>
<para>
On <emphasis role="bold">UltraSPARCs</emphasis>,
<application>MPlayer</application> takes advantage of their
<emphasis role="bold">VIS</emphasis> extensions
(equivalent to MMX), currently only in
<systemitem class="library">libmpeg2</systemitem>,
<systemitem class="library">libvo</systemitem>
and <systemitem class="library">libavcodec</systemitem>, but not in
<systemitem class="library">mp3lib</systemitem>. You can watch a VOB file
on a 400MHz CPU. You'll need
<ulink url="http://www.sun.com/sparc/vis/mediaLib.html"><systemitem class="library">mLib</systemitem></ulink>
installed.
</para>
<para><emphasis role="bold">Caveat:</emphasis></para>
<itemizedlist>
<listitem><para>
<emphasis role="bold">mediaLib</emphasis> is
<emphasis role="bold">currently disabled</emphasis> by default in
<application>MPlayer</application> because of brokenness. SPARC users
who build MPlayer with mediaLib support have reported a thick,
green-tint on video encoded and decoded with libavcodec. You may enable
it if you wish with:
<screen>./configure --enable-mlib</screen>
You do this at your own risk. x86 users should
<emphasis role="bold">never</emphasis> use mediaLib, as this will
result in very poor MPlayer performance.
</para></listitem>
</itemizedlist>
<para>
On Solaris SPARC, you need the GNU C/C++ Compiler; it does not matter if
GNU C/C++ compiler is configured with or without the GNU assembler.
</para>
<para>
On Solaris x86, you need the GNU assembler and the GNU C/C++ compiler,
configured to use the GNU assembler! The <application>MPlayer</application>
code on the x86 platform makes heavy use of MMX, SSE and 3DNOW! instructions
that cannot be compiled using Sun's assembler
<filename>/usr/ccs/bin/as</filename>.
</para>
<para>
The <filename>configure</filename> script tries to find out, which assembler
program is used by your "gcc" command (in case the autodetection
fails, use the
<option>--as=<replaceable>/wherever/you/have/installed/gnu-as</replaceable></option>
option to tell the <filename>configure</filename> script where it can find GNU
"as" on your system).
</para>
<para>Solutions to common problems:</para>
<itemizedlist>
<listitem><para>
Error message from <filename>configure</filename> on a Solaris x86 system
using GCC without GNU assembler:
<screen>
% configure
...
Checking assembler (/usr/ccs/bin/as) ... , failed
Please upgrade(downgrade) binutils to 2.10.1...<!--
--></screen>
(Solution: Install and use a gcc configured with
<option>--with-as=gas</option>)
</para>
<para>
Typical error you get when building with a GNU C compiler that does not
use GNU as:
<screen>
% gmake
...
gcc -c -Iloader -Ilibvo -O4 -march=i686 -mcpu=i686 -pipe -ffast-math
-fomit-frame-pointer -I/usr/local/include -o mplayer.o mplayer.c
Assembler: mplayer.c
"(stdin)", line 3567 : Illegal mnemonic
"(stdin)", line 3567 : Syntax error
... more "Illegal mnemonic" and "Syntax error" errors ...
</screen>
</para>
</listitem>
<listitem><para>
<application>MPlayer</application> may segfault when decoding
and encoding video that uses the win32codecs:
<screen>
...
Trying to force audio codec driver family acm...
Opening audio decoder: [acm] Win32/ACM decoders
sysi86(SI86DSCR): Invalid argument
Couldn't install fs segment, expect segfault
MPlayer interrupted by signal 11 in module: init_audio_codec
...<!--
--></screen>
This is because of a change to sysi86() in Solaris 10 and pre-Solaris
Nevada b31 releases. This has been fixed in Solaris Nevada b32;
however, Sun has yet to backport the fix to Solaris 10. The MPlayer
Project has made Sun aware of the problem and a patch is currently in
progress for Solaris 10. More information about this bug can be found
at:
<ulink url="http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=6308413"/>.
</para></listitem>
<listitem><para>
Due to bugs in Solaris 8,
you may not be able to play DVD discs larger than 4 GB:
</para>
<itemizedlist>
<listitem><para>
The sd(7D) driver on Solaris 8 x86 has a bug when accessing a disk block >4GB
on a device using a logical blocksize != DEV_BSIZE
(i.e. CD-ROM and DVD media).
Due to a 32Bit int overflow, a disk address modulo 4GB is accessed
(<ulink url="http://groups.yahoo.com/group/solarisonintel/message/22516"/>).
This problem does not exist in the SPARC version of Solaris 8.
</para></listitem>
<listitem><para>
A similar bug is present in the hsfs(7FS) file system code (AKA ISO9660),
hsfs may not not support partitions/disks larger than 4GB, all data is
accessed modulo 4GB
(<ulink url="http://groups.yahoo.com/group/solarisonintel/message/22592"/>).
The hsfs problem can be fixed by installing
patch 109764-04 (SPARC) / 109765-04 (x86).
</para></listitem>
</itemizedlist>
</listitem>
</itemizedlist>
</sect2>
<!-- ********** -->
<sect2 id="hp-ux">
<title>HP-UX</title>
<para>
Joe Page hosts a detailed HP-UX <application>MPlayer</application>
<ulink url="http://users.rcn.com/joepage/mplayer_on_hpux11.htm">HOWTO</ulink>
by Martin Gansser on his homepage. With these instructions the build should
work out of the box. The following information is taken from this HOWTO.
</para>
<para>
You need GCC 3.4.0 or later and SDL 1.2.7 or later.
HP cc will not produce a working program, prior GCC versions are buggy.
For OpenGL functionality you need to install Mesa and the gl and gl2 video
output drivers should work, speed may be very bad, depending on the CPU speed,
though. A good replacement for the rather poor native HP-UX sound system is
GNU esound.
</para>
<para>
Create the DVD device
scan the SCSI bus with:
<screen>
# ioscan -fn
Class I H/W Path Driver S/W State H/W Type Description
...
ext_bus 1 8/16/5 c720 CLAIMED INTERFACE Built-in SCSI
target 3 8/16/5.2 tgt CLAIMED DEVICE
disk 4 8/16/5.<emphasis role="bold">2</emphasis>.<emphasis role="bold">0</emphasis> sdisk CLAIMED DEVICE <emphasis role="bold">PIONEER DVD-ROM DVD-305</emphasis>
/dev/dsk/c1t2d0 <emphasis role="bold">/dev/rdsk/c1t2d0</emphasis>
target 4 8/16/5.7 tgt CLAIMED DEVICE
ctl <emphasis role="bold">1</emphasis> 8/16/5.7.0 sctl CLAIMED DEVICE Initiator
/dev/rscsi/c1t7d0 /dev/rscsi/c1t7l0 /dev/scsi/c1t7l0
...
</screen>
The screen output shows a Pioneer DVD-ROM at SCSI address 2.
The card instance for hardware path 8/16 is 1.
</para>
<para>
Create a link from the raw device to the DVD device.
<screen>
ln -s /dev/rdsk/c<replaceable>&lt;SCSI bus instance&gt;</replaceable>t<replaceable>&lt;SCSI target ID&gt;</replaceable>d<replaceable>&lt;LUN&gt;</replaceable> /dev/<replaceable>&lt;device&gt;</replaceable>
</screen>
Example:
<screen>ln -s /dev/rdsk/c1t2d0 /dev/dvd</screen>
</para>
<para>
Below are solutions for some common problems:
<itemizedlist>
<listitem>
<para>
Crash at Start with the following error message:
<screen>
/usr/lib/dld.sl: Unresolved symbol: finite (code) from /usr/local/lib/gcc-lib/hppa2.0n-hp-hpux11.00/3.2/../../../libGL.sl<!--
--></screen>
</para>
<para>
This means that the function <systemitem>.finite().</systemitem> is not
available in the standard HP-UX math library.
Instead there is <systemitem>.isfinite().</systemitem>.
Solution: Use the latest Mesa depot file.
</para>
</listitem>
<listitem>
<para>
Crash at playback with the following error message:
<screen>
/usr/lib/dld.sl: Unresolved symbol: sem_init (code) from /usr/local/lib/libSDL-1.2.sl.0<!--
--></screen>
</para>
<para>
Solution: Use the extralibdir option of configure
<option>--extra-ldflags="/usr/lib -lrt"</option>
</para>
</listitem>
<listitem>
<para>
MPlayer segfaults with a message like this:
<screen>
Pid 10166 received a SIGSEGV for stack growth failure.
Possible causes: insufficient memory or swap space, or stack size exceeded maxssiz.
Segmentation fault<!--
--></screen>
</para>
<para>
Solution:
The HP-UX kernel has a default stack size of 8MB(?) per process.(11.0 and
newer 10.20 patches let you increase <systemitem>maxssiz</systemitem> up to
350MB for 32-bit programs). You need to extend
<systemitem>maxssiz</systemitem> and recompile the kernel (and reboot).
You can use SAM to do this.
(While at it, check out the <systemitem>maxdsiz</systemitem> parameter for
the maximum amount of data a program can use.
It depends on your applications, if the default of 64MB is enough or not.)
</para>
</listitem>
</itemizedlist>
</para>
</sect2>
<!-- ********** -->
<sect2 id="aix">
<title>AIX</title>
<para>
<application>MPlayer</application> builds successfully on AIX 5.1,
5.2, and 5.3, using GCC 3.3 or greater. Building
<application>MPlayer</application> on AIX 4.3.3 and below is
untested. It is highly recommended that you build
<application>MPlayer</application> using GCC 3.4 or greater,
or if you are building on POWER5, GCC 4.0 is required.
</para>
<para>
CPU detection is still a work in progress.
The following architectures have been tested:
</para>
<itemizedlist>
<listitem><para>604e</para></listitem>
<listitem><para>POWER3</para></listitem>
<listitem><para>POWER4</para></listitem>
</itemizedlist>
<para>
The following architectures are untested, but should still work:
<itemizedlist>
<listitem><para>POWER</para></listitem>
<listitem><para>POWER2</para></listitem>
<listitem><para>POWER5</para></listitem>
</itemizedlist>
</para>
<para>
Sound via the Ultimedia Services is not supported, as Ultimedia was
dropped in AIX 5.1; therefore, the only option is to use the AIX Open
Sound System (OSS) drivers from 4Front Technologies at
<ulink url="http://www.opensound.com/aix.html">http://www.opensound.com/aix.html</ulink>.
4Front Technologies freely provides OSS drivers for AIX 5.1 for
non-commercial use; however, there are currently no sound output
drivers for AIX 5.2 or 5.3. This means <emphasis role="bold">AIX 5.2
and 5.3 are not capable of MPlayer audio output, presently.</emphasis>
</para>
<para>Solutions to common problems:</para>
<itemizedlist>
<listitem>
<para>
If you encounter this error message from <filename>./configure</filename>:
<screen>
$ ./configure
...
Checking for iconv program ... no
No working iconv program found, use
--charset=US-ASCII to continue anyway.
Messages in the GTK-2 interface will be broken then.<!--
--></screen>
This is because AIX uses non-standard character set names; therefore,
converting MPlayer output to another character set is currently not
supported. The solution is to use:
<screen>$ ./configure --charset=noconv</screen>
</para>
</listitem>
</itemizedlist>
</sect2>
<!-- ********** -->
<sect2 id="qnx">
<title>QNX</title>
<para>
You'll need to download and install SDL for QNX. Then run
<application>MPlayer</application> with <option>-vo sdl:driver=photon</option>
and <option>-ao sdl:nto</option> options, it should be fast.
</para>
<para>
The <option>-vo x11</option> output will be even slower than on Linux,
since QNX has only X <emphasis>emulation</emphasis> which is very slow.
</para>
</sect2>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="windows">
<title>Windows</title>
<para>
Yes, <application>MPlayer</application> runs on Windows under
<ulink url="http://www.cygwin.com/"><application>Cygwin</application></ulink>
and
<ulink url="http://www.mingw.org/"><application>MinGW</application></ulink>.
It does not have an official GUI yet, but the command line version
is completely functional. You should check out the
<ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-cygwin/">MPlayer-cygwin</ulink>
mailing list for help and latest information.
Official Windows binaries can be found on the
<ulink url="http://www.mplayerhq.hu/design7/dload.html">download page</ulink>.
Installer packages and simple GUI frontends are available from external
sources, we have collected then in the Windows section of our
<ulink url="http://www.mplayerhq.hu/design7/projects.html#windows">projects page</ulink>.
</para>
<para>
If you wish to avoid using the command line, a simple trick is
to put a shortcut on your desktop that contains something like the
following in the execute section:
<screen><replaceable>c:\path\to\</replaceable>mplayer.exe %1</screen>
This will make <application>MPlayer</application> play any movie that is
dropped on the shortcut. Add <option>-fs</option> for fullscreen mode.
</para>
<para>
Best results are achieved with the native DirectX video output driver
(<option>-vo directx</option>). Alternatives are OpenGL and SDL, but OpenGL
performance varies greatly between systems and SDL is known to
distort video or crash on some systems. If the image is
distorted, try turning off hardware acceleration with
<option>-vo directx:noaccel</option>. Download
<ulink url="http://www.mplayerhq.hu/MPlayer/contrib/win32/dx7headers.tgz">DirectX 7 header files</ulink>
to compile the DirectX video output driver. Furthermore you need to have
DirectX 7 or later installed for the DirectX video output driver to work.
</para>
<para>
<link linkend="vidix">VIDIX</link> now works under Windows as
<option>-vo winvidix</option>, although it is still experimental
and needs a bit of manual setup. Download
<ulink url="http://www.mplayerhq.hu/MPlayer/releases/win32/dhahelperwin/dhahelper.sys">dhahelper.sys</ulink> or
<ulink url="http://www.mplayerhq.hu/MPlayer/releases/win32/dhahelperwin/withmtrr/dhahelper.sys">dhahelper.sys (with MTRR support)</ulink>
and copy it to the <filename class="directory">vidix/dhahelperwin</filename>
directory in your <application>MPlayer</application> source tree.
Open a console and type
<screen>make install-dhahelperwin</screen>
as Administrator. After that you will have to reboot.
</para>
<para>
For best results <application>MPlayer</application> should use a
colorspace that your video card supports in hardware. Unfortunately many
Windows graphics drivers wrongly report some colorspaces as supported in
hardware. To find out which, try
<screen>
mplayer -benchmark -nosound -frames 100 -vf format=<replaceable>colorspace</replaceable> <replaceable>movie</replaceable>
</screen>
where <replaceable>colorspace</replaceable> can be any colorspace
printed by the <option>-vf format=fmt=help</option> option. If you
find a colorspace your card handles particularly bad
<option>-vf noformat=<replaceable>colorspace</replaceable></option>
will keep it from being used. Add this to your config file to permanently
keep it from being used.
</para>
<para>There are special codec packages for Windows available on our
<ulink url="http://www.mplayerhq.hu/design7/dload.html">download page</ulink>
to allow playing formats for which there is no native support yet.
Put the codecs somewhere in your path or pass
<option>--codecsdir=<replaceable>c:/path/to/your/codecs</replaceable></option>
(alternatively
<option>--codecsdir=<replaceable>/path/to/your/codecs</replaceable></option>
only on <application>Cygwin</application>) to <filename>configure</filename>.
We have had some reports that Real DLLs need to be writable by the user
running <application>MPlayer</application>, but only on some systems (NT4).
Try making them writable if you have problems.
</para>
<para>
You can play VCDs by playing the <filename>.DAT</filename> or
<filename>.MPG</filename> files that Windows exposes on VCDs. It works like
this (adjust for the drive letter of your CD-ROM):
<screen>mplayer <replaceable>d:/mpegav/avseq01.dat</replaceable></screen>
Alternatively, you can play a VCD track directly by using:
<screen>mplayer vcd://<replaceable>&lt;track&gt;</replaceable> -cdrom-device <replaceable>d:</replaceable>
</screen>
DVDs also work, adjust <option>-dvd-device</option> for the drive letter
of your DVD-ROM:
<screen>
mplayer dvd://<replaceable>&lt;title&gt;</replaceable> -dvd-device <replaceable>d:</replaceable>
</screen>
The <application>Cygwin</application>/<application>MinGW</application>
console is rather slow. Redirecting output or using the
<option>-quiet</option> option has been reported to improve performance on
some systems. Direct rendering (<option>-dr</option>) may also help.
If playback is jerky, try
<option>-autosync 100</option>. If some of these options help you, you
may want to put them in your config file.
</para>
<note>
<para>
If you have a Pentium 4 and are experiencing a crash using the
RealPlayer codecs, you may need to disable hyperthreading support.
</para>
</note>
<!-- ********** -->
<sect2 id="cygwin">
<title><application>Cygwin</application></title>
<para>
You need to run <application>Cygwin</application> 1.5.0 or later in
order to compile <application>MPlayer</application>.
</para>
<para>
DirectX header files need to be extracted to
<filename class="directory">/usr/include/</filename> or
<filename class="directory">/usr/local/include/</filename>.
</para>
<para>
Instructions and files for making SDL run under
<application>Cygwin</application> can be found on the
<ulink url="http://www.libsdl.org/extras/win32/cygwin/">libsdl site</ulink>.
</para>
</sect2>
<!-- ********** -->
<sect2 id="mingw">
<title><application>MinGW</application></title>
<para>
You need <application>MinGW</application> 3.1.0 or later and MSYS 1.0.9 or
later. Tell the MSYS postinstall that <application>MinGW</application> is
installed.
</para>
<para>
Extract DirectX header files to
<filename class="directory">/mingw/include/</filename>.
</para>
<para>
MOV compressed header support requires
<ulink url="http://www.gzip.org/zlib/">zlib</ulink>,
which <application>MinGW</application> does not provide by default.
Configure it with <option>--prefix=/mingw</option> and install
it before compiling <application>MPlayer</application>.
</para>
<para>
Complete instructions for building <application>MPlayer</application>
and necessary libraries can be found in the
<ulink url="http://www.mplayerhq.hu/MPlayer/contrib/win32/MPlayer-MinGW-Howto.txt">MPlayer MinGW HOWTO</ulink>.
</para>
</sect2>
</sect1>
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<sect1 id="macos">
<title>Mac OS</title>
<para>
<application>MPlayer</application> does not work on Mac OS versions before
10, but should compile out-of-the-box on Mac OS X 10.2 and up.
The preferred compiler is the Apple version of
GCC 3.x or later.
You can get the basic compilation environment by installing Apple's
<ulink url="http://developer.apple.com/tools/download/">Xcode</ulink>.
If you have Mac OS X 10.3.9 or later and QuickTime 7
you can use the <option>corevideo</option> video output driver.
</para>
<para>
Unfortunately, this basic environment will not allow you to take advantage
of all the nice features of <application>MPlayer</application>.
For instance, in order to have OSD support compiled in, you will
need to have <systemitem class="library">fontconfig</systemitem>
and <systemitem class="library">freetype</systemitem> libraries
installed on your machine. Contrary to other Unixes such as most
Linux and BSD variants, OS X does not have a package system
that comes with the system.
</para>
<para>
There are at least two to choose from:
<ulink url="http://fink.sourceforge.net/">Fink</ulink> and
<ulink url="http://www.macports.org/">MacPorts</ulink>.
Both of them provide about the same service (i.e. a lot of packages to
choose from, dependency resolution, the ability to simply add/update/remove
packages, etc...).
Fink offers both precompiled binary packages or building everything from
source, whereas MacPorts only offers building from source.
The author of this guide chose MacPorts for the simple fact that its basic
setup was more lightweight.
Later examples will be based on MacPorts.
</para>
<para>
For instance, to compile <application>MPlayer</application> with OSD support:
<screen>sudo port install pkg-config</screen>
This will install <application>pkg-config</application>, which is a system for
managing library compile/link flags.
<application>MPlayer</application>'s <systemitem>configure</systemitem> script
uses it to properly detect libraries.
Then you can install <application>fontconfig</application> in a
similar way:
<screen>sudo port install fontconfig</screen>
Then you can proceed with launching <application>MPlayer</application>'s
<systemitem>configure</systemitem> script (note the
<systemitem>PKG_CONFIG_PATH</systemitem> and <systemitem>PATH</systemitem>
environment variables so that <systemitem>configure</systemitem> finds the
libraries installed with MacPorts):
<screen>
PKG_CONFIG_PATH=/opt/local/lib/pkgconfig/ PATH=$PATH:/opt/local/bin/ ./configure
</screen>
</para>
<!-- ********** -->
<sect2 id="osx_gui">
<title>MPlayer OS X GUI</title>
<para>
You can get a native GUI for <application>MPlayer</application> together with
precompiled <application>MPlayer</application> binaries for Mac OS X from the
<ulink url="http://mplayerosx.sf.net/">MPlayerOSX</ulink> project, but be
warned: that project is not active anymore.
</para>
<para>
Fortunately, <application>MPlayerOSX</application> has been taken over
by a member of the <application>MPlayer</application> team.
Preview releases are available from our
<ulink url="http://mplayerhq.hu/dload.html">download page</ulink>
and an official release should arrive soon.
</para>
<para>
In order to build <application>MPlayerOSX</application> from source
yourself, you need the <systemitem>mplayerosx</systemitem>, the
<systemitem>main</systemitem> and a copy of the
<systemitem>main</systemitem> SVN module named
<systemitem>main_noaltivec</systemitem>.
<systemitem>mplayerosx</systemitem> is the GUI frontend,
<systemitem>main</systemitem> is MPlayer and
<systemitem>main_noaltivec</systemitem> is MPlayer built without AltiVec
support.
</para>
<para>
To check out SVN modules use:
<screen>
svn checkout svn://svn.mplayerhq.hu/mplayerosx/trunk/ mplayerosx
svn checkout svn://svn.mplayerhq.hu/mplayer/trunk/ main
</screen>
</para>
<para>
In order to build <application>MPlayerOSX</application> you will need to
set up something like this:
<screen>
MPlayer_source_directory
|
|--->main (MPlayer Subversion source)
|
|--->main_noaltivec (MPlayer Subversion source configured with --disable-altivec)
|
\--->mplayerosx (MPlayer OS X Subversion source)
</screen>
You first need to build main and main_noaltivec.
</para>
<para>
To begin with, in order to ensure maximum backwards compatibility, set an
environment variable:
<screen>export MACOSX_DEPLOYMENT_TARGET=10.3</screen>
</para>
<para>
Then, configure:
</para>
<para>
If you configure for a G4 or later CPU with AltiVec support, do as follows:
<screen>
./configure --disable-gl --disable-x11
</screen>
If you configure for a G3-powered machine without AltiVec, use:
<screen>
./configure --disable-gl --disable-x11 --disable-altivec
</screen>
You may need to edit <filename>config.mak</filename> and change
<systemitem>-mcpu</systemitem> and <systemitem>-mtune</systemitem>
from <systemitem>74XX</systemitem> to <systemitem>G3</systemitem>.
</para>
<para>
Continue with
<screen>make</screen>
then go to the mplayerosx directory and type
<screen>make dist</screen>
This will create a compressed <systemitem>.dmg</systemitem> archive
with the ready to use binary.
</para>
<para>
You can also use the <application>Xcode</application> 2.1 project;
the old project for <application>Xcode</application> 1.x does
not work anymore.
</para>
</sect2>
</sect1>
</chapter>

View File

@ -110,124 +110,7 @@ mplayer -abs 65536 -delay -0.4 -nobps <replaceable>~/movies/test.avi</replaceabl
<title>Subtitles and OSD</title>
<para>
<application>MPlayer</application> can display subtitles along with movie files.
Currently the following formats are supported:
<itemizedlist>
<listitem><para>VOBsub</para></listitem>
<listitem><para>OGM</para></listitem>
<listitem><para>CC (closed caption)</para></listitem>
<listitem><para>MicroDVD</para></listitem>
<listitem><para>SubRip</para></listitem>
<listitem><para>SubViewer</para></listitem>
<listitem><para>Sami</para></listitem>
<listitem><para>VPlayer</para></listitem>
<listitem><para>RT</para></listitem>
<listitem><para>SSA</para></listitem>
<listitem><para>PJS (Phoenix Japanimation Society)</para></listitem>
<listitem><para>MPsub</para></listitem>
<listitem><para>AQTitle</para></listitem>
<listitem><para>
<ulink url="http://unicorn.us.com/jacosub/">JACOsub</ulink>
</para></listitem>
</itemizedlist>
</para>
<para>
<application>MPlayer</application> can dump the previously listed subtitle
formats (<emphasis role="bold">except the three first</emphasis>) into the
following destination formats, with the given options:
<itemizedlist>
<listitem><para>MPsub: <option>-dumpmpsub</option></para></listitem>
<listitem><para>SubRip: <option>-dumpsrtsub</option></para></listitem>
<listitem><para>MicroDVD: <option>-dumpmicrodvdsub</option></para></listitem>
<listitem><para>JACOsub: <option>-dumpjacosub</option></para></listitem>
<listitem><para>Sami: <option>-dumpsami</option></para></listitem>
</itemizedlist>
</para>
<para>
<application>MEncoder</application> can dump DVD subtitles into
<link linkend="menc-feat-extractsub">VOBsub</link> format.
</para>
<para>
The command line options differ slightly for the different formats:
</para>
<formalpara>
<title>VOBsub subtitles</title>
<para>
VOBsub subtitles consist of a big (some megabytes) <filename>.SUB</filename>
file, and optional <filename>.IDX</filename> and/or <filename>.IFO</filename>
files. If you have files like
<filename><replaceable>sample.sub</replaceable></filename>,
<filename><replaceable>sample.ifo</replaceable></filename> (optional),
<filename><replaceable>sample.idx</replaceable></filename> - you have to pass
<application>MPlayer</application> the <option>-vobsub sample
[-vobsubid <replaceable>id</replaceable>]</option> options
(full path optional). The <option>-vobsubid</option> option is like
<option>-sid</option> for DVDs, you can choose between subtitle tracks
(languages) with it. In case that <option>-vobsubid</option> is omitted,
<application>MPlayer</application> will try to use the languages given by the
<option>-slang</option> option and fall back to the
<systemitem>langidx</systemitem> in the <filename>.IDX</filename> file to set
the subtitle language. If it fails, there will be no subtitles.
</para>
</formalpara>
<formalpara>
<title>Other subtitles</title>
<para>
The other formats consist of a single text file containing timing,
placement and text information. Usage: If you have a file like
<filename><replaceable>sample.txt</replaceable></filename>,
you have to pass the option <option>-sub
<replaceable>sample.txt</replaceable></option> (full path optional).
</para>
</formalpara>
<variablelist>
<title>Adjusting subtitle timing and placement:</title>
<varlistentry>
<term><option>-subdelay <replaceable>sec</replaceable></option></term>
<listitem><para>
Delays subtitles by <option><replaceable>sec</replaceable></option> seconds.
Can be negative. The value is added to movie's time position counter.
</para></listitem>
</varlistentry>
<varlistentry>
<term><option>-subfps <replaceable>RATE</replaceable></option></term>
<listitem><para>
Specify frame/sec rate of subtitle file (float number).
</para></listitem>
</varlistentry>
<varlistentry>
<term><option>-subpos <replaceable>0-100</replaceable></option></term>
<listitem><para>
Specify the position of subtitles.
</para></listitem>
</varlistentry>
</variablelist>
<para>
If you experience a growing delay between the movie and the subtitles when
using a MicroDVD subtitle file, most likely the framerate of the movie and
the subtitle file are different. Please note that the MicroDVD subtitle
format uses absolute frame numbers for its timing, but there is no fps
information in it, and therefore the <option>-subfps</option> option should
be used with this format. If you like to solve this problem permanently,
you have to manually convert the subtitle file framerate.
<application>MPlayer</application> can do this
conversion for you:
<screen>
mplayer -dumpmicrodvdsub -fps <replaceable>subtitles_fps</replaceable> -subfps <replaceable>avi_fps</replaceable> \
-sub <replaceable>subtitle_filename</replaceable> <replaceable>dummy.avi</replaceable>
</screen>
</para>
<para>
About DVD subtitles, read the <link linkend="dvd">DVD</link> section.
OUTDATED CONTENT REMOVED
</para>
</sect1>

File diff suppressed because it is too large Load Diff