[Libva] [PATCH] vpp: expose BGRA surface formats on Ivybridge and Haswell.

Gwenole Beauchesne gb.devel at gmail.com
Tue Sep 9 05:34:21 PDT 2014


Pushed to git master and staging branches.

This needs to go to 1.4-branch too.

Thanks,
Gwenole

2014-09-08 19:10 GMT+02:00 Gwenole Beauchesne <gb.devel at gmail.com>:
> Allow for vaQuerySurfaceAttributes() to return BGRA and BGRX formats
> for VPP on Ivybridge and Haswell. This is supported as both source
> and target surface formats.
>
> This fixes VA/EGL interop on Gen7 processors when a BGR[AX] surface
> is exported into an EGLImage.
>
> Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne at intel.com>
> ---
>  src/i965_drv_video.c |   12 ++++++++++++
>  1 file changed, 12 insertions(+)
>
> diff --git a/src/i965_drv_video.c b/src/i965_drv_video.c
> index a628e05..75ea2f4 100755
> --- a/src/i965_drv_video.c
> +++ b/src/i965_drv_video.c
> @@ -4952,6 +4952,18 @@ i965_QuerySurfaceAttributes(VADriverContextP ctx,
>                  attribs[i].type = VASurfaceAttribPixelFormat;
>                  attribs[i].value.type = VAGenericValueTypeInteger;
>                  attribs[i].flags = VA_SURFACE_ATTRIB_GETTABLE | VA_SURFACE_ATTRIB_SETTABLE;
> +                attribs[i].value.value.i = VA_FOURCC_BGRA;
> +                i++;
> +
> +                attribs[i].type = VASurfaceAttribPixelFormat;
> +                attribs[i].value.type = VAGenericValueTypeInteger;
> +                attribs[i].flags = VA_SURFACE_ATTRIB_GETTABLE | VA_SURFACE_ATTRIB_SETTABLE;
> +                attribs[i].value.value.i = VA_FOURCC_BGRX;
> +                i++;
> +
> +                attribs[i].type = VASurfaceAttribPixelFormat;
> +                attribs[i].value.type = VAGenericValueTypeInteger;
> +                attribs[i].flags = VA_SURFACE_ATTRIB_GETTABLE | VA_SURFACE_ATTRIB_SETTABLE;
>                  attribs[i].value.value.i = VA_FOURCC_YV16;
>                  i++;
>              }
> --
> 1.7.9.5
>



-- 
Gwenole Beauchesne
Intel Corporation SAS / 2 rue de Paris, 92196 Meudon Cedex, France
Registration Number (RCS): Nanterre B 302 456 199


More information about the Libva mailing list