diff options
author | Jesse Barnes <[email protected]> | 2011-05-06 10:31:24 -0700 |
---|---|---|
committer | Jesse Barnes <[email protected]> | 2011-07-08 12:38:20 -0700 |
commit | 4df137691ee29bb812347fa2c5f19095243ede22 (patch) | |
tree | d8785b7099a772d4993b3855e65173d0b090868d /src/glx/glxclient.h | |
parent | 1e39fc784bc3d0d5ad01d9c147529ac0e10f1262 (diff) |
GLX/DRI2: handle swap event swap count wrapping
Create a new GLX drawable struct to track client related info, and add a
wrap counter to it drawable and track it as we receive events. This
allows us to support the full 64 bits of the event structure we pass to
the client even though the server only gives us a 32 bit count.
Reviewed-by: Michel Dänzer <[email protected]>
Reviewed-by: Jeremy Huddleston <[email protected]>
Signed-off-by: Jesse Barnes <[email protected]>
Diffstat (limited to 'src/glx/glxclient.h')
-rw-r--r-- | src/glx/glxclient.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/glx/glxclient.h b/src/glx/glxclient.h index 06415288165..f9154266101 100644 --- a/src/glx/glxclient.h +++ b/src/glx/glxclient.h @@ -567,6 +567,8 @@ struct glx_display */ struct glx_screen **screens; + __glxHashTable *glXDrawHash; + #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL) __glxHashTable *drawHash; @@ -579,6 +581,14 @@ struct glx_display #endif }; +struct glx_drawable { + XID xDrawable; + XID drawable; + + uint32_t lastEventSbc; + int64_t eventSbcWrap; +}; + extern int glx_screen_init(struct glx_screen *psc, int screen, struct glx_display * priv); @@ -784,6 +794,12 @@ extern int applegl_create_display(struct glx_display *display); #endif + +extern struct glx_drawable *GetGLXDrawable(Display *dpy, GLXDrawable drawable); +extern int InitGLXDrawable(Display *dpy, struct glx_drawable *glxDraw, + XID xDrawable, GLXDrawable drawable); +extern void DestroyGLXDrawable(Display *dpy, GLXDrawable drawable); + extern struct glx_context dummyContext; extern struct glx_screen * |