Mercurial > mplayer.hg
annotate DOCS/sound.html @ 6960:87deea511b1f
continuing paragraph reformatting
author | gabucino |
---|---|
date | Sat, 10 Aug 2002 20:26:43 +0000 |
parents | 027d2140942b |
children | 916f62dd0910 |
rev | line source |
---|---|
6403
c0f189e49ee4
Background color now set by CSS, added doctype and default character set,
diego
parents:
6393
diff
changeset
|
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> |
1612 | 2 <HTML> |
4982
6cb9d9a1716d
HTML: different font handling - idea from new hp dezign
gabucino
parents:
4928
diff
changeset
|
3 |
6cb9d9a1716d
HTML: different font handling - idea from new hp dezign
gabucino
parents:
4928
diff
changeset
|
4 <HEAD> |
6882
f3f87f6bf5cf
Added a uniform title: something - MPlayer - The Movie Player for Linux.
diego
parents:
6583
diff
changeset
|
5 <TITLE>Sound - MPlayer - The Movie Player for Linux</TITLE> |
6391 | 6 <LINK REL="stylesheet" TYPE="text/css" HREF="default.css"> |
6403
c0f189e49ee4
Background color now set by CSS, added doctype and default character set,
diego
parents:
6393
diff
changeset
|
7 <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1"> |
4982
6cb9d9a1716d
HTML: different font handling - idea from new hp dezign
gabucino
parents:
4928
diff
changeset
|
8 </HEAD> |
6cb9d9a1716d
HTML: different font handling - idea from new hp dezign
gabucino
parents:
4928
diff
changeset
|
9 |
6403
c0f189e49ee4
Background color now set by CSS, added doctype and default character set,
diego
parents:
6393
diff
changeset
|
10 <BODY> |
1704 | 11 |
1612 | 12 |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
13 <P><B><A NAME="audio">2.3.2 Audio output devices</A></B></P> |
1612 | 14 |
1892 | 15 <P><B>MPlayer</B>'s audio interface is called <I>libao2</I>. It currently |
5765 | 16 contains these drivers:</P> |
1892 | 17 |
1905 | 18 <TABLE BORDER=0> |
19 | |
6393 | 20 <TR><TD COLSPAN=4><P><B>General:</B></P></TD></TR> |
1905 | 21 |
6393 | 22 <TR><TD> </TD><TD VALIGN=top>oss</TD><TD> </TD><TD>OSS (ioctl) driver (supports hardware AC3 passthrough)</TD></TR> |
23 <TR><TD></TD><TD VALIGN=top>sdl</TD><TD></TD><TD>SDL driver (supports up/downsampling, <B>ESD</B>, <B>ARTS</B> etc)</TD></TR> | |
24 <TR><TD></TD><TD VALIGN=top>nas</TD><TD></TD><TD>NAS (Network Audio System) driver</TD></TR> | |
25 <TR><TD></TD><TD VALIGN=top>alsa5</TD><TD></TD><TD>native ALSA 0.5 driver</TD></TR> | |
6583 | 26 <TR><TD></TD><TD VALIGN=top>alsa9</TD><TD></TD><TD>native ALSA 0.9 driver (supports hardware AC3 passthrough)</TD></TR> |
6393 | 27 <TR><TD></TD><TD VALIGN=top>sun</TD><TD></TD><TD>SUN audio driver (<CODE>/dev/audio</CODE>) for BSD and Solaris8 users</TD></TR> |
28 <TR><TD></TD><TD VALIGN=top>arts</TD><TD></TD><TD>native ARTS driver (mostly for KDE users)</TD></TR> | |
1905 | 29 |
30 </TABLE> | |
1612 | 31 |
5765 | 32 <P>Fact is, Linux sound card drivers have compatibility problems. |
33 It <B>may</B> take a while to find your optimal settings.</P> | |
34 | |
35 <UL> | |
6960 | 36 <LI>If you have an OSS driver, first try <CODE>-ao oss</CODE> (this is the |
37 default). If you experience glitches, halts or anything out of the | |
38 ordinary, try <CODE>-ao sdl</CODE> (NOTE: you need to have SDL libraries | |
39 and header files installed). The SDL audio driver helps in a lot of cases | |
40 and also supports ESD, ARTS, and up/downsampling. (ESD is the sound daemon | |
41 from GNOME, ARTS is from KDE.)</LI> | |
42 <LI>If you have ALSA version 0.5, then you almost always have to use | |
43 <CODE>-ao alsa5</CODE> , since ALSA 0.5 has buggy OSS emulation code, and | |
44 will <B>crash MPlayer</B> with a message like this:<BR> | |
45 <CODE>DEMUXER: Too many (945 in 8390980 bytes) video packets in the buffer!</CODE></LI> | |
46 <LI>If you have ALSA version 0.9 you may choose between <CODE>-ao oss</CODE> | |
47 and <CODE>-ao sdl</CODE>. You can also use <CODE>-ao alsa9</CODE>. It | |
48 works, but there may be problems like lost sync and disappearing | |
49 audio.</LI> | |
5765 | 50 </UL> |
1892 | 51 |
52 <P>On <B>Solaris/FreeBSD</B> systems, use the SUN audio driver with the | |
6960 | 53 <CODE>-ao sun</CODE> option, otherwise neither video nor audio will work.</P> |
1892 | 54 |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
55 <P><B><A NAME="experiences">2.3.2.1 Sound Card experiences, recommendations</A></B></P> |
1612 | 56 |
5765 | 57 <TABLE BORDER=0 WIDTH="100%"> |
6393 | 58 <TR><TD COLSPAN=3><B>VIA onboard chipset (via82cxxx) 48kHz only</B></TD><TR> |
59 <TD></TD><TD>Driver:</TD><TD> from <A HREF="http://sourceforge.net/project/showfiles.php?group_id=3242&release_id=59602">here</A></TD><TR> | |
3190 | 60 |
6393 | 61 <TD COLSPAN=3><B>Aureal Vortex 2</B></TD><TR> |
62 <TD> </TD><TD>OSS:</TD><TD>no driver</TD><TR> | |
63 <TD></TD><TD>OSS/Pro:</TD><TD>OK</TD><TR> | |
64 <TD></TD><TD>ALSA:</TD><TD>no driver</TD><TR> | |
65 <TD></TD><TD>Max kHz:</TD><TD>48</TD><TR> | |
66 <TD></TD><TD>Driver:</TD><TD><A HREF="http://aureal.sourceforge.net">aureal.sourceforge.net</A></TD><TR> | |
67 <TD></TD><TD>Driver2:</TD><TD> from <A HREF="http://makacs.poliod.hu/~pontscho/aureal/au88xx-1.1.3.tar.bz2">here</A><BR> | |
2999 | 68 (<I>buffer size increased to 32k</I>)</TD><TR> |
1612 | 69 |
6393 | 70 <TD COLSPAN=3><B>GUS PnP</B></TD><TR> |
71 <TD></TD><TD>OSS:</TD><TD>no driver</TD><TR> | |
72 <TD></TD><TD>OSS/Pro:</TD><TD>OK</TD><TR> | |
73 <TD></TD><TD>ALSA:</TD><TD>OK</TD><TR> | |
74 <TD></TD><TD>Max kHz:</TD><TD>48</TD><TR> | |
1682 | 75 |
6393 | 76 <TD COLSPAN=3><B>SB Live!</B></TD><TR> |
77 <TD></TD><TD>OSS:</TD><TD>Analog OK, SP/DIF not working</TD><TR> | |
78 <TD></TD><TD>ALSA:</TD><TD>Both OK</TD><TR> | |
79 <TD></TD><TD>Max kHz:</TD><TD>192</TD><TR> | |
1612 | 80 |
6393 | 81 <TD COLSPAN=3><B>SB AWE 64</B></TD><TR> |
82 <TD></TD><TD>OSS:</TD><TD>max 44kHz</TD><TR> | |
83 <TD></TD><TD>ALSA:</TD><TD>48kHz sounds bad</TD><TR> | |
84 <TD></TD><TD>Max kHz:</TD><TD>48</TD><TR> | |
1892 | 85 |
6393 | 86 <TD COLSPAN=3><B>Gravis UltraSound ACE</B></TD><TR> |
87 <TD></TD><TD>OSS:</TD><TD>not OK</TD><TR> | |
88 <TD></TD><TD>ALSA:</TD><TD>OK</TD><TR> | |
89 <TD></TD><TD>Max kHz:</TD><TD>44</TD><TR> | |
1612 | 90 |
6393 | 91 <TD COLSPAN=3><B>Gravis UltraSound MAX</B></TD><TR> |
92 <TD></TD><TD>OSS:</TD><TD>OK</TD><TR> | |
93 <TD></TD><TD>ALSA:</TD><TD>OK (?)</TD><TR> | |
94 <TD></TD><TD>Max kHz:</TD><TD>48</TD><TR> | |
1612 | 95 |
6393 | 96 <TD COLSPAN=3><B>ESS 688</B></TD><TR> |
97 <TD></TD><TD>OSS:</TD><TD>OK</TD><TR> | |
98 <TD></TD><TD>ALSA:</TD><TD>OK (?)</TD><TR> | |
99 <TD></TD><TD>Max kHz:</TD><TD>48</TD><TR> | |
1612 | 100 |
6393 | 101 <TD COLSPAN=3><B>C-Media cards (which ones?)</B></TD><TR> |
102 <TD></TD><TD>OSS:</TD><TD>not OK (hissing) (?)</TD><TR> | |
103 <TD></TD><TD>ALSA:</TD><TD>OK (?)</TD><TR> | |
104 <TD></TD><TD>Max kHz:</TD><TD>?</TD><TR> | |
1612 | 105 |
6393 | 106 <TD COLSPAN=3><B>Yamaha cards (*ymf*)</B></TD><TR> |
107 <TD></TD><TD>OSS:</TD><TD>not OK (?) (maybe <CODE>-ao sdl</CODE>)</TD><TR> | |
108 <TD></TD><TD>ALSA:</TD><TD>OK only with ALSA 0.5 with OSS emulation <B>AND</B> <CODE>-ao sdl</CODE> (!) (?)</TD><TR> | |
109 <TD></TD><TD>Max kHz:</TD><TD>?</TD><TR> | |
1612 | 110 |
6393 | 111 <TD COLSPAN=3><B>Cards with envy24 chips (like Terratec EWS88MT)</B></TD><TR> |
112 <TD></TD><TD>OSS:</TD><TD>?</TD><TR> | |
113 <TD></TD><TD>OSS/Pro:</TD><TD>OK</TD><TR> | |
114 <TD></TD><TD>ALSA:</TD><TD>?</TD><TR> | |
115 <TD></TD><TD>Max kHz:</TD><TD>?</TD><TR> | |
3438 | 116 |
6393 | 117 <TD COLSPAN=3><B>PC Speaker or DAC</B></TD><TR> |
118 <TD></TD><TD>OSS:</TD><TD>OK (Use the SDL driver: <CODE>-ao sdl</CODE>)</TD><TR> | |
119 <TD></TD><TD>ALSA:</TD><TD>no driver</TD><TR> | |
120 <TD></TD><TD>Max kHz:</TD><TD>The driver emulates 44.1, maybe more.</TD><TR> | |
121 <TD></TD><TD>Driver:</TD><TD><A HREF="ftp://ftp.infradead.org/pub/pcsp">ftp://ftp.infradead.org/pub/pcsp</A></TD> | |
5765 | 122 </TABLE> |
1612 | 123 |
5765 | 124 <UL> |
6960 | 125 <LI>On Linux, a 2.4.x kernel is highly recommended. Kernel 2.2 is not tested.</LI> |
126 <LI>If sound clicks when playing from CD-ROM, turn on IRQ unmasking, e.g. | |
127 <CODE>hdparm -u1 /dev/cdrom</CODE> (<CODE>man hdparm</CODE>). This is | |
128 generally beneficial and described more detailed in the <A | |
129 HREF="cd-dvd.html#drives">CD-ROM section</A>.</LI> | |
130 <LI>Sharing your sound card with another application like XMMS is <B>strongly | |
131 discouraged</B>! If the other sound application is using ESD, start | |
132 <B>MPlayer</B> with the <CODE>-vo sdl:esd</CODE> option to combine both | |
133 sound streams! In fact, the option <CODE>-vo sdl:esd</CODE> could be used | |
134 with ESD even when playing <B>Mplayer</B> alone.</LI> | |
135 <LI>Feedback to this document is welcome. Please tell us how <B>MPlayer</B> | |
136 and your sound card(s) worked together.</LI> | |
5765 | 137 </UL> |
1612 | 138 |
3671 | 139 |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
140 <P><B><A NAME="plugins">2.3.2.2 Audio plugins</A></B></P> |
3671 | 141 |
4508 | 142 <P><B>MPlayer</B> has support for audio plugins. Audio plugins can be used for |
143 changing the properties of the audio data before the sound reaches the sound | |
5765 | 144 card. They are enabled using the <CODE>-aop</CODE> switch which takes a |
145 <CODE>list=plugin1,plugin2,...</CODE> argument. The <CODE>list</CODE> argument | |
146 is required and determines which plugins should be used and in which order they | |
147 should be executed. Example: | |
4508 | 148 </P> |
149 | |
150 <P> <CODE>mplayer media.avi -aop list=resample,format</CODE></P> | |
151 | |
152 <P>would run the sound through the resampling plugin followed by the format | |
153 plugin. | |
154 </P> | |
155 | |
5765 | 156 <P>The plugins can also have switches that change their behavior. These |
4508 | 157 switches are explained in detail in the sections below. A plugin will execute |
5765 | 158 using default settings if its switches are omitted. Here is an example of how |
159 to use plugins in combination with plugin specific switches: | |
4508 | 160 </P> |
161 | |
162 <P> <CODE>mplayer media.avi -aop | |
5765 | 163 list=resample,format:fout=44100:format=0x8</CODE> |
4508 | 164 </P> |
165 | |
166 <P>would set the output frequency of the resample plugin to 44100Hz and the | |
167 output format of the format plugin to AFMT_U8. | |
168 </P> | |
169 | |
170 <P>Currently audio plugins can not be used in <B>MEncoder</B>.</P> | |
171 | |
172 | |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
173 <P><B><A NAME="resample">2.3.2.2.1 Up/Downsampling</A></B></P> |
3671 | 174 |
5765 | 175 <P><B>MPlayer</B> fully supports up/downsampling of the sound. This plugin can |
176 be used if you have a fixed frequency sound card or if you are | |
177 stuck with an old sound card that is only capable of max 44.1kHz. | |
4508 | 178 Limitations in your hardware are not auto detected, so you have to specify |
179 the sample frequency explicitly. This plugin has one switch: | |
180 <CODE>fout</CODE> which is used for setting the desired output sample | |
5765 | 181 frequency. It defaults to 48kHz, and is given in |
4508 | 182 <Hz>. |
183 </P> | |
3671 | 184 |
5765 | 185 <P>Usage:<BR> |
3671 | 186 <CODE>mplayer media.avi -aop list=resample:fout=<required |
187 frequency in Hz, like 44100></CODE></P> | |
188 | |
5765 | 189 <P>Note that the output frequency should not be scaled up from the default value. |
190 Scaling up will cause the audio and video streams to be played in slow motion | |
191 in addition to audio distortion.</P> | |
3671 | 192 |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
193 <P><B><A NAME="surround_decoding">2.3.2.2.2 Surround Sound decoding</A></B></P> |
3931 | 194 |
5765 | 195 <P><B>MPlayer</B> has an audio plugin that can decode matrix encoded |
196 surround sound. Dolby Surround is an example of a matrix encoded format. | |
197 Many files with 2 channel audio actually contain matrixed surround sound. | |
198 To use this feature you need a sound card supporting at least 4 channels.</P> | |
3931 | 199 |
5765 | 200 <P>Usage:<BR> |
3931 | 201 <CODE>mplayer media.avi -aop list=surround</CODE></P> |
202 | |
4508 | 203 |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
204 <P><B><A NAME="format">2.3.2.2.3 Sample format converter</A></B></P> |
4508 | 205 |
5765 | 206 <P>If your sound card driver does not support signed 16bit <CODE>int</CODE> data type, |
207 this plugin can | |
4508 | 208 be used to change the format to one which your sound card can understand. It |
5765 | 209 has one switch, <CODE>format</CODE>, which can be set to one of the numbers |
210 found in <CODE>libao2/afmt.h</CODE>. This plugin is hardly ever needed and is | |
211 intended for advanced users. Keep in mind that this plugin only changes the | |
212 sample format and not the sample frequency or the number of channels. | |
4508 | 213 </P> |
214 | |
5765 | 215 <P>Usage:<BR> |
4508 | 216 <CODE>mplayer media.avi -aop |
217 list=format:format=<required output format></CODE> | |
218 </P> | |
219 | |
220 | |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
221 <P><B><A NAME="delay">2.3.2.2.4 Delay</A></B></P> |
4508 | 222 |
223 <P>This plugin delays the sound and is intended as an example of how to develop | |
5765 | 224 new plugins. It can not be used for anything useful from a users perspective |
4508 | 225 and is mentioned here for the sake of completeness only. Do not use this |
226 plugin unless you are a developer.</P> | |
227 | |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
228 <P><B><A NAME="volume">2.3.2.2.5 Software volume control</A></B></P> |
4913 | 229 |
230 <P>This plugin is a software replacement for the volume control, and | |
5765 | 231 can be used on machines with a broken mixer device. It can also be |
232 used if one wants to change the output volume of <B>MPlayer</B> | |
4913 | 233 without changing the PCM volume setting in the mixer. It has one |
234 switch <CODE>volume</CODE> that is used for setting the initial | |
235 sound level. The initial sound level can be set to values between 0 | |
5099 | 236 and 255 and defaults to 101 which equals 0dB amplification. Use this |
237 plugin with caution since it can reduce the signal to noise ratio of | |
238 the sound. In most cases it is best to set the level for the PCM | |
239 sound to max, leave this plugin out and control the output level to | |
5765 | 240 your speakers with the master volume control of the mixer. If there is an |
5099 | 241 external amplifier connected to the computer (this is almost always |
242 the case), the noise level can be minimized by adjusting the master | |
243 level and the volume knob on the amplifier until the hissing noise | |
244 in the background is gone. | |
4913 | 245 </P> |
246 | |
5765 | 247 <P>Usage:<BR> |
4913 | 248 <CODE>mplayer media.avi -aop |
249 list=volume:volume=<0-255></CODE> | |
250 </P> | |
251 | |
5765 | 252 <P>This plugin also has compressor or "soft-clipping" capabilities. |
5099 | 253 Compression can be used if the dynamic range of the sound is very |
254 high or if the dynamic range of the loudspeakers is very | |
5765 | 255 low. Be aware that this feature creates distortion and should be |
5099 | 256 considered a last resort. |
257 </P> | |
258 | |
5765 | 259 <P>Usage:<BR> |
5099 | 260 <CODE>mplayer media.avi -aop |
261 list=volume:softclip</CODE> | |
262 </P> | |
4928
ecf9f93dd9b6
added documentation for "extrastereo" plugin (patch by pl)
gabucino
parents:
4913
diff
changeset
|
263 |
5109 | 264 |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
265 <P><B><A NAME="extrastereo">2.3.2.2.6 Extrastereo</A></B></P> |
4928
ecf9f93dd9b6
added documentation for "extrastereo" plugin (patch by pl)
gabucino
parents:
4913
diff
changeset
|
266 |
5765 | 267 <P>This plugin (linearly) increases the difference between left and right |
268 channels (like the XMMS extrastereo plugin) which gives some sort of "live" | |
269 effect to playback. | |
4928
ecf9f93dd9b6
added documentation for "extrastereo" plugin (patch by pl)
gabucino
parents:
4913
diff
changeset
|
270 </P> |
ecf9f93dd9b6
added documentation for "extrastereo" plugin (patch by pl)
gabucino
parents:
4913
diff
changeset
|
271 |
5765 | 272 <P>Usage:<BR> |
4928
ecf9f93dd9b6
added documentation for "extrastereo" plugin (patch by pl)
gabucino
parents:
4913
diff
changeset
|
273 <CODE>mplayer media.avi -aop list=extrastereo</CODE><BR> |
ecf9f93dd9b6
added documentation for "extrastereo" plugin (patch by pl)
gabucino
parents:
4913
diff
changeset
|
274 <CODE>mplayer media.avi -aop list=extrastereo:mul=3.45</CODE></P> |
ecf9f93dd9b6
added documentation for "extrastereo" plugin (patch by pl)
gabucino
parents:
4913
diff
changeset
|
275 |
ecf9f93dd9b6
added documentation for "extrastereo" plugin (patch by pl)
gabucino
parents:
4913
diff
changeset
|
276 <P>The default coefficient (<CODE>mul</CODE>) is a float number that defaults |
5765 | 277 to 2.5. If you set it to 0.0, you will have mono sound (average of both |
6272 | 278 channels). If you set it to 1.0, sound will be unchanged, if you set it to |
279 -1.0, left and right channels will be swapped.</P> | |
4928
ecf9f93dd9b6
added documentation for "extrastereo" plugin (patch by pl)
gabucino
parents:
4913
diff
changeset
|
280 |
5109 | 281 |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
282 <P><B><A NAME="normalizer">2.3.2.2.7 Volume normalizer</A></B></P> |
5109 | 283 |
5765 | 284 <P>This plugin maximizes the volume without distorting the sound.</P> |
5109 | 285 |
5765 | 286 <P>Usage:<BR> |
5109 | 287 <CODE>mplayer media.avi -aop list=volnorm</CODE><BR> |
288 | |
5721 | 289 |
6906
3274d0725fde
Changed all link names from the section number to a sensible label.
diego
parents:
6882
diff
changeset
|
290 <P><B><A NAME="surround">2.3.2.2.8 Surround</A></B></P> |
5721 | 291 |
292 <P>Someone should document something, sometime.</P> | |
293 | |
1612 | 294 </BODY> |
295 </HTML> |