| Index: third_party/libva/va/wayland/va_backend_wayland.h
|
| diff --git a/third_party/libva/va/glx/va_backend_glx.h b/third_party/libva/va/wayland/va_backend_wayland.h
|
| similarity index 51%
|
| copy from third_party/libva/va/glx/va_backend_glx.h
|
| copy to third_party/libva/va/wayland/va_backend_wayland.h
|
| index d1104854971f4ac9cf98b5fef49ac7259cbb642c..b33e3a13d2781c2da90d232724f150ef29162522 100644
|
| --- a/third_party/libva/va/glx/va_backend_glx.h
|
| +++ b/third_party/libva/va/wayland/va_backend_wayland.h
|
| @@ -1,5 +1,7 @@
|
| /*
|
| - * Copyright (C) 2009 Splitted-Desktop Systems. All Rights Reserved.
|
| + * va_backend_wayland.h - VA driver implementation hooks for Wayland
|
| + *
|
| + * Copyright (c) 2012 Intel Corporation. All Rights Reserved.
|
| *
|
| * Permission is hereby granted, free of charge, to any person obtaining a
|
| * copy of this software and associated documentation files (the
|
| @@ -16,39 +18,48 @@
|
| * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
| * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
| * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
|
| - * IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
|
| + * IN NO EVENT SHALL INTEL AND/OR ITS SUPPLIERS BE LIABLE FOR
|
| * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
| * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
| * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
| */
|
|
|
| -#ifndef VA_BACKEND_GLX_H
|
| -#define VA_BACKEND_GLX_H
|
| +#ifndef VA_BACKEND_WAYLAND_H
|
| +#define VA_BACKEND_WAYLAND_H
|
| +
|
| +#include <va/va.h>
|
| +#include <wayland-client.h>
|
|
|
| +/** \brief VA/Wayland API version. */
|
| +#define VA_WAYLAND_API_VERSION (0x574c4400) /* WLD0 */
|
| +
|
| +/* Forward declarations */
|
| struct VADriverContext;
|
|
|
| -struct VADriverVTableGLX {
|
| - /* Optional: create a surface used for display to OpenGL */
|
| - VAStatus (*vaCreateSurfaceGLX)(
|
| - struct VADriverContext *ctx,
|
| - unsigned int gl_target,
|
| - unsigned int gl_texture,
|
| - void **gl_surface
|
| - );
|
| +/** \brief VA/Wayland implementation hooks. */
|
| +struct VADriverVTableWayland {
|
| + /**
|
| + * \brief Interface version.
|
| + *
|
| + * Implementations shall set this field to \ref VA_WAYLAND_API_VERSION.
|
| + */
|
| + unsigned int version;
|
|
|
| - /* Optional: destroy a VA/GLX surface */
|
| - VAStatus (*vaDestroySurfaceGLX)(
|
| + /** \brief Hook to return Wayland buffer associated with the VA surface. */
|
| + VAStatus (*vaGetSurfaceBufferWl)(
|
| struct VADriverContext *ctx,
|
| - void *gl_surface
|
| + VASurfaceID surface,
|
| + unsigned int flags,
|
| + struct wl_buffer **out_buffer
|
| );
|
|
|
| - /* Optional: copy a VA surface to a VA/GLX surface */
|
| - VAStatus (*vaCopySurfaceGLX)(
|
| + /** \brief Hook to return Wayland buffer associated with the VA image. */
|
| + VAStatus (*vaGetImageBufferWl)(
|
| struct VADriverContext *ctx,
|
| - void *gl_surface,
|
| - VASurfaceID surface,
|
| - unsigned int flags
|
| + VAImageID image,
|
| + unsigned int flags,
|
| + struct wl_buffer **out_buffer
|
| );
|
| };
|
|
|
| -#endif /* VA_BACKEND_GLX_H */
|
| +#endif /* VA_BACKEND_WAYLAND_H */
|
|
|