Page 1 of 1

gl-option for VAAPI

Posted: 09 Jan 2011 17:12
by direx
Hi,

I am using vlc 1.1.5 with vaapi support for GPU-based h264 decoding. GPU decoding itself works fine with vlc on my ATI Radeon Mobility HD4200 (CPU stays at 800MHz, CPU load of 40%). However I get terrible video tearing in fast scenes (because the stupid fglrx driver does not support XVideo vsync).
I figured that I can get rid of video tearing in mplayer by using OpenGL rendering with VAAPI ("-vo vaapi:gl"). Is there an equivilant vlc option?

I've tried the following:
  • Preferences->Video Output->GLX; result: 100% CPU load, 1080p unwatchable
  • Command line switch: --ffmpeg-hw --vout opengl; result: 100% CPU load, 1080p unwatchable
I guess I must be missing something. It seems that for me VAAPI in vlc only works with "XVideo" - but XVideo is not a good option for ATI users :( Anything else I could do?

Re: gl-option for VAAPI

Posted: 09 Jan 2011 18:23
by Rémi Denis-Courmont
VLC cannot render directly from VAAPI. So it's completely orthogonal to the video output. And then XVideo is really the only good option as it supports hardware YUV conversion. Did you try to use another XVideo adaptor than the first one?

Re: gl-option for VAAPI

Posted: 09 Jan 2011 18:43
by direx
Did you try to use another XVideo adaptor than the first one?
Yes - I've tried various XVideo-settings. But XVideo does not work well with the fglrx drivers - many people using fglrx suffer from video tearing (which is not VAAPI-related). Video tearing also occurs in mplayer with "-vo xv" - this is sad, but normal on ATI graphics cards with the proprietary driver.

And I've already invested a fair amount of time fine-tuning my xorg.conf - I experimented with "VideoOverlay", "TexturedVideo", "TexturedVideoSync" and the like, but I was not successful. After doing some research it turned out that VSync does not work with XVideo (again, this is not VAAPI-related). The easiest workaround is to use OpenGL output, which can make use of VSync on ATI cards. This is why ATI users need "-vo vaapi:gl" with mplayer, for example.

So you say that it is not possible to use something like "vaapi:gl" in VLC at the moment? If this is true, I'll open a new bug because this is a very serious issue (this makes VAAPI kinda useless for ATI people, as AMD is incapable of implementing proper VSync for XVideo).

Re: gl-option for VAAPI

Posted: 25 Jul 2012 15:12
by Rémi Denis-Courmont
In VLC, VAAPI is totally independent from the video output system. It uses Xorg to talk to the GPU, but not to render. You can select OpenGL/GLX output if you want that instead of XVideo.

I guess it will not solve your problem though.