dvdnav: Support for image highlights for dvdnav menus.
[mplayer/glamo.git] / DOCS / xml / en / faq.xml
blobea54989b8c865c2c33a7d51ca2729a0faf91d755
1 <?xml version="1.0" encoding="utf-8"?>
2 <!-- $Revision$ -->
3 <chapter id="faq" xreflabel="FAQ">
4 <title>Frequently Asked Questions</title>
6 <qandaset defaultlabel="qanda">
8 <qandadiv id="faq-development">
9 <title>Development</title>
11 <qandaentry>
12 <question><para>
13 How do I create a proper patch for <application>MPlayer</application>?
14 </para></question>
15 <answer><para>
16 We made a <ulink url="../../tech/patches.txt">short document</ulink>
17 describing all the necessary details. Please follow the instructions.
18 </para></answer>
19 </qandaentry>
21 <qandaentry>
22 <question><para>
23 How do I translate <application>MPlayer</application> to a new language?
24 </para></question>
25 <answer><para>
26 Read the <ulink url="../../tech/translations.txt">translation HOWTO</ulink>,
27 it should explain everything. You can get further help on the
28 <ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-translations">MPlayer-translations</ulink>
29 mailing list.
30 </para></answer>
31 </qandaentry>
33 <qandaentry>
34 <question><para>
35 How can I support <application>MPlayer</application> development?
36 </para></question>
37 <answer><para>
38 We are more than happy to accept your hardware and software
39 <ulink url="http://www.mplayerhq.hu/donations.html">donations</ulink>.
40 They help us in continuously improving <application>MPlayer</application>.
41 </para></answer>
42 </qandaentry>
44 <qandaentry>
45 <question><para>
46 How can I become an <application>MPlayer</application> developer?
47 </para></question>
48 <answer><para>
49 We always welcome coders and documenters. Read the
50 <ulink url="../../tech/">technical documentation</ulink>
51 to get a first grasp. Then you should subscribe to the
52 <ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-dev-eng">MPlayer-dev-eng</ulink>
53 mailing list and start coding. If you want to help out with the documentation,
54 join the
55 <ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-docs">MPlayer-docs</ulink>
56 mailing list.
57 </para></answer>
58 </qandaentry>
60 <qandaentry>
61 <question><para>
62 Why don't you use autoconf/automake?
63 </para></question>
64 <answer><para>
65 We have a modular, handwritten build system. It does a reasonably good
66 job, so why change? Besides, we dislike the auto* tools, just like
67 <ulink url="http://freshmeat.net/articles/view/889/">other people</ulink>.
68 </para></answer>
69 </qandaentry>
70 </qandadiv>
72 <!-- ********** -->
74 <qandadiv id="faq-compilation-installation">
75 <title>Compilation and installation</title>
77 <qandaentry>
78 <question><para>
79 Compilation fails with an error and <application>gcc</application> bails out
80 with some cryptic message containing the phrase
81 <systemitem>internal compiler error</systemitem> or
82 <systemitem>unable to find a register to spill</systemitem> or
83 <systemitem>can't find a register in class `GENERAL_REGS'
84 while reloading `asm'</systemitem>.
85 </para></question>
86 <answer><para>
87 You have stumbled over a bug in <application>gcc</application>. Please
88 <ulink url="http://gcc.gnu.org/bugs.html">report it to the gcc team</ulink>
89 but not to us. For some reason <application>MPlayer</application> seems to
90 trigger compiler bugs frequently. Nevertheless we cannot fix them and do not
91 add workarounds for compiler bugs to our sources. To avoid this problem,
92 either stick with a compiler version that is known to be reliable and
93 stable, or upgrade frequently.
94 </para></answer>
95 </qandaentry>
97 <qandaentry>
98 <question><para>
99 Are there binary (RPM/Debian) packages of <application>MPlayer</application>?
100 </para></question>
101 <answer><para>
102 See the <link linkend="debian">Debian</link> and <link linkend="rpm">RPM</link>
103 section for details.
104 </para></answer>
105 </qandaentry>
107 <qandaentry>
108 <question><para>
109 How can I build a 32 bit <application>MPlayer</application> on a 64 bit Athlon?
110 </para></question>
111 <answer><para>
112 Try the following configure options:
113 <screen>
114 ./configure --target=i386-linux --cc="gcc -m32" --as="as --32" --with-extralibdir=/usr/lib
115 </screen>
116 </para></answer>
117 </qandaentry>
119 <qandaentry>
120 <question><para>
121 Configure ends with this text, and <application>MPlayer</application> won't compile!
122 <screen>Your gcc does not support even i386 for '-march' and '-mcpu'</screen>
123 </para></question>
124 <answer><para>
125 Your gcc isn't installed correctly, check the <filename>config.log</filename>
126 file for details.
127 </para></answer>
128 </qandaentry>
130 <qandaentry>
131 <question><para>
132 I have a Matrox G200/G400/G450/G550, how do I compile/use the
133 <systemitem>mga_vid</systemitem> driver?
134 </para></question>
135 <answer><para>
136 Read the <link linkend="mga_vid">mga_vid</link> section.
137 </para></answer>
138 </qandaentry>
140 <qandaentry>
141 <question><para>
142 During 'make', <application>MPlayer</application> complains about
143 missing X11 libraries. I don't understand, I <emphasis>do</emphasis>
144 have X11 installed!?
145 </para></question>
146 <answer><para>
147 ... but you don't have the X11 development package installed. Or not correctly.
148 It's called <filename>XFree86-devel*</filename> under Red Hat,
149 <filename>xlibs-dev</filename> under Debian Woody and
150 <filename>libx11-dev</filename> under Debian Sarge. Also check if the
151 <filename class="directory">/usr/X11</filename> and
152 <filename class="directory">/usr/include/X11</filename> symlinks exist.
153 </para></answer>
154 </qandaentry>
156 <qandaentry>
157 <question><para>
158 Building on Mac OS 10.3 leads to several link errors.
159 </para></question>
160 <answer>
161 <para>
162 The link error you're experiencing most likely looks like this:
163 <screen>
164 ld: Undefined symbols:
165 _LLCStyleInfoCheckForOpenTypeTables referenced from QuartzCore expected to be defined in ApplicationServices
166 _LLCStyleInfoGetUserRunFeatures referenced from QuartzCore expected to be defined in ApplicationServices
167 </screen>
168 This problem is the result of Apple developers using 10.4 to compile
169 their software and distributing the binaries to 10.3 users via
170 Software Update.
171 The undefined symbols are present in Mac OS 10.4,
172 but not 10.3.
173 One solution can be to downgrade to QuickTime 7.0.1.
174 Here is a better solution.
175 </para>
176 <para>
177 Get an
178 <ulink url="http://rapidshare.de/files/20281171/CompatFrameworks.tgz.html">older copy of the frameworks</ulink>.
179 This will give you a compressed file that contains the QuickTime
180 7.0.1 Framework and a 10.3.9 QuartzCore Framework.
181 </para>
182 <para>
183 Uncompress the files somewhere that is not in your System folder.
184 (i.e. do not install these frameworks into your
185 <filename class="directory">/System/Library/Frameworks</filename>!
186 Using this older copy is only meant to get around link errors!)
187 <screen>gunzip &lt; CompatFrameworks.tgz | tar xvf -</screen>
188 In config.mak, you should append
189 <systemitem>-F/path/to/where/you/extracted</systemitem>
190 to the <systemitem>OPTFLAGS</systemitem> variable.
191 If you use <application>X-Code</application>, you can just select these
192 frameworks instead of the system ones.
193 </para>
194 <para>
195 The resulting <application>MPlayer</application> binary will actually
196 use the framework that is installed on your system via dynamic links that
197 are resolved at run-time.
198 (You can verify this using <systemitem>otool -l</systemitem>).
199 </para>
200 </answer>
201 </qandaentry>
202 </qandadiv>
204 <!-- ********** -->
206 <qandadiv id="faq-general">
207 <title>General questions</title>
209 <qandaentry>
210 <question><para>
211 Are there any mailing lists on <application>MPlayer</application>?
212 </para></question>
213 <answer><para>
214 Yes. Look at the
215 <ulink url="http://www.mplayerhq.hu/design7/mailing_lists.html">mailing lists section</ulink>
216 of our homepage.
217 </para></answer>
218 </qandaentry>
220 <qandaentry>
221 <question><para>
222 I've found a nasty bug when I tried to play my favorite video!
223 Who should I inform?
224 </para></question>
225 <answer><para>
226 Please read the <link linkend="bugreports">bug reporting guidelines</link>
227 and follow the instructions.
228 </para></answer>
229 </qandaentry>
231 <qandaentry>
232 <question><para>
233 I get a core dump when trying to dump streams, what's wrong?
234 </para></question>
235 <answer><para>
236 Don't panic. Make sure you know where your towel is.</para>
237 <para>
238 Seriously, notice the smiley and start looking for files that end in
239 <filename>.dump</filename>.
240 </para></answer>
241 </qandaentry>
243 <qandaentry>
244 <question><para>
245 When I start playing, I get this message but everything seems fine:
246 <screen>Linux RTC init: ioctl (rtc_pie_on): Permission denied</screen>
247 </para></question>
248 <answer><para>
249 You need a specially set up kernel to use the RTC timing code.
250 For details see the <link linkend="rtc">RTC</link> section of the documentation.
251 </para></answer>
252 </qandaentry>
254 <qandaentry>
255 <question><para>
256 How can I make a screenshot?
257 </para></question>
258 <answer><para>
259 You have to use a video output driver that does not employ an overlay to be
260 able to take a screenshot. Under X11, <option>-vo x11</option> will do, under
261 Windows <option>-vo directx:noaccel</option> works.
262 </para>
263 <para>
264 Alternatively you can run <application>MPlayer</application> with the
265 <systemitem>screenshot</systemitem> video filter
266 (<option>-vf screenshot</option>), and press the <keycap>s</keycap>
267 key to grab a screenshot.
268 </para></answer>
269 </qandaentry>
271 <qandaentry>
272 <question><para>
273 What is the meaning of the numbers on the status line?
274 </para></question>
275 <answer><para>
276 Example:
277 <screen>
278 A: 2.1 V: 2.2 A-V: -0.167 ct: 0.042 57/57 41% 0% 2.6% 0 4 49% 1.00x
279 </screen>
280 <variablelist>
281 <varlistentry>
282   <term><systemitem>A: 2.1</systemitem></term>
283   <listitem><para>audio position in seconds</para></listitem>
284 </varlistentry>
285 <varlistentry>
286   <term><systemitem>V: 2.2</systemitem></term>
287   <listitem><para>video position in seconds</para></listitem>
288 </varlistentry>
289 <varlistentry>
290   <term><systemitem>A-V: -0.167</systemitem></term>
291   <listitem><para>audio-video difference in seconds (delay)</para></listitem>
292 </varlistentry>
293 <varlistentry>
294   <term><systemitem>ct: 0.042</systemitem></term>
295   <listitem><para>total A-V sync correction done</para></listitem>
296 </varlistentry>
297 <varlistentry>
298   <term><systemitem>57/57</systemitem></term>
299   <listitem><para>
300   frames played/decoded (counting from last seek)
301   </para></listitem>
302 </varlistentry>
303 <varlistentry>
304   <term><systemitem>41%</systemitem></term>
305   <listitem><para>
306   video codec CPU usage in percent
307   (for slice rendering and direct rendering this includes video_out)
308   </para></listitem>
309 </varlistentry>
310 <varlistentry>
311   <term><systemitem>0%</systemitem></term>
312   <listitem><para>video_out CPU usage</para></listitem>
313 </varlistentry>
314 <varlistentry>
315   <term><systemitem>2.6%</systemitem></term>
316   <listitem><para>audio codec CPU usage in percent</para></listitem>
317 </varlistentry>
318 <varlistentry>
319   <term><systemitem>0</systemitem></term>
320   <listitem><para>frames dropped to maintain A-V sync</para></listitem>
321 </varlistentry>
322 <varlistentry>
323   <term><systemitem>4</systemitem></term>
324   <listitem><para>
325   current level of image postprocessing (when using <option>-autoq</option>)
326   </para></listitem>
327 </varlistentry>
328 <varlistentry>
329   <term><systemitem>49%</systemitem></term>
330   <listitem><para>
331   current cache size used (around 50% is normal)
332   </para></listitem>
333 </varlistentry>
334 <varlistentry>
335   <term><systemitem>1.00x</systemitem></term>
336   <listitem><para>playback speed as a factor of original speed</para></listitem>
337 </varlistentry>
338 </variablelist>
339 Most of them are for debug purposes, use the <option>-quiet</option>
340 option to make them disappear.
341 You might notice that video_out CPU usage is zero (0%) for some files.
342 This is because it is called directly from the codec and thus cannot
343 be measured separately. If you wish to know the video_out speed, compare
344 the difference when playing the file with <option>-vo null</option> and
345 your usual video output driver.
346 </para></answer>
347 </qandaentry>
349 <qandaentry>
350 <question><para>
351 There are error messages about file not found
352 <filename>/usr/local/lib/codecs/</filename> ...
353 </para></question>
354 <answer><para>
355 Download and install the binary codecs from our
356 <ulink url="http://www.mplayerhq.hu/design7/dload.html">download page</ulink>.
357 </para></answer>
358 </qandaentry>
360 <qandaentry>
361 <question><para>
362 How can I make <application>MPlayer</application> remember the options I
363 use for a particular file, e.g. <filename>movie.avi</filename>?
364 </para></question>
365 <answer><para>
366 Create a file named <filename>movie.avi.conf</filename> with the file-specific
367 options in it and put it in <filename class="directory">~/.mplayer</filename>
368 or in the same directory as the file.
369 </para></answer>
370 </qandaentry>
372 <qandaentry>
373 <question><para>
374 Subtitles are very nice, the most beautiful I've ever seen, but they
375 slow down playing! I know it's unlikely ...
376 </para></question>
377 <answer><para>
378 After running <filename>./configure</filename>,
379 edit <filename>config.h</filename> and replace
380 <systemitem>#undef FAST_OSD</systemitem> with
381 <systemitem>#define FAST_OSD</systemitem>. Then recompile.
382 </para></answer>
383 </qandaentry>
385 <qandaentry>
386 <question><para>
387 How can I run <application>MPlayer</application> in the background?
388 </para></question>
389 <answer><para>
390 Use:
391 <screen>
392 mplayer <replaceable>options</replaceable> <replaceable>filename</replaceable> &lt; /dev/null &amp;
393 </screen>
394 </para></answer>
395 </qandaentry>
396 </qandadiv>
398 <!-- ********** -->
400 <qandadiv id="faq-playback">
401 <title>Playback problems</title>
403 <qandaentry>
404 <question><para>
405 I cannot pinpoint the cause of some strange playback problem.
406 </para></question>
407 <answer><para>
408 Do you have a stray <filename>codecs.conf</filename> file in
409 <filename>~/.mplayer/</filename>, <filename>/etc/</filename>,
410 <filename>/usr/local/etc/</filename> or a similar location? Remove it,
411 an outdated <filename>codecs.conf</filename> file can cause obscure
412 problems and is intended for use only by developers working on codec
413 support. It overrides <application>MPlayer</application>'s internal
414 codec settings, which will wreak havoc if incompatible changes are
415 made in newer program versions. Unless used by experts it is a recipe
416 for disaster in the form of seemingly random and very hard to localize
417 crashes and playback problems. If you still have it somewhere on your
418 system, you should remove it now.
419 </para></answer>
420 </qandaentry>
422 <qandaentry>
423 <question><para>
424 How can I get subtitles to appear on the black margins around a movie?
425 </para></question>
426 <answer><para>
427 Use the <systemitem>expand</systemitem> video filter to increase the
428 area onto which the movie is rendered vertically and place the movie
429 at the top border, for example:
430 <screen>mplayer -vf expand=0:-100:0:0 -slang de dvd://1</screen>
431 </para></answer>
432 </qandaentry>
434 <qandaentry>
435 <question><para>
436 How can I select audio/subtitle tracks from a DVD, OGM, Matroska or NUT file?
437 </para></question>
438 <answer><para>
439 You have to use <option>-aid</option> (audio ID) or <option>-alang</option>
440 (audio language), <option>-sid</option>(subtitle ID) or <option>-slang</option>
441 (subtitle language), for example:
442 <screen>
443 mplayer -alang eng -slang eng <replaceable>example.mkv</replaceable>
444 mplayer -aid 1 -sid 1 <replaceable>example.mkv</replaceable>
445 </screen>
446 To see which ones are available:
447 <screen>
448 mplayer -vo null -ao null -frames 0 -v <replaceable>filename</replaceable> | grep sid
449 mplayer -vo null -ao null -frames 0 -v <replaceable>filename</replaceable> | grep aid
450 </screen>
451 </para></answer>
452 </qandaentry>
454 <qandaentry>
455 <question><para>
456 I'm trying to play a random stream off the internet but it fails.
457 </para></question>
458 <answer><para>
459 Try playing the stream with the <option>-playlist</option> option.
460 </para></answer>
461 </qandaentry>
463 <qandaentry>
464 <question><para>
465 I downloaded a movie off a P2P network and it doesn't work!
466 </para></question>
467 <answer><para>
468 Your file is most probably broken or a fake file. If you got it from
469 a friend, and he says it works, try comparing
470 <application>md5sum</application> hashes.
471 </para></answer>
472 </qandaentry>
474 <qandaentry>
475 <question><para>
476 I'm having trouble getting my subtitles to display, help!!
477 </para></question>
478 <answer><para>
479 Make sure you have installed fonts properly. Run through the steps in the
480 <link linkend="fonts-osd">Fonts and OSD</link> part of the installation
481 section again. If you are using TrueType fonts, verify that you have the
482 <systemitem class="library">FreeType</systemitem> library installed.
483 Other things include checking your subtitles in a text editor or with other
484 players. Also try converting them to another format.
485 </para></answer>
486 </qandaentry>
488 <qandaentry>
489 <question><para>
490 Why doesn't <application>MPlayer</application> work on Fedora Core?
491 </para></question>
492 <answer><para>
493 There is a bad interaction on Fedora between exec-shield,
494 prelink, and any applications which use Windows DLLs
495 (such as <application>MPlayer</application>).
496 </para>
497 <para>
498 The problem is that exec-shield randomizes the load addresses of all the
499 system libraries. This randomization happens at prelink time (once every
500 two weeks).
501 </para>
502 <para>
503 When <application>MPlayer</application> tries to load a Windows DLL it
504 wants to put it at a specific address (0x400000). If an important system
505 library happens to be there already, <application>MPlayer</application>
506 will crash.
507 (A typical symptom would be a segmentation fault when trying
508 to play Windows Media 9 files.)
509 </para>
510 <para>
511 If you run into this problem you have two options:
512 <itemizedlist>
513 <listitem><para>
514   Wait two weeks. It might start working again.
515 </para></listitem>
516 <listitem><para>
517   Relink all the binaries on the system with different
518   prelink options. Here are step by step instructions:
519   </para>
520   <procedure>
521   <step><para>
522     Edit <filename>/etc/syconfig/prelink</filename> and change
523     <programlisting>PRELINK_OPTS=-mR</programlisting> to
524     <programlisting>PRELINK_OPTS="-mR --no-exec-shield"</programlisting>
525   </para></step>
526   <step><para>
527     <command>touch /var/lib/misc/prelink.force</command>
528   </para></step>
529   <step><para>
530     <command>/etc/cron.daily/prelink</command>
531     (This relinks all the applications, and it takes quite a while.)
532   </para></step>
533   <step><para>
534     <command>execstack -s <replaceable>/path/to/</replaceable>mplayer</command>
535     (This turns off exec-shield for the
536     <application>MPlayer</application> binary.)
537   </para></step>
538   </procedure>
539 </listitem>
540 </itemizedlist>
541 </para></answer>
542 </qandaentry>
544 <qandaentry>
545 <question><para>
546 <application>MPlayer</application> dies with
547 <screen>MPlayer interrupted by signal 4 in module: decode_video</screen>
548 </para></question>
549 <answer><para>
550 Don't use <application>MPlayer</application> on a CPU different from the one
551 it was compiled on or recompile with runtime CPU detection
552 (<command>./configure --enable-runtime-cpudetection</command>).
553 </para></answer>
554 </qandaentry>
556 <qandaentry>
557 <question><para>
558 When I try to grab from my tuner, it works, but colors are strange.
559 It's OK with other applications.
560 </para></question>
561 <answer><para>
562 Your card probably reports some colorspaces as supported when in fact
563 it does not support them. Try with YUY2 instead of the
564 default YV12 (see the <link linkend="tv-input">TV</link> section).
565 </para></answer>
566 </qandaentry>
568 <qandaentry>
569 <question><para>
570 I get very strange percentage values (way too big)
571 while playing files on my notebook.
572 </para></question>
573 <answer><para>
574 It's an effect of the power management / power saving system of your notebook
575 (BIOS, not kernel). Plug the external power connector in
576 <emphasis role="bold">before</emphasis> you power on your notebook. You can
577 also try whether
578 <ulink url="http://www.kernel.org/pub/linux/utils/kernel/cpufreq/cpufreq.html">cpufreq</ulink>
579 (a SpeedStep interface for Linux) helps you.
580 </para></answer>
581 </qandaentry>
583 <qandaentry>
584 <question><para>
585 The audio/video gets totally out of sync when I run
586 <application>MPlayer</application> as
587 <systemitem class="username">root</systemitem> on my notebook.
588 It works normal when i run it as a user.
589 </para></question>
590 <answer><para>
591 This is again a power management effect (see above). Plug the external power
592 connector in <emphasis role="bold">before</emphasis> you power on your notebook
593 or make sure you do not use the <option>-rtc</option> option.
594 </para></answer>
595 </qandaentry>
597 <qandaentry>
598 <question><para>
599 While playing a movie it suddenly gets jerky and I get the following message:
600 <screen>Badly interleaved AVI file detected - switching to -ni mode...</screen>
601 </para></question>
602 <answer><para>
603 Badly interleaved files and <option>-cache</option> don't work well together.
604 Try <option>-nocache</option>.
605 </para></answer>
606 </qandaentry>
607 </qandadiv>
609 <!-- ********** -->
611 <qandadiv id="faq-driver">
612 <title>Video/audio driver problems (vo/ao)</title>
614 <qandaentry>
615 <question><para>
616 When I go into fullscreen mode I just get black borders around the image
617 and no real scaling to fullscreen mode.
618 </para></question>
619 <answer><para>
620 Your video output driver does not support scaling in hardware and since
621 scaling in software can be incredibly slow <application>MPlayer</application>
622 does not automatically enable it. Most likely you are using the
623 <systemitem>x11</systemitem> instead of the <systemitem>xv</systemitem>
624 video output driver. Try adding <option>-vo xv</option> to the command
625 line or read the <link linkend="video">video section</link> to find out
626 about alternative video output drivers. The <option>-zoom</option>
627 option explicitly enables software scaling.
628 </para></answer>
629 </qandaentry>
631 <qandaentry>
632 <question><para>
633 I've just installed <application>MPlayer</application>. When I want to
634 open a video file it causes a fatal error:
635 <screen>Error opening/initializing the selected video_out (-vo) device.</screen>
636 How can I solve my problem?
637 </para></question>
638 <answer><para>
639 Just change your video output device. Issue the following command to get
640 a list of available video output drivers:
641 <screen>mplayer -vo help</screen>
642 After you've chosen the correct video output driver, add it to
643 your configuration file. Add
644 <programlisting>
645 vo = <replaceable>selected_vo</replaceable>
646 </programlisting>
647 to <filename>~/.mplayer/config</filename>
648 </para></answer>
649 </qandaentry>
651 <qandaentry>
652 <question><para>
653 I have problems with <replaceable>[your window manager]</replaceable>
654 and fullscreen xv/xmga/sdl/x11 modes ...
655 </para></question>
656 <answer><para>
657 Read the <link linkend="bugreports">bug reporting guidelines</link> and send us
658 a proper bug report.
659 Also try experimenting with the <option>-fstype</option> option.
660 </para></answer>
661 </qandaentry>
663 <qandaentry>
664 <question><para>
665 Audio goes out of sync playing an AVI file.
666 </para></question>
667 <answer><para>
668 Try the <option>-bps</option> or <option>-nobps</option> option. If it does not
669 improve, read the
670 <link linkend="bugreports">bug reporting guidelines</link>
671 and upload the file to FTP.
672 </para></answer>
673 </qandaentry>
675 <qandaentry>
676 <question><para>
677 How can I use <application>dmix</application> with
678 <application>MPlayer</application>?
679 </para></question>
680 <answer><para>
681 After setting up your
682 <ulink url="http://alsa.opensrc.org/index.php?page=DmixPlugin">asoundrc</ulink>
683 you have to use <option>-ao alsa:device=dmix</option>.
684 </para></answer>
685 </qandaentry>
687 <qandaentry>
688 <question><para>
689 I have no sound when playing a video and get error messages similar to this one:
690 <screen>
691 AO: [oss] 44100Hz 2ch Signed 16-bit (Little-Endian)
692 [AO OSS] audio_setup: Can't open audio device /dev/dsp: Device or resource busy
693 Could not open/initialize audio device -> no sound.
694 Audio: no sound
695 Starting playback...
696 </screen>
697 </para></question>
698 <answer><para>
699 Are you running KDE or GNOME with the aRts or ESD sound daemon? Try disabling
700 the sound daemon or use the <option>-ao arts</option> or
701 <option>-ao esd</option> option to make <application>MPlayer</application> use
702 aRts or ESD.
703 You might also be running ALSA without OSS emulation, try loading the ALSA OSS
704 kernel modules or add <option>-ao alsa</option> to your command line to
705 directly use the ALSA audio output driver.
706 </para></answer>
707 </qandaentry>
709 <qandaentry>
710 <question><para>
711 When starting <application>MPlayer</application> under KDE I just get a black
712 screen and nothing happens. After about one minute the video starts playing.
713 </para></question>
714 <answer><para>
715 The KDE aRts sound daemon is blocking the sound device. Either wait until the
716 video starts or disable the aRts daemon in control center. If you want to use
717 aRts sound, specify audio output via our native aRts audio driver
718 (<option>-ao arts</option>). If it fails or isn't compiled in, try SDL
719 (<option>-ao sdl</option>) and make sure your SDL can handle aRts sound. Yet
720 another option is to start <application>MPlayer</application> with artsdsp.
721 </para></answer>
722 </qandaentry>
724 <qandaentry>
725 <question><para>
726 I have A/V sync problems.
727 Some of my AVIs play fine, but some play with double speed!
728 </para></question>
729 <answer><para>
730 You have a buggy sound card/driver. Most likely it's fixed at 44100Hz, and you
731 try to play a file which has 22050Hz audio. Try the
732 <systemitem>resample</systemitem> audio filter.
733 </para></answer>
734 </qandaentry>
736 <qandaentry>
737 <question><para>
738 When I play this movie I get video-audio desync and/or
739 <application>MPlayer</application> crashes with the following message:
740 <screen>
741 Too many (945 in 8390980 bytes) video packets in the buffer!
742 </screen>
743 </para></question>
744 <answer><para>
745 This can have multiple reasons.
746 <itemizedlist>
747 <listitem><para>
748   Your CPU <emphasis>and/or</emphasis> video card <emphasis>and/or</emphasis>
749   bus is too slow. <application>MPlayer</application> displays a message if
750   this is the case (and the dropped frames counter goes up fast).
751 </para></listitem>
752 <listitem><para>
753   If it is an AVI, maybe it has bad interleaving, try the
754   <option>-ni</option> option to work around this.
755   Or it may have a bad header, in this case <option>-nobps</option>
756   and/or <option>-mc 0</option> can help.
757 </para></listitem>
758 <listitem><para>
759   Many FLV files will only play correctly with <option>-correct-pts</option>.
760   Unfortunately <application>MEncoder</application> does not have this option,
761   but you can try setting <option>-fps</option> to the correct value manually
762   if you know it.
763 </para></listitem>
764 <listitem><para>
765   Your sound driver is buggy.
766 </para></listitem>
767 </itemizedlist>
768 </para></answer>
769 </qandaentry>
771 <qandaentry>
772 <question><para>
773 How can I get rid of A/V desynchronization
774 while seeking through RealMedia streams?
775 </para></question>
776 <answer><para>
777 <option>-mc 0.1</option> can help.
778 </para></answer>
779 </qandaentry>
780 </qandadiv>
782 <!-- ********** -->
784 <qandadiv id="faq-dvd">
785 <title>DVD playback</title>
787 <qandaentry>
788 <question><para>
789 What about DVD navigation/menus?
790 </para></question>
791 <answer><para>
792 <application>MPlayer</application> should support DVD menus nowadays.
793 Your mileage may vary.
794 </para></answer>
795 </qandaentry>
797 <qandaentry>
798 <question><para>
799 What about subtitles? Can <application>MPlayer</application> display them?
800 </para></question>
801 <answer><para>
802 Yes. See the <link linkend="dvd">DVD chapter</link>.
803 </para></answer>
804 </qandaentry>
806 <qandaentry>
807 <question><para>
808 How can I set the region code of my DVD-drive? I don't have Windows!
809 </para></question>
810 <answer><para>
811 Use the
812 <ulink url="http://linvdr.org/projects/regionset/">regionset tool</ulink>.
813 </para></answer>
814 </qandaentry>
816 <qandaentry>
817 <question><para>
818 I can't play a DVD, MPlayer hangs or outputs "Encrypted VOB file!" errors.
819 </para></question>
820 <answer><para>
821 CSS decryption code does not work with some DVD drives unless you set
822 the region code appropriately. See the answer to the previous question.
823 </para></answer>
824 </qandaentry>
826 <qandaentry>
827 <question><para>
828 Do I need to be (setuid) root to be able to play a DVD?
829 </para></question>
830 <answer><para>
831 No. However you must have the proper rights
832 on the DVD device entry (in <filename class="directory">/dev/</filename>).
833 </para></answer>
834 </qandaentry>
836 <qandaentry>
837 <question><para>
838 Is it possible to play/encode only selected chapters?
839 </para></question>
840 <answer><para>
841 Yes, try the <option>-chapter</option> option.
842 </para></answer>
843 </qandaentry>
845 <qandaentry>
846 <question><para>
847 My DVD playback is sluggish!
848 </para></question>
849 <answer><para>
850 Use the <option>-cache</option> option (described in the man page) and try
851 enabling DMA for the DVD drive with the <command>hdparm</command> tool.
852 </para></answer>
853 </qandaentry>
855 <qandaentry>
856 <question><para>
857 I copied a DVD using vobcopy. How do I play/encode it from my hard disk?
858 </para></question>
859 <answer><para>
860 Use the <option>-dvd-device</option> option to refer to the directory
861 that contains the files:
862 <screen>
863 mplayer dvd://1 -dvd-device <replaceable>/path/to/directory</replaceable>
864 </screen>
865 </para></answer>
866 </qandaentry>
867 </qandadiv>
870 <qandadiv id="faq-features">
871 <title>Feature requests</title>
873 <qandaentry>
874 <question><para>
875 If <application>MPlayer</application> is paused and I try to seek or press any
876 key at all, <application>MPlayer</application> ceases to be paused.
877 I would like to be able to seek in the paused movie.
878 </para></question>
879 <answer><para>
880 This is very tricky to implement without losing A/V synchronization.
881 All attempts have failed so far, but patches are welcome.
882 </para></answer>
883 </qandaentry>
885 <qandaentry>
886 <question><para>
887 I'd like to seek +/- 1 frame instead of 10 seconds.
888 </para></question>
889 <answer><para>
890 You can step forward one frame by pressing <keycap>.</keycap>.
891 If the movie was not paused it will be paused afterwards
892 (see the man page for details).
893 Stepping backwards is unlikely to be implemented anytime soon.
894 </para></answer>
895 </qandaentry>
896 </qandadiv>
898 <!-- ********** -->
900 <qandadiv id="faq-encoding">
901 <title>Encoding</title>
903 <qandaentry>
904 <question><para>
905 How can I encode?
906 </para></question>
907 <answer><para>
908 Read the <link linkend="mencoder"><application>MEncoder</application></link>
909 section.
910 </para></answer>
911 </qandaentry>
913 <qandaentry>
914 <question><para>
915 How can I dump a full DVD title into a file?
916 </para></question>
917 <answer><para>
918 Once you have selected your title, and made sure it plays fine with
919 <application>MPlayer</application>, use the option <option>-dumpstream</option>.
920 For example:
921 <screen>
922 mplayer dvd://5 -dumpstream -dumpfile <replaceable>dvd_dump.vob</replaceable>
923 </screen>
924 will dump the 5th title of the DVD into the file
925 <replaceable>dvd_dump.vob</replaceable>
926 </para></answer>
927 </qandaentry>
929 <qandaentry>
930 <question><para>
931 How can I create (S)VCDs automatically?
932 </para></question>
933 <answer><para>
934 Try the <filename>mencvcd.sh</filename> script from the
935 <filename class="directory">TOOLS</filename> subdirectory.
936 With it you can encode DVDs or other movies to VCD or SVCD format
937 and even burn them directly to CD.
938 </para></answer>
939 </qandaentry>
941 <qandaentry>
942 <question><para>
943 How can I create (S)VCDs?
944 </para></question>
945 <answer><para>
946 Newer versions of <application>MEncoder</application> can directly
947 generate MPEG-2 files that can be used as a base to create a VCD or SVCD and
948 are likely to be playable out of the box on all platforms (for example,
949 to share a video from a digital camcorder with your computer-illiterate
950 friends).
951 Please read
952 <link linkend="menc-feat-vcd-dvd">Using MEncoder to create VCD/SVCD/DVD-compliant files</link>
953 for more details.
954 </para></answer>
955 </qandaentry>
957 <qandaentry>
958 <question><para>
959 How can I join two video files?
960 </para></question>
961 <answer><para>
962 MPEG files can be concatenated into a single file with luck.
963 For AVI files, you can use <application>MEncoder</application>'s
964 multiple file support like this:
965 <screen>
966 mencoder -ovc copy -oac copy -o <replaceable>out.avi</replaceable> <replaceable>file1.avi</replaceable> <replaceable>file2.avi</replaceable>
967 </screen>
968 This will only work if the files are of the same resolution
969 and use the same codec.
970 You can also try
971 <ulink url="http://fixounet.free.fr/avidemux/">avidemux</ulink> and
972 <application>avimerge</application> (part of the
973 <ulink url="http://www.transcoding.org/">transcode</ulink>
974 tool set).
975 </para></answer>
976 </qandaentry>
978 <qandaentry>
979 <question><para>
980 How can I fix AVI files with a broken index or bad interleaving?
981 </para></question>
982 <answer><para>
983 To avoid having to use <option>-idx</option> to be able to seek in
984 AVI files with a broken index or <option>-ni</option> to play AVI
985 files with bad interleaving, use the command
986 <screen>
987 mencoder <replaceable>input.avi</replaceable> -idx -ovc copy -oac copy -o <replaceable>output.avi</replaceable>
988 </screen>
989 to copy the video and audio streams into a new AVI file while
990 regenerating the index and correctly interleaving the data.
991 Of course this cannot fix possible bugs in the video and/or audio streams.
992 </para></answer>
993 </qandaentry>
995 <qandaentry>
996 <question><para>
997 How can I fix the aspect ratio of an AVI file?
998 </para></question>
999 <answer><para>
1000 You can do such a thing thanks to <application>MEncoder</application>'s
1001 <option>-force-avi-aspect</option> option, which overrides the aspect
1002 stored in the AVI OpenDML vprp header option. For example:
1003 <screen>
1004 mencoder <replaceable>input.avi</replaceable> -ovc copy -oac copy -o <replaceable>output.avi</replaceable> -force-avi-aspect 4/3
1005 </screen>
1006 </para></answer>
1007 </qandaentry>
1009 <qandaentry>
1010 <question><para>
1011 How can I backup and encode a VOB file with a broken beginning?
1012 </para></question>
1013 <answer><para>
1014 The main problem when you want to encode a VOB file which is corrupted
1015 <footnote id='fn-corrupted-files-or-copy-protection'><para>
1016 To some extent, some forms of copy protection used in DVDs can be
1017 assumed to be content corruption.
1018 </para></footnote>
1019 is that it will be hard to get an encode with perfect A/V sync.
1020 One workaround is to just shave off the corrupted part and encode just the
1021 clean part.
1022 First you need to find where the clean part starts:
1023 <screen>
1024 mplayer <replaceable>input.vob</replaceable> -sb <replaceable>nb_of_bytes_to_skip</replaceable>
1025 </screen>
1026 Then you can create a new file which contains just the clean part:
1027 <screen>
1028 dd if=<replaceable>input.vob</replaceable> of=<replaceable>output_cut.vob</replaceable> skip=1 ibs=<replaceable>nb_of_bytes_to_skip</replaceable>
1029 </screen>
1030 </para></answer>
1031 </qandaentry>
1033 <qandaentry>
1034 <question><para>
1035 I can't encode DVD subtitles into the AVI!
1036 </para></question>
1037 <answer><para>
1038 You have to properly specify the <option>-sid</option> option.
1039 </para></answer>
1040 </qandaentry>
1042 <qandaentry>
1043 <question><para>
1044 How can I encode only selected chapters from a DVD?
1045 </para></question>
1046 <answer><para>
1047 Use the <option>-chapter</option> option correctly,
1048 like: <option>-chapter 5-7</option>.
1049 </para></answer>
1050 </qandaentry>
1052 <qandaentry>
1053 <question><para>
1054 I'm trying to work with 2GB+ files on a VFAT file system. Does it work?
1055 </para></question>
1056 <answer><para>
1057 No, VFAT doesn't support 2GB+ files.
1058 </para></answer>
1059 </qandaentry>
1061 <qandaentry>
1062 <question><para>
1063 What is the meaning of the numbers on the status line
1064 during the encoding process?
1065 </para></question>
1066 <answer><para>
1067 Example:
1068 <screen>
1069 Pos: 264.5s   6612f ( 2%)  7.12fps Trem: 576min 2856mb  A-V:0.065 [2126:192]
1070 </screen>
1071 <variablelist>
1072   <varlistentry>
1073   <term><systemitem>Pos: 264.5s</systemitem></term>
1074   <listitem><para>time position in the encoded stream</para></listitem>
1075 </varlistentry>
1076 <varlistentry>
1077   <term><systemitem>6612f</systemitem></term>
1078   <listitem><para>number of video frames encoded</para></listitem>
1079 </varlistentry>
1080 <varlistentry>
1081   <term><systemitem>( 2%)</systemitem></term>
1082   <listitem><para>portion of the input stream encoded</para></listitem>
1083 </varlistentry>
1084 <varlistentry>
1085   <term><systemitem>7.12fps</systemitem></term>
1086   <listitem><para>encoding speed</para></listitem>
1087 </varlistentry>
1088 <varlistentry>
1089   <term><systemitem>Trem: 576min</systemitem></term>
1090   <listitem><para>estimated remaining encoding time</para></listitem>
1091 </varlistentry>
1092 <varlistentry>
1093   <term><systemitem>2856mb</systemitem></term>
1094   <listitem><para>estimated size of the final encode</para></listitem>
1095 </varlistentry>
1096 <varlistentry>
1097   <term><systemitem>A-V:0.065</systemitem></term>
1098   <listitem><para>current delay between audio and video streams</para></listitem>
1099 </varlistentry>
1100 <varlistentry>
1101   <term><systemitem>[2126:192]</systemitem></term>
1102   <listitem><para>
1103   average video bitrate (in kb/s) and average audio bitrate (in kb/s)
1104   </para></listitem>
1105 </varlistentry>
1106 </variablelist>
1107 </para></answer>
1108 </qandaentry>
1110 <qandaentry>
1111 <question><para>
1112 Why is the recommended bitrate printed by <application>MEncoder</application>
1113 negative?
1114 </para></question>
1115 <answer><para>
1116 Because the bitrate you encoded the audio with is too large to fit the
1117 movie on any CD. Check if you have libmp3lame installed properly.
1118 </para></answer>
1119 </qandaentry>
1121 <qandaentry>
1122 <question><para>
1123 I can't encode an ASF file to AVI/MPEG-4 (DivX) because it uses 1000 fps.
1124 </para></question>
1125 <answer><para>
1126 Since ASF uses variable framerate but AVI uses a fixed one, you
1127 have to set it by hand with the <option>-ofps</option> option.
1128 </para></answer>
1129 </qandaentry>
1131 <qandaentry>
1132 <question><para>
1133 How can I put subtitles in the output file?
1134 </para></question>
1135 <answer><para>
1136 Just pass the <option>-sub &lt;filename&gt;</option> (or <option>-sid</option>,
1137 respectively) option to <application>MEncoder</application>.
1138 </para></answer>
1139 </qandaentry>
1141 <qandaentry>
1142 <question><para>
1143 How do I encode only sound from a music video?
1144 </para></question>
1145 <answer><para>
1146 It's not possible directly, but you can try this (note the
1147 <emphasis role="bold">&amp;</emphasis> at the end of
1148 <command>mplayer</command> command):
1149 <screen>
1150 mkfifo <replaceable>encode</replaceable>
1151 mplayer -ao pcm -aofile <replaceable>encode</replaceable> dvd://1 &amp;
1152 lame <replaceable>your_opts</replaceable> <replaceable>encode</replaceable> <replaceable>music.mp3</replaceable>
1153 rm <replaceable>encode</replaceable>
1154 </screen>
1155 This allows you to use any encoder, not only <application>LAME</application>,
1156 just replace <command>lame</command> with your favorite audio encoder in the
1157 above command.
1158 </para></answer>
1159 </qandaentry>
1161 <qandaentry>
1162 <question><para>
1163 Why do third-party players fail to play MPEG-4 movies encoded by
1164 <application>MEncoder</application> versions later than 1.0pre7?
1165 </para></question>
1166 <answer><para>
1167 <systemitem class="library">libavcodec</systemitem>, the native MPEG-4
1168 encoding library usually shipped with <application>MEncoder</application>,
1169 used to set the FourCC to 'DIVX' when encoding MPEG-4 videos
1170 (the FourCC is an AVI tag to identify the software used to encode and
1171 the intended software to use for decoding the video).
1172 This led many people to think that
1173 <systemitem class="library">libavcodec</systemitem>
1174 was a DivX encoding library, when in fact it is a completely different
1175 MPEG-4 encoding library which implements the MPEG-4 standard much
1176 better than DivX does.
1177 Therefore, the new default FourCC used by
1178 <systemitem class="library">libavcodec</systemitem> is 'FMP4', but you
1179 may override this behavior using <application>MEncoder</application>'s
1180 <option>-ffourcc</option> option.
1181 You may also change the FourCC of existing files in the same way:
1182 <screen>
1183 mencoder <replaceable>input.avi</replaceable> -o <replaceable>output.avi</replaceable> -ffourcc XVID
1184 </screen>
1185 Note that this will set the FourCC to XVID rather than DIVX.
1186 This is recommended as DIVX FourCC means DivX4, which is a very basic
1187 MPEG-4 codec, whereas DX50 and XVID both mean full MPEG-4 (ASP).
1188 Therefore, if you change the FourCC to DIVX, some bad software or
1189 hardware players may choke on some advanced features that
1190 <systemitem class="library">libavcodec</systemitem> supports, but DivX
1191 doesn't; on the other hand <systemitem class="library">Xvid</systemitem>
1192 is closer to <systemitem class="library">libavcodec</systemitem> in
1193 terms of functionality, and is supported by all decent players.
1194 </para></answer>
1195 </qandaentry>
1197 <qandaentry>
1198 <question><para>
1199 How can I encode an audio only file?
1200 </para></question>
1201 <answer><para>
1202 Use <filename>aconvert.sh</filename> from the
1203 <filename class="directory">TOOLS</filename>
1204 subdirectory in the MPlayer source tree.
1205 </para></answer>
1206 </qandaentry>
1208 <qandaentry>
1209 <question><para>
1210 How can I play subtitles embedded in AVI?
1211 </para></question>
1212 <answer><para>
1213 Use <filename>avisubdump.c</filename> from the
1214 <filename class="directory">TOOLS</filename> subdirectory or read
1215 <ulink url="http://xlife.zuavra.net/curse/0012/">this document about extracting/demultiplexing subtitles embedded in OpenDML AVI files</ulink>.
1216 </para></answer>
1217 </qandaentry>
1219 <qandaentry>
1220 <question><para>
1221 MEncoder won't...
1222 </para></question>
1223 <answer><para>
1224 Have a look at the <filename class="directory">TOOLS</filename>
1225 subdirectory for a collection of random scripts and hacks.
1226 <filename>TOOLS/README</filename> contains documentation.
1227 </para></answer>
1228 </qandaentry>
1229 </qandadiv>
1231 </qandaset>
1233 </chapter>