[Mesa-dev] [PATCH] glx: Use struct xshmfence* instead of int32_t*.

Chí-Thanh Christopher Nguyễn chithanh at gentoo.org
Thu Dec 5 02:23:10 PST 2013


Matt Turner schrieb:
> ---
>  src/glx/dri3_glx.c  | 4 ++--
>  src/glx/dri3_priv.h | 2 +-
>  2 files changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/src/glx/dri3_glx.c b/src/glx/dri3_glx.c
> index b047cc8..1834c6d 100644
> --- a/src/glx/dri3_glx.c
> +++ b/src/glx/dri3_glx.c
> @@ -676,7 +676,7 @@ dri3_alloc_render_buffer(struct glx_screen *glx_screen, Drawable draw,
>     xcb_connection_t *c = XGetXCBConnection(dpy);
>     xcb_pixmap_t pixmap;
>     xcb_sync_fence_t sync_fence;
> -   int32_t *shm_fence;
> +   struct xshmfence *shm_fence;
>     int buffer_fd, fence_fd;
>     int stride;
>  
> @@ -921,7 +921,7 @@ dri3_get_pixmap_buffer(__DRIdrawable *driDrawable,
>     struct dri3_screen                   *psc;
>     xcb_connection_t                     *c;
>     xcb_sync_fence_t                     sync_fence;
> -   int32_t                              *shm_fence;
> +   struct xshmfence                     *shm_fence;
>     int                                  fence_fd;
>     __DRIimage                           *image_planar;
>     int                                  stride, offset;
> diff --git a/src/glx/dri3_priv.h b/src/glx/dri3_priv.h
> index c892800..efdc2ae 100644
> --- a/src/glx/dri3_priv.h
> +++ b/src/glx/dri3_priv.h
> @@ -87,7 +87,7 @@ struct dri3_buffer {
>      */
>  
>     uint32_t     sync_fence;     /* XID of X SyncFence object */
> -   int32_t      *shm_fence;     /* pointer to xshmfence object */
> +   struct xshmfence *shm_fence; /* pointer to xshmfence object */
>     GLboolean    busy;           /* Set on swap, cleared on IdleNotify */
>     void         *driverPrivate;
>  

You possibly need to require xshmfence >= 1.1 for this.



More information about the mesa-dev mailing list