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