diff options
author | Eric Anholt <[email protected]> | 2012-09-25 08:39:39 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2012-10-09 14:32:02 -0700 |
commit | 3f0e3a7ad5cf9bef745d460b0fa5e75ff830cb32 (patch) | |
tree | 543b4fa592005c6b5cffe9e2ed7d86bd1daf7851 /src/glx/single2.c | |
parent | 31c7d4ec188b6f25a23a3eb9a3e05e103792aa4d (diff) |
glx: Unifdef USE_XCB.
It's been required for building glx since
b518dfb513742984f27577d25566f93afd86d4fc in january.
Reviewed-by: Chad Versace <[email protected]>
Diffstat (limited to 'src/glx/single2.c')
-rw-r--r-- | src/glx/single2.c | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/src/glx/single2.c b/src/glx/single2.c index 993ad3647f9..103558fb5b2 100644 --- a/src/glx/single2.c +++ b/src/glx/single2.c @@ -36,11 +36,9 @@ #include "indirect.h" #include "indirect_vertex_array.h" #include "glapi.h" -#ifdef USE_XCB #include <xcb/xcb.h> #include <xcb/glx.h> #include <X11/Xlib-xcb.h> -#endif /* USE_XCB */ #if !defined(__GNUC__) # define __builtin_expect(x, y) x @@ -887,7 +885,6 @@ __indirect_glAreTexturesResident(GLsizei n, const GLuint * textures, Display *const dpy = gc->currentDpy; GLboolean retval = (GLboolean) 0; if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) { -#ifdef USE_XCB xcb_connection_t *c = XGetXCBConnection(dpy); (void) __glXFlushRenderBuffer(gc, gc->pc); xcb_glx_are_textures_resident_reply_t *reply = @@ -900,31 +897,6 @@ __indirect_glAreTexturesResident(GLsizei n, const GLuint * textures, sizeof(GLboolean)); retval = reply->ret_val; free(reply); -#else - const GLuint cmdlen = 4 + __GLX_PAD((n * 4)); - GLubyte const *pc = - __glXSetupSingleRequest(gc, X_GLsop_AreTexturesResident, cmdlen); - (void) memcpy((void *) (pc + 0), (void *) (&n), 4); - (void) memcpy((void *) (pc + 4), (void *) (textures), (n * 4)); - if (n & 3) { - /* n is not a multiple of four. - * When reply_is_always_array is TRUE, __glXReadReply() will - * put a multiple of four bytes into the dest buffer. If the - * caller's buffer is not a multiple of four in size, we'll write - * out of bounds. So use a temporary buffer that's a few bytes - * larger. - */ - GLboolean *res4 = malloc((n + 3) & ~3); - retval = (GLboolean) __glXReadReply(dpy, 1, res4, GL_TRUE); - memcpy(residences, res4, n); - free(res4); - } - else { - retval = (GLboolean) __glXReadReply(dpy, 1, residences, GL_TRUE); - } - UnlockDisplay(dpy); - SyncHandle(); -#endif /* USE_XCB */ } return retval; } |