[MPlayer-dev-eng] [RFC][PATCH][EXPERIMENTAL] VAAPI support

Roberto Togni rxt at rtogni.it
Tue Oct 6 23:43:57 CEST 2015


Hi,
 this is a first attempt at porting VAAPI support from mplayer-vaapi
(https://github.com/gbeauchesne/mplayer-vaapi).

The patch still requires a lot of cleanup, but it works for me at least
for h264, mpeg2 and some wmv3. mpeg4 and h263 fails for me, but I get
the same results with the original mplayer-vaapi.

In my test it doesn't break VDPAU (h264 only, tested via vaapi wrapper)
nor software decoding.
It breaks mencoder (linking fails); fixing is trivial but I haven't
bothered to look at it yet.
Compilation may fail without vaapi headers (untested).

This is tested only on a sandybridge with vaapi 0.36.0 (debian stable).

All the options of the vo (deinterlacing, gl, xrender, ...) are
untested.

The stat files require some dependency, but the configure part is not
added yet; the files are there only to make the compiler happy.



Please note that I have no clue about the vaapi vo code, except that it
uses plane 3 for the surface. It just works.


What is still missing:
 - check and update with latest ffmpeg api (mplayer-vaapi development
   basically ended in 2011, with a small update for 0.34 in 2012)
 - cleanup and testing
 - support for newer libvaaapi
 - new features: vp8 and hevc (vp9 also?)
 - EGL?


More general things to do
 - better usability (why do I have to force the decoder? mplayer-vaapi
   uses a -va acceltype switch, together with the -vo)
 - encoding? (if ffmpeg supports it) (also for vdpau)






If you want to test it, copy vo_vaapi.c, stats.c and stats.h in libvo,
apply the patch and configure+compile as usual.
The interface is the same as VDPAU, pass -vo vaapi and -vc yourcodec
(eg. ffh264vaapi for h264 video).


Have fun!


Ciao,
 Roberto
-------------- next part --------------
A non-text attachment was scrubbed...
Name: vaapi.diff
Type: text/x-patch
Size: 22286 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20151006/8deb224c/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: stats.c
Type: text/x-c++src
Size: 6036 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20151006/8deb224c/attachment-0002.c>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: stats.h
Type: text/x-chdr
Size: 479 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20151006/8deb224c/attachment-0001.h>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: vo_vaapi.c
Type: text/x-c++src
Size: 84517 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20151006/8deb224c/attachment-0003.c>


More information about the MPlayer-dev-eng mailing list