140
|
1
|
|
2 Videocards with hardware acceleration:
|
|
3 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
4
|
|
5 * read DOCS/MTRR too!
|
|
6
|
|
7 "Hardware acceleration" usually means hardware YUV conversion, scaling,
|
141
|
8 bilinear filtering. Under Linux, there are several ways to access it:
|
|
9
|
|
10 I. the Xv (XVideo) extension of XFree86-4.0.x
|
|
11 II. opengl drivers with glTexSubImage() support (currently the Utah-GLX drivers)
|
|
12 III. native card-specific drivers, using special abilities of some cards
|
|
13 IV. DGA - direct graphic access. no yuv & scaling, but faster than raw X11
|
|
14
|
|
15 Now, see them in details:
|
|
16
|
|
17 I. under XFree86 v4.0.x, using the XVideo extension:
|
|
18 this is what the option '-vo xv' uses.
|
|
19
|
|
20 In order to make this work, be sure to check the following:
|
|
21
|
|
22 1. you use XFree86 4.0.2 or newer (former versions don't have XVideo)
|
|
23
|
|
24 2. your card actually supports harware acceleration (modern cards does)
|
|
25
|
140
|
26 3. X loads the XVideo extension, it's something like this:
|
|
27 (II) Loading extension XVideo
|
|
28 in /var/log/XFree86.0.log
|
|
29 NOTE : this loads only the XFree86 support. In a good install, this is
|
|
30 always loaded, and doesn't mean that the _card's_ XVideo support is
|
|
31 loaded!
|
141
|
32
|
|
33 4. your card has Xv support under linux. To check, try 'xvinfo', it is the
|
|
34 part of the XFree86 distribution. It should display a long text, similar
|
|
35 to this:
|
140
|
36
|
|
37 X-Video Extension version 2.2
|
|
38 screen #0
|
|
39 Adaptor #0: "Savage Streams Engine"
|
|
40 number of ports: 1
|
|
41 port base: 43
|
|
42 operations supported: PutImage
|
|
43 supported visuals:
|
|
44 depth 16, visualID 0x22
|
|
45 depth 16, visualID 0x23
|
|
46 number of attributes: 5
|
|
47 (...etc...)
|
141
|
48
|
|
49 It must support YUY2 packed, and YV12 planar pixel formats to be
|
|
50 usable with MPlayer.
|
|
51
|
140
|
52 5. Be sure MPlayer is compiled with the "xv" target. "./configure" should say:
|
|
53 Checking for Xv ... yes
|
141
|
54
|
140
|
55 6. If all is fine, try the option '-vo xv' . It should work.
|
|
56 (if it doesn't, send us a bugreport. See the README on how to do this.)
|
|
57
|
|
58
|
141
|
59 II. OpenGL drivers with *working* *fast* glTexSubImage() support.
|
140
|
60
|
141
|
61 Currently only the old Utah-GLX drivers (for X 3.3.6) have it.
|
|
62 See http://utah-glx.sourceforge.net for details about how to install it.
|
|
63
|
|
64 The new X4/DRI and nVidia's binary drivers has no usable glTexSubImage :(
|
|
65
|
|
66 III. native card-specific drivers
|
|
67
|
|
68 There is 3 native drivers for linux:
|
|
69 1. Matrox G200/G400/G450 BES (Back-End Scaler) support -> mga_vid kernel drv.
|
|
70 It's active developed by me (A'rpi), and it has hardware VSYNC support
|
|
71 with triple buffering. It works on both framebuffer console and under X.
|
|
72
|
|
73 To use, simply compile the mga_vid.o in the drivers/ subdir (type: make)
|
|
74 and load it with insmod mga_vid.o. You should verify the memory size
|
|
75 detection using the 'dmesg' command. If it's bad, use the mga_ram_size
|
|
76 option (rmmod mga_vid first), specify card's memory size in MB:
|
|
77 insmod mga_vid.o mga_ram_size 16
|
|
78
|
|
79 Using it from MPlayer: (you should re-compile it with mga_vid support...)
|
|
80
|
|
81 Use the 'mga' vo driver on framebuffer console (matroxfb): -vo mga
|
|
82 and use the xmga driver for X 3.3.x: -vo xmga
|
|
83
|
|
84 Note: it works under X 4.0.x too, but it conflicts with the Xv driver,
|
|
85 so avoid using both. Usually X restart or reboot needs to get Xv usable
|
|
86 again :(
|
|
87
|
|
88 2. SiS 6326 YUV Framebuffer driver -> sis_vid kernel driver
|
|
89 Its interface should be compatible with the mga_vid, but the driver
|
|
90 was not updated after the mga_vid changes, so it's outdated now.
|
|
91 Volunteers needed to test it and bring the code up-to-date.
|
|
92
|
|
93 3. 3dfx (which ones?) YUV+scaler support, using /dev/3dfx (tdfx.o driver?)
|
|
94 The /dev/3dfx kernel driver exists only for 2.2.x kernels, for use with
|
|
95 Glide 2.x linux ports. It's not tested with MPlayer, and so no more
|
|
96 supported. Volunteers needed to test it and bring the code up-to-date.
|
140
|
97
|
|
98
|
141
|
99 IV. If your card lacks hardware acceleration, you can still boost your fps by
|
|
100 using the DGA driver:
|
140
|
101
|
|
102 1. Make sure X loads the DGA extension:
|
|
103 (II) Loading extension XFree86-DGA
|
|
104 2. MPlayer's DGA driver is autodetected on ./configure, or you can force it
|
|
105 with --enable-dga.
|
|
106 3. Be sure to use 24/32bpp mode, since there is no converter right now.. :(
|
|
107 4. Install MPlayer SUID root.
|
|
108 (see the FAQ on how to do this, and... heed the warning!)
|
|
109 5. Use '-vo dga' option, and there you go! (hope so:)
|
|
110
|
141
|
111 If you have fast enough CPU (P3 800 for example) you can try fsdga for
|
|
112 fullscreen mpeg playing (using software YUV->RGB scaling):
|
|
113 mplayer -vo fsdga ...
|
140
|
114
|
|
115
|
|
116
|
141
|
117 Gabucino & A'rpi
|
140
|
118
|