diff options
Diffstat (limited to 'DOCS/xml/en/usage.xml')
-rw-r--r-- | DOCS/xml/en/usage.xml | 1501 |
1 files changed, 0 insertions, 1501 deletions
diff --git a/DOCS/xml/en/usage.xml b/DOCS/xml/en/usage.xml deleted file mode 100644 index aa59f05004..0000000000 --- a/DOCS/xml/en/usage.xml +++ /dev/null @@ -1,1501 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- $Revision$ --> -<chapter id="usage"> -<title>Usage</title> - -<sect1 id="commandline"> -<title>Command line</title> - -<para> -<application>MPlayer</application> utilizes a complex playtree. Options passed -on the command line can apply to all files/URLs or just to specific ones -depending on their position. For example -<screen>mplayer -vfm ffmpeg movie1.avi movie2.avi</screen> -will use FFmpeg decoders for both files, but -<screen> -mplayer -vfm ffmpeg <replaceable>movie1.avi</replaceable> <replaceable>movie2.avi</replaceable> -vfm dmo -</screen> -will play the second file with a DMO decoder. -</para> - -<para> -You can group filenames/URLs together using <literal>{</literal> and -<literal>}</literal>. It is useful with option <option>-loop</option>: -<screen>mplayer { 1.avi -loop 2 2.avi } -loop 3</screen> -The above command will play files in this order: 1, 1, 2, 1, 1, 2, 1, 1, 2. -</para> - -<para> -Playing a file: -<synopsis> -<command>mplayer</command><!-- ---> [<replaceable>options</replaceable>]<!-- ---> [<replaceable>path</replaceable>/]<replaceable>filename</replaceable> -</synopsis> -</para> - -<para> -Another way to play a file: -<synopsis> -<command>mplayer</command><!-- ---> [<replaceable>options</replaceable>]<!-- ---> <replaceable>file:///uri-escaped-path</replaceable> -</synopsis> -</para> - -<para> -Playing more files: -<synopsis> -<command>mplayer</command><!-- ---> [<replaceable>default options</replaceable>]<!-- ---> [<replaceable>path</replaceable>/]<replaceable>filename1</replaceable><!-- ---> [<replaceable>options for filename1</replaceable>]<!-- ---> <replaceable>filename2</replaceable><!-- ---> [<replaceable>options for filename2</replaceable>] ... -</synopsis> -</para> - -<para> -Playing VCD: -<synopsis> -<command>mplayer</command> [<replaceable>options</replaceable>]<!-- ---> vcd://<replaceable>trackno</replaceable><!-- ---> [-cdrom-device <replaceable>/dev/cdrom</replaceable>] -</synopsis> -</para> - -<para> -Playing DVD: -<synopsis> -<command>mplayer</command> [<replaceable>options</replaceable>]<!-- ---> dvd://<replaceable>titleno</replaceable><!-- ---> [-dvd-device <replaceable>/dev/dvd</replaceable>] -</synopsis> -</para> - -<para> -Playing from the WWW: -<synopsis> -<command>mplayer</command> [<replaceable>options</replaceable>]<!-- ---> http://<replaceable>site.com/file.asf</replaceable> -</synopsis> -(playlists can be used, too) -</para> - -<para> -Playing from RTSP: -<synopsis> -<command>mplayer</command> [<replaceable>options</replaceable>]<!-- ---> rtsp://<replaceable>server.example.com/streamName</replaceable> -</synopsis> -</para> - -<para> -Examples: -<screen> -mplayer -vo x11 <replaceable>/mnt/Films/Contact/contact2.mpg</replaceable> -mplayer vcd://<replaceable>2</replaceable> -cdrom-device <replaceable>/dev/hdc</replaceable> -mplayer -afm 3 <replaceable>/mnt/DVDtrailers/alien4.vob</replaceable> -mplayer dvd://<replaceable>1</replaceable> -dvd-device <replaceable>/dev/hdc</replaceable> -mplayer -abs 65536 -delay -0.4 -nobps <replaceable>~/movies/test.avi</replaceable><!-- ---></screen> -</para> -</sect1> - - -<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - --> - - -<sect1 id="subosd"> -<title>Subtitles and OSD</title> - -<para> -OUTDATED CONTENT REMOVED -</para> -</sect1> - - -<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - --> - - -<sect1 id="control"> -<title>Control</title> - -<para> -<application>MPlayer</application> has a fully configurable, command -driven, control layer which lets you control -<application>MPlayer</application> with keyboard, mouse, joystick or remote -control (using LIRC). See the man page for the complete list of keyboard controls. -</para> - -<!-- ********** --> - -<sect2 id="ctrl-cfg"> -<title>Controls configuration</title> - -<para> -<application>MPlayer</application> allows you bind any key/button to any -<application>MPlayer</application> command using a simple config file. -The syntax consist of a key name followed by a command. The default config file location is -<filename>$HOME/.mplayer/input.conf</filename> but it can be overridden -using the <option>-input <replaceable>conf</replaceable></option> option -(relative path are relative to <filename>$HOME/.mplayer</filename>). -</para> - -<para> -You can get a full list of supported key names by running -<command>mplayer -input keylist</command> -and a full list of available commands by running -<command>mplayer -input cmdlist</command>. -</para> - -<example id="input_control_file"> -<title>A simple input control file</title> -<programlisting> -## -## MPlayer input control file -## - -RIGHT seek +10 -LEFT seek -10 -- audio_delay 0.100 -+ audio_delay -0.100 -q quit -> pt_step 1 -< pt_step -1 -ENTER pt_step 1 1<!-- ---></programlisting> -</example> -</sect2> - -<!-- ********** --> - -<sect2 id="lirc"> -<title>Control from LIRC</title> - -<para> -Linux Infrared Remote Control - use an easy to build home-brewed IR-receiver, -an (almost) arbitrary remote control and control your Linux box with it! -More about it on the <ulink url="http://www.lirc.org">LIRC homepage</ulink>. -</para> - -<para> -If you have the LIRC package installed, <filename>configure</filename> will -autodetect it. If everything went fine, <application>MPlayer</application> -will print "<systemitem>Setting up LIRC support...</systemitem>" -on startup. If an error occurs it will tell you. If there is no message about -LIRC there is no support compiled in. That's it :-) -</para> - -<para> -The application name for <application>MPlayer</application> is - surprise - -<filename>mplayer</filename>. You can use any <application>MPlayer</application> -commands and even pass more than one command by separating them with -<literal>\n</literal>. -Do not forget to enable the repeat flag in <filename>.lircrc</filename> when -it makes sense (seek, volume, etc). Here is an excerpt from a sample -<filename>.lircrc</filename>: -</para> - -<programlisting> -begin - button = VOLUME_PLUS - prog = mplayer - config = volume 1 - repeat = 1 -end - -begin - button = VOLUME_MINUS - prog = mplayer - config = volume -1 - repeat = 1 -end - -begin - button = CD_PLAY - prog = mplayer - config = pause -end - -begin - button = CD_STOP - prog = mplayer - config = seek 0 1\npause -end<!-- ---></programlisting> - -<para> -If you do not like the standard location for the lirc-config file -(<filename>~/.lircrc</filename>) use the <option>-lircconf -<replaceable>filename</replaceable></option> switch to specify another -file. -</para> -</sect2> - -<!-- ********** --> - -<sect2 id="slave-mode"> -<title>Slave mode</title> - -<para> -The slave mode allows you to build simple frontends to -<application>MPlayer</application>. When run with the -<option>-slave</option> option <application>MPlayer</application> will -read commands separated by a newline (\n) from stdin. -The commands are documented in the -<ulink url="../../tech/slave.txt">slave.txt</ulink> file. -</para> -</sect2> -</sect1> - - -<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - --> - - -<sect1 id="streaming"> -<title>Streaming from network or pipes</title> - -<para> -<application>MPlayer</application> can play files from the network, using the -HTTP, FTP, MMS or RTSP/RTP protocol. -</para> - -<para> -Playing works simply by passing the URL on the command line. -<application>MPlayer</application> honors the <envar>http_proxy</envar> -environment variable, using a proxy if available. Proxies can also be forced: -<screen> -mplayer <replaceable>http_proxy://proxy.micorsops.com:3128/http://micorsops.com:80/stream.asf</replaceable> -</screen> -</para> - -<para> -<application>MPlayer</application> can read from stdin -(<emphasis>not</emphasis> named pipes). This can for example be used to -play from FTP: -<screen> -wget <replaceable>ftp://micorsops.com/something.avi</replaceable> -O - | mplayer - -</screen> -</para> - -<note><para> -It is also recommended to enable <option>-cache</option> when playing -from the network: -<screen> -wget <replaceable>ftp://micorsops.com/something.avi</replaceable> -O - | mplayer -cache 8192 - -</screen> -</para></note> - -<!-- ********** --> - -<sect2 id="streaming-save"> -<title>Saving streamed content</title> - -<para> -Once you succeed in making <application>MPlayer</application> play -your favorite internet stream, you can use the option -<option>-dumpstream</option> to save the stream into a file. -For example: -<screen> -mplayer <replaceable>http://217.71.208.37:8006</replaceable> -dumpstream -dumpfile <replaceable>stream.asf</replaceable> -</screen> -will save the content streamed from -<replaceable>http://217.71.208.37:8006</replaceable> into -<replaceable>stream.asf</replaceable>. -This works with all protocols supported by -<application>MPlayer</application>, like MMS, RTSP, and so forth. -</para> -</sect2> -</sect1> - - -<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - --> - - -<sect1 id="dvd"> -<title>DVD playback</title> - -<para> -For the complete list of available options, please read the man page. -The syntax to play a standard DVD is as follows: -<screen> -mplayer dvd://<replaceable><track></replaceable> [-dvd-device <replaceable><device></replaceable>] -</screen> -</para> - -<para> -Example: -<screen>mplayer dvd://1 -dvd-device /dev/hdc</screen> -</para> - -<para> -If you have compiled <application>MPlayer</application> with dvdnav support, the -syntax is the same, except that you need to use dvdnav:// instead of dvd://. -</para> - -<para> -The default DVD device is <filename>/dev/dvd</filename>. If your setup -differs, make a symlink or specify the correct device on the command -line with the <option>-dvd-device</option> option. -</para> - -<para> -<application>MPlayer</application> uses <systemitem>libdvdread</systemitem> and -<systemitem>libdvdcss</systemitem> for DVD playback and decryption. These two -libraries are contained in the -<application>MPlayer</application> source tree, you do not have -to install them separately. You can also use system-wide versions of the two -libraries, but this solution is not recommended, as it can result in bugs, -library incompatibilities and slower speed. -</para> - -<note><para> -In case of DVD decoding problems, try disabling supermount, or any other such -facilities. Some RPC-2 drives may also require setting the region code. -</para></note> - -<formalpara> -<title>DVD decryption</title> -<para> -DVD decryption is done by <systemitem>libdvdcss</systemitem>. The method -can be specified through the <envar>DVDCSS_METHOD</envar> environment -variable, see the manual page for details. -</para> -</formalpara> - -<!-- ********** --> - -<sect2 id="region_code"> -<title>region code</title> -<para> -DVD drives nowadays come with a nonsensical restriction labeled -<ulink url="http://en.wikipedia.org/wiki/DVD_region_code">region code</ulink>. -This is a scheme to force DVD drives to only accept DVDs produced for one of -the six different regions into which the world was partitioned. How a group -of people can sit around a table, come up with such an idea and expect the -world of the 21st century to bow to their will is beyond anyone's guess. -</para> - -<para> -Drives that enforce region settings through software only are also known as -RPC-1 drives, those that do it in hardware as RPC-2. RPC-2 drives allow -changing the region code five times before it remains fixed. -Under Linux you can use the -<ulink url="http://linvdr.org/projects/regionset/">regionset</ulink> tool -to set the region code of your DVD drive. -</para> - -<para> -Thankfully, it is possible to convert RPC-2 drives into RPC-1 drives through -a firmware upgrade. Feed the model number of your DVD drive into your favorite -search engine or have a look at the forum and download sections of -<ulink url="http://www.rpc1.org/">"The firmware page"</ulink>. -While the usual caveats for firmware upgrades apply, experience with -getting rid of region code enforcement is generally positive. -</para> -</sect2> -</sect1> - - -<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - --> - - -<sect1 id="vcd"> -<title>VCD playback</title> - -<para> -For the complete list of available options, please read the man page. The -Syntax for a standard Video CD (VCD) is as follows: -<screen>mplayer vcd://<replaceable><track></replaceable> [-cdrom-device <replaceable><device></replaceable>]</screen> -Example: -<screen>mplayer vcd://2 -cdrom-device /dev/hdc</screen> -The default VCD device is <filename>/dev/cdrom</filename>. If your setup -differs, make a symlink or specify the correct device on the command line -with the <option>-cdrom-device</option> option. -</para> - -<note><para> -At least Plextor and some Toshiba SCSI CD-ROM drives have horrible performance -reading VCDs. This is because the CDROMREADRAW <systemitem>ioctl</systemitem> -is not fully implemented for these drives. If you have some knowledge of SCSI -programming, please <ulink url="../../tech/patches.txt">help us</ulink> -implement generic SCSI support for VCDs. -</para></note> - -<para> -In the meantime you can extract data from VCDs with -<ulink url="http://ftp.ntut.edu.tw/ftp/OS/Linux/packages/X/viewers/readvcd/">readvcd</ulink> -and play the resulting file with <application>MPlayer</application>. -</para> - -<formalpara> -<title>VCD structure</title> -<para> -A Video CD (VCD) is made up of CD-ROM XA sectors, i.e. CD-ROM mode 2 -form 1 and 2 tracks: -<itemizedlist> -<listitem><para> - The first track is in mode 2 form 2 format which means it uses L2 - error correction. The track contains an ISO-9660 file system with 2048 - bytes/sector. This file system contains VCD metadata information, as - well as still frames often used in menus. MPEG segments for menus can - also be stored in this first track, but the MPEGs have to be broken up - into a series of 150-sector chunks. The ISO-9660 file system may - contain other files or programs that are not essential for VCD - operation. -</para></listitem> - -<listitem><para> - The second and remaining tracks are generally raw 2324 bytes/sector - MPEG (movie) tracks, containing one MPEG PS data packet per - sector. These are in mode 2 form 1 format, so they store more data per - sector at the loss of some error correction. It is also legal to have - CD-DA tracks in a VCD after the first track as well. - On some operating systems there is some trickery that goes on to make - these non-ISO-9660 tracks appear in a file system. On other operating - systems like GNU/Linux this is not the case (yet). Here the MPEG data - <emphasis role="bold">cannot be mounted</emphasis>. As most movies are - inside this kind of track, you should try <option>vcd://2</option> - first. -</para></listitem> - -<listitem><para> - There exist VCD disks without the first track (single track and no file system - at all). They are still playable, but cannot be mounted. -</para></listitem> - -<listitem><para> - The definition of the Video CD standard is called the - Philips "White Book" and it is not generally available online as it - must be purchased from Philips. More detailed information about Video - CDs can be found in the - <ulink url="http://www.vcdimager.org/pub/vcdimager/manuals/0.7/vcdimager.html#SEC4">vcdimager documentation</ulink>. -</para></listitem> -</itemizedlist> -</para> -</formalpara> - -<formalpara> -<title>About .DAT files</title> -<para> -The ~600 MB file visible on the first track of the mounted VCD is not a real -file! It is a so called ISO gateway, created to allow Windows to handle such -tracks (Windows does not allow raw device access to applications at all). -Under Linux you cannot copy or play such files (they contain garbage). Under -Windows it is possible as its iso9660 driver emulates the raw reading of -tracks in this file. To play a .DAT file you need the kernel driver which can -be found in the Linux version of PowerDVD. It has a modified iso9660 file system -(<filename>vcdfs/isofs-2.4.X.o</filename>) driver, which is able to emulate the -raw tracks through this shadow .DAT file. If you mount the disc using their -driver, you can copy and even play .DAT files with -<application>MPlayer</application>. But it will not -work with the standard iso9660 driver of the Linux kernel! Use -<option>vcd://</option> instead. Alternatives for VCD copying are the -new <ulink url="http://www.elis.rug.ac.be/~ronsse/cdfs/">cdfs</ulink> kernel -driver (not part of the official kernel) that shows CD sessions as image files -and <ulink url="http://cdrdao.sf.net/">cdrdao</ulink>, a bit-by-bit -CD grabbing/copying application. -</para> -</formalpara> -</sect1> - - -<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - --> - - -<sect1 id="edl" xreflabel="Edit Decision Lists (EDL)"> -<title>Edit Decision Lists (EDL)</title> - -<para> -The edit decision list (EDL) system allows you to automatically skip -or mute sections of videos during playback, based on a movie specific -EDL configuration file. -</para> - -<para> -This is useful for those who may want to watch a film in "family-friendly" -mode. You can cut out any violence, profanity, Jar-Jar Binks .. from a movie -according to your own personal preferences. Aside from this, there are other -uses, like automatically skipping over commercials in video files you watch. -</para> - -<para> -The EDL file format is pretty bare-bones. There is one command per line that -indicates what to do (skip/mute) and when to do it (using pts in seconds). -</para> - -<!-- ********** --> - -<sect2 id="edl_using"> -<title>Using an EDL file</title> - -<para> -Include the <option>-edl <filename></option> flag when you run -<application>MPlayer</application>, with the name of the EDL file you -want applied to the video. -</para> -</sect2> - -<!-- ********** --> - -<sect2 id="edl_making"> -<title>Making an EDL file</title> - -<para> -The current EDL file format is: -<programlisting>[begin second] [end second] [action]</programlisting> -Where the seconds are floating-point numbers and the action is either -<literal>0</literal> for skip or <literal>1</literal> for mute. Example: -<programlisting> -5.3 7.1 0 -15 16.7 1 -420 422 0 -</programlisting> -This will skip from second 5.3 to second 7.1 of the video, then mute at -15 seconds, unmute at 16.7 seconds and skip from second 420 to second 422 -of the video. These actions will be performed when the playback timer -reaches the times given in the file. -</para> - -<para> -To create an EDL file to work from, use the <option>-edlout -<filename></option> flag. During playback, just hit <keycap>i</keycap> to -mark the beginning and end of a skip block. -A corresponding entry will be written to the file for that time. -You can then go back and fine-tune the generated EDL file as well as -change the default operation which is to skip the block described by each line. -</para> -</sect2> -</sect1> - - -<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - --> - - -<sect1 id="advaudio-surround"> -<title>Surround/Multichannel playback</title> - -<sect2 id="advaudio-surround-DVD"> -<title>DVDs</title> - -<para> -Most DVDs and many other files include surround sound. -<application>MPlayer</application> supports surround playback but does not -enable it by default because stereo equipment is by far more common. To play a -file that has more than two channels of audio use <option>-channels</option>. -For example, to play a DVD with 5.1 audio: -<screen>mplayer dvd://1 -channels 6</screen> -Note that despite the name "5.1" there are actually six discrete channels. -If you have surround sound equipment it is safe to put the -<option>channels</option> option in your <application>MPlayer</application> -configuration file <filename>~/.mplayer/config</filename>. For example, to make -quadraphonic playback the default, add this line: -<programlisting>channels=4</programlisting> -<application>MPlayer</application> will then output audio in four channels when -all four channels are available. -</para> -</sect2> - - -<sect2 id="advaudio-surround-stereoinfour"> -<title>Playing stereo files to four speakers</title> - -<para> -<application>MPlayer</application> does not duplicate any channels by default, -and neither do most audio drivers. If you want to do that manually: -<screen>mplayer <replaceable>filename</replaceable> -af channels=2:2:0:1:0:0</screen> -See the section on -<link linkend="advaudio-channels-copying">channel copying</link> for an -explanation. -</para> -</sect2> - - -<sect2 id="advaudio-surround-passthrough"> -<title>AC-3/DTS Passthrough</title> - -<para> -DVDs usually have surround audio encoded in AC-3 (Dolby Digital) or DTS -(Digital Theater System) format. Some modern audio equipment is capable of -decoding these formats internally. <application>MPlayer</application> can be -configured to relay the audio data without decoding it. This will only work if -you have a S/PDIF (Sony/Philips Digital Interface) jack in your sound card, or -if you are passing audio over HDMI. -</para> - -<para> -If your audio equipment can decode both AC-3 and DTS, you can safely enable -passthrough for both formats. Otherwise, enable passthrough for only the format -your equipment supports. -</para> - -<itemizedlist> -<title>To enable passthrough on the command line:</title> -<listitem><para> - For AC-3 only, use <option>-ac hwac3</option> -</para></listitem> -<listitem><para> - For DTS only, use <option>-ac hwdts</option> -</para></listitem> -<listitem><para> - For both AC-3 and DTS, use <option>-afm hwac3</option> -</para></listitem> -</itemizedlist> - -<itemizedlist> -<title>To enable passthrough in the <application>MPlayer</application> - configuration file: </title> -<listitem><para> - For AC-3 only, use <option>ac=hwac3,</option> -</para></listitem> -<listitem><para> - For DTS only, use <option>ac=hwdts,</option> -</para></listitem> -<listitem><para> - For both AC-3 and DTS, use <option>afm=hwac3</option> -</para></listitem> -</itemizedlist> - -<para> -Note that there is a comma (",") at the end of -<option>ac=hwac3,</option> and <option>ac=hwdts,</option>. This will make -<application>MPlayer</application> fall back on the codecs it normally uses when -playing a file that does not have AC-3 or DTS audio. -<option>afm=hwac3</option> does not need a comma; -<application>MPlayer</application> will fall back anyway when an audio family -is specified. -</para> -</sect2> - - -<sect2 id="hwmpa-surround-passthrough"> -<title>MPEG audio Passthrough</title> - -<para> -Digital TV transmissions (such as DVB and ATSC) and some DVDs usually have -MPEG audio streams (in particular MP2). -Some MPEG hardware decoders such as full-featured DVB cards and DXR2 -adapters can natively decode this format. -<application>MPlayer</application> can be configured to relay the audio data -without decoding it. -</para> - -<para> -To use this codec: -<screen> mplayer -ac hwmpa </screen> -</para> -</sect2> - - -<sect2 id="advaudio-surround-matrix"> -<title>Matrix-encoded audio</title> - -<para> -<emphasis>***TODO***</emphasis> -</para> - -<para> -This section has yet to be written and cannot be completed until somebody -provides sample files for us to test. If you have any matrix-encoded audio -files, know where to find some, or have any information that could be helpful, -please send a message to the -<ulink url="http://lists.mplayerhq.hu/mailman/listinfo/mplayer-docs">MPlayer-DOCS</ulink> -mailing list. Put "[matrix-encoded audio]" in the subject line. -</para> - -<para> -If no files or further information are forthcoming this section will be dropped. -</para> - -<para> -Good links: -<itemizedlist> -<listitem><para> - <ulink url="http://electronics.howstuffworks.com/surround-sound5.htm">http://electronics.howstuffworks.com/surround-sound5.htm</ulink> -</para></listitem> -<listitem><para> - <ulink url="http://www.extremetech.com/article2/0,1697,1016875,00.asp">http://www.extremetech.com/article2/0,1697,1016875,00.asp</ulink> -</para></listitem> -</itemizedlist> -</para> -</sect2> - - -<sect2 id="advaudio-surround-hrtf"> -<title>Surround emulation in headphones</title> - -<para> -<application>MPlayer</application> includes an HRTF (Head Related Transfer -Function) filter based on an -<ulink url="http://sound.media.mit.edu/KEMAR.html">MIT project</ulink> -wherein measurements were taken from microphones mounted on a dummy human head. -</para> - -<para> -Although it is not possible to exactly imitate a surround system, -<application>MPlayer</application>'s HRTF filter does provide more spatially -immersive audio in 2-channel headphones. Regular downmixing simply combines all -the channels into two; besides combining the channels, <option>hrtf</option> -generates subtle echoes, increases the stereo separation slightly, and alters -the volume of some frequencies. Whether HRTF sounds better may be dependent on -the source audio and a matter of personal taste, but it is definitely worth -trying out. -</para> - -<para> -To play a DVD with HRTF: -<screen>mplayer dvd://1 -channels 6 -af hrtf</screen> -</para> - -<para> -<option>hrtf</option> only works well with 5 or 6 channels. Also, -<option>hrtf</option> requires 48 kHz audio. DVD audio is already 48 kHz, but if -you have a file with a different sampling rate that you want to play using -<option>hrtf</option> you must resample it: -<screen> -mplayer <replaceable>filename</replaceable> -channels 6 -af resample=48000,hrtf -</screen> -</para> -</sect2> - - -<sect2 id="advaudio-surround-troubleshooting"> -<title>Troubleshooting</title> - -<para> -If you do not hear any sound out of your surround channels, check your mixer -settings with a mixer program such as <application>alsamixer</application>; -audio outputs are often muted and set to zero volume by default. -</para> -</sect2> -</sect1> - -<!-- ********** --> - -<sect1 id="advaudio-channels"> -<title>Channel manipulation</title> - -<sect2 id="advaudio-channels-general"> -<title>General information</title> - -<para> -Unfortunately, there is no standard for how channels are ordered. The orders -listed below are those of AC-3 and are fairly typical; try them and see if your -source matches. Channels are numbered starting with 0. - -<orderedlist spacing="compact"> -<title>mono</title> - <listitem override="0"><para>center</para></listitem> -</orderedlist> - -<orderedlist spacing="compact"> -<title>stereo</title> - <listitem override="0"><para>left</para></listitem> - <listitem><para>right</para></listitem> -</orderedlist> - -<orderedlist spacing="compact"> -<title>quadraphonic</title> - <listitem override="0"><para>left front</para></listitem> - <listitem><para>right front</para></listitem> - <listitem><para>left rear</para></listitem> - <listitem><para>right rear</para></listitem> -</orderedlist> - -<orderedlist spacing="compact"> -<title>surround 4.0</title> - <listitem override="0"><para>left front</para></listitem> - <listitem><para>right front</para></listitem> - <listitem><para>center rear</para></listitem> - <listitem><para>center front</para></listitem> -</orderedlist> - -<orderedlist spacing="compact"> -<title>surround 5.0</title> - <listitem override="0"><para>left front</para></listitem> - <listitem><para>right front</para></listitem> - <listitem><para>left rear</para></listitem> - <listitem><para>right rear</para></listitem> - <listitem><para>center front</para></listitem> -</orderedlist> - -<orderedlist spacing="compact"> -<title>surround 5.1</title> - <listitem override="0"><para>left front</para></listitem> - <listitem><para>right front</para></listitem> - <listitem><para>left rear</para></listitem> - <listitem><para>right rear</para></listitem> - <listitem><para>center front</para></listitem> - <listitem><para>subwoofer</para></listitem> -</orderedlist> -</para> - -<para> -The <option>-channels</option> option is used to request the number of -channels from the audio decoder. Some audio codecs use the number of specified -channels to decide if downmixing the source is necessary. Note that this does -not always affect the number of output channels. For example, using -<option>-channels 4</option> to play a stereo MP3 file will still result in -2-channel output since the MP3 codec will not produce the extra channels. -</para> - -<para> -The <option>channels</option> audio filter can be used to create or remove -channels and is useful for controlling the number of channels sent to the sound -card. See the following sections for more information on channel manipulation. -</para> -</sect2> - - -<sect2 id="advaudio-channels-mono"> -<title>Playing mono with two speakers</title> - -<para> -Mono sounds a lot better when played through two speakers - especially when -using headphones. Audio files that truly have one channel are automatically -played through two speakers; unfortunately, most files with mono sound are -actually encoded as stereo with one channel silent. The easiest and most -foolproof way to make both speakers output the same audio is the -<option>extrastereo</option> filter: -<screen>mplayer <replaceable>filename</replaceable> -af extrastereo=0</screen> -</para> - -<para> -This averages both channels, resulting in both channels being half as loud as -the original. The next sections have examples of other ways to do this without a -volume decrease, but they are more complex and require different options -depending on which channel to keep. If you really need to maintain the volume, -it may be easier to experiment with the <option>volume</option> filter and find -the right value. For example: -<screen> -mplayer <replaceable>filename</replaceable> -af extrastereo=0,volume=5 -</screen> -</para> -</sect2> - - -<sect2 id="advaudio-channels-copying"> -<title>Channel copying/moving</title> - -<para> -The <option>channels</option> filter can move any or all channels. -Setting up all the suboptions for the <option>channels</option> -filter can be complicated and takes a little care. - -<orderedlist spacing="compact"> -<listitem><para> - Decide how many output channels you need. This is the first suboption. -</para></listitem> -<listitem><para> - Count how many channel moves you will do. This is the second suboption. Each - channel can be moved to several different channels at the same time, but keep - in mind that when a channel is moved (even if to only one destination) the - source channel will be empty unless another channel is moved into it. To copy - a channel, keeping the source the same, simply move the channel into both the - destination and the source. For example: - <programlisting> -channel 2 --> channel 3 -channel 2 --> channel 2<!-- - --></programlisting> -</para></listitem> -<listitem><para> - Write out the channel copies as pairs of suboptions. Note that the first - channel is 0, the second is 1, etc. The order of these suboptions does not - matter as long as they are properly grouped into - <replaceable>source:destination</replaceable> pairs. -</para></listitem> -</orderedlist> -</para> - -<bridgehead>Example: one channel in two speakers</bridgehead> -<para> -Here is an example of another way to play one channel in both speakers. Suppose -for this example that the left channel should be played and the right channel -discarded. Following the steps above: -<orderedlist> -<listitem><para> - In order to provide an output channel for each of the two speakers, the |