[PATCH 21/36] dix: pixmap sharing infrastructure (v2)

Keith Packard keithp at keithp.com
Mon Jul 2 12:20:17 PDT 2012


Dave Airlie <airlied at gmail.com> writes:

> From: Dave Airlie <airlied at redhat.com>
>
> This is a hooks for pixmap sharing and tracking.
>
> The pixmap sharing ones get an integer handle for the pixmap
> and use a handle to be the backing for a pixmap.
>
> The tracker interface is to be used when a GPU needs to
> track pixmaps to be updated for another GPU.
>
> v2: pass slave to sharing so it can use it to work out driver.
>
> Signed-off-by: Dave Airlie <airlied at redhat.com>
> ---
>  include/scrnintstr.h |   17 +++++++++++++++++
>  1 file changed, 17 insertions(+)
>
> diff --git a/include/scrnintstr.h b/include/scrnintstr.h
> index 6a22167..5b9f245 100644
> --- a/include/scrnintstr.h
> +++ b/include/scrnintstr.h
> @@ -179,6 +179,8 @@ typedef void (*ClipNotifyProcPtr) (WindowPtr /*pWindow */ ,
>  #define CREATE_PIXMAP_USAGE_BACKING_PIXMAP              2
>  /* pixmap will contain a glyph */
>  #define CREATE_PIXMAP_USAGE_GLYPH_PICTURE               3
> +/* pixmap will be shared */
> +#define CREATE_PIXMAP_USAGE_SHARED                      4
>  
>  typedef PixmapPtr (*CreatePixmapProcPtr) (ScreenPtr /*pScreen */ ,
>                                            int /*width */ ,
> @@ -339,6 +341,16 @@ typedef void (*DeviceCursorCleanupProcPtr) (DeviceIntPtr /* pDev */ ,
>  typedef void (*ConstrainCursorHarderProcPtr) (DeviceIntPtr, ScreenPtr, int,
>                                                int *, int *);
>  
> +
> +typedef Bool (*SharePixmapBackingProcPtr)(PixmapPtr, ScreenPtr, int *);

Not sure 'int' is the best type for this; I know it's sufficient for
current usage, but one wonders if 64-bit identifiers, or something even
more complicated will happen in the future. (void *) instead?

-- 
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 827 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg-devel/attachments/20120702/c3301266/attachment.pgp>


More information about the xorg-devel mailing list