Xv Xdbe combination

Matthew Fincham matthewf at cat.co.za
Wed Apr 14 01:27:24 PDT 2010


On 13-04-10 10:44, Michel Dänzer wrote:
> On Mon, 2010-04-12 at 07:54 +0200, Matthew Fincham wrote:
>    
>> I am trying to display scaled video with text and pixmaps (amongst other
>> things) "overlayed". I have Xv working, but when the overlay (to be
>> clear, this is not an Xv overlay) is drawn the overlay flickers. So I
>> need use Xv, but with double buffering.
>>
>> My first attempt was to use Xv to draw to a pixmap instead of a window,
>> only to find out that Xv does not support this (at least it looks like
>> the Intel driver doesn't support this).
>>      
> See https://bugs.freedesktop.org/show_bug.cgi?id=21143 . It shouldn't be
> too hard to finish up the patches floating around for this, someone just
> needs to do it

Hi Michel

Thank you for the reply - I appreciate the response. I have actually 
already seen this patch and applied it, but this is what I found:

  - After applying the patch the request to display the XvImage results 
in a BadMatch error. This error is generated by the modification to 
xvmain.c that checks the drawable and adaptor type match.
  - Leaving this check out results in X freezing.
  - After checking the Intel driver I see that it is responsible for 
setting the Xv adaptor type. Forcing it to be a pixmap also results in X 
freezing (not surprisingly!)

Looking at xf86XVPutImage in xf86xv.c it looks like it relies on the 
drawable being a Window, and simply removing the check that the drawable 
is a Window (which is what the patch does) is not sufficient.

So I can see two issues:
  - the Intel driver needs to export the adaptor type with XvPixmapMask 
flag (or both XvPixmapMask and XvWindowMask flags, although I am not 
sure if these are exclusive)
  - Xorg needs to deal with the drawable not being a Window (in xf86xv.c)

Does anyone know if firstly, this is even possible, and secondly, how to 
go about doing this if it is possible. I am happy to do it and test it, 
but I am going to need some guidance (!).

Thanks again to anyone taking the time to read this.

Matthew Fincham







More information about the xorg-devel mailing list