*** empty log message ***

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@1501 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
gabucino 2001-08-13 10:38:01 +00:00
parent d970d85401
commit eefce080f0
3 changed files with 122 additions and 47 deletions

View File

@ -201,6 +201,9 @@ Table of Contents
_before_ compiling <B>MPlayer</B>, otherwise no Matrox-specific support will be _before_ compiling <B>MPlayer</B>, otherwise no Matrox-specific support will be
built. built.
If you plan to use the ProjectMayo's <B>OpenDivX</B> codec, check the
<A HREF="#2.1.2.1">2.1.2.1</A> section before compiling.
Then build <B>MPlayer</B>: Then build <B>MPlayer</B>:
@ -260,7 +263,7 @@ Table of Contents
The most important video codecs: The most important video codecs:
- MPEG1 (VCD) and MPEG2 (DVD) video - MPEG1 (VCD) and MPEG2 (DVD) video
- DivX, OpenDivX and other MPEG4 variants - DivX, FFmpeg, OpenDivX and other MPEG4 variants
- Windows Media Video 7 (WMV1) used in .wmv files - Windows Media Video 7 (WMV1) used in .wmv files
- Intel Indeo codecs (3.1,3.2,4.1,5.0) - Intel Indeo codecs (3.1,3.2,4.1,5.0)
- MJPEG, ASV2 and other hardware formats - MJPEG, ASV2 and other hardware formats
@ -307,7 +310,8 @@ Table of Contents
<B>MPlayer</B> autodetects if OpenDivX is (properly) installed, just compile <B>MPlayer</B> autodetects if OpenDivX is (properly) installed, just compile
as usual. as usual. If it doesn't detect it, you didn't install it exactly as above,
and/or has fucked up config (see last question of 6.1 section).
Using it is a bit tricky. As it conflicts with the old OpenDivX (it's API is Using it is a bit tricky. As it conflicts with the old OpenDivX (it's API is
very similar to OpenDivX's), OpenDivX code is disabled, and the OpenDivX very similar to OpenDivX's), OpenDivX code is disabled, and the OpenDivX
@ -345,16 +349,36 @@ Table of Contents
which is compatible with the traditional DivX. <B>MPlayer</B> contains this codec, which is compatible with the traditional DivX. <B>MPlayer</B> contains this codec,
and this makes it possible to <B>watch DivX movies on non-x86 platforms!</B> and this makes it possible to <B>watch DivX movies on non-x86 platforms!</B>
To get it compile, you'll need nasm, bison, and flex, above the other To get it compile, you'll need nasm, bison, and flex, above the other
devel tools. No manual hacking is needed to build it, ./configure detects devel tools. It was removed from <B>MPlayer</B>'s cvs tree, you have
if it can be built. At the moment it doesn't support postprocessing, and to download it manually directly from <B>FFmpeg</B>'s tree :
is under optimization (it's generally a bit faster than the DirectShow
DivX codec, now).
cvs -d:pserver:anonymous@cvs.ffmpeg.sourceforge.net:/cvsroot/ffmpeg login
cvs -d:pserver:anonymous@cvs.ffmpeg.sourceforge.net:/cvsroot/ffmpeg co ffmpeg
Note: if you copy with CVS subdirs, next time it's enough to do
'cvs update'.
Now, move the newly downloaded ffmpeg source's <B>libavcodec</B> directory,
(with all it's subdirectories) to <B>MPlayer</B>'s tree, so it will look
like this :
main/libavcodec
Symlinking is NOT enough, you have to copy it.
./configure detects if it can be built. At the moment it doesn't support
postprocessing, and is under optimization (it's faster than the DS/VfW DivX
codec).
In order to use it, refresh your codecs.conf file, and do as the manpage, In order to use it, refresh your codecs.conf file, and do as the manpage,
or the example.conf says (the -vfm option). or the example.conf says (the -vfm option).
Note: libavcodec contains other codecs as well, but at the moment we mostly Note: libavcodec contains other codecs as well, but at the moment we mostly
focus on ffdivx. focus on ffdivx, and it's unlikely that this will change.
<A NAME=2.1.3>2.1.4. Codec importing howto <A NAME=2.1.3>2.1.4. Codec importing howto
@ -388,7 +412,7 @@ Table of Contents
This is the MP3 codec. This is the MP3 codec.
So, now we have all the info needed (fourcc, codec file, sample AVI), submit So, now we have all the info needed (fourcc, codec file, sample AVI), submit
your codec support request in mail, and upload these files to the FTP: your codec support request in mail, and upload these files to the FTP:
ftp://mplayerhq.hu/MPlayer/incoming/<codecname>/ ftp://mplayerhq.hu/MPlayer/incoming/[codecname]/
<A NAME=2.1.4.2>2.1.4.2. DirectShow codecs <A NAME=2.1.4.2>2.1.4.2. DirectShow codecs
@ -421,7 +445,7 @@ Table of Contents
So, now we have all the info needed (fourcc, GUID, codec file, sample AVI), So, now we have all the info needed (fourcc, GUID, codec file, sample AVI),
submit your codec support request in mail, and upload these files to the FTP: submit your codec support request in mail, and upload these files to the FTP:
ftp://mplayerhq.hu/MPlayer/incoming/<codecname>/ ftp://mplayerhq.hu/MPlayer/incoming/[codecname]/
<A NAME=2.2>2.2. Video & Audio output devices <A NAME=2.2>2.2. Video & Audio output devices
@ -782,7 +806,7 @@ Table of Contents
-vo sdl:name specifies sdl video driver to use (ie. aalib, -vo sdl:name specifies sdl video driver to use (ie. aalib,
dga, x11) dga, x11)
-ao sdl:name specifies sdl audio driver to use (ie. dsp, -ao sdl:name specifies sdl audio driver to use (ie. dsp,
esd) esd, arts)
-noxv disables Xvideo hardware acceleration -noxv disables Xvideo hardware acceleration
-forcexv tries to force Xvideo acceleration -forcexv tries to force Xvideo acceleration
@ -821,6 +845,26 @@ Table of Contents
Doctor (formerly UniVBE) before booting Linux. Use a DOS boot disk or Doctor (formerly UniVBE) before booting Linux. Use a DOS boot disk or
whatever. And don't forget to register your UniVBE ;)) whatever. And don't forget to register your UniVBE ;))
The FBdev output takes some additional parameters above the others:
-fb specify the framebuffer device to use (/dev/fd0)
-fbmode mode name to use (according to /etc/fb.modes)
-fbmodeconfig config file of modes (default /etc/fb.modes)
monitor_hfreq
monitor_vfreq IMPORTANT values, see example.conf
monitor_dotclock
If you want to change to a specific mode, then use
mplayer -vm -fbmode (NameOfMode) filename
-vm alone will choose the most suitable mode from /etc/fb.modes . Can be
used together with -x and -y options too. The -flip option is supported only
if the movie's pixel format matches the video mode's pixel format.
Pay attention to the bpp value, fbdev driver tries to use the current,
or if you specify the -bpp option, then that.
-zoom option isn't supported (software scaling is slow). -fs option
isn't supported. You can't use 8bpp (or less) modes.
NOTE: FBdev video mode changing _does not work_ with the VESA framebuffer, NOTE: FBdev video mode changing _does not work_ with the VESA framebuffer,
and don't ask for it, since it's not an <B>MPlayer</B> limitation. and don't ask for it, since it's not an <B>MPlayer</B> limitation.
@ -1057,7 +1101,7 @@ Table of Contents
end end
If you don't like the standard location for the lirc-config file (~/.lircrc) If you don't like the standard location for the lirc-config file (~/.lircrc)
use the -lircconf <filename> switch to specify another file. use the -lircconf [filename] switch to specify another file.
<A NAME=3.3>3.3. Streaming from network or pipes <A NAME=3.3>3.3. Streaming from network or pipes
@ -1184,7 +1228,7 @@ Table of Contents
It's recommended that you tuneup your CDROM drive also with hdparm : It's recommended that you tuneup your CDROM drive also with hdparm :
hdparm -d1 -a8 -u1 <cdrom device> hdparm -d1 -a8 -u1 (cdrom device)
to enable using DMA access, readahead, and IRQ unmasking. to enable using DMA access, readahead, and IRQ unmasking.
@ -1351,11 +1395,19 @@ Table of Contents
<B>Q: What's the problem with gcc 2.96 ? <B>Q: What's the problem with gcc 2.96 ?
</B>A: gcc 2.96 is RedHat's UNOFFICIAL (it can be found only on RedHat sites, or </B>A: gcc 2.96 is RedHat's UNOFFICIAL (it can be found only on RedHat sites, or
RedHat distributions) and BUGGY gcc release. gcc 2.96 is TOTALLY RedHat distributions) and BUGGY gcc release. gcc 2.96 is TOTALLY
unsupported by <B>MPlayer</B>, because it simply SKIPS MMX codes, it just does not unsupported by <B>MPlayer</B>, because it simply SKIPS MMX codes, it just does
compile it. Important: this is NOT an <B>MPlayer</B>-specific problem, numerous not compile it. Important: this is NOT an <B>MPlayer</B>-specific problem,
other projects (DRI, avifile, etc..) have problems with this shit too. numerous other projects (DRI, avifile, etc..) have problems with this shit
too.
** DO NOT USE gcc 2.96 !!! ** ** DO NOT USE gcc 2.96 !!! **
<B>Q: Great, I have gcc 3.0.1 from RedHat/Mandrake, then I'm fine--!
</B>A: No :) Their gcc 3.0.1 was compiled with gcc 2.96, so they are
buggy shit too.
<B>Q: Now then. What should I use?
</B>A: Any of gcc 2.95 series.
<B>Q: SDL output doesn't work or compile. Problem is .... <B>Q: SDL output doesn't work or compile. Problem is ....
</B>A: It is tested with newest SDL (probably runs on 1.1.7+). </B>A: It is tested with newest SDL (probably runs on 1.1.7+).
It does NOT work with 1.1.6, 1.1.5 1.1.4 1.1.3 1.0.4 etc, don't ask. It does NOT work with 1.1.6, 1.1.5 1.1.4 1.1.3 1.0.4 etc, don't ask.
@ -1404,14 +1456,16 @@ Table of Contents
<B>Q: I can't compile SVGAlib.. I'm using 2.3/2.4 kernel. <B>Q: I can't compile SVGAlib.. I'm using 2.3/2.4 kernel.
</B>A: You have to edit SVGAlib's Makefile.cfg and comment "BACKGROUND = y" out. </B>A: You have to edit SVGAlib's Makefile.cfg and comment "BACKGROUND = y" out.
<B>Q: I compiled <B>MPlayer</B> with libcss support, but when I try to start <B>Q: I compiled <B>MPlayer</B> with libcss/libdivxdecore support, but when
it, it says : I try to start it, it says :
> error while loading shared libraries: libcss.so.0: cannot load > error while loading shared libraries: libcss.so.0: cannot load
> shared object file: No such file or directory > shared object file: No such file or directory
I checked up on the file and it IS there in /usr/local/lib. I checked up on the file and it IS there in /usr/local/lib.
</B>A: What are you doing on Linux? Can't you install a library? Why do </B>A: What are you doing on Linux? Can't you install a library? Why do
we get these questions? It's not <B>MPlayer</B> specific at all! Add we get these questions? It's not <B>MPlayer</B> specific at all! Add
/usr/local/lib to <B>/etc/ld.so.conf</B> and run <B>ldconfig</B> . /usr/local/lib to <B>/etc/ld.so.conf</B> and run <B>ldconfig</B> .
Or install it to /usr/lib , because if you can't solve the /usr/local
problem, you are careless enough to do such things.
<A NAME=6.2>6.2. General questions <A NAME=6.2>6.2. General questions
@ -1714,7 +1768,7 @@ Table of Contents
"options USER_LDT" (unless you are running -CURRENT, where this is default). "options USER_LDT" (unless you are running -CURRENT, where this is default).
If <B>MPlayer</B> complains about "CD-ROM Device '/dev/cdrom' not found!" make a If <B>MPlayer</B> complains about "CD-ROM Device '/dev/cdrom' not found!" make a
symbolic link : ln -s /dev/<your_cdrom_device> /dev/cdrom symbolic link : ln -s /dev/(your_cdrom_device) /dev/cdrom
There's no DVD support for FreeBSD yet. There's no DVD support for FreeBSD yet.
Feel free to add it :-) Feel free to add it :-)
@ -1770,8 +1824,8 @@ Table of Contents
gcc -c -Iloader -Ilibvo -O4 -march=i686 -mcpu=i686 -pipe -ffast-math gcc -c -Iloader -Ilibvo -O4 -march=i686 -mcpu=i686 -pipe -ffast-math
-fomit-frame-pointer -I/usr/local/include -o mplayer.o mplayer.c -fomit-frame-pointer -I/usr/local/include -o mplayer.o mplayer.c
Assembler: mplayer.c Assembler: mplayer.c
"<stdin>", line 3567 : Illegal mnemonic "(stdin)", line 3567 : Illegal mnemonic
"<stdin>", line 3567 : Syntax error "(stdin)", line 3567 : Syntax error
... more "Illegal mnemonic" and "Syntax error" errors ... ... more "Illegal mnemonic" and "Syntax error" errors ...

View File

@ -60,6 +60,9 @@ mplayer \- Movie Player for Linux
.RB [ \-afm\ audio\ codec\ family ] .RB [ \-afm\ audio\ codec\ family ]
.RB [ \-frames\ number ] .RB [ \-frames\ number ]
.RB [ \-autoq\ quality ] .RB [ \-autoq\ quality ]
.RB [ \-fb\ device ]
.RB [ \-fbmode\ modename ]
.RB [ \-fbmodeconfig filename ]
.I - or file .I - or file
.PP .PP
.SH DESCRIPTION .SH DESCRIPTION
@ -326,6 +329,7 @@ tells MPlayer to handle the subtitle file as UTF8.
This option workarounds some problems when using specific windowmanagers and This option workarounds some problems when using specific windowmanagers and
fullscreen mode. If you experience fullscreen problems, try changing this fullscreen mode. If you experience fullscreen problems, try changing this
value between 0 and 7. value between 0 and 7.
-fsmode 0 new method (since 0.18pre3) -fsmode 0 new method (since 0.18pre3)
-fsmode 1 ICCCWM patch (for KDE2/icewm) -fsmode 1 ICCCWM patch (for KDE2/icewm)
-fsmode 2 old method (0.17a) -fsmode 2 old method (0.17a)
@ -333,6 +337,21 @@ value between 0 and 7.
.TP .TP
.B \-frames\ number .B \-frames\ number
MPlayer plays <number> frames, then quits. MPlayer plays <number> frames, then quits.
.TP
.B \-fb\ device
Specifies the framebuffer device to use. By default it uses /dev/fb0 .
Only valid for the fbdev driver.
.TP
.B \-fbmode\ modename
Change videomode to the one that is labelled as <modename> in /etc/fb.modes .
Only valid for the fbdev driver.
.TP
.I NOTE
VESA framebuffer doesn't support mode changing.
.TP
.B \-fbmodeconfig\ filename
Use this config file instead of the default /etc/fb.modes .
Only valid for the fbdev driver.
.IP .IP
.SH "ALPHA/BETA CODE" .SH "ALPHA/BETA CODE"
.TP .TP

View File

@ -73,11 +73,11 @@ So everything is ok 'till now, I want to move them to a separate lib.
Now, go on: Now, go on:
3. mplayer.c - ooh, he's the boss :) 3. mplayer.c - ooh, he's the boss :)
The timing is solved odd, since it has/recommended to be done differently It's main purpose is connecting the other modules, and maintaining A/V
for each of the formats, and sometimes can be done in many ways. sync.
There are float variables called a_frame and v_frame, they store The given stream's actual position is in the corresponding stream header
the just played A/V position in seconds. timer field (sh_audio / sh_video).
The structure of the playing loop : The structure of the playing loop :
while(not EOF) { while(not EOF) {
@ -129,19 +129,28 @@ Now, go on:
Life didn't get simpler with AVI. There's the "official" timing Life didn't get simpler with AVI. There's the "official" timing
method, the BPS-based, so the header contains how many compressed method, the BPS-based, so the header contains how many compressed
audio bytes belong to one second of frames. audio bytes or chunks belong to one second of frames.
Of course this doesn't always work... why it should :) In the AVI stream header there are 2 important fields, the
So I emulate the MPEG's PTS/sector method on AVI, that is the dwSampleSize, and dwRate/dwScale pairs:
AVI parser calculates a fake PTS for every read chunk, decided by - If the dwSampleSize is 0, then it's VBR stream, so its bitrate
the type of the frames. This is how my timing is done. And sometimes isn't constant. It means that 1 chunk stores 1 sample, and
this works better. dwRate/dwScale gives the chunks/sec value.
- If the dwSampleSize is >0, then it's constant bitrate, and the
time can be measured this way: time = (bytepos/dwSampleSize) /
(dwRate/dwScale) (so the sample's number is divided with the
samplerate). Now the audio can be handled as a stream, which can
be cut to chunks, but can be one chunk also.
In AVI, usually there is a bigger piece of audio stored first, then The other method can be used only for interleaved files: from
comes the video. This needs to be calculated into the delay, this is the order of the chunks, a timestamp (PTS) value can be calculated.
called "Initial PTS delay". The PTS of the video chunks are simple: chunk number * fps
Of course there are 2 of them, one is stored in the header and not The audio is the same as the previous video chunk was.
really used :) the other isn't stored anywhere, this can only be We have to pay attention to the so called "audio preload", that is,
measured... there is a delay between the audio and video streams. This is
usually 0.5-1.0 sec, but can be totally different.
The exact value was measured until now, but now the demux_avi.c
handles it: at the audio chunk after the first video, it calculates
the A/V difference, and take this as a measure for audio preload.
3.a. audio playback: 3.a. audio playback:
Some words on audio playback: Some words on audio playback:
@ -166,17 +175,10 @@ Now, go on:
4. Codecs. They are separate libs. 4. Codecs. They are separate libs.
For example libac3, libmpeg2, xa/*, alaw.c, opendivx/*, loader, mp3lib. For example libac3, libmpeg2, xa/*, alaw.c, opendivx/*, loader, mp3lib.
mplayer.c calls them if a piece of audio or video needs to be played.
(see the beginning of 3.) mplayer.c doesn't call the directly, but through the dec_audio.c and
And they call the appropriate demuxer, to get the compressed data. dec_video.c files, so the mplayer.c doesn't have to know anything about
(see 2.) the codec.
We have to pass the appropriate stream header as parameter (sh_audio/
sh_video), this should contain all the needed info for decoding
(the demuxer too: sh->ds).
The codecs' seprating is underway, the audio is already done, the video is
work-in-progress. The aim is that mplayer.c won't have to know
which are the codecs and how to use 'em, instead it should call
an init/decode audio/video function.
5. libvo: this displays the frame. 5. libvo: this displays the frame.
The constants for different pixelformats are defined in img_format.h, The constants for different pixelformats are defined in img_format.h,