• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* DO NOT EDIT - This file generated automatically by glX_proto_send.py (from Mesa) script */
2 
3 /*
4  * (C) Copyright IBM Corporation 2004, 2005
5  * All Rights Reserved.
6  *
7  * Permission is hereby granted, free of charge, to any person obtaining a
8  * copy of this software and associated documentation files (the "Software"),
9  * to deal in the Software without restriction, including without limitation
10  * the rights to use, copy, modify, merge, publish, distribute, sub license,
11  * and/or sell copies of the Software, and to permit persons to whom the
12  * Software is furnished to do so, subject to the following conditions:
13  *
14  * The above copyright notice and this permission notice (including the next
15  * paragraph) shall be included in all copies or substantial portions of the
16  * Software.
17  *
18  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20  * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.  IN NO EVENT SHALL
21  * IBM,
22  * AND/OR THEIR SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
23  * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
24  * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
25  * SOFTWARE.
26  */
27 
28 
29 #include <GL/gl.h>
30 #include "indirect.h"
31 #include "glxclient.h"
32 #include "indirect_size.h"
33 #include "glapi.h"
34 #include "glthread.h"
35 #include <GL/glxproto.h>
36 #ifdef USE_XCB
37 #include <X11/Xlib-xcb.h>
38 #include <xcb/xcb.h>
39 #include <xcb/glx.h>
40 #endif /* USE_XCB */
41 
42 #define __GLX_PAD(n) (((n) + 3) & ~3)
43 
44 #  if defined(__i386__) && defined(__GNUC__) && !defined(__CYGWIN__) && !defined(__MINGW32__)
45 #    define FASTCALL __attribute__((fastcall))
46 #  else
47 #    define FASTCALL
48 #  endif
49 #  if defined(__GNUC__) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590))
50 #    define NOINLINE __attribute__((noinline))
51 #  else
52 #    define NOINLINE
53 #  endif
54 
55 #ifndef __GNUC__
56 #  define __builtin_expect(x, y) x
57 #endif
58 
59 /* If the size and opcode values are known at compile-time, this will, on
60  * x86 at least, emit them with a single instruction.
61  */
62 #define emit_header(dest, op, size)            \
63     do { union { short s[2]; int i; } temp;    \
64          temp.s[0] = (size); temp.s[1] = (op); \
65          *((int *)(dest)) = temp.i; } while(0)
66 
67 NOINLINE CARD32
__glXReadReply(Display * dpy,size_t size,void * dest,GLboolean reply_is_always_array)68 __glXReadReply( Display *dpy, size_t size, void * dest, GLboolean reply_is_always_array )
69 {
70     xGLXSingleReply reply;
71 
72     (void) _XReply(dpy, (xReply *) & reply, 0, False);
73     if (size != 0) {
74         if ((reply.length > 0) || reply_is_always_array) {
75             const GLint bytes = (reply_is_always_array)
76               ? (4 * reply.length) : (reply.size * size);
77             const GLint extra = 4 - (bytes & 3);
78 
79             _XRead(dpy, dest, bytes);
80             if ( extra < 4 ) {
81                 _XEatData(dpy, extra);
82             }
83         }
84         else {
85             (void) memcpy( dest, &(reply.pad3), size);
86         }
87     }
88 
89     return reply.retval;
90 }
91 
92 NOINLINE void
__glXReadPixelReply(Display * dpy,struct glx_context * gc,unsigned max_dim,GLint width,GLint height,GLint depth,GLenum format,GLenum type,void * dest,GLboolean dimensions_in_reply)93 __glXReadPixelReply( Display *dpy, struct glx_context * gc, unsigned max_dim,
94     GLint width, GLint height, GLint depth, GLenum format, GLenum type,
95     void * dest, GLboolean dimensions_in_reply )
96 {
97     xGLXSingleReply reply;
98     GLint size;
99 
100     (void) _XReply(dpy, (xReply *) & reply, 0, False);
101 
102     if ( dimensions_in_reply ) {
103         width  = reply.pad3;
104         height = reply.pad4;
105         depth  = reply.pad5;
106 
107 	if ((height == 0) || (max_dim < 2)) { height = 1; }
108 	if ((depth  == 0) || (max_dim < 3)) { depth  = 1; }
109     }
110 
111     size = reply.length * 4;
112     if (size != 0) {
113         void * buf = Xmalloc( size );
114 
115         if ( buf == NULL ) {
116             _XEatData(dpy, size);
117             __glXSetError(gc, GL_OUT_OF_MEMORY);
118         }
119         else {
120             const GLint extra = 4 - (size & 3);
121 
122             _XRead(dpy, buf, size);
123             if ( extra < 4 ) {
124                 _XEatData(dpy, extra);
125             }
126 
127             __glEmptyImage(gc, 3, width, height, depth, format, type,
128                            buf, dest);
129             Xfree(buf);
130         }
131     }
132 }
133 
134 #define X_GLXSingle 0
135 
136 NOINLINE FASTCALL GLubyte *
__glXSetupSingleRequest(struct glx_context * gc,GLint sop,GLint cmdlen)137 __glXSetupSingleRequest( struct glx_context * gc, GLint sop, GLint cmdlen )
138 {
139     xGLXSingleReq * req;
140     Display * const dpy = gc->currentDpy;
141 
142     (void) __glXFlushRenderBuffer(gc, gc->pc);
143     LockDisplay(dpy);
144     GetReqExtra(GLXSingle, cmdlen, req);
145     req->reqType = gc->majorOpcode;
146     req->contextTag = gc->currentContextTag;
147     req->glxCode = sop;
148     return (GLubyte *)(req) + sz_xGLXSingleReq;
149 }
150 
151 NOINLINE FASTCALL GLubyte *
__glXSetupVendorRequest(struct glx_context * gc,GLint code,GLint vop,GLint cmdlen)152 __glXSetupVendorRequest( struct glx_context * gc, GLint code, GLint vop, GLint cmdlen )
153 {
154     xGLXVendorPrivateReq * req;
155     Display * const dpy = gc->currentDpy;
156 
157     (void) __glXFlushRenderBuffer(gc, gc->pc);
158     LockDisplay(dpy);
159     GetReqExtra(GLXVendorPrivate, cmdlen, req);
160     req->reqType = gc->majorOpcode;
161     req->glxCode = code;
162     req->vendorCode = vop;
163     req->contextTag = gc->currentContextTag;
164     return (GLubyte *)(req) + sz_xGLXVendorPrivateReq;
165 }
166 
167 const GLuint __glXDefaultPixelStore[9] = { 0, 0, 0, 0, 0, 0, 0, 0, 1 };
168 
169 #define zero                        (__glXDefaultPixelStore+0)
170 #define one                         (__glXDefaultPixelStore+8)
171 #define default_pixel_store_1D      (__glXDefaultPixelStore+4)
172 #define default_pixel_store_1D_size 20
173 #define default_pixel_store_2D      (__glXDefaultPixelStore+4)
174 #define default_pixel_store_2D_size 20
175 #define default_pixel_store_3D      (__glXDefaultPixelStore+0)
176 #define default_pixel_store_3D_size 36
177 #define default_pixel_store_4D      (__glXDefaultPixelStore+0)
178 #define default_pixel_store_4D_size 36
179 
180 static FASTCALL NOINLINE void
generic_3_byte(GLint rop,const void * ptr)181 generic_3_byte( GLint rop, const void * ptr )
182 {
183     struct glx_context * const gc = __glXGetCurrentContext();
184     const GLuint cmdlen = 8;
185 
186     emit_header(gc->pc, rop, cmdlen);
187     (void) memcpy((void *)(gc->pc + 4), ptr, 4);
188     gc->pc += cmdlen;
189     if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
190 }
191 
192 static FASTCALL NOINLINE void
generic_4_byte(GLint rop,const void * ptr)193 generic_4_byte( GLint rop, const void * ptr )
194 {
195     struct glx_context * const gc = __glXGetCurrentContext();
196     const GLuint cmdlen = 8;
197 
198     emit_header(gc->pc, rop, cmdlen);
199     (void) memcpy((void *)(gc->pc + 4), ptr, 4);
200     gc->pc += cmdlen;
201     if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
202 }
203 
204 static FASTCALL NOINLINE void
generic_6_byte(GLint rop,const void * ptr)205 generic_6_byte( GLint rop, const void * ptr )
206 {
207     struct glx_context * const gc = __glXGetCurrentContext();
208     const GLuint cmdlen = 12;
209 
210     emit_header(gc->pc, rop, cmdlen);
211     (void) memcpy((void *)(gc->pc + 4), ptr, 8);
212     gc->pc += cmdlen;
213     if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
214 }
215 
216 static FASTCALL NOINLINE void
generic_8_byte(GLint rop,const void * ptr)217 generic_8_byte( GLint rop, const void * ptr )
218 {
219     struct glx_context * const gc = __glXGetCurrentContext();
220     const GLuint cmdlen = 12;
221 
222     emit_header(gc->pc, rop, cmdlen);
223     (void) memcpy((void *)(gc->pc + 4), ptr, 8);
224     gc->pc += cmdlen;
225     if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
226 }
227 
228 static FASTCALL NOINLINE void
generic_12_byte(GLint rop,const void * ptr)229 generic_12_byte( GLint rop, const void * ptr )
230 {
231     struct glx_context * const gc = __glXGetCurrentContext();
232     const GLuint cmdlen = 16;
233 
234     emit_header(gc->pc, rop, cmdlen);
235     (void) memcpy((void *)(gc->pc + 4), ptr, 12);
236     gc->pc += cmdlen;
237     if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
238 }
239 
240 static FASTCALL NOINLINE void
generic_16_byte(GLint rop,const void * ptr)241 generic_16_byte( GLint rop, const void * ptr )
242 {
243     struct glx_context * const gc = __glXGetCurrentContext();
244     const GLuint cmdlen = 20;
245 
246     emit_header(gc->pc, rop, cmdlen);
247     (void) memcpy((void *)(gc->pc + 4), ptr, 16);
248     gc->pc += cmdlen;
249     if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
250 }
251 
252 static FASTCALL NOINLINE void
generic_24_byte(GLint rop,const void * ptr)253 generic_24_byte( GLint rop, const void * ptr )
254 {
255     struct glx_context * const gc = __glXGetCurrentContext();
256     const GLuint cmdlen = 28;
257 
258     emit_header(gc->pc, rop, cmdlen);
259     (void) memcpy((void *)(gc->pc + 4), ptr, 24);
260     gc->pc += cmdlen;
261     if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
262 }
263 
264 static FASTCALL NOINLINE void
generic_32_byte(GLint rop,const void * ptr)265 generic_32_byte( GLint rop, const void * ptr )
266 {
267     struct glx_context * const gc = __glXGetCurrentContext();
268     const GLuint cmdlen = 36;
269 
270     emit_header(gc->pc, rop, cmdlen);
271     (void) memcpy((void *)(gc->pc + 4), ptr, 32);
272     gc->pc += cmdlen;
273     if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
274 }
275 
276 #define X_GLsop_NewList 101
__indirect_glNewList(GLuint list,GLenum mode)277 void __indirect_glNewList(GLuint list, GLenum mode)
278 {
279     struct glx_context * const gc = __glXGetCurrentContext();
280     Display * const dpy = gc->currentDpy;
281 #ifndef USE_XCB
282     const GLuint cmdlen = 8;
283 #endif
284     if (__builtin_expect(dpy != NULL, 1)) {
285 #ifdef USE_XCB
286         xcb_connection_t *c = XGetXCBConnection(dpy);
287         (void) __glXFlushRenderBuffer(gc, gc->pc);
288         xcb_glx_new_list(c, gc->currentContextTag, list, mode);
289 #else
290         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_NewList, cmdlen);
291 (void) memcpy((void *)(pc + 0), (void *)(&list), 4);
292 (void) memcpy((void *)(pc + 4), (void *)(&mode), 4);
293         UnlockDisplay(dpy); SyncHandle();
294 #endif /* USE_XCB */
295     }
296     return;
297 }
298 
299 #define X_GLsop_EndList 102
__indirect_glEndList(void)300 void __indirect_glEndList(void)
301 {
302     struct glx_context * const gc = __glXGetCurrentContext();
303     Display * const dpy = gc->currentDpy;
304 #ifndef USE_XCB
305     const GLuint cmdlen = 0;
306 #endif
307     if (__builtin_expect(dpy != NULL, 1)) {
308 #ifdef USE_XCB
309         xcb_connection_t *c = XGetXCBConnection(dpy);
310         (void) __glXFlushRenderBuffer(gc, gc->pc);
311         xcb_glx_end_list(c, gc->currentContextTag);
312 #else
313         (void) __glXSetupSingleRequest(gc, X_GLsop_EndList, cmdlen);
314         UnlockDisplay(dpy); SyncHandle();
315 #endif /* USE_XCB */
316     }
317     return;
318 }
319 
320 #define X_GLrop_CallList 1
__indirect_glCallList(GLuint list)321 void __indirect_glCallList(GLuint list)
322 {
323     struct glx_context * const gc = __glXGetCurrentContext();
324     const GLuint cmdlen = 8;
325 emit_header(gc->pc, X_GLrop_CallList, cmdlen);
326 (void) memcpy((void *)(gc->pc + 4), (void *)(&list), 4);
327 gc->pc += cmdlen;
328 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
329 }
330 
331 #define X_GLrop_CallLists 2
__indirect_glCallLists(GLsizei n,GLenum type,const GLvoid * lists)332 void __indirect_glCallLists(GLsizei n, GLenum type, const GLvoid * lists)
333 {
334     struct glx_context * const gc = __glXGetCurrentContext();
335     const GLuint compsize = __glCallLists_size(type);
336     const GLuint cmdlen = 12 + __GLX_PAD((compsize * n));
337     if (n < 0) {
338         __glXSetError(gc, GL_INVALID_VALUE);
339         return;
340     }
341     if (__builtin_expect((n >= 0) && (gc->currentDpy != NULL), 1)) {
342 if (cmdlen <= gc->maxSmallRenderCommandSize) {
343     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
344         (void) __glXFlushRenderBuffer(gc, gc->pc);
345     }
346 emit_header(gc->pc, X_GLrop_CallLists, cmdlen);
347 (void) memcpy((void *)(gc->pc + 4), (void *)(&n), 4);
348 (void) memcpy((void *)(gc->pc + 8), (void *)(&type), 4);
349 (void) memcpy((void *)(gc->pc + 12), (void *)(lists), (compsize * n));
350 gc->pc += cmdlen;
351 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
352 }
353 else {
354 const GLint op = X_GLrop_CallLists;
355 const GLuint cmdlenLarge = cmdlen + 4;
356 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
357 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
358 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
359 (void) memcpy((void *)(pc + 8), (void *)(&n), 4);
360 (void) memcpy((void *)(pc + 12), (void *)(&type), 4);
361     __glXSendLargeCommand(gc, pc, 16, lists, (compsize * n));
362 }
363     }
364 }
365 
366 #define X_GLsop_DeleteLists 103
__indirect_glDeleteLists(GLuint list,GLsizei range)367 void __indirect_glDeleteLists(GLuint list, GLsizei range)
368 {
369     struct glx_context * const gc = __glXGetCurrentContext();
370     Display * const dpy = gc->currentDpy;
371 #ifndef USE_XCB
372     const GLuint cmdlen = 8;
373 #endif
374     if (__builtin_expect(dpy != NULL, 1)) {
375 #ifdef USE_XCB
376         xcb_connection_t *c = XGetXCBConnection(dpy);
377         (void) __glXFlushRenderBuffer(gc, gc->pc);
378         xcb_glx_delete_lists(c, gc->currentContextTag, list, range);
379 #else
380         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_DeleteLists, cmdlen);
381 (void) memcpy((void *)(pc + 0), (void *)(&list), 4);
382 (void) memcpy((void *)(pc + 4), (void *)(&range), 4);
383         UnlockDisplay(dpy); SyncHandle();
384 #endif /* USE_XCB */
385     }
386     return;
387 }
388 
389 #define X_GLsop_GenLists 104
__indirect_glGenLists(GLsizei range)390 GLuint __indirect_glGenLists(GLsizei range)
391 {
392     struct glx_context * const gc = __glXGetCurrentContext();
393     Display * const dpy = gc->currentDpy;
394     GLuint retval = (GLuint) 0;
395 #ifndef USE_XCB
396     const GLuint cmdlen = 4;
397 #endif
398     if (__builtin_expect(dpy != NULL, 1)) {
399 #ifdef USE_XCB
400         xcb_connection_t *c = XGetXCBConnection(dpy);
401         (void) __glXFlushRenderBuffer(gc, gc->pc);
402         xcb_glx_gen_lists_reply_t *reply = xcb_glx_gen_lists_reply(c, xcb_glx_gen_lists(c, gc->currentContextTag, range), NULL);
403         retval = reply->ret_val;
404         free(reply);
405 #else
406         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GenLists, cmdlen);
407 (void) memcpy((void *)(pc + 0), (void *)(&range), 4);
408         retval = (GLuint) __glXReadReply(dpy, 0, NULL, GL_FALSE);
409         UnlockDisplay(dpy); SyncHandle();
410 #endif /* USE_XCB */
411     }
412     return retval;
413 }
414 
415 #define X_GLrop_ListBase 3
__indirect_glListBase(GLuint base)416 void __indirect_glListBase(GLuint base)
417 {
418     struct glx_context * const gc = __glXGetCurrentContext();
419     const GLuint cmdlen = 8;
420 emit_header(gc->pc, X_GLrop_ListBase, cmdlen);
421 (void) memcpy((void *)(gc->pc + 4), (void *)(&base), 4);
422 gc->pc += cmdlen;
423 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
424 }
425 
426 #define X_GLrop_Begin 4
__indirect_glBegin(GLenum mode)427 void __indirect_glBegin(GLenum mode)
428 {
429     struct glx_context * const gc = __glXGetCurrentContext();
430     const GLuint cmdlen = 8;
431 emit_header(gc->pc, X_GLrop_Begin, cmdlen);
432 (void) memcpy((void *)(gc->pc + 4), (void *)(&mode), 4);
433 gc->pc += cmdlen;
434 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
435 }
436 
437 #define X_GLrop_Bitmap 5
__indirect_glBitmap(GLsizei width,GLsizei height,GLfloat xorig,GLfloat yorig,GLfloat xmove,GLfloat ymove,const GLubyte * bitmap)438 void __indirect_glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte * bitmap)
439 {
440     struct glx_context * const gc = __glXGetCurrentContext();
441     const GLuint compsize = (bitmap != NULL) ? __glImageSize(width, height, 1, GL_COLOR_INDEX, GL_BITMAP, 0) : 0;
442     const GLuint cmdlen = 48 + __GLX_PAD(compsize);
443     if (__builtin_expect(gc->currentDpy != NULL, 1)) {
444 if (cmdlen <= gc->maxSmallRenderCommandSize) {
445     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
446         (void) __glXFlushRenderBuffer(gc, gc->pc);
447     }
448 emit_header(gc->pc, X_GLrop_Bitmap, cmdlen);
449 (void) memcpy((void *)(gc->pc + 24), (void *)(&width), 4);
450 (void) memcpy((void *)(gc->pc + 28), (void *)(&height), 4);
451 (void) memcpy((void *)(gc->pc + 32), (void *)(&xorig), 4);
452 (void) memcpy((void *)(gc->pc + 36), (void *)(&yorig), 4);
453 (void) memcpy((void *)(gc->pc + 40), (void *)(&xmove), 4);
454 (void) memcpy((void *)(gc->pc + 44), (void *)(&ymove), 4);
455 if (compsize > 0) {
456     (*gc->fillImage)(gc, 2, width, height, 1, GL_COLOR_INDEX, GL_BITMAP, bitmap, gc->pc + 48, gc->pc + 4);
457 } else {
458     (void) memcpy( gc->pc + 4, default_pixel_store_2D, default_pixel_store_2D_size );
459 }
460 gc->pc += cmdlen;
461 if (gc->pc > gc->limit) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
462 }
463 else {
464 const GLint op = X_GLrop_Bitmap;
465 const GLuint cmdlenLarge = cmdlen + 4;
466 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
467 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
468 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
469 (void) memcpy((void *)(pc + 28), (void *)(&width), 4);
470 (void) memcpy((void *)(pc + 32), (void *)(&height), 4);
471 (void) memcpy((void *)(pc + 36), (void *)(&xorig), 4);
472 (void) memcpy((void *)(pc + 40), (void *)(&yorig), 4);
473 (void) memcpy((void *)(pc + 44), (void *)(&xmove), 4);
474 (void) memcpy((void *)(pc + 48), (void *)(&ymove), 4);
475 __glXSendLargeImage(gc, compsize, 2, width, height, 1, GL_COLOR_INDEX, GL_BITMAP, bitmap, pc + 52, pc + 8);
476 }
477     }
478 }
479 
480 #define X_GLrop_Color3bv 6
__indirect_glColor3b(GLbyte red,GLbyte green,GLbyte blue)481 void __indirect_glColor3b(GLbyte red, GLbyte green, GLbyte blue)
482 {
483     struct glx_context * const gc = __glXGetCurrentContext();
484     const GLuint cmdlen = 8;
485 emit_header(gc->pc, X_GLrop_Color3bv, cmdlen);
486 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 1);
487 (void) memcpy((void *)(gc->pc + 5), (void *)(&green), 1);
488 (void) memcpy((void *)(gc->pc + 6), (void *)(&blue), 1);
489 gc->pc += cmdlen;
490 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
491 }
492 
493 #define X_GLrop_Color3bv 6
__indirect_glColor3bv(const GLbyte * v)494 void __indirect_glColor3bv(const GLbyte * v)
495 {
496     generic_3_byte( X_GLrop_Color3bv, v );
497 }
498 
499 #define X_GLrop_Color3dv 7
__indirect_glColor3d(GLdouble red,GLdouble green,GLdouble blue)500 void __indirect_glColor3d(GLdouble red, GLdouble green, GLdouble blue)
501 {
502     struct glx_context * const gc = __glXGetCurrentContext();
503     const GLuint cmdlen = 28;
504 emit_header(gc->pc, X_GLrop_Color3dv, cmdlen);
505 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 8);
506 (void) memcpy((void *)(gc->pc + 12), (void *)(&green), 8);
507 (void) memcpy((void *)(gc->pc + 20), (void *)(&blue), 8);
508 gc->pc += cmdlen;
509 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
510 }
511 
512 #define X_GLrop_Color3dv 7
__indirect_glColor3dv(const GLdouble * v)513 void __indirect_glColor3dv(const GLdouble * v)
514 {
515     generic_24_byte( X_GLrop_Color3dv, v );
516 }
517 
518 #define X_GLrop_Color3fv 8
__indirect_glColor3f(GLfloat red,GLfloat green,GLfloat blue)519 void __indirect_glColor3f(GLfloat red, GLfloat green, GLfloat blue)
520 {
521     struct glx_context * const gc = __glXGetCurrentContext();
522     const GLuint cmdlen = 16;
523 emit_header(gc->pc, X_GLrop_Color3fv, cmdlen);
524 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
525 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
526 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
527 gc->pc += cmdlen;
528 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
529 }
530 
531 #define X_GLrop_Color3fv 8
__indirect_glColor3fv(const GLfloat * v)532 void __indirect_glColor3fv(const GLfloat * v)
533 {
534     generic_12_byte( X_GLrop_Color3fv, v );
535 }
536 
537 #define X_GLrop_Color3iv 9
__indirect_glColor3i(GLint red,GLint green,GLint blue)538 void __indirect_glColor3i(GLint red, GLint green, GLint blue)
539 {
540     struct glx_context * const gc = __glXGetCurrentContext();
541     const GLuint cmdlen = 16;
542 emit_header(gc->pc, X_GLrop_Color3iv, cmdlen);
543 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
544 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
545 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
546 gc->pc += cmdlen;
547 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
548 }
549 
550 #define X_GLrop_Color3iv 9
__indirect_glColor3iv(const GLint * v)551 void __indirect_glColor3iv(const GLint * v)
552 {
553     generic_12_byte( X_GLrop_Color3iv, v );
554 }
555 
556 #define X_GLrop_Color3sv 10
__indirect_glColor3s(GLshort red,GLshort green,GLshort blue)557 void __indirect_glColor3s(GLshort red, GLshort green, GLshort blue)
558 {
559     struct glx_context * const gc = __glXGetCurrentContext();
560     const GLuint cmdlen = 12;
561 emit_header(gc->pc, X_GLrop_Color3sv, cmdlen);
562 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 2);
563 (void) memcpy((void *)(gc->pc + 6), (void *)(&green), 2);
564 (void) memcpy((void *)(gc->pc + 8), (void *)(&blue), 2);
565 gc->pc += cmdlen;
566 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
567 }
568 
569 #define X_GLrop_Color3sv 10
__indirect_glColor3sv(const GLshort * v)570 void __indirect_glColor3sv(const GLshort * v)
571 {
572     generic_6_byte( X_GLrop_Color3sv, v );
573 }
574 
575 #define X_GLrop_Color3ubv 11
__indirect_glColor3ub(GLubyte red,GLubyte green,GLubyte blue)576 void __indirect_glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
577 {
578     struct glx_context * const gc = __glXGetCurrentContext();
579     const GLuint cmdlen = 8;
580 emit_header(gc->pc, X_GLrop_Color3ubv, cmdlen);
581 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 1);
582 (void) memcpy((void *)(gc->pc + 5), (void *)(&green), 1);
583 (void) memcpy((void *)(gc->pc + 6), (void *)(&blue), 1);
584 gc->pc += cmdlen;
585 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
586 }
587 
588 #define X_GLrop_Color3ubv 11
__indirect_glColor3ubv(const GLubyte * v)589 void __indirect_glColor3ubv(const GLubyte * v)
590 {
591     generic_3_byte( X_GLrop_Color3ubv, v );
592 }
593 
594 #define X_GLrop_Color3uiv 12
__indirect_glColor3ui(GLuint red,GLuint green,GLuint blue)595 void __indirect_glColor3ui(GLuint red, GLuint green, GLuint blue)
596 {
597     struct glx_context * const gc = __glXGetCurrentContext();
598     const GLuint cmdlen = 16;
599 emit_header(gc->pc, X_GLrop_Color3uiv, cmdlen);
600 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
601 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
602 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
603 gc->pc += cmdlen;
604 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
605 }
606 
607 #define X_GLrop_Color3uiv 12
__indirect_glColor3uiv(const GLuint * v)608 void __indirect_glColor3uiv(const GLuint * v)
609 {
610     generic_12_byte( X_GLrop_Color3uiv, v );
611 }
612 
613 #define X_GLrop_Color3usv 13
__indirect_glColor3us(GLushort red,GLushort green,GLushort blue)614 void __indirect_glColor3us(GLushort red, GLushort green, GLushort blue)
615 {
616     struct glx_context * const gc = __glXGetCurrentContext();
617     const GLuint cmdlen = 12;
618 emit_header(gc->pc, X_GLrop_Color3usv, cmdlen);
619 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 2);
620 (void) memcpy((void *)(gc->pc + 6), (void *)(&green), 2);
621 (void) memcpy((void *)(gc->pc + 8), (void *)(&blue), 2);
622 gc->pc += cmdlen;
623 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
624 }
625 
626 #define X_GLrop_Color3usv 13
__indirect_glColor3usv(const GLushort * v)627 void __indirect_glColor3usv(const GLushort * v)
628 {
629     generic_6_byte( X_GLrop_Color3usv, v );
630 }
631 
632 #define X_GLrop_Color4bv 14
__indirect_glColor4b(GLbyte red,GLbyte green,GLbyte blue,GLbyte alpha)633 void __indirect_glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
634 {
635     struct glx_context * const gc = __glXGetCurrentContext();
636     const GLuint cmdlen = 8;
637 emit_header(gc->pc, X_GLrop_Color4bv, cmdlen);
638 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 1);
639 (void) memcpy((void *)(gc->pc + 5), (void *)(&green), 1);
640 (void) memcpy((void *)(gc->pc + 6), (void *)(&blue), 1);
641 (void) memcpy((void *)(gc->pc + 7), (void *)(&alpha), 1);
642 gc->pc += cmdlen;
643 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
644 }
645 
646 #define X_GLrop_Color4bv 14
__indirect_glColor4bv(const GLbyte * v)647 void __indirect_glColor4bv(const GLbyte * v)
648 {
649     generic_4_byte( X_GLrop_Color4bv, v );
650 }
651 
652 #define X_GLrop_Color4dv 15
__indirect_glColor4d(GLdouble red,GLdouble green,GLdouble blue,GLdouble alpha)653 void __indirect_glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
654 {
655     struct glx_context * const gc = __glXGetCurrentContext();
656     const GLuint cmdlen = 36;
657 emit_header(gc->pc, X_GLrop_Color4dv, cmdlen);
658 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 8);
659 (void) memcpy((void *)(gc->pc + 12), (void *)(&green), 8);
660 (void) memcpy((void *)(gc->pc + 20), (void *)(&blue), 8);
661 (void) memcpy((void *)(gc->pc + 28), (void *)(&alpha), 8);
662 gc->pc += cmdlen;
663 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
664 }
665 
666 #define X_GLrop_Color4dv 15
__indirect_glColor4dv(const GLdouble * v)667 void __indirect_glColor4dv(const GLdouble * v)
668 {
669     generic_32_byte( X_GLrop_Color4dv, v );
670 }
671 
672 #define X_GLrop_Color4fv 16
__indirect_glColor4f(GLfloat red,GLfloat green,GLfloat blue,GLfloat alpha)673 void __indirect_glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
674 {
675     struct glx_context * const gc = __glXGetCurrentContext();
676     const GLuint cmdlen = 20;
677 emit_header(gc->pc, X_GLrop_Color4fv, cmdlen);
678 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
679 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
680 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
681 (void) memcpy((void *)(gc->pc + 16), (void *)(&alpha), 4);
682 gc->pc += cmdlen;
683 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
684 }
685 
686 #define X_GLrop_Color4fv 16
__indirect_glColor4fv(const GLfloat * v)687 void __indirect_glColor4fv(const GLfloat * v)
688 {
689     generic_16_byte( X_GLrop_Color4fv, v );
690 }
691 
692 #define X_GLrop_Color4iv 17
__indirect_glColor4i(GLint red,GLint green,GLint blue,GLint alpha)693 void __indirect_glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
694 {
695     struct glx_context * const gc = __glXGetCurrentContext();
696     const GLuint cmdlen = 20;
697 emit_header(gc->pc, X_GLrop_Color4iv, cmdlen);
698 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
699 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
700 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
701 (void) memcpy((void *)(gc->pc + 16), (void *)(&alpha), 4);
702 gc->pc += cmdlen;
703 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
704 }
705 
706 #define X_GLrop_Color4iv 17
__indirect_glColor4iv(const GLint * v)707 void __indirect_glColor4iv(const GLint * v)
708 {
709     generic_16_byte( X_GLrop_Color4iv, v );
710 }
711 
712 #define X_GLrop_Color4sv 18
__indirect_glColor4s(GLshort red,GLshort green,GLshort blue,GLshort alpha)713 void __indirect_glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
714 {
715     struct glx_context * const gc = __glXGetCurrentContext();
716     const GLuint cmdlen = 12;
717 emit_header(gc->pc, X_GLrop_Color4sv, cmdlen);
718 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 2);
719 (void) memcpy((void *)(gc->pc + 6), (void *)(&green), 2);
720 (void) memcpy((void *)(gc->pc + 8), (void *)(&blue), 2);
721 (void) memcpy((void *)(gc->pc + 10), (void *)(&alpha), 2);
722 gc->pc += cmdlen;
723 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
724 }
725 
726 #define X_GLrop_Color4sv 18
__indirect_glColor4sv(const GLshort * v)727 void __indirect_glColor4sv(const GLshort * v)
728 {
729     generic_8_byte( X_GLrop_Color4sv, v );
730 }
731 
732 #define X_GLrop_Color4ubv 19
__indirect_glColor4ub(GLubyte red,GLubyte green,GLubyte blue,GLubyte alpha)733 void __indirect_glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
734 {
735     struct glx_context * const gc = __glXGetCurrentContext();
736     const GLuint cmdlen = 8;
737 emit_header(gc->pc, X_GLrop_Color4ubv, cmdlen);
738 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 1);
739 (void) memcpy((void *)(gc->pc + 5), (void *)(&green), 1);
740 (void) memcpy((void *)(gc->pc + 6), (void *)(&blue), 1);
741 (void) memcpy((void *)(gc->pc + 7), (void *)(&alpha), 1);
742 gc->pc += cmdlen;
743 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
744 }
745 
746 #define X_GLrop_Color4ubv 19
__indirect_glColor4ubv(const GLubyte * v)747 void __indirect_glColor4ubv(const GLubyte * v)
748 {
749     generic_4_byte( X_GLrop_Color4ubv, v );
750 }
751 
752 #define X_GLrop_Color4uiv 20
__indirect_glColor4ui(GLuint red,GLuint green,GLuint blue,GLuint alpha)753 void __indirect_glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
754 {
755     struct glx_context * const gc = __glXGetCurrentContext();
756     const GLuint cmdlen = 20;
757 emit_header(gc->pc, X_GLrop_Color4uiv, cmdlen);
758 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
759 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
760 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
761 (void) memcpy((void *)(gc->pc + 16), (void *)(&alpha), 4);
762 gc->pc += cmdlen;
763 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
764 }
765 
766 #define X_GLrop_Color4uiv 20
__indirect_glColor4uiv(const GLuint * v)767 void __indirect_glColor4uiv(const GLuint * v)
768 {
769     generic_16_byte( X_GLrop_Color4uiv, v );
770 }
771 
772 #define X_GLrop_Color4usv 21
__indirect_glColor4us(GLushort red,GLushort green,GLushort blue,GLushort alpha)773 void __indirect_glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
774 {
775     struct glx_context * const gc = __glXGetCurrentContext();
776     const GLuint cmdlen = 12;
777 emit_header(gc->pc, X_GLrop_Color4usv, cmdlen);
778 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 2);
779 (void) memcpy((void *)(gc->pc + 6), (void *)(&green), 2);
780 (void) memcpy((void *)(gc->pc + 8), (void *)(&blue), 2);
781 (void) memcpy((void *)(gc->pc + 10), (void *)(&alpha), 2);
782 gc->pc += cmdlen;
783 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
784 }
785 
786 #define X_GLrop_Color4usv 21
__indirect_glColor4usv(const GLushort * v)787 void __indirect_glColor4usv(const GLushort * v)
788 {
789     generic_8_byte( X_GLrop_Color4usv, v );
790 }
791 
792 #define X_GLrop_EdgeFlagv 22
__indirect_glEdgeFlag(GLboolean flag)793 void __indirect_glEdgeFlag(GLboolean flag)
794 {
795     struct glx_context * const gc = __glXGetCurrentContext();
796     const GLuint cmdlen = 8;
797 emit_header(gc->pc, X_GLrop_EdgeFlagv, cmdlen);
798 (void) memcpy((void *)(gc->pc + 4), (void *)(&flag), 1);
799 gc->pc += cmdlen;
800 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
801 }
802 
803 #define X_GLrop_EdgeFlagv 22
__indirect_glEdgeFlagv(const GLboolean * flag)804 void __indirect_glEdgeFlagv(const GLboolean * flag)
805 {
806     struct glx_context * const gc = __glXGetCurrentContext();
807     const GLuint cmdlen = 8;
808 emit_header(gc->pc, X_GLrop_EdgeFlagv, cmdlen);
809 (void) memcpy((void *)(gc->pc + 4), (void *)(flag), 1);
810 gc->pc += cmdlen;
811 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
812 }
813 
814 #define X_GLrop_End 23
__indirect_glEnd(void)815 void __indirect_glEnd(void)
816 {
817     struct glx_context * const gc = __glXGetCurrentContext();
818     const GLuint cmdlen = 4;
819 emit_header(gc->pc, X_GLrop_End, cmdlen);
820 gc->pc += cmdlen;
821 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
822 }
823 
824 #define X_GLrop_Indexdv 24
__indirect_glIndexd(GLdouble c)825 void __indirect_glIndexd(GLdouble c)
826 {
827     struct glx_context * const gc = __glXGetCurrentContext();
828     const GLuint cmdlen = 12;
829 emit_header(gc->pc, X_GLrop_Indexdv, cmdlen);
830 (void) memcpy((void *)(gc->pc + 4), (void *)(&c), 8);
831 gc->pc += cmdlen;
832 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
833 }
834 
835 #define X_GLrop_Indexdv 24
__indirect_glIndexdv(const GLdouble * c)836 void __indirect_glIndexdv(const GLdouble * c)
837 {
838     generic_8_byte( X_GLrop_Indexdv, c );
839 }
840 
841 #define X_GLrop_Indexfv 25
__indirect_glIndexf(GLfloat c)842 void __indirect_glIndexf(GLfloat c)
843 {
844     struct glx_context * const gc = __glXGetCurrentContext();
845     const GLuint cmdlen = 8;
846 emit_header(gc->pc, X_GLrop_Indexfv, cmdlen);
847 (void) memcpy((void *)(gc->pc + 4), (void *)(&c), 4);
848 gc->pc += cmdlen;
849 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
850 }
851 
852 #define X_GLrop_Indexfv 25
__indirect_glIndexfv(const GLfloat * c)853 void __indirect_glIndexfv(const GLfloat * c)
854 {
855     generic_4_byte( X_GLrop_Indexfv, c );
856 }
857 
858 #define X_GLrop_Indexiv 26
__indirect_glIndexi(GLint c)859 void __indirect_glIndexi(GLint c)
860 {
861     struct glx_context * const gc = __glXGetCurrentContext();
862     const GLuint cmdlen = 8;
863 emit_header(gc->pc, X_GLrop_Indexiv, cmdlen);
864 (void) memcpy((void *)(gc->pc + 4), (void *)(&c), 4);
865 gc->pc += cmdlen;
866 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
867 }
868 
869 #define X_GLrop_Indexiv 26
__indirect_glIndexiv(const GLint * c)870 void __indirect_glIndexiv(const GLint * c)
871 {
872     generic_4_byte( X_GLrop_Indexiv, c );
873 }
874 
875 #define X_GLrop_Indexsv 27
__indirect_glIndexs(GLshort c)876 void __indirect_glIndexs(GLshort c)
877 {
878     struct glx_context * const gc = __glXGetCurrentContext();
879     const GLuint cmdlen = 8;
880 emit_header(gc->pc, X_GLrop_Indexsv, cmdlen);
881 (void) memcpy((void *)(gc->pc + 4), (void *)(&c), 2);
882 gc->pc += cmdlen;
883 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
884 }
885 
886 #define X_GLrop_Indexsv 27
__indirect_glIndexsv(const GLshort * c)887 void __indirect_glIndexsv(const GLshort * c)
888 {
889     struct glx_context * const gc = __glXGetCurrentContext();
890     const GLuint cmdlen = 8;
891 emit_header(gc->pc, X_GLrop_Indexsv, cmdlen);
892 (void) memcpy((void *)(gc->pc + 4), (void *)(c), 2);
893 gc->pc += cmdlen;
894 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
895 }
896 
897 #define X_GLrop_Normal3bv 28
__indirect_glNormal3b(GLbyte nx,GLbyte ny,GLbyte nz)898 void __indirect_glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
899 {
900     struct glx_context * const gc = __glXGetCurrentContext();
901     const GLuint cmdlen = 8;
902 emit_header(gc->pc, X_GLrop_Normal3bv, cmdlen);
903 (void) memcpy((void *)(gc->pc + 4), (void *)(&nx), 1);
904 (void) memcpy((void *)(gc->pc + 5), (void *)(&ny), 1);
905 (void) memcpy((void *)(gc->pc + 6), (void *)(&nz), 1);
906 gc->pc += cmdlen;
907 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
908 }
909 
910 #define X_GLrop_Normal3bv 28
__indirect_glNormal3bv(const GLbyte * v)911 void __indirect_glNormal3bv(const GLbyte * v)
912 {
913     generic_3_byte( X_GLrop_Normal3bv, v );
914 }
915 
916 #define X_GLrop_Normal3dv 29
__indirect_glNormal3d(GLdouble nx,GLdouble ny,GLdouble nz)917 void __indirect_glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
918 {
919     struct glx_context * const gc = __glXGetCurrentContext();
920     const GLuint cmdlen = 28;
921 emit_header(gc->pc, X_GLrop_Normal3dv, cmdlen);
922 (void) memcpy((void *)(gc->pc + 4), (void *)(&nx), 8);
923 (void) memcpy((void *)(gc->pc + 12), (void *)(&ny), 8);
924 (void) memcpy((void *)(gc->pc + 20), (void *)(&nz), 8);
925 gc->pc += cmdlen;
926 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
927 }
928 
929 #define X_GLrop_Normal3dv 29
__indirect_glNormal3dv(const GLdouble * v)930 void __indirect_glNormal3dv(const GLdouble * v)
931 {
932     generic_24_byte( X_GLrop_Normal3dv, v );
933 }
934 
935 #define X_GLrop_Normal3fv 30
__indirect_glNormal3f(GLfloat nx,GLfloat ny,GLfloat nz)936 void __indirect_glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
937 {
938     struct glx_context * const gc = __glXGetCurrentContext();
939     const GLuint cmdlen = 16;
940 emit_header(gc->pc, X_GLrop_Normal3fv, cmdlen);
941 (void) memcpy((void *)(gc->pc + 4), (void *)(&nx), 4);
942 (void) memcpy((void *)(gc->pc + 8), (void *)(&ny), 4);
943 (void) memcpy((void *)(gc->pc + 12), (void *)(&nz), 4);
944 gc->pc += cmdlen;
945 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
946 }
947 
948 #define X_GLrop_Normal3fv 30
__indirect_glNormal3fv(const GLfloat * v)949 void __indirect_glNormal3fv(const GLfloat * v)
950 {
951     generic_12_byte( X_GLrop_Normal3fv, v );
952 }
953 
954 #define X_GLrop_Normal3iv 31
__indirect_glNormal3i(GLint nx,GLint ny,GLint nz)955 void __indirect_glNormal3i(GLint nx, GLint ny, GLint nz)
956 {
957     struct glx_context * const gc = __glXGetCurrentContext();
958     const GLuint cmdlen = 16;
959 emit_header(gc->pc, X_GLrop_Normal3iv, cmdlen);
960 (void) memcpy((void *)(gc->pc + 4), (void *)(&nx), 4);
961 (void) memcpy((void *)(gc->pc + 8), (void *)(&ny), 4);
962 (void) memcpy((void *)(gc->pc + 12), (void *)(&nz), 4);
963 gc->pc += cmdlen;
964 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
965 }
966 
967 #define X_GLrop_Normal3iv 31
__indirect_glNormal3iv(const GLint * v)968 void __indirect_glNormal3iv(const GLint * v)
969 {
970     generic_12_byte( X_GLrop_Normal3iv, v );
971 }
972 
973 #define X_GLrop_Normal3sv 32
__indirect_glNormal3s(GLshort nx,GLshort ny,GLshort nz)974 void __indirect_glNormal3s(GLshort nx, GLshort ny, GLshort nz)
975 {
976     struct glx_context * const gc = __glXGetCurrentContext();
977     const GLuint cmdlen = 12;
978 emit_header(gc->pc, X_GLrop_Normal3sv, cmdlen);
979 (void) memcpy((void *)(gc->pc + 4), (void *)(&nx), 2);
980 (void) memcpy((void *)(gc->pc + 6), (void *)(&ny), 2);
981 (void) memcpy((void *)(gc->pc + 8), (void *)(&nz), 2);
982 gc->pc += cmdlen;
983 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
984 }
985 
986 #define X_GLrop_Normal3sv 32
__indirect_glNormal3sv(const GLshort * v)987 void __indirect_glNormal3sv(const GLshort * v)
988 {
989     generic_6_byte( X_GLrop_Normal3sv, v );
990 }
991 
992 #define X_GLrop_RasterPos2dv 33
__indirect_glRasterPos2d(GLdouble x,GLdouble y)993 void __indirect_glRasterPos2d(GLdouble x, GLdouble y)
994 {
995     struct glx_context * const gc = __glXGetCurrentContext();
996     const GLuint cmdlen = 20;
997 emit_header(gc->pc, X_GLrop_RasterPos2dv, cmdlen);
998 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 8);
999 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 8);
1000 gc->pc += cmdlen;
1001 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1002 }
1003 
1004 #define X_GLrop_RasterPos2dv 33
__indirect_glRasterPos2dv(const GLdouble * v)1005 void __indirect_glRasterPos2dv(const GLdouble * v)
1006 {
1007     generic_16_byte( X_GLrop_RasterPos2dv, v );
1008 }
1009 
1010 #define X_GLrop_RasterPos2fv 34
__indirect_glRasterPos2f(GLfloat x,GLfloat y)1011 void __indirect_glRasterPos2f(GLfloat x, GLfloat y)
1012 {
1013     struct glx_context * const gc = __glXGetCurrentContext();
1014     const GLuint cmdlen = 12;
1015 emit_header(gc->pc, X_GLrop_RasterPos2fv, cmdlen);
1016 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1017 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1018 gc->pc += cmdlen;
1019 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1020 }
1021 
1022 #define X_GLrop_RasterPos2fv 34
__indirect_glRasterPos2fv(const GLfloat * v)1023 void __indirect_glRasterPos2fv(const GLfloat * v)
1024 {
1025     generic_8_byte( X_GLrop_RasterPos2fv, v );
1026 }
1027 
1028 #define X_GLrop_RasterPos2iv 35
__indirect_glRasterPos2i(GLint x,GLint y)1029 void __indirect_glRasterPos2i(GLint x, GLint y)
1030 {
1031     struct glx_context * const gc = __glXGetCurrentContext();
1032     const GLuint cmdlen = 12;
1033 emit_header(gc->pc, X_GLrop_RasterPos2iv, cmdlen);
1034 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1035 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1036 gc->pc += cmdlen;
1037 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1038 }
1039 
1040 #define X_GLrop_RasterPos2iv 35
__indirect_glRasterPos2iv(const GLint * v)1041 void __indirect_glRasterPos2iv(const GLint * v)
1042 {
1043     generic_8_byte( X_GLrop_RasterPos2iv, v );
1044 }
1045 
1046 #define X_GLrop_RasterPos2sv 36
__indirect_glRasterPos2s(GLshort x,GLshort y)1047 void __indirect_glRasterPos2s(GLshort x, GLshort y)
1048 {
1049     struct glx_context * const gc = __glXGetCurrentContext();
1050     const GLuint cmdlen = 8;
1051 emit_header(gc->pc, X_GLrop_RasterPos2sv, cmdlen);
1052 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 2);
1053 (void) memcpy((void *)(gc->pc + 6), (void *)(&y), 2);
1054 gc->pc += cmdlen;
1055 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1056 }
1057 
1058 #define X_GLrop_RasterPos2sv 36
__indirect_glRasterPos2sv(const GLshort * v)1059 void __indirect_glRasterPos2sv(const GLshort * v)
1060 {
1061     generic_4_byte( X_GLrop_RasterPos2sv, v );
1062 }
1063 
1064 #define X_GLrop_RasterPos3dv 37
__indirect_glRasterPos3d(GLdouble x,GLdouble y,GLdouble z)1065 void __indirect_glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
1066 {
1067     struct glx_context * const gc = __glXGetCurrentContext();
1068     const GLuint cmdlen = 28;
1069 emit_header(gc->pc, X_GLrop_RasterPos3dv, cmdlen);
1070 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 8);
1071 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 8);
1072 (void) memcpy((void *)(gc->pc + 20), (void *)(&z), 8);
1073 gc->pc += cmdlen;
1074 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1075 }
1076 
1077 #define X_GLrop_RasterPos3dv 37
__indirect_glRasterPos3dv(const GLdouble * v)1078 void __indirect_glRasterPos3dv(const GLdouble * v)
1079 {
1080     generic_24_byte( X_GLrop_RasterPos3dv, v );
1081 }
1082 
1083 #define X_GLrop_RasterPos3fv 38
__indirect_glRasterPos3f(GLfloat x,GLfloat y,GLfloat z)1084 void __indirect_glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
1085 {
1086     struct glx_context * const gc = __glXGetCurrentContext();
1087     const GLuint cmdlen = 16;
1088 emit_header(gc->pc, X_GLrop_RasterPos3fv, cmdlen);
1089 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1090 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1091 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
1092 gc->pc += cmdlen;
1093 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1094 }
1095 
1096 #define X_GLrop_RasterPos3fv 38
__indirect_glRasterPos3fv(const GLfloat * v)1097 void __indirect_glRasterPos3fv(const GLfloat * v)
1098 {
1099     generic_12_byte( X_GLrop_RasterPos3fv, v );
1100 }
1101 
1102 #define X_GLrop_RasterPos3iv 39
__indirect_glRasterPos3i(GLint x,GLint y,GLint z)1103 void __indirect_glRasterPos3i(GLint x, GLint y, GLint z)
1104 {
1105     struct glx_context * const gc = __glXGetCurrentContext();
1106     const GLuint cmdlen = 16;
1107 emit_header(gc->pc, X_GLrop_RasterPos3iv, cmdlen);
1108 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1109 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1110 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
1111 gc->pc += cmdlen;
1112 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1113 }
1114 
1115 #define X_GLrop_RasterPos3iv 39
__indirect_glRasterPos3iv(const GLint * v)1116 void __indirect_glRasterPos3iv(const GLint * v)
1117 {
1118     generic_12_byte( X_GLrop_RasterPos3iv, v );
1119 }
1120 
1121 #define X_GLrop_RasterPos3sv 40
__indirect_glRasterPos3s(GLshort x,GLshort y,GLshort z)1122 void __indirect_glRasterPos3s(GLshort x, GLshort y, GLshort z)
1123 {
1124     struct glx_context * const gc = __glXGetCurrentContext();
1125     const GLuint cmdlen = 12;
1126 emit_header(gc->pc, X_GLrop_RasterPos3sv, cmdlen);
1127 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 2);
1128 (void) memcpy((void *)(gc->pc + 6), (void *)(&y), 2);
1129 (void) memcpy((void *)(gc->pc + 8), (void *)(&z), 2);
1130 gc->pc += cmdlen;
1131 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1132 }
1133 
1134 #define X_GLrop_RasterPos3sv 40
__indirect_glRasterPos3sv(const GLshort * v)1135 void __indirect_glRasterPos3sv(const GLshort * v)
1136 {
1137     generic_6_byte( X_GLrop_RasterPos3sv, v );
1138 }
1139 
1140 #define X_GLrop_RasterPos4dv 41
__indirect_glRasterPos4d(GLdouble x,GLdouble y,GLdouble z,GLdouble w)1141 void __indirect_glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
1142 {
1143     struct glx_context * const gc = __glXGetCurrentContext();
1144     const GLuint cmdlen = 36;
1145 emit_header(gc->pc, X_GLrop_RasterPos4dv, cmdlen);
1146 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 8);
1147 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 8);
1148 (void) memcpy((void *)(gc->pc + 20), (void *)(&z), 8);
1149 (void) memcpy((void *)(gc->pc + 28), (void *)(&w), 8);
1150 gc->pc += cmdlen;
1151 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1152 }
1153 
1154 #define X_GLrop_RasterPos4dv 41
__indirect_glRasterPos4dv(const GLdouble * v)1155 void __indirect_glRasterPos4dv(const GLdouble * v)
1156 {
1157     generic_32_byte( X_GLrop_RasterPos4dv, v );
1158 }
1159 
1160 #define X_GLrop_RasterPos4fv 42
__indirect_glRasterPos4f(GLfloat x,GLfloat y,GLfloat z,GLfloat w)1161 void __indirect_glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
1162 {
1163     struct glx_context * const gc = __glXGetCurrentContext();
1164     const GLuint cmdlen = 20;
1165 emit_header(gc->pc, X_GLrop_RasterPos4fv, cmdlen);
1166 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1167 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1168 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
1169 (void) memcpy((void *)(gc->pc + 16), (void *)(&w), 4);
1170 gc->pc += cmdlen;
1171 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1172 }
1173 
1174 #define X_GLrop_RasterPos4fv 42
__indirect_glRasterPos4fv(const GLfloat * v)1175 void __indirect_glRasterPos4fv(const GLfloat * v)
1176 {
1177     generic_16_byte( X_GLrop_RasterPos4fv, v );
1178 }
1179 
1180 #define X_GLrop_RasterPos4iv 43
__indirect_glRasterPos4i(GLint x,GLint y,GLint z,GLint w)1181 void __indirect_glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
1182 {
1183     struct glx_context * const gc = __glXGetCurrentContext();
1184     const GLuint cmdlen = 20;
1185 emit_header(gc->pc, X_GLrop_RasterPos4iv, cmdlen);
1186 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1187 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1188 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
1189 (void) memcpy((void *)(gc->pc + 16), (void *)(&w), 4);
1190 gc->pc += cmdlen;
1191 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1192 }
1193 
1194 #define X_GLrop_RasterPos4iv 43
__indirect_glRasterPos4iv(const GLint * v)1195 void __indirect_glRasterPos4iv(const GLint * v)
1196 {
1197     generic_16_byte( X_GLrop_RasterPos4iv, v );
1198 }
1199 
1200 #define X_GLrop_RasterPos4sv 44
__indirect_glRasterPos4s(GLshort x,GLshort y,GLshort z,GLshort w)1201 void __indirect_glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
1202 {
1203     struct glx_context * const gc = __glXGetCurrentContext();
1204     const GLuint cmdlen = 12;
1205 emit_header(gc->pc, X_GLrop_RasterPos4sv, cmdlen);
1206 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 2);
1207 (void) memcpy((void *)(gc->pc + 6), (void *)(&y), 2);
1208 (void) memcpy((void *)(gc->pc + 8), (void *)(&z), 2);
1209 (void) memcpy((void *)(gc->pc + 10), (void *)(&w), 2);
1210 gc->pc += cmdlen;
1211 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1212 }
1213 
1214 #define X_GLrop_RasterPos4sv 44
__indirect_glRasterPos4sv(const GLshort * v)1215 void __indirect_glRasterPos4sv(const GLshort * v)
1216 {
1217     generic_8_byte( X_GLrop_RasterPos4sv, v );
1218 }
1219 
1220 #define X_GLrop_Rectdv 45
__indirect_glRectd(GLdouble x1,GLdouble y1,GLdouble x2,GLdouble y2)1221 void __indirect_glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
1222 {
1223     struct glx_context * const gc = __glXGetCurrentContext();
1224     const GLuint cmdlen = 36;
1225 emit_header(gc->pc, X_GLrop_Rectdv, cmdlen);
1226 (void) memcpy((void *)(gc->pc + 4), (void *)(&x1), 8);
1227 (void) memcpy((void *)(gc->pc + 12), (void *)(&y1), 8);
1228 (void) memcpy((void *)(gc->pc + 20), (void *)(&x2), 8);
1229 (void) memcpy((void *)(gc->pc + 28), (void *)(&y2), 8);
1230 gc->pc += cmdlen;
1231 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1232 }
1233 
1234 #define X_GLrop_Rectdv 45
__indirect_glRectdv(const GLdouble * v1,const GLdouble * v2)1235 void __indirect_glRectdv(const GLdouble * v1, const GLdouble * v2)
1236 {
1237     struct glx_context * const gc = __glXGetCurrentContext();
1238     const GLuint cmdlen = 36;
1239 emit_header(gc->pc, X_GLrop_Rectdv, cmdlen);
1240 (void) memcpy((void *)(gc->pc + 4), (void *)(v1), 16);
1241 (void) memcpy((void *)(gc->pc + 20), (void *)(v2), 16);
1242 gc->pc += cmdlen;
1243 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1244 }
1245 
1246 #define X_GLrop_Rectfv 46
__indirect_glRectf(GLfloat x1,GLfloat y1,GLfloat x2,GLfloat y2)1247 void __indirect_glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
1248 {
1249     struct glx_context * const gc = __glXGetCurrentContext();
1250     const GLuint cmdlen = 20;
1251 emit_header(gc->pc, X_GLrop_Rectfv, cmdlen);
1252 (void) memcpy((void *)(gc->pc + 4), (void *)(&x1), 4);
1253 (void) memcpy((void *)(gc->pc + 8), (void *)(&y1), 4);
1254 (void) memcpy((void *)(gc->pc + 12), (void *)(&x2), 4);
1255 (void) memcpy((void *)(gc->pc + 16), (void *)(&y2), 4);
1256 gc->pc += cmdlen;
1257 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1258 }
1259 
1260 #define X_GLrop_Rectfv 46
__indirect_glRectfv(const GLfloat * v1,const GLfloat * v2)1261 void __indirect_glRectfv(const GLfloat * v1, const GLfloat * v2)
1262 {
1263     struct glx_context * const gc = __glXGetCurrentContext();
1264     const GLuint cmdlen = 20;
1265 emit_header(gc->pc, X_GLrop_Rectfv, cmdlen);
1266 (void) memcpy((void *)(gc->pc + 4), (void *)(v1), 8);
1267 (void) memcpy((void *)(gc->pc + 12), (void *)(v2), 8);
1268 gc->pc += cmdlen;
1269 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1270 }
1271 
1272 #define X_GLrop_Rectiv 47
__indirect_glRecti(GLint x1,GLint y1,GLint x2,GLint y2)1273 void __indirect_glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
1274 {
1275     struct glx_context * const gc = __glXGetCurrentContext();
1276     const GLuint cmdlen = 20;
1277 emit_header(gc->pc, X_GLrop_Rectiv, cmdlen);
1278 (void) memcpy((void *)(gc->pc + 4), (void *)(&x1), 4);
1279 (void) memcpy((void *)(gc->pc + 8), (void *)(&y1), 4);
1280 (void) memcpy((void *)(gc->pc + 12), (void *)(&x2), 4);
1281 (void) memcpy((void *)(gc->pc + 16), (void *)(&y2), 4);
1282 gc->pc += cmdlen;
1283 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1284 }
1285 
1286 #define X_GLrop_Rectiv 47
__indirect_glRectiv(const GLint * v1,const GLint * v2)1287 void __indirect_glRectiv(const GLint * v1, const GLint * v2)
1288 {
1289     struct glx_context * const gc = __glXGetCurrentContext();
1290     const GLuint cmdlen = 20;
1291 emit_header(gc->pc, X_GLrop_Rectiv, cmdlen);
1292 (void) memcpy((void *)(gc->pc + 4), (void *)(v1), 8);
1293 (void) memcpy((void *)(gc->pc + 12), (void *)(v2), 8);
1294 gc->pc += cmdlen;
1295 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1296 }
1297 
1298 #define X_GLrop_Rectsv 48
__indirect_glRects(GLshort x1,GLshort y1,GLshort x2,GLshort y2)1299 void __indirect_glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
1300 {
1301     struct glx_context * const gc = __glXGetCurrentContext();
1302     const GLuint cmdlen = 12;
1303 emit_header(gc->pc, X_GLrop_Rectsv, cmdlen);
1304 (void) memcpy((void *)(gc->pc + 4), (void *)(&x1), 2);
1305 (void) memcpy((void *)(gc->pc + 6), (void *)(&y1), 2);
1306 (void) memcpy((void *)(gc->pc + 8), (void *)(&x2), 2);
1307 (void) memcpy((void *)(gc->pc + 10), (void *)(&y2), 2);
1308 gc->pc += cmdlen;
1309 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1310 }
1311 
1312 #define X_GLrop_Rectsv 48
__indirect_glRectsv(const GLshort * v1,const GLshort * v2)1313 void __indirect_glRectsv(const GLshort * v1, const GLshort * v2)
1314 {
1315     struct glx_context * const gc = __glXGetCurrentContext();
1316     const GLuint cmdlen = 12;
1317 emit_header(gc->pc, X_GLrop_Rectsv, cmdlen);
1318 (void) memcpy((void *)(gc->pc + 4), (void *)(v1), 4);
1319 (void) memcpy((void *)(gc->pc + 8), (void *)(v2), 4);
1320 gc->pc += cmdlen;
1321 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1322 }
1323 
1324 #define X_GLrop_TexCoord1dv 49
__indirect_glTexCoord1d(GLdouble s)1325 void __indirect_glTexCoord1d(GLdouble s)
1326 {
1327     struct glx_context * const gc = __glXGetCurrentContext();
1328     const GLuint cmdlen = 12;
1329 emit_header(gc->pc, X_GLrop_TexCoord1dv, cmdlen);
1330 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 8);
1331 gc->pc += cmdlen;
1332 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1333 }
1334 
1335 #define X_GLrop_TexCoord1dv 49
__indirect_glTexCoord1dv(const GLdouble * v)1336 void __indirect_glTexCoord1dv(const GLdouble * v)
1337 {
1338     generic_8_byte( X_GLrop_TexCoord1dv, v );
1339 }
1340 
1341 #define X_GLrop_TexCoord1fv 50
__indirect_glTexCoord1f(GLfloat s)1342 void __indirect_glTexCoord1f(GLfloat s)
1343 {
1344     struct glx_context * const gc = __glXGetCurrentContext();
1345     const GLuint cmdlen = 8;
1346 emit_header(gc->pc, X_GLrop_TexCoord1fv, cmdlen);
1347 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 4);
1348 gc->pc += cmdlen;
1349 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1350 }
1351 
1352 #define X_GLrop_TexCoord1fv 50
__indirect_glTexCoord1fv(const GLfloat * v)1353 void __indirect_glTexCoord1fv(const GLfloat * v)
1354 {
1355     generic_4_byte( X_GLrop_TexCoord1fv, v );
1356 }
1357 
1358 #define X_GLrop_TexCoord1iv 51
__indirect_glTexCoord1i(GLint s)1359 void __indirect_glTexCoord1i(GLint s)
1360 {
1361     struct glx_context * const gc = __glXGetCurrentContext();
1362     const GLuint cmdlen = 8;
1363 emit_header(gc->pc, X_GLrop_TexCoord1iv, cmdlen);
1364 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 4);
1365 gc->pc += cmdlen;
1366 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1367 }
1368 
1369 #define X_GLrop_TexCoord1iv 51
__indirect_glTexCoord1iv(const GLint * v)1370 void __indirect_glTexCoord1iv(const GLint * v)
1371 {
1372     generic_4_byte( X_GLrop_TexCoord1iv, v );
1373 }
1374 
1375 #define X_GLrop_TexCoord1sv 52
__indirect_glTexCoord1s(GLshort s)1376 void __indirect_glTexCoord1s(GLshort s)
1377 {
1378     struct glx_context * const gc = __glXGetCurrentContext();
1379     const GLuint cmdlen = 8;
1380 emit_header(gc->pc, X_GLrop_TexCoord1sv, cmdlen);
1381 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 2);
1382 gc->pc += cmdlen;
1383 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1384 }
1385 
1386 #define X_GLrop_TexCoord1sv 52
__indirect_glTexCoord1sv(const GLshort * v)1387 void __indirect_glTexCoord1sv(const GLshort * v)
1388 {
1389     struct glx_context * const gc = __glXGetCurrentContext();
1390     const GLuint cmdlen = 8;
1391 emit_header(gc->pc, X_GLrop_TexCoord1sv, cmdlen);
1392 (void) memcpy((void *)(gc->pc + 4), (void *)(v), 2);
1393 gc->pc += cmdlen;
1394 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1395 }
1396 
1397 #define X_GLrop_TexCoord2dv 53
__indirect_glTexCoord2d(GLdouble s,GLdouble t)1398 void __indirect_glTexCoord2d(GLdouble s, GLdouble t)
1399 {
1400     struct glx_context * const gc = __glXGetCurrentContext();
1401     const GLuint cmdlen = 20;
1402 emit_header(gc->pc, X_GLrop_TexCoord2dv, cmdlen);
1403 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 8);
1404 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 8);
1405 gc->pc += cmdlen;
1406 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1407 }
1408 
1409 #define X_GLrop_TexCoord2dv 53
__indirect_glTexCoord2dv(const GLdouble * v)1410 void __indirect_glTexCoord2dv(const GLdouble * v)
1411 {
1412     generic_16_byte( X_GLrop_TexCoord2dv, v );
1413 }
1414 
1415 #define X_GLrop_TexCoord2fv 54
__indirect_glTexCoord2f(GLfloat s,GLfloat t)1416 void __indirect_glTexCoord2f(GLfloat s, GLfloat t)
1417 {
1418     struct glx_context * const gc = __glXGetCurrentContext();
1419     const GLuint cmdlen = 12;
1420 emit_header(gc->pc, X_GLrop_TexCoord2fv, cmdlen);
1421 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 4);
1422 (void) memcpy((void *)(gc->pc + 8), (void *)(&t), 4);
1423 gc->pc += cmdlen;
1424 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1425 }
1426 
1427 #define X_GLrop_TexCoord2fv 54
__indirect_glTexCoord2fv(const GLfloat * v)1428 void __indirect_glTexCoord2fv(const GLfloat * v)
1429 {
1430     generic_8_byte( X_GLrop_TexCoord2fv, v );
1431 }
1432 
1433 #define X_GLrop_TexCoord2iv 55
__indirect_glTexCoord2i(GLint s,GLint t)1434 void __indirect_glTexCoord2i(GLint s, GLint t)
1435 {
1436     struct glx_context * const gc = __glXGetCurrentContext();
1437     const GLuint cmdlen = 12;
1438 emit_header(gc->pc, X_GLrop_TexCoord2iv, cmdlen);
1439 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 4);
1440 (void) memcpy((void *)(gc->pc + 8), (void *)(&t), 4);
1441 gc->pc += cmdlen;
1442 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1443 }
1444 
1445 #define X_GLrop_TexCoord2iv 55
__indirect_glTexCoord2iv(const GLint * v)1446 void __indirect_glTexCoord2iv(const GLint * v)
1447 {
1448     generic_8_byte( X_GLrop_TexCoord2iv, v );
1449 }
1450 
1451 #define X_GLrop_TexCoord2sv 56
__indirect_glTexCoord2s(GLshort s,GLshort t)1452 void __indirect_glTexCoord2s(GLshort s, GLshort t)
1453 {
1454     struct glx_context * const gc = __glXGetCurrentContext();
1455     const GLuint cmdlen = 8;
1456 emit_header(gc->pc, X_GLrop_TexCoord2sv, cmdlen);
1457 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 2);
1458 (void) memcpy((void *)(gc->pc + 6), (void *)(&t), 2);
1459 gc->pc += cmdlen;
1460 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1461 }
1462 
1463 #define X_GLrop_TexCoord2sv 56
__indirect_glTexCoord2sv(const GLshort * v)1464 void __indirect_glTexCoord2sv(const GLshort * v)
1465 {
1466     generic_4_byte( X_GLrop_TexCoord2sv, v );
1467 }
1468 
1469 #define X_GLrop_TexCoord3dv 57
__indirect_glTexCoord3d(GLdouble s,GLdouble t,GLdouble r)1470 void __indirect_glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
1471 {
1472     struct glx_context * const gc = __glXGetCurrentContext();
1473     const GLuint cmdlen = 28;
1474 emit_header(gc->pc, X_GLrop_TexCoord3dv, cmdlen);
1475 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 8);
1476 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 8);
1477 (void) memcpy((void *)(gc->pc + 20), (void *)(&r), 8);
1478 gc->pc += cmdlen;
1479 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1480 }
1481 
1482 #define X_GLrop_TexCoord3dv 57
__indirect_glTexCoord3dv(const GLdouble * v)1483 void __indirect_glTexCoord3dv(const GLdouble * v)
1484 {
1485     generic_24_byte( X_GLrop_TexCoord3dv, v );
1486 }
1487 
1488 #define X_GLrop_TexCoord3fv 58
__indirect_glTexCoord3f(GLfloat s,GLfloat t,GLfloat r)1489 void __indirect_glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
1490 {
1491     struct glx_context * const gc = __glXGetCurrentContext();
1492     const GLuint cmdlen = 16;
1493 emit_header(gc->pc, X_GLrop_TexCoord3fv, cmdlen);
1494 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 4);
1495 (void) memcpy((void *)(gc->pc + 8), (void *)(&t), 4);
1496 (void) memcpy((void *)(gc->pc + 12), (void *)(&r), 4);
1497 gc->pc += cmdlen;
1498 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1499 }
1500 
1501 #define X_GLrop_TexCoord3fv 58
__indirect_glTexCoord3fv(const GLfloat * v)1502 void __indirect_glTexCoord3fv(const GLfloat * v)
1503 {
1504     generic_12_byte( X_GLrop_TexCoord3fv, v );
1505 }
1506 
1507 #define X_GLrop_TexCoord3iv 59
__indirect_glTexCoord3i(GLint s,GLint t,GLint r)1508 void __indirect_glTexCoord3i(GLint s, GLint t, GLint r)
1509 {
1510     struct glx_context * const gc = __glXGetCurrentContext();
1511     const GLuint cmdlen = 16;
1512 emit_header(gc->pc, X_GLrop_TexCoord3iv, cmdlen);
1513 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 4);
1514 (void) memcpy((void *)(gc->pc + 8), (void *)(&t), 4);
1515 (void) memcpy((void *)(gc->pc + 12), (void *)(&r), 4);
1516 gc->pc += cmdlen;
1517 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1518 }
1519 
1520 #define X_GLrop_TexCoord3iv 59
__indirect_glTexCoord3iv(const GLint * v)1521 void __indirect_glTexCoord3iv(const GLint * v)
1522 {
1523     generic_12_byte( X_GLrop_TexCoord3iv, v );
1524 }
1525 
1526 #define X_GLrop_TexCoord3sv 60
__indirect_glTexCoord3s(GLshort s,GLshort t,GLshort r)1527 void __indirect_glTexCoord3s(GLshort s, GLshort t, GLshort r)
1528 {
1529     struct glx_context * const gc = __glXGetCurrentContext();
1530     const GLuint cmdlen = 12;
1531 emit_header(gc->pc, X_GLrop_TexCoord3sv, cmdlen);
1532 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 2);
1533 (void) memcpy((void *)(gc->pc + 6), (void *)(&t), 2);
1534 (void) memcpy((void *)(gc->pc + 8), (void *)(&r), 2);
1535 gc->pc += cmdlen;
1536 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1537 }
1538 
1539 #define X_GLrop_TexCoord3sv 60
__indirect_glTexCoord3sv(const GLshort * v)1540 void __indirect_glTexCoord3sv(const GLshort * v)
1541 {
1542     generic_6_byte( X_GLrop_TexCoord3sv, v );
1543 }
1544 
1545 #define X_GLrop_TexCoord4dv 61
__indirect_glTexCoord4d(GLdouble s,GLdouble t,GLdouble r,GLdouble q)1546 void __indirect_glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
1547 {
1548     struct glx_context * const gc = __glXGetCurrentContext();
1549     const GLuint cmdlen = 36;
1550 emit_header(gc->pc, X_GLrop_TexCoord4dv, cmdlen);
1551 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 8);
1552 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 8);
1553 (void) memcpy((void *)(gc->pc + 20), (void *)(&r), 8);
1554 (void) memcpy((void *)(gc->pc + 28), (void *)(&q), 8);
1555 gc->pc += cmdlen;
1556 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1557 }
1558 
1559 #define X_GLrop_TexCoord4dv 61
__indirect_glTexCoord4dv(const GLdouble * v)1560 void __indirect_glTexCoord4dv(const GLdouble * v)
1561 {
1562     generic_32_byte( X_GLrop_TexCoord4dv, v );
1563 }
1564 
1565 #define X_GLrop_TexCoord4fv 62
__indirect_glTexCoord4f(GLfloat s,GLfloat t,GLfloat r,GLfloat q)1566 void __indirect_glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
1567 {
1568     struct glx_context * const gc = __glXGetCurrentContext();
1569     const GLuint cmdlen = 20;
1570 emit_header(gc->pc, X_GLrop_TexCoord4fv, cmdlen);
1571 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 4);
1572 (void) memcpy((void *)(gc->pc + 8), (void *)(&t), 4);
1573 (void) memcpy((void *)(gc->pc + 12), (void *)(&r), 4);
1574 (void) memcpy((void *)(gc->pc + 16), (void *)(&q), 4);
1575 gc->pc += cmdlen;
1576 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1577 }
1578 
1579 #define X_GLrop_TexCoord4fv 62
__indirect_glTexCoord4fv(const GLfloat * v)1580 void __indirect_glTexCoord4fv(const GLfloat * v)
1581 {
1582     generic_16_byte( X_GLrop_TexCoord4fv, v );
1583 }
1584 
1585 #define X_GLrop_TexCoord4iv 63
__indirect_glTexCoord4i(GLint s,GLint t,GLint r,GLint q)1586 void __indirect_glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
1587 {
1588     struct glx_context * const gc = __glXGetCurrentContext();
1589     const GLuint cmdlen = 20;
1590 emit_header(gc->pc, X_GLrop_TexCoord4iv, cmdlen);
1591 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 4);
1592 (void) memcpy((void *)(gc->pc + 8), (void *)(&t), 4);
1593 (void) memcpy((void *)(gc->pc + 12), (void *)(&r), 4);
1594 (void) memcpy((void *)(gc->pc + 16), (void *)(&q), 4);
1595 gc->pc += cmdlen;
1596 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1597 }
1598 
1599 #define X_GLrop_TexCoord4iv 63
__indirect_glTexCoord4iv(const GLint * v)1600 void __indirect_glTexCoord4iv(const GLint * v)
1601 {
1602     generic_16_byte( X_GLrop_TexCoord4iv, v );
1603 }
1604 
1605 #define X_GLrop_TexCoord4sv 64
__indirect_glTexCoord4s(GLshort s,GLshort t,GLshort r,GLshort q)1606 void __indirect_glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
1607 {
1608     struct glx_context * const gc = __glXGetCurrentContext();
1609     const GLuint cmdlen = 12;
1610 emit_header(gc->pc, X_GLrop_TexCoord4sv, cmdlen);
1611 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 2);
1612 (void) memcpy((void *)(gc->pc + 6), (void *)(&t), 2);
1613 (void) memcpy((void *)(gc->pc + 8), (void *)(&r), 2);
1614 (void) memcpy((void *)(gc->pc + 10), (void *)(&q), 2);
1615 gc->pc += cmdlen;
1616 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1617 }
1618 
1619 #define X_GLrop_TexCoord4sv 64
__indirect_glTexCoord4sv(const GLshort * v)1620 void __indirect_glTexCoord4sv(const GLshort * v)
1621 {
1622     generic_8_byte( X_GLrop_TexCoord4sv, v );
1623 }
1624 
1625 #define X_GLrop_Vertex2dv 65
__indirect_glVertex2d(GLdouble x,GLdouble y)1626 void __indirect_glVertex2d(GLdouble x, GLdouble y)
1627 {
1628     struct glx_context * const gc = __glXGetCurrentContext();
1629     const GLuint cmdlen = 20;
1630 emit_header(gc->pc, X_GLrop_Vertex2dv, cmdlen);
1631 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 8);
1632 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 8);
1633 gc->pc += cmdlen;
1634 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1635 }
1636 
1637 #define X_GLrop_Vertex2dv 65
__indirect_glVertex2dv(const GLdouble * v)1638 void __indirect_glVertex2dv(const GLdouble * v)
1639 {
1640     generic_16_byte( X_GLrop_Vertex2dv, v );
1641 }
1642 
1643 #define X_GLrop_Vertex2fv 66
__indirect_glVertex2f(GLfloat x,GLfloat y)1644 void __indirect_glVertex2f(GLfloat x, GLfloat y)
1645 {
1646     struct glx_context * const gc = __glXGetCurrentContext();
1647     const GLuint cmdlen = 12;
1648 emit_header(gc->pc, X_GLrop_Vertex2fv, cmdlen);
1649 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1650 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1651 gc->pc += cmdlen;
1652 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1653 }
1654 
1655 #define X_GLrop_Vertex2fv 66
__indirect_glVertex2fv(const GLfloat * v)1656 void __indirect_glVertex2fv(const GLfloat * v)
1657 {
1658     generic_8_byte( X_GLrop_Vertex2fv, v );
1659 }
1660 
1661 #define X_GLrop_Vertex2iv 67
__indirect_glVertex2i(GLint x,GLint y)1662 void __indirect_glVertex2i(GLint x, GLint y)
1663 {
1664     struct glx_context * const gc = __glXGetCurrentContext();
1665     const GLuint cmdlen = 12;
1666 emit_header(gc->pc, X_GLrop_Vertex2iv, cmdlen);
1667 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1668 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1669 gc->pc += cmdlen;
1670 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1671 }
1672 
1673 #define X_GLrop_Vertex2iv 67
__indirect_glVertex2iv(const GLint * v)1674 void __indirect_glVertex2iv(const GLint * v)
1675 {
1676     generic_8_byte( X_GLrop_Vertex2iv, v );
1677 }
1678 
1679 #define X_GLrop_Vertex2sv 68
__indirect_glVertex2s(GLshort x,GLshort y)1680 void __indirect_glVertex2s(GLshort x, GLshort y)
1681 {
1682     struct glx_context * const gc = __glXGetCurrentContext();
1683     const GLuint cmdlen = 8;
1684 emit_header(gc->pc, X_GLrop_Vertex2sv, cmdlen);
1685 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 2);
1686 (void) memcpy((void *)(gc->pc + 6), (void *)(&y), 2);
1687 gc->pc += cmdlen;
1688 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1689 }
1690 
1691 #define X_GLrop_Vertex2sv 68
__indirect_glVertex2sv(const GLshort * v)1692 void __indirect_glVertex2sv(const GLshort * v)
1693 {
1694     generic_4_byte( X_GLrop_Vertex2sv, v );
1695 }
1696 
1697 #define X_GLrop_Vertex3dv 69
__indirect_glVertex3d(GLdouble x,GLdouble y,GLdouble z)1698 void __indirect_glVertex3d(GLdouble x, GLdouble y, GLdouble z)
1699 {
1700     struct glx_context * const gc = __glXGetCurrentContext();
1701     const GLuint cmdlen = 28;
1702 emit_header(gc->pc, X_GLrop_Vertex3dv, cmdlen);
1703 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 8);
1704 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 8);
1705 (void) memcpy((void *)(gc->pc + 20), (void *)(&z), 8);
1706 gc->pc += cmdlen;
1707 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1708 }
1709 
1710 #define X_GLrop_Vertex3dv 69
__indirect_glVertex3dv(const GLdouble * v)1711 void __indirect_glVertex3dv(const GLdouble * v)
1712 {
1713     generic_24_byte( X_GLrop_Vertex3dv, v );
1714 }
1715 
1716 #define X_GLrop_Vertex3fv 70
__indirect_glVertex3f(GLfloat x,GLfloat y,GLfloat z)1717 void __indirect_glVertex3f(GLfloat x, GLfloat y, GLfloat z)
1718 {
1719     struct glx_context * const gc = __glXGetCurrentContext();
1720     const GLuint cmdlen = 16;
1721 emit_header(gc->pc, X_GLrop_Vertex3fv, cmdlen);
1722 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1723 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1724 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
1725 gc->pc += cmdlen;
1726 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1727 }
1728 
1729 #define X_GLrop_Vertex3fv 70
__indirect_glVertex3fv(const GLfloat * v)1730 void __indirect_glVertex3fv(const GLfloat * v)
1731 {
1732     generic_12_byte( X_GLrop_Vertex3fv, v );
1733 }
1734 
1735 #define X_GLrop_Vertex3iv 71
__indirect_glVertex3i(GLint x,GLint y,GLint z)1736 void __indirect_glVertex3i(GLint x, GLint y, GLint z)
1737 {
1738     struct glx_context * const gc = __glXGetCurrentContext();
1739     const GLuint cmdlen = 16;
1740 emit_header(gc->pc, X_GLrop_Vertex3iv, cmdlen);
1741 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1742 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1743 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
1744 gc->pc += cmdlen;
1745 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1746 }
1747 
1748 #define X_GLrop_Vertex3iv 71
__indirect_glVertex3iv(const GLint * v)1749 void __indirect_glVertex3iv(const GLint * v)
1750 {
1751     generic_12_byte( X_GLrop_Vertex3iv, v );
1752 }
1753 
1754 #define X_GLrop_Vertex3sv 72
__indirect_glVertex3s(GLshort x,GLshort y,GLshort z)1755 void __indirect_glVertex3s(GLshort x, GLshort y, GLshort z)
1756 {
1757     struct glx_context * const gc = __glXGetCurrentContext();
1758     const GLuint cmdlen = 12;
1759 emit_header(gc->pc, X_GLrop_Vertex3sv, cmdlen);
1760 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 2);
1761 (void) memcpy((void *)(gc->pc + 6), (void *)(&y), 2);
1762 (void) memcpy((void *)(gc->pc + 8), (void *)(&z), 2);
1763 gc->pc += cmdlen;
1764 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1765 }
1766 
1767 #define X_GLrop_Vertex3sv 72
__indirect_glVertex3sv(const GLshort * v)1768 void __indirect_glVertex3sv(const GLshort * v)
1769 {
1770     generic_6_byte( X_GLrop_Vertex3sv, v );
1771 }
1772 
1773 #define X_GLrop_Vertex4dv 73
__indirect_glVertex4d(GLdouble x,GLdouble y,GLdouble z,GLdouble w)1774 void __indirect_glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
1775 {
1776     struct glx_context * const gc = __glXGetCurrentContext();
1777     const GLuint cmdlen = 36;
1778 emit_header(gc->pc, X_GLrop_Vertex4dv, cmdlen);
1779 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 8);
1780 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 8);
1781 (void) memcpy((void *)(gc->pc + 20), (void *)(&z), 8);
1782 (void) memcpy((void *)(gc->pc + 28), (void *)(&w), 8);
1783 gc->pc += cmdlen;
1784 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1785 }
1786 
1787 #define X_GLrop_Vertex4dv 73
__indirect_glVertex4dv(const GLdouble * v)1788 void __indirect_glVertex4dv(const GLdouble * v)
1789 {
1790     generic_32_byte( X_GLrop_Vertex4dv, v );
1791 }
1792 
1793 #define X_GLrop_Vertex4fv 74
__indirect_glVertex4f(GLfloat x,GLfloat y,GLfloat z,GLfloat w)1794 void __indirect_glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
1795 {
1796     struct glx_context * const gc = __glXGetCurrentContext();
1797     const GLuint cmdlen = 20;
1798 emit_header(gc->pc, X_GLrop_Vertex4fv, cmdlen);
1799 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1800 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1801 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
1802 (void) memcpy((void *)(gc->pc + 16), (void *)(&w), 4);
1803 gc->pc += cmdlen;
1804 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1805 }
1806 
1807 #define X_GLrop_Vertex4fv 74
__indirect_glVertex4fv(const GLfloat * v)1808 void __indirect_glVertex4fv(const GLfloat * v)
1809 {
1810     generic_16_byte( X_GLrop_Vertex4fv, v );
1811 }
1812 
1813 #define X_GLrop_Vertex4iv 75
__indirect_glVertex4i(GLint x,GLint y,GLint z,GLint w)1814 void __indirect_glVertex4i(GLint x, GLint y, GLint z, GLint w)
1815 {
1816     struct glx_context * const gc = __glXGetCurrentContext();
1817     const GLuint cmdlen = 20;
1818 emit_header(gc->pc, X_GLrop_Vertex4iv, cmdlen);
1819 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
1820 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
1821 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
1822 (void) memcpy((void *)(gc->pc + 16), (void *)(&w), 4);
1823 gc->pc += cmdlen;
1824 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1825 }
1826 
1827 #define X_GLrop_Vertex4iv 75
__indirect_glVertex4iv(const GLint * v)1828 void __indirect_glVertex4iv(const GLint * v)
1829 {
1830     generic_16_byte( X_GLrop_Vertex4iv, v );
1831 }
1832 
1833 #define X_GLrop_Vertex4sv 76
__indirect_glVertex4s(GLshort x,GLshort y,GLshort z,GLshort w)1834 void __indirect_glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
1835 {
1836     struct glx_context * const gc = __glXGetCurrentContext();
1837     const GLuint cmdlen = 12;
1838 emit_header(gc->pc, X_GLrop_Vertex4sv, cmdlen);
1839 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 2);
1840 (void) memcpy((void *)(gc->pc + 6), (void *)(&y), 2);
1841 (void) memcpy((void *)(gc->pc + 8), (void *)(&z), 2);
1842 (void) memcpy((void *)(gc->pc + 10), (void *)(&w), 2);
1843 gc->pc += cmdlen;
1844 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1845 }
1846 
1847 #define X_GLrop_Vertex4sv 76
__indirect_glVertex4sv(const GLshort * v)1848 void __indirect_glVertex4sv(const GLshort * v)
1849 {
1850     generic_8_byte( X_GLrop_Vertex4sv, v );
1851 }
1852 
1853 #define X_GLrop_ClipPlane 77
__indirect_glClipPlane(GLenum plane,const GLdouble * equation)1854 void __indirect_glClipPlane(GLenum plane, const GLdouble * equation)
1855 {
1856     struct glx_context * const gc = __glXGetCurrentContext();
1857     const GLuint cmdlen = 40;
1858 emit_header(gc->pc, X_GLrop_ClipPlane, cmdlen);
1859 (void) memcpy((void *)(gc->pc + 4), (void *)(equation), 32);
1860 (void) memcpy((void *)(gc->pc + 36), (void *)(&plane), 4);
1861 gc->pc += cmdlen;
1862 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1863 }
1864 
1865 #define X_GLrop_ColorMaterial 78
__indirect_glColorMaterial(GLenum face,GLenum mode)1866 void __indirect_glColorMaterial(GLenum face, GLenum mode)
1867 {
1868     struct glx_context * const gc = __glXGetCurrentContext();
1869     const GLuint cmdlen = 12;
1870 emit_header(gc->pc, X_GLrop_ColorMaterial, cmdlen);
1871 (void) memcpy((void *)(gc->pc + 4), (void *)(&face), 4);
1872 (void) memcpy((void *)(gc->pc + 8), (void *)(&mode), 4);
1873 gc->pc += cmdlen;
1874 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1875 }
1876 
1877 #define X_GLrop_CullFace 79
__indirect_glCullFace(GLenum mode)1878 void __indirect_glCullFace(GLenum mode)
1879 {
1880     struct glx_context * const gc = __glXGetCurrentContext();
1881     const GLuint cmdlen = 8;
1882 emit_header(gc->pc, X_GLrop_CullFace, cmdlen);
1883 (void) memcpy((void *)(gc->pc + 4), (void *)(&mode), 4);
1884 gc->pc += cmdlen;
1885 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1886 }
1887 
1888 #define X_GLrop_Fogf 80
__indirect_glFogf(GLenum pname,GLfloat param)1889 void __indirect_glFogf(GLenum pname, GLfloat param)
1890 {
1891     struct glx_context * const gc = __glXGetCurrentContext();
1892     const GLuint cmdlen = 12;
1893 emit_header(gc->pc, X_GLrop_Fogf, cmdlen);
1894 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
1895 (void) memcpy((void *)(gc->pc + 8), (void *)(&param), 4);
1896 gc->pc += cmdlen;
1897 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1898 }
1899 
1900 #define X_GLrop_Fogfv 81
__indirect_glFogfv(GLenum pname,const GLfloat * params)1901 void __indirect_glFogfv(GLenum pname, const GLfloat * params)
1902 {
1903     struct glx_context * const gc = __glXGetCurrentContext();
1904     const GLuint compsize = __glFogfv_size(pname);
1905     const GLuint cmdlen = 8 + __GLX_PAD((compsize * 4));
1906 emit_header(gc->pc, X_GLrop_Fogfv, cmdlen);
1907 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
1908 (void) memcpy((void *)(gc->pc + 8), (void *)(params), (compsize * 4));
1909 gc->pc += cmdlen;
1910 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1911 }
1912 
1913 #define X_GLrop_Fogi 82
__indirect_glFogi(GLenum pname,GLint param)1914 void __indirect_glFogi(GLenum pname, GLint param)
1915 {
1916     struct glx_context * const gc = __glXGetCurrentContext();
1917     const GLuint cmdlen = 12;
1918 emit_header(gc->pc, X_GLrop_Fogi, cmdlen);
1919 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
1920 (void) memcpy((void *)(gc->pc + 8), (void *)(&param), 4);
1921 gc->pc += cmdlen;
1922 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1923 }
1924 
1925 #define X_GLrop_Fogiv 83
__indirect_glFogiv(GLenum pname,const GLint * params)1926 void __indirect_glFogiv(GLenum pname, const GLint * params)
1927 {
1928     struct glx_context * const gc = __glXGetCurrentContext();
1929     const GLuint compsize = __glFogiv_size(pname);
1930     const GLuint cmdlen = 8 + __GLX_PAD((compsize * 4));
1931 emit_header(gc->pc, X_GLrop_Fogiv, cmdlen);
1932 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
1933 (void) memcpy((void *)(gc->pc + 8), (void *)(params), (compsize * 4));
1934 gc->pc += cmdlen;
1935 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1936 }
1937 
1938 #define X_GLrop_FrontFace 84
__indirect_glFrontFace(GLenum mode)1939 void __indirect_glFrontFace(GLenum mode)
1940 {
1941     struct glx_context * const gc = __glXGetCurrentContext();
1942     const GLuint cmdlen = 8;
1943 emit_header(gc->pc, X_GLrop_FrontFace, cmdlen);
1944 (void) memcpy((void *)(gc->pc + 4), (void *)(&mode), 4);
1945 gc->pc += cmdlen;
1946 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1947 }
1948 
1949 #define X_GLrop_Hint 85
__indirect_glHint(GLenum target,GLenum mode)1950 void __indirect_glHint(GLenum target, GLenum mode)
1951 {
1952     struct glx_context * const gc = __glXGetCurrentContext();
1953     const GLuint cmdlen = 12;
1954 emit_header(gc->pc, X_GLrop_Hint, cmdlen);
1955 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
1956 (void) memcpy((void *)(gc->pc + 8), (void *)(&mode), 4);
1957 gc->pc += cmdlen;
1958 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1959 }
1960 
1961 #define X_GLrop_Lightf 86
__indirect_glLightf(GLenum light,GLenum pname,GLfloat param)1962 void __indirect_glLightf(GLenum light, GLenum pname, GLfloat param)
1963 {
1964     struct glx_context * const gc = __glXGetCurrentContext();
1965     const GLuint cmdlen = 16;
1966 emit_header(gc->pc, X_GLrop_Lightf, cmdlen);
1967 (void) memcpy((void *)(gc->pc + 4), (void *)(&light), 4);
1968 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
1969 (void) memcpy((void *)(gc->pc + 12), (void *)(&param), 4);
1970 gc->pc += cmdlen;
1971 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1972 }
1973 
1974 #define X_GLrop_Lightfv 87
__indirect_glLightfv(GLenum light,GLenum pname,const GLfloat * params)1975 void __indirect_glLightfv(GLenum light, GLenum pname, const GLfloat * params)
1976 {
1977     struct glx_context * const gc = __glXGetCurrentContext();
1978     const GLuint compsize = __glLightfv_size(pname);
1979     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
1980 emit_header(gc->pc, X_GLrop_Lightfv, cmdlen);
1981 (void) memcpy((void *)(gc->pc + 4), (void *)(&light), 4);
1982 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
1983 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
1984 gc->pc += cmdlen;
1985 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1986 }
1987 
1988 #define X_GLrop_Lighti 88
__indirect_glLighti(GLenum light,GLenum pname,GLint param)1989 void __indirect_glLighti(GLenum light, GLenum pname, GLint param)
1990 {
1991     struct glx_context * const gc = __glXGetCurrentContext();
1992     const GLuint cmdlen = 16;
1993 emit_header(gc->pc, X_GLrop_Lighti, cmdlen);
1994 (void) memcpy((void *)(gc->pc + 4), (void *)(&light), 4);
1995 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
1996 (void) memcpy((void *)(gc->pc + 12), (void *)(&param), 4);
1997 gc->pc += cmdlen;
1998 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
1999 }
2000 
2001 #define X_GLrop_Lightiv 89
__indirect_glLightiv(GLenum light,GLenum pname,const GLint * params)2002 void __indirect_glLightiv(GLenum light, GLenum pname, const GLint * params)
2003 {
2004     struct glx_context * const gc = __glXGetCurrentContext();
2005     const GLuint compsize = __glLightiv_size(pname);
2006     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
2007 emit_header(gc->pc, X_GLrop_Lightiv, cmdlen);
2008 (void) memcpy((void *)(gc->pc + 4), (void *)(&light), 4);
2009 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2010 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
2011 gc->pc += cmdlen;
2012 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2013 }
2014 
2015 #define X_GLrop_LightModelf 90
__indirect_glLightModelf(GLenum pname,GLfloat param)2016 void __indirect_glLightModelf(GLenum pname, GLfloat param)
2017 {
2018     struct glx_context * const gc = __glXGetCurrentContext();
2019     const GLuint cmdlen = 12;
2020 emit_header(gc->pc, X_GLrop_LightModelf, cmdlen);
2021 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
2022 (void) memcpy((void *)(gc->pc + 8), (void *)(&param), 4);
2023 gc->pc += cmdlen;
2024 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2025 }
2026 
2027 #define X_GLrop_LightModelfv 91
__indirect_glLightModelfv(GLenum pname,const GLfloat * params)2028 void __indirect_glLightModelfv(GLenum pname, const GLfloat * params)
2029 {
2030     struct glx_context * const gc = __glXGetCurrentContext();
2031     const GLuint compsize = __glLightModelfv_size(pname);
2032     const GLuint cmdlen = 8 + __GLX_PAD((compsize * 4));
2033 emit_header(gc->pc, X_GLrop_LightModelfv, cmdlen);
2034 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
2035 (void) memcpy((void *)(gc->pc + 8), (void *)(params), (compsize * 4));
2036 gc->pc += cmdlen;
2037 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2038 }
2039 
2040 #define X_GLrop_LightModeli 92
__indirect_glLightModeli(GLenum pname,GLint param)2041 void __indirect_glLightModeli(GLenum pname, GLint param)
2042 {
2043     struct glx_context * const gc = __glXGetCurrentContext();
2044     const GLuint cmdlen = 12;
2045 emit_header(gc->pc, X_GLrop_LightModeli, cmdlen);
2046 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
2047 (void) memcpy((void *)(gc->pc + 8), (void *)(&param), 4);
2048 gc->pc += cmdlen;
2049 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2050 }
2051 
2052 #define X_GLrop_LightModeliv 93
__indirect_glLightModeliv(GLenum pname,const GLint * params)2053 void __indirect_glLightModeliv(GLenum pname, const GLint * params)
2054 {
2055     struct glx_context * const gc = __glXGetCurrentContext();
2056     const GLuint compsize = __glLightModeliv_size(pname);
2057     const GLuint cmdlen = 8 + __GLX_PAD((compsize * 4));
2058 emit_header(gc->pc, X_GLrop_LightModeliv, cmdlen);
2059 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
2060 (void) memcpy((void *)(gc->pc + 8), (void *)(params), (compsize * 4));
2061 gc->pc += cmdlen;
2062 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2063 }
2064 
2065 #define X_GLrop_LineStipple 94
__indirect_glLineStipple(GLint factor,GLushort pattern)2066 void __indirect_glLineStipple(GLint factor, GLushort pattern)
2067 {
2068     struct glx_context * const gc = __glXGetCurrentContext();
2069     const GLuint cmdlen = 12;
2070 emit_header(gc->pc, X_GLrop_LineStipple, cmdlen);
2071 (void) memcpy((void *)(gc->pc + 4), (void *)(&factor), 4);
2072 (void) memcpy((void *)(gc->pc + 8), (void *)(&pattern), 2);
2073 gc->pc += cmdlen;
2074 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2075 }
2076 
2077 #define X_GLrop_LineWidth 95
__indirect_glLineWidth(GLfloat width)2078 void __indirect_glLineWidth(GLfloat width)
2079 {
2080     struct glx_context * const gc = __glXGetCurrentContext();
2081     const GLuint cmdlen = 8;
2082 emit_header(gc->pc, X_GLrop_LineWidth, cmdlen);
2083 (void) memcpy((void *)(gc->pc + 4), (void *)(&width), 4);
2084 gc->pc += cmdlen;
2085 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2086 }
2087 
2088 #define X_GLrop_Materialf 96
__indirect_glMaterialf(GLenum face,GLenum pname,GLfloat param)2089 void __indirect_glMaterialf(GLenum face, GLenum pname, GLfloat param)
2090 {
2091     struct glx_context * const gc = __glXGetCurrentContext();
2092     const GLuint cmdlen = 16;
2093 emit_header(gc->pc, X_GLrop_Materialf, cmdlen);
2094 (void) memcpy((void *)(gc->pc + 4), (void *)(&face), 4);
2095 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2096 (void) memcpy((void *)(gc->pc + 12), (void *)(&param), 4);
2097 gc->pc += cmdlen;
2098 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2099 }
2100 
2101 #define X_GLrop_Materialfv 97
__indirect_glMaterialfv(GLenum face,GLenum pname,const GLfloat * params)2102 void __indirect_glMaterialfv(GLenum face, GLenum pname, const GLfloat * params)
2103 {
2104     struct glx_context * const gc = __glXGetCurrentContext();
2105     const GLuint compsize = __glMaterialfv_size(pname);
2106     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
2107 emit_header(gc->pc, X_GLrop_Materialfv, cmdlen);
2108 (void) memcpy((void *)(gc->pc + 4), (void *)(&face), 4);
2109 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2110 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
2111 gc->pc += cmdlen;
2112 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2113 }
2114 
2115 #define X_GLrop_Materiali 98
__indirect_glMateriali(GLenum face,GLenum pname,GLint param)2116 void __indirect_glMateriali(GLenum face, GLenum pname, GLint param)
2117 {
2118     struct glx_context * const gc = __glXGetCurrentContext();
2119     const GLuint cmdlen = 16;
2120 emit_header(gc->pc, X_GLrop_Materiali, cmdlen);
2121 (void) memcpy((void *)(gc->pc + 4), (void *)(&face), 4);
2122 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2123 (void) memcpy((void *)(gc->pc + 12), (void *)(&param), 4);
2124 gc->pc += cmdlen;
2125 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2126 }
2127 
2128 #define X_GLrop_Materialiv 99
__indirect_glMaterialiv(GLenum face,GLenum pname,const GLint * params)2129 void __indirect_glMaterialiv(GLenum face, GLenum pname, const GLint * params)
2130 {
2131     struct glx_context * const gc = __glXGetCurrentContext();
2132     const GLuint compsize = __glMaterialiv_size(pname);
2133     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
2134 emit_header(gc->pc, X_GLrop_Materialiv, cmdlen);
2135 (void) memcpy((void *)(gc->pc + 4), (void *)(&face), 4);
2136 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2137 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
2138 gc->pc += cmdlen;
2139 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2140 }
2141 
2142 #define X_GLrop_PointSize 100
__indirect_glPointSize(GLfloat size)2143 void __indirect_glPointSize(GLfloat size)
2144 {
2145     struct glx_context * const gc = __glXGetCurrentContext();
2146     const GLuint cmdlen = 8;
2147 emit_header(gc->pc, X_GLrop_PointSize, cmdlen);
2148 (void) memcpy((void *)(gc->pc + 4), (void *)(&size), 4);
2149 gc->pc += cmdlen;
2150 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2151 }
2152 
2153 #define X_GLrop_PolygonMode 101
__indirect_glPolygonMode(GLenum face,GLenum mode)2154 void __indirect_glPolygonMode(GLenum face, GLenum mode)
2155 {
2156     struct glx_context * const gc = __glXGetCurrentContext();
2157     const GLuint cmdlen = 12;
2158 emit_header(gc->pc, X_GLrop_PolygonMode, cmdlen);
2159 (void) memcpy((void *)(gc->pc + 4), (void *)(&face), 4);
2160 (void) memcpy((void *)(gc->pc + 8), (void *)(&mode), 4);
2161 gc->pc += cmdlen;
2162 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2163 }
2164 
2165 #define X_GLrop_PolygonStipple 102
__indirect_glPolygonStipple(const GLubyte * mask)2166 void __indirect_glPolygonStipple(const GLubyte * mask)
2167 {
2168     struct glx_context * const gc = __glXGetCurrentContext();
2169     const GLuint compsize = (mask != NULL) ? __glImageSize(32, 32, 1, GL_COLOR_INDEX, GL_BITMAP, 0) : 0;
2170     const GLuint cmdlen = 24 + __GLX_PAD(compsize);
2171 emit_header(gc->pc, X_GLrop_PolygonStipple, cmdlen);
2172 if (compsize > 0) {
2173     (*gc->fillImage)(gc, 2, 32, 32, 1, GL_COLOR_INDEX, GL_BITMAP, mask, gc->pc + 24, gc->pc + 4);
2174 } else {
2175     (void) memcpy( gc->pc + 4, default_pixel_store_2D, default_pixel_store_2D_size );
2176 }
2177 gc->pc += cmdlen;
2178 if (gc->pc > gc->limit) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2179 }
2180 
2181 #define X_GLrop_Scissor 103
__indirect_glScissor(GLint x,GLint y,GLsizei width,GLsizei height)2182 void __indirect_glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
2183 {
2184     struct glx_context * const gc = __glXGetCurrentContext();
2185     const GLuint cmdlen = 20;
2186 emit_header(gc->pc, X_GLrop_Scissor, cmdlen);
2187 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
2188 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
2189 (void) memcpy((void *)(gc->pc + 12), (void *)(&width), 4);
2190 (void) memcpy((void *)(gc->pc + 16), (void *)(&height), 4);
2191 gc->pc += cmdlen;
2192 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2193 }
2194 
2195 #define X_GLrop_ShadeModel 104
__indirect_glShadeModel(GLenum mode)2196 void __indirect_glShadeModel(GLenum mode)
2197 {
2198     struct glx_context * const gc = __glXGetCurrentContext();
2199     const GLuint cmdlen = 8;
2200 emit_header(gc->pc, X_GLrop_ShadeModel, cmdlen);
2201 (void) memcpy((void *)(gc->pc + 4), (void *)(&mode), 4);
2202 gc->pc += cmdlen;
2203 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2204 }
2205 
2206 #define X_GLrop_TexParameterf 105
__indirect_glTexParameterf(GLenum target,GLenum pname,GLfloat param)2207 void __indirect_glTexParameterf(GLenum target, GLenum pname, GLfloat param)
2208 {
2209     struct glx_context * const gc = __glXGetCurrentContext();
2210     const GLuint cmdlen = 16;
2211 emit_header(gc->pc, X_GLrop_TexParameterf, cmdlen);
2212 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
2213 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2214 (void) memcpy((void *)(gc->pc + 12), (void *)(&param), 4);
2215 gc->pc += cmdlen;
2216 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2217 }
2218 
2219 #define X_GLrop_TexParameterfv 106
__indirect_glTexParameterfv(GLenum target,GLenum pname,const GLfloat * params)2220 void __indirect_glTexParameterfv(GLenum target, GLenum pname, const GLfloat * params)
2221 {
2222     struct glx_context * const gc = __glXGetCurrentContext();
2223     const GLuint compsize = __glTexParameterfv_size(pname);
2224     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
2225 emit_header(gc->pc, X_GLrop_TexParameterfv, cmdlen);
2226 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
2227 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2228 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
2229 gc->pc += cmdlen;
2230 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2231 }
2232 
2233 #define X_GLrop_TexParameteri 107
__indirect_glTexParameteri(GLenum target,GLenum pname,GLint param)2234 void __indirect_glTexParameteri(GLenum target, GLenum pname, GLint param)
2235 {
2236     struct glx_context * const gc = __glXGetCurrentContext();
2237     const GLuint cmdlen = 16;
2238 emit_header(gc->pc, X_GLrop_TexParameteri, cmdlen);
2239 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
2240 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2241 (void) memcpy((void *)(gc->pc + 12), (void *)(&param), 4);
2242 gc->pc += cmdlen;
2243 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2244 }
2245 
2246 #define X_GLrop_TexParameteriv 108
__indirect_glTexParameteriv(GLenum target,GLenum pname,const GLint * params)2247 void __indirect_glTexParameteriv(GLenum target, GLenum pname, const GLint * params)
2248 {
2249     struct glx_context * const gc = __glXGetCurrentContext();
2250     const GLuint compsize = __glTexParameteriv_size(pname);
2251     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
2252 emit_header(gc->pc, X_GLrop_TexParameteriv, cmdlen);
2253 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
2254 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2255 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
2256 gc->pc += cmdlen;
2257 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2258 }
2259 
2260 static void
__glx_TexImage_1D2D(unsigned opcode,unsigned dim,GLenum target,GLint level,GLint internalformat,GLsizei width,GLsizei height,GLint border,GLenum format,GLenum type,const GLvoid * pixels)2261 __glx_TexImage_1D2D( unsigned opcode, unsigned dim, GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid * pixels )
2262 {
2263     struct glx_context * const gc = __glXGetCurrentContext();
2264     const GLuint compsize = __glImageSize(width, height, 1, format, type, target);
2265     const GLuint cmdlen = 56 + __GLX_PAD(compsize);
2266     if (__builtin_expect(gc->currentDpy != NULL, 1)) {
2267 if (cmdlen <= gc->maxSmallRenderCommandSize) {
2268     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
2269         (void) __glXFlushRenderBuffer(gc, gc->pc);
2270     }
2271 emit_header(gc->pc, opcode, cmdlen);
2272 (void) memcpy((void *)(gc->pc + 24), (void *)(&target), 4);
2273 (void) memcpy((void *)(gc->pc + 28), (void *)(&level), 4);
2274 (void) memcpy((void *)(gc->pc + 32), (void *)(&internalformat), 4);
2275 (void) memcpy((void *)(gc->pc + 36), (void *)(&width), 4);
2276 (void) memcpy((void *)(gc->pc + 40), (void *)(&height), 4);
2277 (void) memcpy((void *)(gc->pc + 44), (void *)(&border), 4);
2278 (void) memcpy((void *)(gc->pc + 48), (void *)(&format), 4);
2279 (void) memcpy((void *)(gc->pc + 52), (void *)(&type), 4);
2280 if ((compsize > 0) && (pixels != NULL)) {
2281     (*gc->fillImage)(gc, dim, width, height, 1, format, type, pixels, gc->pc + 56, gc->pc + 4);
2282 } else {
2283     (void) memcpy( gc->pc + 4, default_pixel_store_2D, default_pixel_store_2D_size );
2284 }
2285 gc->pc += cmdlen;
2286 if (gc->pc > gc->limit) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2287 }
2288 else {
2289 const GLint op = opcode;
2290 const GLuint cmdlenLarge = cmdlen + 4;
2291 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
2292 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
2293 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
2294 (void) memcpy((void *)(pc + 28), (void *)(&target), 4);
2295 (void) memcpy((void *)(pc + 32), (void *)(&level), 4);
2296 (void) memcpy((void *)(pc + 36), (void *)(&internalformat), 4);
2297 (void) memcpy((void *)(pc + 40), (void *)(&width), 4);
2298 (void) memcpy((void *)(pc + 44), (void *)(&height), 4);
2299 (void) memcpy((void *)(pc + 48), (void *)(&border), 4);
2300 (void) memcpy((void *)(pc + 52), (void *)(&format), 4);
2301 (void) memcpy((void *)(pc + 56), (void *)(&type), 4);
2302 __glXSendLargeImage(gc, compsize, dim, width, height, 1, format, type, pixels, pc + 60, pc + 8);
2303 }
2304     }
2305 }
2306 
2307 #define X_GLrop_TexImage1D 109
__indirect_glTexImage1D(GLenum target,GLint level,GLint internalformat,GLsizei width,GLint border,GLenum format,GLenum type,const GLvoid * pixels)2308 void __indirect_glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid * pixels)
2309 {
2310     __glx_TexImage_1D2D(X_GLrop_TexImage1D, 1, target, level, internalformat, width, 1, border, format, type, pixels );
2311 }
2312 
2313 #define X_GLrop_TexImage2D 110
__indirect_glTexImage2D(GLenum target,GLint level,GLint internalformat,GLsizei width,GLsizei height,GLint border,GLenum format,GLenum type,const GLvoid * pixels)2314 void __indirect_glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid * pixels)
2315 {
2316     __glx_TexImage_1D2D(X_GLrop_TexImage2D, 2, target, level, internalformat, width, height, border, format, type, pixels );
2317 }
2318 
2319 #define X_GLrop_TexEnvf 111
__indirect_glTexEnvf(GLenum target,GLenum pname,GLfloat param)2320 void __indirect_glTexEnvf(GLenum target, GLenum pname, GLfloat param)
2321 {
2322     struct glx_context * const gc = __glXGetCurrentContext();
2323     const GLuint cmdlen = 16;
2324 emit_header(gc->pc, X_GLrop_TexEnvf, cmdlen);
2325 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
2326 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2327 (void) memcpy((void *)(gc->pc + 12), (void *)(&param), 4);
2328 gc->pc += cmdlen;
2329 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2330 }
2331 
2332 #define X_GLrop_TexEnvfv 112
__indirect_glTexEnvfv(GLenum target,GLenum pname,const GLfloat * params)2333 void __indirect_glTexEnvfv(GLenum target, GLenum pname, const GLfloat * params)
2334 {
2335     struct glx_context * const gc = __glXGetCurrentContext();
2336     const GLuint compsize = __glTexEnvfv_size(pname);
2337     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
2338 emit_header(gc->pc, X_GLrop_TexEnvfv, cmdlen);
2339 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
2340 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2341 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
2342 gc->pc += cmdlen;
2343 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2344 }
2345 
2346 #define X_GLrop_TexEnvi 113
__indirect_glTexEnvi(GLenum target,GLenum pname,GLint param)2347 void __indirect_glTexEnvi(GLenum target, GLenum pname, GLint param)
2348 {
2349     struct glx_context * const gc = __glXGetCurrentContext();
2350     const GLuint cmdlen = 16;
2351 emit_header(gc->pc, X_GLrop_TexEnvi, cmdlen);
2352 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
2353 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2354 (void) memcpy((void *)(gc->pc + 12), (void *)(&param), 4);
2355 gc->pc += cmdlen;
2356 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2357 }
2358 
2359 #define X_GLrop_TexEnviv 114
__indirect_glTexEnviv(GLenum target,GLenum pname,const GLint * params)2360 void __indirect_glTexEnviv(GLenum target, GLenum pname, const GLint * params)
2361 {
2362     struct glx_context * const gc = __glXGetCurrentContext();
2363     const GLuint compsize = __glTexEnviv_size(pname);
2364     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
2365 emit_header(gc->pc, X_GLrop_TexEnviv, cmdlen);
2366 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
2367 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2368 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
2369 gc->pc += cmdlen;
2370 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2371 }
2372 
2373 #define X_GLrop_TexGend 115
__indirect_glTexGend(GLenum coord,GLenum pname,GLdouble param)2374 void __indirect_glTexGend(GLenum coord, GLenum pname, GLdouble param)
2375 {
2376     struct glx_context * const gc = __glXGetCurrentContext();
2377     const GLuint cmdlen = 20;
2378 emit_header(gc->pc, X_GLrop_TexGend, cmdlen);
2379 (void) memcpy((void *)(gc->pc + 4), (void *)(&param), 8);
2380 (void) memcpy((void *)(gc->pc + 12), (void *)(&coord), 4);
2381 (void) memcpy((void *)(gc->pc + 16), (void *)(&pname), 4);
2382 gc->pc += cmdlen;
2383 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2384 }
2385 
2386 #define X_GLrop_TexGendv 116
__indirect_glTexGendv(GLenum coord,GLenum pname,const GLdouble * params)2387 void __indirect_glTexGendv(GLenum coord, GLenum pname, const GLdouble * params)
2388 {
2389     struct glx_context * const gc = __glXGetCurrentContext();
2390     const GLuint compsize = __glTexGendv_size(pname);
2391     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 8));
2392 emit_header(gc->pc, X_GLrop_TexGendv, cmdlen);
2393 (void) memcpy((void *)(gc->pc + 4), (void *)(&coord), 4);
2394 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2395 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 8));
2396 gc->pc += cmdlen;
2397 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2398 }
2399 
2400 #define X_GLrop_TexGenf 117
__indirect_glTexGenf(GLenum coord,GLenum pname,GLfloat param)2401 void __indirect_glTexGenf(GLenum coord, GLenum pname, GLfloat param)
2402 {
2403     struct glx_context * const gc = __glXGetCurrentContext();
2404     const GLuint cmdlen = 16;
2405 emit_header(gc->pc, X_GLrop_TexGenf, cmdlen);
2406 (void) memcpy((void *)(gc->pc + 4), (void *)(&coord), 4);
2407 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2408 (void) memcpy((void *)(gc->pc + 12), (void *)(&param), 4);
2409 gc->pc += cmdlen;
2410 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2411 }
2412 
2413 #define X_GLrop_TexGenfv 118
__indirect_glTexGenfv(GLenum coord,GLenum pname,const GLfloat * params)2414 void __indirect_glTexGenfv(GLenum coord, GLenum pname, const GLfloat * params)
2415 {
2416     struct glx_context * const gc = __glXGetCurrentContext();
2417     const GLuint compsize = __glTexGenfv_size(pname);
2418     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
2419 emit_header(gc->pc, X_GLrop_TexGenfv, cmdlen);
2420 (void) memcpy((void *)(gc->pc + 4), (void *)(&coord), 4);
2421 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2422 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
2423 gc->pc += cmdlen;
2424 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2425 }
2426 
2427 #define X_GLrop_TexGeni 119
__indirect_glTexGeni(GLenum coord,GLenum pname,GLint param)2428 void __indirect_glTexGeni(GLenum coord, GLenum pname, GLint param)
2429 {
2430     struct glx_context * const gc = __glXGetCurrentContext();
2431     const GLuint cmdlen = 16;
2432 emit_header(gc->pc, X_GLrop_TexGeni, cmdlen);
2433 (void) memcpy((void *)(gc->pc + 4), (void *)(&coord), 4);
2434 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2435 (void) memcpy((void *)(gc->pc + 12), (void *)(&param), 4);
2436 gc->pc += cmdlen;
2437 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2438 }
2439 
2440 #define X_GLrop_TexGeniv 120
__indirect_glTexGeniv(GLenum coord,GLenum pname,const GLint * params)2441 void __indirect_glTexGeniv(GLenum coord, GLenum pname, const GLint * params)
2442 {
2443     struct glx_context * const gc = __glXGetCurrentContext();
2444     const GLuint compsize = __glTexGeniv_size(pname);
2445     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
2446 emit_header(gc->pc, X_GLrop_TexGeniv, cmdlen);
2447 (void) memcpy((void *)(gc->pc + 4), (void *)(&coord), 4);
2448 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
2449 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
2450 gc->pc += cmdlen;
2451 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2452 }
2453 
2454 #define X_GLrop_InitNames 121
__indirect_glInitNames(void)2455 void __indirect_glInitNames(void)
2456 {
2457     struct glx_context * const gc = __glXGetCurrentContext();
2458     const GLuint cmdlen = 4;
2459 emit_header(gc->pc, X_GLrop_InitNames, cmdlen);
2460 gc->pc += cmdlen;
2461 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2462 }
2463 
2464 #define X_GLrop_LoadName 122
__indirect_glLoadName(GLuint name)2465 void __indirect_glLoadName(GLuint name)
2466 {
2467     struct glx_context * const gc = __glXGetCurrentContext();
2468     const GLuint cmdlen = 8;
2469 emit_header(gc->pc, X_GLrop_LoadName, cmdlen);
2470 (void) memcpy((void *)(gc->pc + 4), (void *)(&name), 4);
2471 gc->pc += cmdlen;
2472 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2473 }
2474 
2475 #define X_GLrop_PassThrough 123
__indirect_glPassThrough(GLfloat token)2476 void __indirect_glPassThrough(GLfloat token)
2477 {
2478     struct glx_context * const gc = __glXGetCurrentContext();
2479     const GLuint cmdlen = 8;
2480 emit_header(gc->pc, X_GLrop_PassThrough, cmdlen);
2481 (void) memcpy((void *)(gc->pc + 4), (void *)(&token), 4);
2482 gc->pc += cmdlen;
2483 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2484 }
2485 
2486 #define X_GLrop_PopName 124
__indirect_glPopName(void)2487 void __indirect_glPopName(void)
2488 {
2489     struct glx_context * const gc = __glXGetCurrentContext();
2490     const GLuint cmdlen = 4;
2491 emit_header(gc->pc, X_GLrop_PopName, cmdlen);
2492 gc->pc += cmdlen;
2493 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2494 }
2495 
2496 #define X_GLrop_PushName 125
__indirect_glPushName(GLuint name)2497 void __indirect_glPushName(GLuint name)
2498 {
2499     struct glx_context * const gc = __glXGetCurrentContext();
2500     const GLuint cmdlen = 8;
2501 emit_header(gc->pc, X_GLrop_PushName, cmdlen);
2502 (void) memcpy((void *)(gc->pc + 4), (void *)(&name), 4);
2503 gc->pc += cmdlen;
2504 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2505 }
2506 
2507 #define X_GLrop_DrawBuffer 126
__indirect_glDrawBuffer(GLenum mode)2508 void __indirect_glDrawBuffer(GLenum mode)
2509 {
2510     struct glx_context * const gc = __glXGetCurrentContext();
2511     const GLuint cmdlen = 8;
2512 emit_header(gc->pc, X_GLrop_DrawBuffer, cmdlen);
2513 (void) memcpy((void *)(gc->pc + 4), (void *)(&mode), 4);
2514 gc->pc += cmdlen;
2515 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2516 }
2517 
2518 #define X_GLrop_Clear 127
__indirect_glClear(GLbitfield mask)2519 void __indirect_glClear(GLbitfield mask)
2520 {
2521     struct glx_context * const gc = __glXGetCurrentContext();
2522     const GLuint cmdlen = 8;
2523 emit_header(gc->pc, X_GLrop_Clear, cmdlen);
2524 (void) memcpy((void *)(gc->pc + 4), (void *)(&mask), 4);
2525 gc->pc += cmdlen;
2526 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2527 }
2528 
2529 #define X_GLrop_ClearAccum 128
__indirect_glClearAccum(GLfloat red,GLfloat green,GLfloat blue,GLfloat alpha)2530 void __indirect_glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
2531 {
2532     struct glx_context * const gc = __glXGetCurrentContext();
2533     const GLuint cmdlen = 20;
2534 emit_header(gc->pc, X_GLrop_ClearAccum, cmdlen);
2535 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
2536 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
2537 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
2538 (void) memcpy((void *)(gc->pc + 16), (void *)(&alpha), 4);
2539 gc->pc += cmdlen;
2540 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2541 }
2542 
2543 #define X_GLrop_ClearIndex 129
__indirect_glClearIndex(GLfloat c)2544 void __indirect_glClearIndex(GLfloat c)
2545 {
2546     struct glx_context * const gc = __glXGetCurrentContext();
2547     const GLuint cmdlen = 8;
2548 emit_header(gc->pc, X_GLrop_ClearIndex, cmdlen);
2549 (void) memcpy((void *)(gc->pc + 4), (void *)(&c), 4);
2550 gc->pc += cmdlen;
2551 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2552 }
2553 
2554 #define X_GLrop_ClearColor 130
__indirect_glClearColor(GLclampf red,GLclampf green,GLclampf blue,GLclampf alpha)2555 void __indirect_glClearColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha)
2556 {
2557     struct glx_context * const gc = __glXGetCurrentContext();
2558     const GLuint cmdlen = 20;
2559 emit_header(gc->pc, X_GLrop_ClearColor, cmdlen);
2560 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
2561 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
2562 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
2563 (void) memcpy((void *)(gc->pc + 16), (void *)(&alpha), 4);
2564 gc->pc += cmdlen;
2565 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2566 }
2567 
2568 #define X_GLrop_ClearStencil 131
__indirect_glClearStencil(GLint s)2569 void __indirect_glClearStencil(GLint s)
2570 {
2571     struct glx_context * const gc = __glXGetCurrentContext();
2572     const GLuint cmdlen = 8;
2573 emit_header(gc->pc, X_GLrop_ClearStencil, cmdlen);
2574 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 4);
2575 gc->pc += cmdlen;
2576 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2577 }
2578 
2579 #define X_GLrop_ClearDepth 132
__indirect_glClearDepth(GLclampd depth)2580 void __indirect_glClearDepth(GLclampd depth)
2581 {
2582     struct glx_context * const gc = __glXGetCurrentContext();
2583     const GLuint cmdlen = 12;
2584 emit_header(gc->pc, X_GLrop_ClearDepth, cmdlen);
2585 (void) memcpy((void *)(gc->pc + 4), (void *)(&depth), 8);
2586 gc->pc += cmdlen;
2587 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2588 }
2589 
2590 #define X_GLrop_StencilMask 133
__indirect_glStencilMask(GLuint mask)2591 void __indirect_glStencilMask(GLuint mask)
2592 {
2593     struct glx_context * const gc = __glXGetCurrentContext();
2594     const GLuint cmdlen = 8;
2595 emit_header(gc->pc, X_GLrop_StencilMask, cmdlen);
2596 (void) memcpy((void *)(gc->pc + 4), (void *)(&mask), 4);
2597 gc->pc += cmdlen;
2598 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2599 }
2600 
2601 #define X_GLrop_ColorMask 134
__indirect_glColorMask(GLboolean red,GLboolean green,GLboolean blue,GLboolean alpha)2602 void __indirect_glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
2603 {
2604     struct glx_context * const gc = __glXGetCurrentContext();
2605     const GLuint cmdlen = 8;
2606 emit_header(gc->pc, X_GLrop_ColorMask, cmdlen);
2607 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 1);
2608 (void) memcpy((void *)(gc->pc + 5), (void *)(&green), 1);
2609 (void) memcpy((void *)(gc->pc + 6), (void *)(&blue), 1);
2610 (void) memcpy((void *)(gc->pc + 7), (void *)(&alpha), 1);
2611 gc->pc += cmdlen;
2612 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2613 }
2614 
2615 #define X_GLrop_DepthMask 135
__indirect_glDepthMask(GLboolean flag)2616 void __indirect_glDepthMask(GLboolean flag)
2617 {
2618     struct glx_context * const gc = __glXGetCurrentContext();
2619     const GLuint cmdlen = 8;
2620 emit_header(gc->pc, X_GLrop_DepthMask, cmdlen);
2621 (void) memcpy((void *)(gc->pc + 4), (void *)(&flag), 1);
2622 gc->pc += cmdlen;
2623 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2624 }
2625 
2626 #define X_GLrop_IndexMask 136
__indirect_glIndexMask(GLuint mask)2627 void __indirect_glIndexMask(GLuint mask)
2628 {
2629     struct glx_context * const gc = __glXGetCurrentContext();
2630     const GLuint cmdlen = 8;
2631 emit_header(gc->pc, X_GLrop_IndexMask, cmdlen);
2632 (void) memcpy((void *)(gc->pc + 4), (void *)(&mask), 4);
2633 gc->pc += cmdlen;
2634 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2635 }
2636 
2637 #define X_GLrop_Accum 137
__indirect_glAccum(GLenum op,GLfloat value)2638 void __indirect_glAccum(GLenum op, GLfloat value)
2639 {
2640     struct glx_context * const gc = __glXGetCurrentContext();
2641     const GLuint cmdlen = 12;
2642 emit_header(gc->pc, X_GLrop_Accum, cmdlen);
2643 (void) memcpy((void *)(gc->pc + 4), (void *)(&op), 4);
2644 (void) memcpy((void *)(gc->pc + 8), (void *)(&value), 4);
2645 gc->pc += cmdlen;
2646 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2647 }
2648 
2649 #define X_GLrop_PopAttrib 141
__indirect_glPopAttrib(void)2650 void __indirect_glPopAttrib(void)
2651 {
2652     struct glx_context * const gc = __glXGetCurrentContext();
2653     const GLuint cmdlen = 4;
2654 emit_header(gc->pc, X_GLrop_PopAttrib, cmdlen);
2655 gc->pc += cmdlen;
2656 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2657 }
2658 
2659 #define X_GLrop_PushAttrib 142
__indirect_glPushAttrib(GLbitfield mask)2660 void __indirect_glPushAttrib(GLbitfield mask)
2661 {
2662     struct glx_context * const gc = __glXGetCurrentContext();
2663     const GLuint cmdlen = 8;
2664 emit_header(gc->pc, X_GLrop_PushAttrib, cmdlen);
2665 (void) memcpy((void *)(gc->pc + 4), (void *)(&mask), 4);
2666 gc->pc += cmdlen;
2667 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2668 }
2669 
2670 #define X_GLrop_MapGrid1d 147
__indirect_glMapGrid1d(GLint un,GLdouble u1,GLdouble u2)2671 void __indirect_glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
2672 {
2673     struct glx_context * const gc = __glXGetCurrentContext();
2674     const GLuint cmdlen = 24;
2675 emit_header(gc->pc, X_GLrop_MapGrid1d, cmdlen);
2676 (void) memcpy((void *)(gc->pc + 4), (void *)(&u1), 8);
2677 (void) memcpy((void *)(gc->pc + 12), (void *)(&u2), 8);
2678 (void) memcpy((void *)(gc->pc + 20), (void *)(&un), 4);
2679 gc->pc += cmdlen;
2680 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2681 }
2682 
2683 #define X_GLrop_MapGrid1f 148
__indirect_glMapGrid1f(GLint un,GLfloat u1,GLfloat u2)2684 void __indirect_glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
2685 {
2686     struct glx_context * const gc = __glXGetCurrentContext();
2687     const GLuint cmdlen = 16;
2688 emit_header(gc->pc, X_GLrop_MapGrid1f, cmdlen);
2689 (void) memcpy((void *)(gc->pc + 4), (void *)(&un), 4);
2690 (void) memcpy((void *)(gc->pc + 8), (void *)(&u1), 4);
2691 (void) memcpy((void *)(gc->pc + 12), (void *)(&u2), 4);
2692 gc->pc += cmdlen;
2693 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2694 }
2695 
2696 #define X_GLrop_MapGrid2d 149
__indirect_glMapGrid2d(GLint un,GLdouble u1,GLdouble u2,GLint vn,GLdouble v1,GLdouble v2)2697 void __indirect_glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
2698 {
2699     struct glx_context * const gc = __glXGetCurrentContext();
2700     const GLuint cmdlen = 44;
2701 emit_header(gc->pc, X_GLrop_MapGrid2d, cmdlen);
2702 (void) memcpy((void *)(gc->pc + 4), (void *)(&u1), 8);
2703 (void) memcpy((void *)(gc->pc + 12), (void *)(&u2), 8);
2704 (void) memcpy((void *)(gc->pc + 20), (void *)(&v1), 8);
2705 (void) memcpy((void *)(gc->pc + 28), (void *)(&v2), 8);
2706 (void) memcpy((void *)(gc->pc + 36), (void *)(&un), 4);
2707 (void) memcpy((void *)(gc->pc + 40), (void *)(&vn), 4);
2708 gc->pc += cmdlen;
2709 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2710 }
2711 
2712 #define X_GLrop_MapGrid2f 150
__indirect_glMapGrid2f(GLint un,GLfloat u1,GLfloat u2,GLint vn,GLfloat v1,GLfloat v2)2713 void __indirect_glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
2714 {
2715     struct glx_context * const gc = __glXGetCurrentContext();
2716     const GLuint cmdlen = 28;
2717 emit_header(gc->pc, X_GLrop_MapGrid2f, cmdlen);
2718 (void) memcpy((void *)(gc->pc + 4), (void *)(&un), 4);
2719 (void) memcpy((void *)(gc->pc + 8), (void *)(&u1), 4);
2720 (void) memcpy((void *)(gc->pc + 12), (void *)(&u2), 4);
2721 (void) memcpy((void *)(gc->pc + 16), (void *)(&vn), 4);
2722 (void) memcpy((void *)(gc->pc + 20), (void *)(&v1), 4);
2723 (void) memcpy((void *)(gc->pc + 24), (void *)(&v2), 4);
2724 gc->pc += cmdlen;
2725 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2726 }
2727 
2728 #define X_GLrop_EvalCoord1dv 151
__indirect_glEvalCoord1d(GLdouble u)2729 void __indirect_glEvalCoord1d(GLdouble u)
2730 {
2731     struct glx_context * const gc = __glXGetCurrentContext();
2732     const GLuint cmdlen = 12;
2733 emit_header(gc->pc, X_GLrop_EvalCoord1dv, cmdlen);
2734 (void) memcpy((void *)(gc->pc + 4), (void *)(&u), 8);
2735 gc->pc += cmdlen;
2736 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2737 }
2738 
2739 #define X_GLrop_EvalCoord1dv 151
__indirect_glEvalCoord1dv(const GLdouble * u)2740 void __indirect_glEvalCoord1dv(const GLdouble * u)
2741 {
2742     generic_8_byte( X_GLrop_EvalCoord1dv, u );
2743 }
2744 
2745 #define X_GLrop_EvalCoord1fv 152
__indirect_glEvalCoord1f(GLfloat u)2746 void __indirect_glEvalCoord1f(GLfloat u)
2747 {
2748     struct glx_context * const gc = __glXGetCurrentContext();
2749     const GLuint cmdlen = 8;
2750 emit_header(gc->pc, X_GLrop_EvalCoord1fv, cmdlen);
2751 (void) memcpy((void *)(gc->pc + 4), (void *)(&u), 4);
2752 gc->pc += cmdlen;
2753 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2754 }
2755 
2756 #define X_GLrop_EvalCoord1fv 152
__indirect_glEvalCoord1fv(const GLfloat * u)2757 void __indirect_glEvalCoord1fv(const GLfloat * u)
2758 {
2759     generic_4_byte( X_GLrop_EvalCoord1fv, u );
2760 }
2761 
2762 #define X_GLrop_EvalCoord2dv 153
__indirect_glEvalCoord2d(GLdouble u,GLdouble v)2763 void __indirect_glEvalCoord2d(GLdouble u, GLdouble v)
2764 {
2765     struct glx_context * const gc = __glXGetCurrentContext();
2766     const GLuint cmdlen = 20;
2767 emit_header(gc->pc, X_GLrop_EvalCoord2dv, cmdlen);
2768 (void) memcpy((void *)(gc->pc + 4), (void *)(&u), 8);
2769 (void) memcpy((void *)(gc->pc + 12), (void *)(&v), 8);
2770 gc->pc += cmdlen;
2771 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2772 }
2773 
2774 #define X_GLrop_EvalCoord2dv 153
__indirect_glEvalCoord2dv(const GLdouble * u)2775 void __indirect_glEvalCoord2dv(const GLdouble * u)
2776 {
2777     generic_16_byte( X_GLrop_EvalCoord2dv, u );
2778 }
2779 
2780 #define X_GLrop_EvalCoord2fv 154
__indirect_glEvalCoord2f(GLfloat u,GLfloat v)2781 void __indirect_glEvalCoord2f(GLfloat u, GLfloat v)
2782 {
2783     struct glx_context * const gc = __glXGetCurrentContext();
2784     const GLuint cmdlen = 12;
2785 emit_header(gc->pc, X_GLrop_EvalCoord2fv, cmdlen);
2786 (void) memcpy((void *)(gc->pc + 4), (void *)(&u), 4);
2787 (void) memcpy((void *)(gc->pc + 8), (void *)(&v), 4);
2788 gc->pc += cmdlen;
2789 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2790 }
2791 
2792 #define X_GLrop_EvalCoord2fv 154
__indirect_glEvalCoord2fv(const GLfloat * u)2793 void __indirect_glEvalCoord2fv(const GLfloat * u)
2794 {
2795     generic_8_byte( X_GLrop_EvalCoord2fv, u );
2796 }
2797 
2798 #define X_GLrop_EvalMesh1 155
__indirect_glEvalMesh1(GLenum mode,GLint i1,GLint i2)2799 void __indirect_glEvalMesh1(GLenum mode, GLint i1, GLint i2)
2800 {
2801     struct glx_context * const gc = __glXGetCurrentContext();
2802     const GLuint cmdlen = 16;
2803 emit_header(gc->pc, X_GLrop_EvalMesh1, cmdlen);
2804 (void) memcpy((void *)(gc->pc + 4), (void *)(&mode), 4);
2805 (void) memcpy((void *)(gc->pc + 8), (void *)(&i1), 4);
2806 (void) memcpy((void *)(gc->pc + 12), (void *)(&i2), 4);
2807 gc->pc += cmdlen;
2808 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2809 }
2810 
2811 #define X_GLrop_EvalPoint1 156
__indirect_glEvalPoint1(GLint i)2812 void __indirect_glEvalPoint1(GLint i)
2813 {
2814     struct glx_context * const gc = __glXGetCurrentContext();
2815     const GLuint cmdlen = 8;
2816 emit_header(gc->pc, X_GLrop_EvalPoint1, cmdlen);
2817 (void) memcpy((void *)(gc->pc + 4), (void *)(&i), 4);
2818 gc->pc += cmdlen;
2819 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2820 }
2821 
2822 #define X_GLrop_EvalMesh2 157
__indirect_glEvalMesh2(GLenum mode,GLint i1,GLint i2,GLint j1,GLint j2)2823 void __indirect_glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
2824 {
2825     struct glx_context * const gc = __glXGetCurrentContext();
2826     const GLuint cmdlen = 24;
2827 emit_header(gc->pc, X_GLrop_EvalMesh2, cmdlen);
2828 (void) memcpy((void *)(gc->pc + 4), (void *)(&mode), 4);
2829 (void) memcpy((void *)(gc->pc + 8), (void *)(&i1), 4);
2830 (void) memcpy((void *)(gc->pc + 12), (void *)(&i2), 4);
2831 (void) memcpy((void *)(gc->pc + 16), (void *)(&j1), 4);
2832 (void) memcpy((void *)(gc->pc + 20), (void *)(&j2), 4);
2833 gc->pc += cmdlen;
2834 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2835 }
2836 
2837 #define X_GLrop_EvalPoint2 158
__indirect_glEvalPoint2(GLint i,GLint j)2838 void __indirect_glEvalPoint2(GLint i, GLint j)
2839 {
2840     struct glx_context * const gc = __glXGetCurrentContext();
2841     const GLuint cmdlen = 12;
2842 emit_header(gc->pc, X_GLrop_EvalPoint2, cmdlen);
2843 (void) memcpy((void *)(gc->pc + 4), (void *)(&i), 4);
2844 (void) memcpy((void *)(gc->pc + 8), (void *)(&j), 4);
2845 gc->pc += cmdlen;
2846 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2847 }
2848 
2849 #define X_GLrop_AlphaFunc 159
__indirect_glAlphaFunc(GLenum func,GLclampf ref)2850 void __indirect_glAlphaFunc(GLenum func, GLclampf ref)
2851 {
2852     struct glx_context * const gc = __glXGetCurrentContext();
2853     const GLuint cmdlen = 12;
2854 emit_header(gc->pc, X_GLrop_AlphaFunc, cmdlen);
2855 (void) memcpy((void *)(gc->pc + 4), (void *)(&func), 4);
2856 (void) memcpy((void *)(gc->pc + 8), (void *)(&ref), 4);
2857 gc->pc += cmdlen;
2858 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2859 }
2860 
2861 #define X_GLrop_BlendFunc 160
__indirect_glBlendFunc(GLenum sfactor,GLenum dfactor)2862 void __indirect_glBlendFunc(GLenum sfactor, GLenum dfactor)
2863 {
2864     struct glx_context * const gc = __glXGetCurrentContext();
2865     const GLuint cmdlen = 12;
2866 emit_header(gc->pc, X_GLrop_BlendFunc, cmdlen);
2867 (void) memcpy((void *)(gc->pc + 4), (void *)(&sfactor), 4);
2868 (void) memcpy((void *)(gc->pc + 8), (void *)(&dfactor), 4);
2869 gc->pc += cmdlen;
2870 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2871 }
2872 
2873 #define X_GLrop_LogicOp 161
__indirect_glLogicOp(GLenum opcode)2874 void __indirect_glLogicOp(GLenum opcode)
2875 {
2876     struct glx_context * const gc = __glXGetCurrentContext();
2877     const GLuint cmdlen = 8;
2878 emit_header(gc->pc, X_GLrop_LogicOp, cmdlen);
2879 (void) memcpy((void *)(gc->pc + 4), (void *)(&opcode), 4);
2880 gc->pc += cmdlen;
2881 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2882 }
2883 
2884 #define X_GLrop_StencilFunc 162
__indirect_glStencilFunc(GLenum func,GLint ref,GLuint mask)2885 void __indirect_glStencilFunc(GLenum func, GLint ref, GLuint mask)
2886 {
2887     struct glx_context * const gc = __glXGetCurrentContext();
2888     const GLuint cmdlen = 16;
2889 emit_header(gc->pc, X_GLrop_StencilFunc, cmdlen);
2890 (void) memcpy((void *)(gc->pc + 4), (void *)(&func), 4);
2891 (void) memcpy((void *)(gc->pc + 8), (void *)(&ref), 4);
2892 (void) memcpy((void *)(gc->pc + 12), (void *)(&mask), 4);
2893 gc->pc += cmdlen;
2894 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2895 }
2896 
2897 #define X_GLrop_StencilOp 163
__indirect_glStencilOp(GLenum fail,GLenum zfail,GLenum zpass)2898 void __indirect_glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
2899 {
2900     struct glx_context * const gc = __glXGetCurrentContext();
2901     const GLuint cmdlen = 16;
2902 emit_header(gc->pc, X_GLrop_StencilOp, cmdlen);
2903 (void) memcpy((void *)(gc->pc + 4), (void *)(&fail), 4);
2904 (void) memcpy((void *)(gc->pc + 8), (void *)(&zfail), 4);
2905 (void) memcpy((void *)(gc->pc + 12), (void *)(&zpass), 4);
2906 gc->pc += cmdlen;
2907 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2908 }
2909 
2910 #define X_GLrop_DepthFunc 164
__indirect_glDepthFunc(GLenum func)2911 void __indirect_glDepthFunc(GLenum func)
2912 {
2913     struct glx_context * const gc = __glXGetCurrentContext();
2914     const GLuint cmdlen = 8;
2915 emit_header(gc->pc, X_GLrop_DepthFunc, cmdlen);
2916 (void) memcpy((void *)(gc->pc + 4), (void *)(&func), 4);
2917 gc->pc += cmdlen;
2918 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2919 }
2920 
2921 #define X_GLrop_PixelZoom 165
__indirect_glPixelZoom(GLfloat xfactor,GLfloat yfactor)2922 void __indirect_glPixelZoom(GLfloat xfactor, GLfloat yfactor)
2923 {
2924     struct glx_context * const gc = __glXGetCurrentContext();
2925     const GLuint cmdlen = 12;
2926 emit_header(gc->pc, X_GLrop_PixelZoom, cmdlen);
2927 (void) memcpy((void *)(gc->pc + 4), (void *)(&xfactor), 4);
2928 (void) memcpy((void *)(gc->pc + 8), (void *)(&yfactor), 4);
2929 gc->pc += cmdlen;
2930 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2931 }
2932 
2933 #define X_GLrop_PixelTransferf 166
__indirect_glPixelTransferf(GLenum pname,GLfloat param)2934 void __indirect_glPixelTransferf(GLenum pname, GLfloat param)
2935 {
2936     struct glx_context * const gc = __glXGetCurrentContext();
2937     const GLuint cmdlen = 12;
2938 emit_header(gc->pc, X_GLrop_PixelTransferf, cmdlen);
2939 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
2940 (void) memcpy((void *)(gc->pc + 8), (void *)(&param), 4);
2941 gc->pc += cmdlen;
2942 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2943 }
2944 
2945 #define X_GLrop_PixelTransferi 167
__indirect_glPixelTransferi(GLenum pname,GLint param)2946 void __indirect_glPixelTransferi(GLenum pname, GLint param)
2947 {
2948     struct glx_context * const gc = __glXGetCurrentContext();
2949     const GLuint cmdlen = 12;
2950 emit_header(gc->pc, X_GLrop_PixelTransferi, cmdlen);
2951 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
2952 (void) memcpy((void *)(gc->pc + 8), (void *)(&param), 4);
2953 gc->pc += cmdlen;
2954 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2955 }
2956 
2957 #define X_GLrop_PixelMapfv 168
__indirect_glPixelMapfv(GLenum map,GLsizei mapsize,const GLfloat * values)2958 void __indirect_glPixelMapfv(GLenum map, GLsizei mapsize, const GLfloat * values)
2959 {
2960     struct glx_context * const gc = __glXGetCurrentContext();
2961     const GLuint cmdlen = 12 + __GLX_PAD((mapsize * 4));
2962     if (mapsize < 0) {
2963         __glXSetError(gc, GL_INVALID_VALUE);
2964         return;
2965     }
2966     if (__builtin_expect((mapsize >= 0) && (gc->currentDpy != NULL), 1)) {
2967 if (cmdlen <= gc->maxSmallRenderCommandSize) {
2968     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
2969         (void) __glXFlushRenderBuffer(gc, gc->pc);
2970     }
2971 emit_header(gc->pc, X_GLrop_PixelMapfv, cmdlen);
2972 (void) memcpy((void *)(gc->pc + 4), (void *)(&map), 4);
2973 (void) memcpy((void *)(gc->pc + 8), (void *)(&mapsize), 4);
2974 (void) memcpy((void *)(gc->pc + 12), (void *)(values), (mapsize * 4));
2975 gc->pc += cmdlen;
2976 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
2977 }
2978 else {
2979 const GLint op = X_GLrop_PixelMapfv;
2980 const GLuint cmdlenLarge = cmdlen + 4;
2981 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
2982 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
2983 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
2984 (void) memcpy((void *)(pc + 8), (void *)(&map), 4);
2985 (void) memcpy((void *)(pc + 12), (void *)(&mapsize), 4);
2986     __glXSendLargeCommand(gc, pc, 16, values, (mapsize * 4));
2987 }
2988     }
2989 }
2990 
2991 #define X_GLrop_PixelMapuiv 169
__indirect_glPixelMapuiv(GLenum map,GLsizei mapsize,const GLuint * values)2992 void __indirect_glPixelMapuiv(GLenum map, GLsizei mapsize, const GLuint * values)
2993 {
2994     struct glx_context * const gc = __glXGetCurrentContext();
2995     const GLuint cmdlen = 12 + __GLX_PAD((mapsize * 4));
2996     if (mapsize < 0) {
2997         __glXSetError(gc, GL_INVALID_VALUE);
2998         return;
2999     }
3000     if (__builtin_expect((mapsize >= 0) && (gc->currentDpy != NULL), 1)) {
3001 if (cmdlen <= gc->maxSmallRenderCommandSize) {
3002     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
3003         (void) __glXFlushRenderBuffer(gc, gc->pc);
3004     }
3005 emit_header(gc->pc, X_GLrop_PixelMapuiv, cmdlen);
3006 (void) memcpy((void *)(gc->pc + 4), (void *)(&map), 4);
3007 (void) memcpy((void *)(gc->pc + 8), (void *)(&mapsize), 4);
3008 (void) memcpy((void *)(gc->pc + 12), (void *)(values), (mapsize * 4));
3009 gc->pc += cmdlen;
3010 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3011 }
3012 else {
3013 const GLint op = X_GLrop_PixelMapuiv;
3014 const GLuint cmdlenLarge = cmdlen + 4;
3015 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
3016 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
3017 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
3018 (void) memcpy((void *)(pc + 8), (void *)(&map), 4);
3019 (void) memcpy((void *)(pc + 12), (void *)(&mapsize), 4);
3020     __glXSendLargeCommand(gc, pc, 16, values, (mapsize * 4));
3021 }
3022     }
3023 }
3024 
3025 #define X_GLrop_PixelMapusv 170
__indirect_glPixelMapusv(GLenum map,GLsizei mapsize,const GLushort * values)3026 void __indirect_glPixelMapusv(GLenum map, GLsizei mapsize, const GLushort * values)
3027 {
3028     struct glx_context * const gc = __glXGetCurrentContext();
3029     const GLuint cmdlen = 12 + __GLX_PAD((mapsize * 2));
3030     if (mapsize < 0) {
3031         __glXSetError(gc, GL_INVALID_VALUE);
3032         return;
3033     }
3034     if (__builtin_expect((mapsize >= 0) && (gc->currentDpy != NULL), 1)) {
3035 if (cmdlen <= gc->maxSmallRenderCommandSize) {
3036     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
3037         (void) __glXFlushRenderBuffer(gc, gc->pc);
3038     }
3039 emit_header(gc->pc, X_GLrop_PixelMapusv, cmdlen);
3040 (void) memcpy((void *)(gc->pc + 4), (void *)(&map), 4);
3041 (void) memcpy((void *)(gc->pc + 8), (void *)(&mapsize), 4);
3042 (void) memcpy((void *)(gc->pc + 12), (void *)(values), (mapsize * 2));
3043 gc->pc += cmdlen;
3044 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3045 }
3046 else {
3047 const GLint op = X_GLrop_PixelMapusv;
3048 const GLuint cmdlenLarge = cmdlen + 4;
3049 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
3050 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
3051 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
3052 (void) memcpy((void *)(pc + 8), (void *)(&map), 4);
3053 (void) memcpy((void *)(pc + 12), (void *)(&mapsize), 4);
3054     __glXSendLargeCommand(gc, pc, 16, values, (mapsize * 2));
3055 }
3056     }
3057 }
3058 
3059 #define X_GLrop_ReadBuffer 171
__indirect_glReadBuffer(GLenum mode)3060 void __indirect_glReadBuffer(GLenum mode)
3061 {
3062     struct glx_context * const gc = __glXGetCurrentContext();
3063     const GLuint cmdlen = 8;
3064 emit_header(gc->pc, X_GLrop_ReadBuffer, cmdlen);
3065 (void) memcpy((void *)(gc->pc + 4), (void *)(&mode), 4);
3066 gc->pc += cmdlen;
3067 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3068 }
3069 
3070 #define X_GLrop_CopyPixels 172
__indirect_glCopyPixels(GLint x,GLint y,GLsizei width,GLsizei height,GLenum type)3071 void __indirect_glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
3072 {
3073     struct glx_context * const gc = __glXGetCurrentContext();
3074     const GLuint cmdlen = 24;
3075 emit_header(gc->pc, X_GLrop_CopyPixels, cmdlen);
3076 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
3077 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
3078 (void) memcpy((void *)(gc->pc + 12), (void *)(&width), 4);
3079 (void) memcpy((void *)(gc->pc + 16), (void *)(&height), 4);
3080 (void) memcpy((void *)(gc->pc + 20), (void *)(&type), 4);
3081 gc->pc += cmdlen;
3082 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3083 }
3084 
3085 #define X_GLsop_ReadPixels 111
__indirect_glReadPixels(GLint x,GLint y,GLsizei width,GLsizei height,GLenum format,GLenum type,GLvoid * pixels)3086 void __indirect_glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid * pixels)
3087 {
3088     struct glx_context * const gc = __glXGetCurrentContext();
3089     const __GLXattribute * const state = gc->client_state_private;
3090     Display * const dpy = gc->currentDpy;
3091 #ifndef USE_XCB
3092     const GLuint cmdlen = 28;
3093 #endif
3094     if (__builtin_expect(dpy != NULL, 1)) {
3095 #ifdef USE_XCB
3096         xcb_connection_t *c = XGetXCBConnection(dpy);
3097         (void) __glXFlushRenderBuffer(gc, gc->pc);
3098         xcb_glx_read_pixels_reply_t *reply = xcb_glx_read_pixels_reply(c, xcb_glx_read_pixels(c, gc->currentContextTag, x, y, width, height, format, type, state->storePack.swapEndian, 0), NULL);
3099         __glEmptyImage(gc, 3, width, height, 1, format, type, xcb_glx_read_pixels_data(reply), pixels);
3100         free(reply);
3101 #else
3102         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_ReadPixels, cmdlen);
3103 (void) memcpy((void *)(pc + 0), (void *)(&x), 4);
3104 (void) memcpy((void *)(pc + 4), (void *)(&y), 4);
3105 (void) memcpy((void *)(pc + 8), (void *)(&width), 4);
3106 (void) memcpy((void *)(pc + 12), (void *)(&height), 4);
3107 (void) memcpy((void *)(pc + 16), (void *)(&format), 4);
3108 (void) memcpy((void *)(pc + 20), (void *)(&type), 4);
3109         *(int32_t *)(pc + 24) = 0;
3110         * (int8_t *)(pc + 24) = state->storePack.swapEndian;
3111         __glXReadPixelReply(dpy, gc, 2, width, height, 1, format, type, pixels, GL_FALSE);
3112         UnlockDisplay(dpy); SyncHandle();
3113 #endif /* USE_XCB */
3114     }
3115     return;
3116 }
3117 
3118 #define X_GLrop_DrawPixels 173
__indirect_glDrawPixels(GLsizei width,GLsizei height,GLenum format,GLenum type,const GLvoid * pixels)3119 void __indirect_glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid * pixels)
3120 {
3121     struct glx_context * const gc = __glXGetCurrentContext();
3122     const GLuint compsize = (pixels != NULL) ? __glImageSize(width, height, 1, format, type, 0) : 0;
3123     const GLuint cmdlen = 40 + __GLX_PAD(compsize);
3124     if (__builtin_expect(gc->currentDpy != NULL, 1)) {
3125 if (cmdlen <= gc->maxSmallRenderCommandSize) {
3126     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
3127         (void) __glXFlushRenderBuffer(gc, gc->pc);
3128     }
3129 emit_header(gc->pc, X_GLrop_DrawPixels, cmdlen);
3130 (void) memcpy((void *)(gc->pc + 24), (void *)(&width), 4);
3131 (void) memcpy((void *)(gc->pc + 28), (void *)(&height), 4);
3132 (void) memcpy((void *)(gc->pc + 32), (void *)(&format), 4);
3133 (void) memcpy((void *)(gc->pc + 36), (void *)(&type), 4);
3134 if (compsize > 0) {
3135     (*gc->fillImage)(gc, 2, width, height, 1, format, type, pixels, gc->pc + 40, gc->pc + 4);
3136 } else {
3137     (void) memcpy( gc->pc + 4, default_pixel_store_2D, default_pixel_store_2D_size );
3138 }
3139 gc->pc += cmdlen;
3140 if (gc->pc > gc->limit) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3141 }
3142 else {
3143 const GLint op = X_GLrop_DrawPixels;
3144 const GLuint cmdlenLarge = cmdlen + 4;
3145 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
3146 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
3147 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
3148 (void) memcpy((void *)(pc + 28), (void *)(&width), 4);
3149 (void) memcpy((void *)(pc + 32), (void *)(&height), 4);
3150 (void) memcpy((void *)(pc + 36), (void *)(&format), 4);
3151 (void) memcpy((void *)(pc + 40), (void *)(&type), 4);
3152 __glXSendLargeImage(gc, compsize, 2, width, height, 1, format, type, pixels, pc + 44, pc + 8);
3153 }
3154     }
3155 }
3156 
3157 #define X_GLsop_GetClipPlane 113
__indirect_glGetClipPlane(GLenum plane,GLdouble * equation)3158 void __indirect_glGetClipPlane(GLenum plane, GLdouble * equation)
3159 {
3160     struct glx_context * const gc = __glXGetCurrentContext();
3161     Display * const dpy = gc->currentDpy;
3162 #ifndef USE_XCB
3163     const GLuint cmdlen = 4;
3164 #endif
3165     if (__builtin_expect(dpy != NULL, 1)) {
3166 #ifdef USE_XCB
3167         xcb_connection_t *c = XGetXCBConnection(dpy);
3168         (void) __glXFlushRenderBuffer(gc, gc->pc);
3169         xcb_glx_get_clip_plane_reply_t *reply = xcb_glx_get_clip_plane_reply(c, xcb_glx_get_clip_plane(c, gc->currentContextTag, plane), NULL);
3170         (void)memcpy(equation, xcb_glx_get_clip_plane_data(reply), xcb_glx_get_clip_plane_data_length(reply) * sizeof(GLdouble));
3171         free(reply);
3172 #else
3173         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetClipPlane, cmdlen);
3174 (void) memcpy((void *)(pc + 0), (void *)(&plane), 4);
3175         (void) __glXReadReply(dpy, 8, equation, GL_TRUE);
3176         UnlockDisplay(dpy); SyncHandle();
3177 #endif /* USE_XCB */
3178     }
3179     return;
3180 }
3181 
3182 #define X_GLsop_GetLightfv 118
__indirect_glGetLightfv(GLenum light,GLenum pname,GLfloat * params)3183 void __indirect_glGetLightfv(GLenum light, GLenum pname, GLfloat * params)
3184 {
3185     struct glx_context * const gc = __glXGetCurrentContext();
3186     Display * const dpy = gc->currentDpy;
3187 #ifndef USE_XCB
3188     const GLuint cmdlen = 8;
3189 #endif
3190     if (__builtin_expect(dpy != NULL, 1)) {
3191 #ifdef USE_XCB
3192         xcb_connection_t *c = XGetXCBConnection(dpy);
3193         (void) __glXFlushRenderBuffer(gc, gc->pc);
3194         xcb_glx_get_lightfv_reply_t *reply = xcb_glx_get_lightfv_reply(c, xcb_glx_get_lightfv(c, gc->currentContextTag, light, pname), NULL);
3195         if (xcb_glx_get_lightfv_data_length(reply) == 0)
3196             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3197         else
3198             (void)memcpy(params, xcb_glx_get_lightfv_data(reply), xcb_glx_get_lightfv_data_length(reply) * sizeof(GLfloat));
3199         free(reply);
3200 #else
3201         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetLightfv, cmdlen);
3202 (void) memcpy((void *)(pc + 0), (void *)(&light), 4);
3203 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3204         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3205         UnlockDisplay(dpy); SyncHandle();
3206 #endif /* USE_XCB */
3207     }
3208     return;
3209 }
3210 
3211 #define X_GLsop_GetLightiv 119
__indirect_glGetLightiv(GLenum light,GLenum pname,GLint * params)3212 void __indirect_glGetLightiv(GLenum light, GLenum pname, GLint * params)
3213 {
3214     struct glx_context * const gc = __glXGetCurrentContext();
3215     Display * const dpy = gc->currentDpy;
3216 #ifndef USE_XCB
3217     const GLuint cmdlen = 8;
3218 #endif
3219     if (__builtin_expect(dpy != NULL, 1)) {
3220 #ifdef USE_XCB
3221         xcb_connection_t *c = XGetXCBConnection(dpy);
3222         (void) __glXFlushRenderBuffer(gc, gc->pc);
3223         xcb_glx_get_lightiv_reply_t *reply = xcb_glx_get_lightiv_reply(c, xcb_glx_get_lightiv(c, gc->currentContextTag, light, pname), NULL);
3224         if (xcb_glx_get_lightiv_data_length(reply) == 0)
3225             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3226         else
3227             (void)memcpy(params, xcb_glx_get_lightiv_data(reply), xcb_glx_get_lightiv_data_length(reply) * sizeof(GLint));
3228         free(reply);
3229 #else
3230         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetLightiv, cmdlen);
3231 (void) memcpy((void *)(pc + 0), (void *)(&light), 4);
3232 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3233         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3234         UnlockDisplay(dpy); SyncHandle();
3235 #endif /* USE_XCB */
3236     }
3237     return;
3238 }
3239 
3240 #define X_GLsop_GetMapdv 120
__indirect_glGetMapdv(GLenum target,GLenum query,GLdouble * v)3241 void __indirect_glGetMapdv(GLenum target, GLenum query, GLdouble * v)
3242 {
3243     struct glx_context * const gc = __glXGetCurrentContext();
3244     Display * const dpy = gc->currentDpy;
3245 #ifndef USE_XCB
3246     const GLuint cmdlen = 8;
3247 #endif
3248     if (__builtin_expect(dpy != NULL, 1)) {
3249 #ifdef USE_XCB
3250         xcb_connection_t *c = XGetXCBConnection(dpy);
3251         (void) __glXFlushRenderBuffer(gc, gc->pc);
3252         xcb_glx_get_mapdv_reply_t *reply = xcb_glx_get_mapdv_reply(c, xcb_glx_get_mapdv(c, gc->currentContextTag, target, query), NULL);
3253         if (xcb_glx_get_mapdv_data_length(reply) == 0)
3254             (void)memcpy(v, &reply->datum, sizeof(reply->datum));
3255         else
3256             (void)memcpy(v, xcb_glx_get_mapdv_data(reply), xcb_glx_get_mapdv_data_length(reply) * sizeof(GLdouble));
3257         free(reply);
3258 #else
3259         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetMapdv, cmdlen);
3260 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
3261 (void) memcpy((void *)(pc + 4), (void *)(&query), 4);
3262         (void) __glXReadReply(dpy, 8, v, GL_FALSE);
3263         UnlockDisplay(dpy); SyncHandle();
3264 #endif /* USE_XCB */
3265     }
3266     return;
3267 }
3268 
3269 #define X_GLsop_GetMapfv 121
__indirect_glGetMapfv(GLenum target,GLenum query,GLfloat * v)3270 void __indirect_glGetMapfv(GLenum target, GLenum query, GLfloat * v)
3271 {
3272     struct glx_context * const gc = __glXGetCurrentContext();
3273     Display * const dpy = gc->currentDpy;
3274 #ifndef USE_XCB
3275     const GLuint cmdlen = 8;
3276 #endif
3277     if (__builtin_expect(dpy != NULL, 1)) {
3278 #ifdef USE_XCB
3279         xcb_connection_t *c = XGetXCBConnection(dpy);
3280         (void) __glXFlushRenderBuffer(gc, gc->pc);
3281         xcb_glx_get_mapfv_reply_t *reply = xcb_glx_get_mapfv_reply(c, xcb_glx_get_mapfv(c, gc->currentContextTag, target, query), NULL);
3282         if (xcb_glx_get_mapfv_data_length(reply) == 0)
3283             (void)memcpy(v, &reply->datum, sizeof(reply->datum));
3284         else
3285             (void)memcpy(v, xcb_glx_get_mapfv_data(reply), xcb_glx_get_mapfv_data_length(reply) * sizeof(GLfloat));
3286         free(reply);
3287 #else
3288         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetMapfv, cmdlen);
3289 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
3290 (void) memcpy((void *)(pc + 4), (void *)(&query), 4);
3291         (void) __glXReadReply(dpy, 4, v, GL_FALSE);
3292         UnlockDisplay(dpy); SyncHandle();
3293 #endif /* USE_XCB */
3294     }
3295     return;
3296 }
3297 
3298 #define X_GLsop_GetMapiv 122
__indirect_glGetMapiv(GLenum target,GLenum query,GLint * v)3299 void __indirect_glGetMapiv(GLenum target, GLenum query, GLint * v)
3300 {
3301     struct glx_context * const gc = __glXGetCurrentContext();
3302     Display * const dpy = gc->currentDpy;
3303 #ifndef USE_XCB
3304     const GLuint cmdlen = 8;
3305 #endif
3306     if (__builtin_expect(dpy != NULL, 1)) {
3307 #ifdef USE_XCB
3308         xcb_connection_t *c = XGetXCBConnection(dpy);
3309         (void) __glXFlushRenderBuffer(gc, gc->pc);
3310         xcb_glx_get_mapiv_reply_t *reply = xcb_glx_get_mapiv_reply(c, xcb_glx_get_mapiv(c, gc->currentContextTag, target, query), NULL);
3311         if (xcb_glx_get_mapiv_data_length(reply) == 0)
3312             (void)memcpy(v, &reply->datum, sizeof(reply->datum));
3313         else
3314             (void)memcpy(v, xcb_glx_get_mapiv_data(reply), xcb_glx_get_mapiv_data_length(reply) * sizeof(GLint));
3315         free(reply);
3316 #else
3317         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetMapiv, cmdlen);
3318 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
3319 (void) memcpy((void *)(pc + 4), (void *)(&query), 4);
3320         (void) __glXReadReply(dpy, 4, v, GL_FALSE);
3321         UnlockDisplay(dpy); SyncHandle();
3322 #endif /* USE_XCB */
3323     }
3324     return;
3325 }
3326 
3327 #define X_GLsop_GetMaterialfv 123
__indirect_glGetMaterialfv(GLenum face,GLenum pname,GLfloat * params)3328 void __indirect_glGetMaterialfv(GLenum face, GLenum pname, GLfloat * params)
3329 {
3330     struct glx_context * const gc = __glXGetCurrentContext();
3331     Display * const dpy = gc->currentDpy;
3332 #ifndef USE_XCB
3333     const GLuint cmdlen = 8;
3334 #endif
3335     if (__builtin_expect(dpy != NULL, 1)) {
3336 #ifdef USE_XCB
3337         xcb_connection_t *c = XGetXCBConnection(dpy);
3338         (void) __glXFlushRenderBuffer(gc, gc->pc);
3339         xcb_glx_get_materialfv_reply_t *reply = xcb_glx_get_materialfv_reply(c, xcb_glx_get_materialfv(c, gc->currentContextTag, face, pname), NULL);
3340         if (xcb_glx_get_materialfv_data_length(reply) == 0)
3341             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3342         else
3343             (void)memcpy(params, xcb_glx_get_materialfv_data(reply), xcb_glx_get_materialfv_data_length(reply) * sizeof(GLfloat));
3344         free(reply);
3345 #else
3346         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetMaterialfv, cmdlen);
3347 (void) memcpy((void *)(pc + 0), (void *)(&face), 4);
3348 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3349         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3350         UnlockDisplay(dpy); SyncHandle();
3351 #endif /* USE_XCB */
3352     }
3353     return;
3354 }
3355 
3356 #define X_GLsop_GetMaterialiv 124
__indirect_glGetMaterialiv(GLenum face,GLenum pname,GLint * params)3357 void __indirect_glGetMaterialiv(GLenum face, GLenum pname, GLint * params)
3358 {
3359     struct glx_context * const gc = __glXGetCurrentContext();
3360     Display * const dpy = gc->currentDpy;
3361 #ifndef USE_XCB
3362     const GLuint cmdlen = 8;
3363 #endif
3364     if (__builtin_expect(dpy != NULL, 1)) {
3365 #ifdef USE_XCB
3366         xcb_connection_t *c = XGetXCBConnection(dpy);
3367         (void) __glXFlushRenderBuffer(gc, gc->pc);
3368         xcb_glx_get_materialiv_reply_t *reply = xcb_glx_get_materialiv_reply(c, xcb_glx_get_materialiv(c, gc->currentContextTag, face, pname), NULL);
3369         if (xcb_glx_get_materialiv_data_length(reply) == 0)
3370             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3371         else
3372             (void)memcpy(params, xcb_glx_get_materialiv_data(reply), xcb_glx_get_materialiv_data_length(reply) * sizeof(GLint));
3373         free(reply);
3374 #else
3375         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetMaterialiv, cmdlen);
3376 (void) memcpy((void *)(pc + 0), (void *)(&face), 4);
3377 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3378         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3379         UnlockDisplay(dpy); SyncHandle();
3380 #endif /* USE_XCB */
3381     }
3382     return;
3383 }
3384 
3385 #define X_GLsop_GetPixelMapfv 125
__indirect_glGetPixelMapfv(GLenum map,GLfloat * values)3386 void __indirect_glGetPixelMapfv(GLenum map, GLfloat * values)
3387 {
3388     struct glx_context * const gc = __glXGetCurrentContext();
3389     Display * const dpy = gc->currentDpy;
3390 #ifndef USE_XCB
3391     const GLuint cmdlen = 4;
3392 #endif
3393     if (__builtin_expect(dpy != NULL, 1)) {
3394 #ifdef USE_XCB
3395         xcb_connection_t *c = XGetXCBConnection(dpy);
3396         (void) __glXFlushRenderBuffer(gc, gc->pc);
3397         xcb_glx_get_pixel_mapfv_reply_t *reply = xcb_glx_get_pixel_mapfv_reply(c, xcb_glx_get_pixel_mapfv(c, gc->currentContextTag, map), NULL);
3398         if (xcb_glx_get_pixel_mapfv_data_length(reply) == 0)
3399             (void)memcpy(values, &reply->datum, sizeof(reply->datum));
3400         else
3401             (void)memcpy(values, xcb_glx_get_pixel_mapfv_data(reply), xcb_glx_get_pixel_mapfv_data_length(reply) * sizeof(GLfloat));
3402         free(reply);
3403 #else
3404         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetPixelMapfv, cmdlen);
3405 (void) memcpy((void *)(pc + 0), (void *)(&map), 4);
3406         (void) __glXReadReply(dpy, 4, values, GL_FALSE);
3407         UnlockDisplay(dpy); SyncHandle();
3408 #endif /* USE_XCB */
3409     }
3410     return;
3411 }
3412 
3413 #define X_GLsop_GetPixelMapuiv 126
__indirect_glGetPixelMapuiv(GLenum map,GLuint * values)3414 void __indirect_glGetPixelMapuiv(GLenum map, GLuint * values)
3415 {
3416     struct glx_context * const gc = __glXGetCurrentContext();
3417     Display * const dpy = gc->currentDpy;
3418 #ifndef USE_XCB
3419     const GLuint cmdlen = 4;
3420 #endif
3421     if (__builtin_expect(dpy != NULL, 1)) {
3422 #ifdef USE_XCB
3423         xcb_connection_t *c = XGetXCBConnection(dpy);
3424         (void) __glXFlushRenderBuffer(gc, gc->pc);
3425         xcb_glx_get_pixel_mapuiv_reply_t *reply = xcb_glx_get_pixel_mapuiv_reply(c, xcb_glx_get_pixel_mapuiv(c, gc->currentContextTag, map), NULL);
3426         if (xcb_glx_get_pixel_mapuiv_data_length(reply) == 0)
3427             (void)memcpy(values, &reply->datum, sizeof(reply->datum));
3428         else
3429             (void)memcpy(values, xcb_glx_get_pixel_mapuiv_data(reply), xcb_glx_get_pixel_mapuiv_data_length(reply) * sizeof(GLuint));
3430         free(reply);
3431 #else
3432         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetPixelMapuiv, cmdlen);
3433 (void) memcpy((void *)(pc + 0), (void *)(&map), 4);
3434         (void) __glXReadReply(dpy, 4, values, GL_FALSE);
3435         UnlockDisplay(dpy); SyncHandle();
3436 #endif /* USE_XCB */
3437     }
3438     return;
3439 }
3440 
3441 #define X_GLsop_GetPixelMapusv 127
__indirect_glGetPixelMapusv(GLenum map,GLushort * values)3442 void __indirect_glGetPixelMapusv(GLenum map, GLushort * values)
3443 {
3444     struct glx_context * const gc = __glXGetCurrentContext();
3445     Display * const dpy = gc->currentDpy;
3446 #ifndef USE_XCB
3447     const GLuint cmdlen = 4;
3448 #endif
3449     if (__builtin_expect(dpy != NULL, 1)) {
3450 #ifdef USE_XCB
3451         xcb_connection_t *c = XGetXCBConnection(dpy);
3452         (void) __glXFlushRenderBuffer(gc, gc->pc);
3453         xcb_glx_get_pixel_mapusv_reply_t *reply = xcb_glx_get_pixel_mapusv_reply(c, xcb_glx_get_pixel_mapusv(c, gc->currentContextTag, map), NULL);
3454         if (xcb_glx_get_pixel_mapusv_data_length(reply) == 0)
3455             (void)memcpy(values, &reply->datum, sizeof(reply->datum));
3456         else
3457             (void)memcpy(values, xcb_glx_get_pixel_mapusv_data(reply), xcb_glx_get_pixel_mapusv_data_length(reply) * sizeof(GLushort));
3458         free(reply);
3459 #else
3460         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetPixelMapusv, cmdlen);
3461 (void) memcpy((void *)(pc + 0), (void *)(&map), 4);
3462         (void) __glXReadReply(dpy, 2, values, GL_FALSE);
3463         UnlockDisplay(dpy); SyncHandle();
3464 #endif /* USE_XCB */
3465     }
3466     return;
3467 }
3468 
3469 #define X_GLsop_GetPolygonStipple 128
__indirect_glGetPolygonStipple(GLubyte * mask)3470 void __indirect_glGetPolygonStipple(GLubyte * mask)
3471 {
3472     struct glx_context * const gc = __glXGetCurrentContext();
3473     Display * const dpy = gc->currentDpy;
3474 #ifndef USE_XCB
3475     const GLuint cmdlen = 4;
3476 #endif
3477     if (__builtin_expect(dpy != NULL, 1)) {
3478 #ifdef USE_XCB
3479         xcb_connection_t *c = XGetXCBConnection(dpy);
3480         (void) __glXFlushRenderBuffer(gc, gc->pc);
3481         xcb_glx_get_polygon_stipple_reply_t *reply = xcb_glx_get_polygon_stipple_reply(c, xcb_glx_get_polygon_stipple(c, gc->currentContextTag, 0), NULL);
3482         __glEmptyImage(gc, 3, 32, 32, 1, GL_COLOR_INDEX, GL_BITMAP, xcb_glx_get_polygon_stipple_data(reply), mask);
3483         free(reply);
3484 #else
3485         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetPolygonStipple, cmdlen);
3486         *(int32_t *)(pc + 0) = 0;
3487         __glXReadPixelReply(dpy, gc, 2, 32, 32, 1, GL_COLOR_INDEX, GL_BITMAP, mask, GL_FALSE);
3488         UnlockDisplay(dpy); SyncHandle();
3489 #endif /* USE_XCB */
3490     }
3491     return;
3492 }
3493 
3494 #define X_GLsop_GetTexEnvfv 130
__indirect_glGetTexEnvfv(GLenum target,GLenum pname,GLfloat * params)3495 void __indirect_glGetTexEnvfv(GLenum target, GLenum pname, GLfloat * params)
3496 {
3497     struct glx_context * const gc = __glXGetCurrentContext();
3498     Display * const dpy = gc->currentDpy;
3499 #ifndef USE_XCB
3500     const GLuint cmdlen = 8;
3501 #endif
3502     if (__builtin_expect(dpy != NULL, 1)) {
3503 #ifdef USE_XCB
3504         xcb_connection_t *c = XGetXCBConnection(dpy);
3505         (void) __glXFlushRenderBuffer(gc, gc->pc);
3506         xcb_glx_get_tex_envfv_reply_t *reply = xcb_glx_get_tex_envfv_reply(c, xcb_glx_get_tex_envfv(c, gc->currentContextTag, target, pname), NULL);
3507         if (xcb_glx_get_tex_envfv_data_length(reply) == 0)
3508             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3509         else
3510             (void)memcpy(params, xcb_glx_get_tex_envfv_data(reply), xcb_glx_get_tex_envfv_data_length(reply) * sizeof(GLfloat));
3511         free(reply);
3512 #else
3513         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetTexEnvfv, cmdlen);
3514 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
3515 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3516         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3517         UnlockDisplay(dpy); SyncHandle();
3518 #endif /* USE_XCB */
3519     }
3520     return;
3521 }
3522 
3523 #define X_GLsop_GetTexEnviv 131
__indirect_glGetTexEnviv(GLenum target,GLenum pname,GLint * params)3524 void __indirect_glGetTexEnviv(GLenum target, GLenum pname, GLint * params)
3525 {
3526     struct glx_context * const gc = __glXGetCurrentContext();
3527     Display * const dpy = gc->currentDpy;
3528 #ifndef USE_XCB
3529     const GLuint cmdlen = 8;
3530 #endif
3531     if (__builtin_expect(dpy != NULL, 1)) {
3532 #ifdef USE_XCB
3533         xcb_connection_t *c = XGetXCBConnection(dpy);
3534         (void) __glXFlushRenderBuffer(gc, gc->pc);
3535         xcb_glx_get_tex_enviv_reply_t *reply = xcb_glx_get_tex_enviv_reply(c, xcb_glx_get_tex_enviv(c, gc->currentContextTag, target, pname), NULL);
3536         if (xcb_glx_get_tex_enviv_data_length(reply) == 0)
3537             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3538         else
3539             (void)memcpy(params, xcb_glx_get_tex_enviv_data(reply), xcb_glx_get_tex_enviv_data_length(reply) * sizeof(GLint));
3540         free(reply);
3541 #else
3542         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetTexEnviv, cmdlen);
3543 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
3544 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3545         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3546         UnlockDisplay(dpy); SyncHandle();
3547 #endif /* USE_XCB */
3548     }
3549     return;
3550 }
3551 
3552 #define X_GLsop_GetTexGendv 132
__indirect_glGetTexGendv(GLenum coord,GLenum pname,GLdouble * params)3553 void __indirect_glGetTexGendv(GLenum coord, GLenum pname, GLdouble * params)
3554 {
3555     struct glx_context * const gc = __glXGetCurrentContext();
3556     Display * const dpy = gc->currentDpy;
3557 #ifndef USE_XCB
3558     const GLuint cmdlen = 8;
3559 #endif
3560     if (__builtin_expect(dpy != NULL, 1)) {
3561 #ifdef USE_XCB
3562         xcb_connection_t *c = XGetXCBConnection(dpy);
3563         (void) __glXFlushRenderBuffer(gc, gc->pc);
3564         xcb_glx_get_tex_gendv_reply_t *reply = xcb_glx_get_tex_gendv_reply(c, xcb_glx_get_tex_gendv(c, gc->currentContextTag, coord, pname), NULL);
3565         if (xcb_glx_get_tex_gendv_data_length(reply) == 0)
3566             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3567         else
3568             (void)memcpy(params, xcb_glx_get_tex_gendv_data(reply), xcb_glx_get_tex_gendv_data_length(reply) * sizeof(GLdouble));
3569         free(reply);
3570 #else
3571         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetTexGendv, cmdlen);
3572 (void) memcpy((void *)(pc + 0), (void *)(&coord), 4);
3573 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3574         (void) __glXReadReply(dpy, 8, params, GL_FALSE);
3575         UnlockDisplay(dpy); SyncHandle();
3576 #endif /* USE_XCB */
3577     }
3578     return;
3579 }
3580 
3581 #define X_GLsop_GetTexGenfv 133
__indirect_glGetTexGenfv(GLenum coord,GLenum pname,GLfloat * params)3582 void __indirect_glGetTexGenfv(GLenum coord, GLenum pname, GLfloat * params)
3583 {
3584     struct glx_context * const gc = __glXGetCurrentContext();
3585     Display * const dpy = gc->currentDpy;
3586 #ifndef USE_XCB
3587     const GLuint cmdlen = 8;
3588 #endif
3589     if (__builtin_expect(dpy != NULL, 1)) {
3590 #ifdef USE_XCB
3591         xcb_connection_t *c = XGetXCBConnection(dpy);
3592         (void) __glXFlushRenderBuffer(gc, gc->pc);
3593         xcb_glx_get_tex_genfv_reply_t *reply = xcb_glx_get_tex_genfv_reply(c, xcb_glx_get_tex_genfv(c, gc->currentContextTag, coord, pname), NULL);
3594         if (xcb_glx_get_tex_genfv_data_length(reply) == 0)
3595             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3596         else
3597             (void)memcpy(params, xcb_glx_get_tex_genfv_data(reply), xcb_glx_get_tex_genfv_data_length(reply) * sizeof(GLfloat));
3598         free(reply);
3599 #else
3600         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetTexGenfv, cmdlen);
3601 (void) memcpy((void *)(pc + 0), (void *)(&coord), 4);
3602 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3603         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3604         UnlockDisplay(dpy); SyncHandle();
3605 #endif /* USE_XCB */
3606     }
3607     return;
3608 }
3609 
3610 #define X_GLsop_GetTexGeniv 134
__indirect_glGetTexGeniv(GLenum coord,GLenum pname,GLint * params)3611 void __indirect_glGetTexGeniv(GLenum coord, GLenum pname, GLint * params)
3612 {
3613     struct glx_context * const gc = __glXGetCurrentContext();
3614     Display * const dpy = gc->currentDpy;
3615 #ifndef USE_XCB
3616     const GLuint cmdlen = 8;
3617 #endif
3618     if (__builtin_expect(dpy != NULL, 1)) {
3619 #ifdef USE_XCB
3620         xcb_connection_t *c = XGetXCBConnection(dpy);
3621         (void) __glXFlushRenderBuffer(gc, gc->pc);
3622         xcb_glx_get_tex_geniv_reply_t *reply = xcb_glx_get_tex_geniv_reply(c, xcb_glx_get_tex_geniv(c, gc->currentContextTag, coord, pname), NULL);
3623         if (xcb_glx_get_tex_geniv_data_length(reply) == 0)
3624             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3625         else
3626             (void)memcpy(params, xcb_glx_get_tex_geniv_data(reply), xcb_glx_get_tex_geniv_data_length(reply) * sizeof(GLint));
3627         free(reply);
3628 #else
3629         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetTexGeniv, cmdlen);
3630 (void) memcpy((void *)(pc + 0), (void *)(&coord), 4);
3631 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3632         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3633         UnlockDisplay(dpy); SyncHandle();
3634 #endif /* USE_XCB */
3635     }
3636     return;
3637 }
3638 
3639 #define X_GLsop_GetTexImage 135
__indirect_glGetTexImage(GLenum target,GLint level,GLenum format,GLenum type,GLvoid * pixels)3640 void __indirect_glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid * pixels)
3641 {
3642     struct glx_context * const gc = __glXGetCurrentContext();
3643     const __GLXattribute * const state = gc->client_state_private;
3644     Display * const dpy = gc->currentDpy;
3645 #ifndef USE_XCB
3646     const GLuint cmdlen = 20;
3647 #endif
3648     if (__builtin_expect(dpy != NULL, 1)) {
3649 #ifdef USE_XCB
3650         xcb_connection_t *c = XGetXCBConnection(dpy);
3651         (void) __glXFlushRenderBuffer(gc, gc->pc);
3652         xcb_glx_get_tex_image_reply_t *reply = xcb_glx_get_tex_image_reply(c, xcb_glx_get_tex_image(c, gc->currentContextTag, target, level, format, type, state->storePack.swapEndian), NULL);
3653         if (reply->height == 0) { reply->height = 1; }
3654         if (reply->depth == 0) { reply->depth = 1; }
3655         __glEmptyImage(gc, 3, reply->width, reply->height, reply->depth, format, type, xcb_glx_get_tex_image_data(reply), pixels);
3656         free(reply);
3657 #else
3658         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetTexImage, cmdlen);
3659 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
3660 (void) memcpy((void *)(pc + 4), (void *)(&level), 4);
3661 (void) memcpy((void *)(pc + 8), (void *)(&format), 4);
3662 (void) memcpy((void *)(pc + 12), (void *)(&type), 4);
3663         *(int32_t *)(pc + 16) = 0;
3664         * (int8_t *)(pc + 16) = state->storePack.swapEndian;
3665         __glXReadPixelReply(dpy, gc, 3, 0, 0, 0, format, type, pixels, GL_TRUE);
3666         UnlockDisplay(dpy); SyncHandle();
3667 #endif /* USE_XCB */
3668     }
3669     return;
3670 }
3671 
3672 #define X_GLsop_GetTexParameterfv 136
__indirect_glGetTexParameterfv(GLenum target,GLenum pname,GLfloat * params)3673 void __indirect_glGetTexParameterfv(GLenum target, GLenum pname, GLfloat * params)
3674 {
3675     struct glx_context * const gc = __glXGetCurrentContext();
3676     Display * const dpy = gc->currentDpy;
3677 #ifndef USE_XCB
3678     const GLuint cmdlen = 8;
3679 #endif
3680     if (__builtin_expect(dpy != NULL, 1)) {
3681 #ifdef USE_XCB
3682         xcb_connection_t *c = XGetXCBConnection(dpy);
3683         (void) __glXFlushRenderBuffer(gc, gc->pc);
3684         xcb_glx_get_tex_parameterfv_reply_t *reply = xcb_glx_get_tex_parameterfv_reply(c, xcb_glx_get_tex_parameterfv(c, gc->currentContextTag, target, pname), NULL);
3685         if (xcb_glx_get_tex_parameterfv_data_length(reply) == 0)
3686             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3687         else
3688             (void)memcpy(params, xcb_glx_get_tex_parameterfv_data(reply), xcb_glx_get_tex_parameterfv_data_length(reply) * sizeof(GLfloat));
3689         free(reply);
3690 #else
3691         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetTexParameterfv, cmdlen);
3692 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
3693 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3694         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3695         UnlockDisplay(dpy); SyncHandle();
3696 #endif /* USE_XCB */
3697     }
3698     return;
3699 }
3700 
3701 #define X_GLsop_GetTexParameteriv 137
__indirect_glGetTexParameteriv(GLenum target,GLenum pname,GLint * params)3702 void __indirect_glGetTexParameteriv(GLenum target, GLenum pname, GLint * params)
3703 {
3704     struct glx_context * const gc = __glXGetCurrentContext();
3705     Display * const dpy = gc->currentDpy;
3706 #ifndef USE_XCB
3707     const GLuint cmdlen = 8;
3708 #endif
3709     if (__builtin_expect(dpy != NULL, 1)) {
3710 #ifdef USE_XCB
3711         xcb_connection_t *c = XGetXCBConnection(dpy);
3712         (void) __glXFlushRenderBuffer(gc, gc->pc);
3713         xcb_glx_get_tex_parameteriv_reply_t *reply = xcb_glx_get_tex_parameteriv_reply(c, xcb_glx_get_tex_parameteriv(c, gc->currentContextTag, target, pname), NULL);
3714         if (xcb_glx_get_tex_parameteriv_data_length(reply) == 0)
3715             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3716         else
3717             (void)memcpy(params, xcb_glx_get_tex_parameteriv_data(reply), xcb_glx_get_tex_parameteriv_data_length(reply) * sizeof(GLint));
3718         free(reply);
3719 #else
3720         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetTexParameteriv, cmdlen);
3721 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
3722 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
3723         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3724         UnlockDisplay(dpy); SyncHandle();
3725 #endif /* USE_XCB */
3726     }
3727     return;
3728 }
3729 
3730 #define X_GLsop_GetTexLevelParameterfv 138
__indirect_glGetTexLevelParameterfv(GLenum target,GLint level,GLenum pname,GLfloat * params)3731 void __indirect_glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat * params)
3732 {
3733     struct glx_context * const gc = __glXGetCurrentContext();
3734     Display * const dpy = gc->currentDpy;
3735 #ifndef USE_XCB
3736     const GLuint cmdlen = 12;
3737 #endif
3738     if (__builtin_expect(dpy != NULL, 1)) {
3739 #ifdef USE_XCB
3740         xcb_connection_t *c = XGetXCBConnection(dpy);
3741         (void) __glXFlushRenderBuffer(gc, gc->pc);
3742         xcb_glx_get_tex_level_parameterfv_reply_t *reply = xcb_glx_get_tex_level_parameterfv_reply(c, xcb_glx_get_tex_level_parameterfv(c, gc->currentContextTag, target, level, pname), NULL);
3743         if (xcb_glx_get_tex_level_parameterfv_data_length(reply) == 0)
3744             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3745         else
3746             (void)memcpy(params, xcb_glx_get_tex_level_parameterfv_data(reply), xcb_glx_get_tex_level_parameterfv_data_length(reply) * sizeof(GLfloat));
3747         free(reply);
3748 #else
3749         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetTexLevelParameterfv, cmdlen);
3750 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
3751 (void) memcpy((void *)(pc + 4), (void *)(&level), 4);
3752 (void) memcpy((void *)(pc + 8), (void *)(&pname), 4);
3753         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3754         UnlockDisplay(dpy); SyncHandle();
3755 #endif /* USE_XCB */
3756     }
3757     return;
3758 }
3759 
3760 #define X_GLsop_GetTexLevelParameteriv 139
__indirect_glGetTexLevelParameteriv(GLenum target,GLint level,GLenum pname,GLint * params)3761 void __indirect_glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint * params)
3762 {
3763     struct glx_context * const gc = __glXGetCurrentContext();
3764     Display * const dpy = gc->currentDpy;
3765 #ifndef USE_XCB
3766     const GLuint cmdlen = 12;
3767 #endif
3768     if (__builtin_expect(dpy != NULL, 1)) {
3769 #ifdef USE_XCB
3770         xcb_connection_t *c = XGetXCBConnection(dpy);
3771         (void) __glXFlushRenderBuffer(gc, gc->pc);
3772         xcb_glx_get_tex_level_parameteriv_reply_t *reply = xcb_glx_get_tex_level_parameteriv_reply(c, xcb_glx_get_tex_level_parameteriv(c, gc->currentContextTag, target, level, pname), NULL);
3773         if (xcb_glx_get_tex_level_parameteriv_data_length(reply) == 0)
3774             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
3775         else
3776             (void)memcpy(params, xcb_glx_get_tex_level_parameteriv_data(reply), xcb_glx_get_tex_level_parameteriv_data_length(reply) * sizeof(GLint));
3777         free(reply);
3778 #else
3779         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetTexLevelParameteriv, cmdlen);
3780 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
3781 (void) memcpy((void *)(pc + 4), (void *)(&level), 4);
3782 (void) memcpy((void *)(pc + 8), (void *)(&pname), 4);
3783         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
3784         UnlockDisplay(dpy); SyncHandle();
3785 #endif /* USE_XCB */
3786     }
3787     return;
3788 }
3789 
3790 #define X_GLsop_IsList 141
__indirect_glIsList(GLuint list)3791 GLboolean __indirect_glIsList(GLuint list)
3792 {
3793     struct glx_context * const gc = __glXGetCurrentContext();
3794     Display * const dpy = gc->currentDpy;
3795     GLboolean retval = (GLboolean) 0;
3796 #ifndef USE_XCB
3797     const GLuint cmdlen = 4;
3798 #endif
3799     if (__builtin_expect(dpy != NULL, 1)) {
3800 #ifdef USE_XCB
3801         xcb_connection_t *c = XGetXCBConnection(dpy);
3802         (void) __glXFlushRenderBuffer(gc, gc->pc);
3803         xcb_glx_is_list_reply_t *reply = xcb_glx_is_list_reply(c, xcb_glx_is_list(c, gc->currentContextTag, list), NULL);
3804         retval = reply->ret_val;
3805         free(reply);
3806 #else
3807         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_IsList, cmdlen);
3808 (void) memcpy((void *)(pc + 0), (void *)(&list), 4);
3809         retval = (GLboolean) __glXReadReply(dpy, 0, NULL, GL_FALSE);
3810         UnlockDisplay(dpy); SyncHandle();
3811 #endif /* USE_XCB */
3812     }
3813     return retval;
3814 }
3815 
3816 #define X_GLrop_DepthRange 174
__indirect_glDepthRange(GLclampd zNear,GLclampd zFar)3817 void __indirect_glDepthRange(GLclampd zNear, GLclampd zFar)
3818 {
3819     struct glx_context * const gc = __glXGetCurrentContext();
3820     const GLuint cmdlen = 20;
3821 emit_header(gc->pc, X_GLrop_DepthRange, cmdlen);
3822 (void) memcpy((void *)(gc->pc + 4), (void *)(&zNear), 8);
3823 (void) memcpy((void *)(gc->pc + 12), (void *)(&zFar), 8);
3824 gc->pc += cmdlen;
3825 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3826 }
3827 
3828 #define X_GLrop_Frustum 175
__indirect_glFrustum(GLdouble left,GLdouble right,GLdouble bottom,GLdouble top,GLdouble zNear,GLdouble zFar)3829 void __indirect_glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
3830 {
3831     struct glx_context * const gc = __glXGetCurrentContext();
3832     const GLuint cmdlen = 52;
3833 emit_header(gc->pc, X_GLrop_Frustum, cmdlen);
3834 (void) memcpy((void *)(gc->pc + 4), (void *)(&left), 8);
3835 (void) memcpy((void *)(gc->pc + 12), (void *)(&right), 8);
3836 (void) memcpy((void *)(gc->pc + 20), (void *)(&bottom), 8);
3837 (void) memcpy((void *)(gc->pc + 28), (void *)(&top), 8);
3838 (void) memcpy((void *)(gc->pc + 36), (void *)(&zNear), 8);
3839 (void) memcpy((void *)(gc->pc + 44), (void *)(&zFar), 8);
3840 gc->pc += cmdlen;
3841 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3842 }
3843 
3844 #define X_GLrop_LoadIdentity 176
__indirect_glLoadIdentity(void)3845 void __indirect_glLoadIdentity(void)
3846 {
3847     struct glx_context * const gc = __glXGetCurrentContext();
3848     const GLuint cmdlen = 4;
3849 emit_header(gc->pc, X_GLrop_LoadIdentity, cmdlen);
3850 gc->pc += cmdlen;
3851 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3852 }
3853 
3854 #define X_GLrop_LoadMatrixf 177
__indirect_glLoadMatrixf(const GLfloat * m)3855 void __indirect_glLoadMatrixf(const GLfloat * m)
3856 {
3857     struct glx_context * const gc = __glXGetCurrentContext();
3858     const GLuint cmdlen = 68;
3859 emit_header(gc->pc, X_GLrop_LoadMatrixf, cmdlen);
3860 (void) memcpy((void *)(gc->pc + 4), (void *)(m), 64);
3861 gc->pc += cmdlen;
3862 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3863 }
3864 
3865 #define X_GLrop_LoadMatrixd 178
__indirect_glLoadMatrixd(const GLdouble * m)3866 void __indirect_glLoadMatrixd(const GLdouble * m)
3867 {
3868     struct glx_context * const gc = __glXGetCurrentContext();
3869     const GLuint cmdlen = 132;
3870 emit_header(gc->pc, X_GLrop_LoadMatrixd, cmdlen);
3871 (void) memcpy((void *)(gc->pc + 4), (void *)(m), 128);
3872 gc->pc += cmdlen;
3873 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3874 }
3875 
3876 #define X_GLrop_MatrixMode 179
__indirect_glMatrixMode(GLenum mode)3877 void __indirect_glMatrixMode(GLenum mode)
3878 {
3879     struct glx_context * const gc = __glXGetCurrentContext();
3880     const GLuint cmdlen = 8;
3881 emit_header(gc->pc, X_GLrop_MatrixMode, cmdlen);
3882 (void) memcpy((void *)(gc->pc + 4), (void *)(&mode), 4);
3883 gc->pc += cmdlen;
3884 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3885 }
3886 
3887 #define X_GLrop_MultMatrixf 180
__indirect_glMultMatrixf(const GLfloat * m)3888 void __indirect_glMultMatrixf(const GLfloat * m)
3889 {
3890     struct glx_context * const gc = __glXGetCurrentContext();
3891     const GLuint cmdlen = 68;
3892 emit_header(gc->pc, X_GLrop_MultMatrixf, cmdlen);
3893 (void) memcpy((void *)(gc->pc + 4), (void *)(m), 64);
3894 gc->pc += cmdlen;
3895 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3896 }
3897 
3898 #define X_GLrop_MultMatrixd 181
__indirect_glMultMatrixd(const GLdouble * m)3899 void __indirect_glMultMatrixd(const GLdouble * m)
3900 {
3901     struct glx_context * const gc = __glXGetCurrentContext();
3902     const GLuint cmdlen = 132;
3903 emit_header(gc->pc, X_GLrop_MultMatrixd, cmdlen);
3904 (void) memcpy((void *)(gc->pc + 4), (void *)(m), 128);
3905 gc->pc += cmdlen;
3906 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3907 }
3908 
3909 #define X_GLrop_Ortho 182
__indirect_glOrtho(GLdouble left,GLdouble right,GLdouble bottom,GLdouble top,GLdouble zNear,GLdouble zFar)3910 void __indirect_glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
3911 {
3912     struct glx_context * const gc = __glXGetCurrentContext();
3913     const GLuint cmdlen = 52;
3914 emit_header(gc->pc, X_GLrop_Ortho, cmdlen);
3915 (void) memcpy((void *)(gc->pc + 4), (void *)(&left), 8);
3916 (void) memcpy((void *)(gc->pc + 12), (void *)(&right), 8);
3917 (void) memcpy((void *)(gc->pc + 20), (void *)(&bottom), 8);
3918 (void) memcpy((void *)(gc->pc + 28), (void *)(&top), 8);
3919 (void) memcpy((void *)(gc->pc + 36), (void *)(&zNear), 8);
3920 (void) memcpy((void *)(gc->pc + 44), (void *)(&zFar), 8);
3921 gc->pc += cmdlen;
3922 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3923 }
3924 
3925 #define X_GLrop_PopMatrix 183
__indirect_glPopMatrix(void)3926 void __indirect_glPopMatrix(void)
3927 {
3928     struct glx_context * const gc = __glXGetCurrentContext();
3929     const GLuint cmdlen = 4;
3930 emit_header(gc->pc, X_GLrop_PopMatrix, cmdlen);
3931 gc->pc += cmdlen;
3932 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3933 }
3934 
3935 #define X_GLrop_PushMatrix 184
__indirect_glPushMatrix(void)3936 void __indirect_glPushMatrix(void)
3937 {
3938     struct glx_context * const gc = __glXGetCurrentContext();
3939     const GLuint cmdlen = 4;
3940 emit_header(gc->pc, X_GLrop_PushMatrix, cmdlen);
3941 gc->pc += cmdlen;
3942 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3943 }
3944 
3945 #define X_GLrop_Rotated 185
__indirect_glRotated(GLdouble angle,GLdouble x,GLdouble y,GLdouble z)3946 void __indirect_glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
3947 {
3948     struct glx_context * const gc = __glXGetCurrentContext();
3949     const GLuint cmdlen = 36;
3950 emit_header(gc->pc, X_GLrop_Rotated, cmdlen);
3951 (void) memcpy((void *)(gc->pc + 4), (void *)(&angle), 8);
3952 (void) memcpy((void *)(gc->pc + 12), (void *)(&x), 8);
3953 (void) memcpy((void *)(gc->pc + 20), (void *)(&y), 8);
3954 (void) memcpy((void *)(gc->pc + 28), (void *)(&z), 8);
3955 gc->pc += cmdlen;
3956 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3957 }
3958 
3959 #define X_GLrop_Rotatef 186
__indirect_glRotatef(GLfloat angle,GLfloat x,GLfloat y,GLfloat z)3960 void __indirect_glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
3961 {
3962     struct glx_context * const gc = __glXGetCurrentContext();
3963     const GLuint cmdlen = 20;
3964 emit_header(gc->pc, X_GLrop_Rotatef, cmdlen);
3965 (void) memcpy((void *)(gc->pc + 4), (void *)(&angle), 4);
3966 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 4);
3967 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 4);
3968 (void) memcpy((void *)(gc->pc + 16), (void *)(&z), 4);
3969 gc->pc += cmdlen;
3970 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3971 }
3972 
3973 #define X_GLrop_Scaled 187
__indirect_glScaled(GLdouble x,GLdouble y,GLdouble z)3974 void __indirect_glScaled(GLdouble x, GLdouble y, GLdouble z)
3975 {
3976     struct glx_context * const gc = __glXGetCurrentContext();
3977     const GLuint cmdlen = 28;
3978 emit_header(gc->pc, X_GLrop_Scaled, cmdlen);
3979 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 8);
3980 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 8);
3981 (void) memcpy((void *)(gc->pc + 20), (void *)(&z), 8);
3982 gc->pc += cmdlen;
3983 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3984 }
3985 
3986 #define X_GLrop_Scalef 188
__indirect_glScalef(GLfloat x,GLfloat y,GLfloat z)3987 void __indirect_glScalef(GLfloat x, GLfloat y, GLfloat z)
3988 {
3989     struct glx_context * const gc = __glXGetCurrentContext();
3990     const GLuint cmdlen = 16;
3991 emit_header(gc->pc, X_GLrop_Scalef, cmdlen);
3992 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
3993 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
3994 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
3995 gc->pc += cmdlen;
3996 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
3997 }
3998 
3999 #define X_GLrop_Translated 189
__indirect_glTranslated(GLdouble x,GLdouble y,GLdouble z)4000 void __indirect_glTranslated(GLdouble x, GLdouble y, GLdouble z)
4001 {
4002     struct glx_context * const gc = __glXGetCurrentContext();
4003     const GLuint cmdlen = 28;
4004 emit_header(gc->pc, X_GLrop_Translated, cmdlen);
4005 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 8);
4006 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 8);
4007 (void) memcpy((void *)(gc->pc + 20), (void *)(&z), 8);
4008 gc->pc += cmdlen;
4009 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4010 }
4011 
4012 #define X_GLrop_Translatef 190
__indirect_glTranslatef(GLfloat x,GLfloat y,GLfloat z)4013 void __indirect_glTranslatef(GLfloat x, GLfloat y, GLfloat z)
4014 {
4015     struct glx_context * const gc = __glXGetCurrentContext();
4016     const GLuint cmdlen = 16;
4017 emit_header(gc->pc, X_GLrop_Translatef, cmdlen);
4018 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
4019 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
4020 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
4021 gc->pc += cmdlen;
4022 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4023 }
4024 
4025 #define X_GLrop_Viewport 191
__indirect_glViewport(GLint x,GLint y,GLsizei width,GLsizei height)4026 void __indirect_glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
4027 {
4028     struct glx_context * const gc = __glXGetCurrentContext();
4029     const GLuint cmdlen = 20;
4030 emit_header(gc->pc, X_GLrop_Viewport, cmdlen);
4031 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
4032 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
4033 (void) memcpy((void *)(gc->pc + 12), (void *)(&width), 4);
4034 (void) memcpy((void *)(gc->pc + 16), (void *)(&height), 4);
4035 gc->pc += cmdlen;
4036 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4037 }
4038 
4039 #define X_GLrop_BindTexture 4117
__indirect_glBindTexture(GLenum target,GLuint texture)4040 void __indirect_glBindTexture(GLenum target, GLuint texture)
4041 {
4042     struct glx_context * const gc = __glXGetCurrentContext();
4043     const GLuint cmdlen = 12;
4044 emit_header(gc->pc, X_GLrop_BindTexture, cmdlen);
4045 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4046 (void) memcpy((void *)(gc->pc + 8), (void *)(&texture), 4);
4047 gc->pc += cmdlen;
4048 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4049 }
4050 
4051 #define X_GLrop_Indexubv 194
__indirect_glIndexub(GLubyte c)4052 void __indirect_glIndexub(GLubyte c)
4053 {
4054     struct glx_context * const gc = __glXGetCurrentContext();
4055     const GLuint cmdlen = 8;
4056 emit_header(gc->pc, X_GLrop_Indexubv, cmdlen);
4057 (void) memcpy((void *)(gc->pc + 4), (void *)(&c), 1);
4058 gc->pc += cmdlen;
4059 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4060 }
4061 
4062 #define X_GLrop_Indexubv 194
__indirect_glIndexubv(const GLubyte * c)4063 void __indirect_glIndexubv(const GLubyte * c)
4064 {
4065     struct glx_context * const gc = __glXGetCurrentContext();
4066     const GLuint cmdlen = 8;
4067 emit_header(gc->pc, X_GLrop_Indexubv, cmdlen);
4068 (void) memcpy((void *)(gc->pc + 4), (void *)(c), 1);
4069 gc->pc += cmdlen;
4070 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4071 }
4072 
4073 #define X_GLrop_PolygonOffset 192
__indirect_glPolygonOffset(GLfloat factor,GLfloat units)4074 void __indirect_glPolygonOffset(GLfloat factor, GLfloat units)
4075 {
4076     struct glx_context * const gc = __glXGetCurrentContext();
4077     const GLuint cmdlen = 12;
4078 emit_header(gc->pc, X_GLrop_PolygonOffset, cmdlen);
4079 (void) memcpy((void *)(gc->pc + 4), (void *)(&factor), 4);
4080 (void) memcpy((void *)(gc->pc + 8), (void *)(&units), 4);
4081 gc->pc += cmdlen;
4082 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4083 }
4084 
4085 #define X_GLrop_CopyTexImage1D 4119
__indirect_glCopyTexImage1D(GLenum target,GLint level,GLenum internalformat,GLint x,GLint y,GLsizei width,GLint border)4086 void __indirect_glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
4087 {
4088     struct glx_context * const gc = __glXGetCurrentContext();
4089     const GLuint cmdlen = 32;
4090 emit_header(gc->pc, X_GLrop_CopyTexImage1D, cmdlen);
4091 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4092 (void) memcpy((void *)(gc->pc + 8), (void *)(&level), 4);
4093 (void) memcpy((void *)(gc->pc + 12), (void *)(&internalformat), 4);
4094 (void) memcpy((void *)(gc->pc + 16), (void *)(&x), 4);
4095 (void) memcpy((void *)(gc->pc + 20), (void *)(&y), 4);
4096 (void) memcpy((void *)(gc->pc + 24), (void *)(&width), 4);
4097 (void) memcpy((void *)(gc->pc + 28), (void *)(&border), 4);
4098 gc->pc += cmdlen;
4099 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4100 }
4101 
4102 #define X_GLrop_CopyTexImage2D 4120
__indirect_glCopyTexImage2D(GLenum target,GLint level,GLenum internalformat,GLint x,GLint y,GLsizei width,GLsizei height,GLint border)4103 void __indirect_glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
4104 {
4105     struct glx_context * const gc = __glXGetCurrentContext();
4106     const GLuint cmdlen = 36;
4107 emit_header(gc->pc, X_GLrop_CopyTexImage2D, cmdlen);
4108 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4109 (void) memcpy((void *)(gc->pc + 8), (void *)(&level), 4);
4110 (void) memcpy((void *)(gc->pc + 12), (void *)(&internalformat), 4);
4111 (void) memcpy((void *)(gc->pc + 16), (void *)(&x), 4);
4112 (void) memcpy((void *)(gc->pc + 20), (void *)(&y), 4);
4113 (void) memcpy((void *)(gc->pc + 24), (void *)(&width), 4);
4114 (void) memcpy((void *)(gc->pc + 28), (void *)(&height), 4);
4115 (void) memcpy((void *)(gc->pc + 32), (void *)(&border), 4);
4116 gc->pc += cmdlen;
4117 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4118 }
4119 
4120 #define X_GLrop_CopyTexSubImage1D 4121
__indirect_glCopyTexSubImage1D(GLenum target,GLint level,GLint xoffset,GLint x,GLint y,GLsizei width)4121 void __indirect_glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
4122 {
4123     struct glx_context * const gc = __glXGetCurrentContext();
4124     const GLuint cmdlen = 28;
4125 emit_header(gc->pc, X_GLrop_CopyTexSubImage1D, cmdlen);
4126 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4127 (void) memcpy((void *)(gc->pc + 8), (void *)(&level), 4);
4128 (void) memcpy((void *)(gc->pc + 12), (void *)(&xoffset), 4);
4129 (void) memcpy((void *)(gc->pc + 16), (void *)(&x), 4);
4130 (void) memcpy((void *)(gc->pc + 20), (void *)(&y), 4);
4131 (void) memcpy((void *)(gc->pc + 24), (void *)(&width), 4);
4132 gc->pc += cmdlen;
4133 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4134 }
4135 
4136 #define X_GLrop_CopyTexSubImage2D 4122
__indirect_glCopyTexSubImage2D(GLenum target,GLint level,GLint xoffset,GLint yoffset,GLint x,GLint y,GLsizei width,GLsizei height)4137 void __indirect_glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
4138 {
4139     struct glx_context * const gc = __glXGetCurrentContext();
4140     const GLuint cmdlen = 36;
4141 emit_header(gc->pc, X_GLrop_CopyTexSubImage2D, cmdlen);
4142 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4143 (void) memcpy((void *)(gc->pc + 8), (void *)(&level), 4);
4144 (void) memcpy((void *)(gc->pc + 12), (void *)(&xoffset), 4);
4145 (void) memcpy((void *)(gc->pc + 16), (void *)(&yoffset), 4);
4146 (void) memcpy((void *)(gc->pc + 20), (void *)(&x), 4);
4147 (void) memcpy((void *)(gc->pc + 24), (void *)(&y), 4);
4148 (void) memcpy((void *)(gc->pc + 28), (void *)(&width), 4);
4149 (void) memcpy((void *)(gc->pc + 32), (void *)(&height), 4);
4150 gc->pc += cmdlen;
4151 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4152 }
4153 
4154 #define X_GLsop_DeleteTextures 144
__indirect_glDeleteTextures(GLsizei n,const GLuint * textures)4155 void __indirect_glDeleteTextures(GLsizei n, const GLuint * textures)
4156 {
4157     struct glx_context * const gc = __glXGetCurrentContext();
4158     Display * const dpy = gc->currentDpy;
4159 #ifndef USE_XCB
4160     const GLuint cmdlen = 4 + __GLX_PAD((n * 4));
4161 #endif
4162     if (n < 0) {
4163         __glXSetError(gc, GL_INVALID_VALUE);
4164         return;
4165     }
4166     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
4167 #ifdef USE_XCB
4168         xcb_connection_t *c = XGetXCBConnection(dpy);
4169         (void) __glXFlushRenderBuffer(gc, gc->pc);
4170         xcb_glx_delete_textures(c, gc->currentContextTag, n, textures);
4171 #else
4172         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_DeleteTextures, cmdlen);
4173 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
4174 (void) memcpy((void *)(pc + 4), (void *)(textures), (n * 4));
4175         UnlockDisplay(dpy); SyncHandle();
4176 #endif /* USE_XCB */
4177     }
4178     return;
4179 }
4180 
4181 #define X_GLvop_DeleteTexturesEXT 12
glDeleteTexturesEXT(GLsizei n,const GLuint * textures)4182 void glDeleteTexturesEXT(GLsizei n, const GLuint * textures)
4183 {
4184     struct glx_context * const gc = __glXGetCurrentContext();
4185 
4186 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
4187     if (gc->isDirect) {
4188         const _glapi_proc *const disp_table = GET_DISPATCH();
4189         PFNGLDELETETEXTURESEXTPROC p =
4190             (PFNGLDELETETEXTURESEXTPROC) disp_table[327];
4191     p(n, textures);
4192     } else
4193 #endif
4194     {
4195     struct glx_context * const gc = __glXGetCurrentContext();
4196     Display * const dpy = gc->currentDpy;
4197     const GLuint cmdlen = 4 + __GLX_PAD((n * 4));
4198     if (n < 0) {
4199         __glXSetError(gc, GL_INVALID_VALUE);
4200         return;
4201     }
4202     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
4203         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivate, X_GLvop_DeleteTexturesEXT, cmdlen);
4204 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
4205 (void) memcpy((void *)(pc + 4), (void *)(textures), (n * 4));
4206         UnlockDisplay(dpy); SyncHandle();
4207     }
4208     return;
4209 }
4210 }
4211 
4212 #define X_GLsop_GenTextures 145
__indirect_glGenTextures(GLsizei n,GLuint * textures)4213 void __indirect_glGenTextures(GLsizei n, GLuint * textures)
4214 {
4215     struct glx_context * const gc = __glXGetCurrentContext();
4216     Display * const dpy = gc->currentDpy;
4217 #ifndef USE_XCB
4218     const GLuint cmdlen = 4;
4219 #endif
4220     if (n < 0) {
4221         __glXSetError(gc, GL_INVALID_VALUE);
4222         return;
4223     }
4224     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
4225 #ifdef USE_XCB
4226         xcb_connection_t *c = XGetXCBConnection(dpy);
4227         (void) __glXFlushRenderBuffer(gc, gc->pc);
4228         xcb_glx_gen_textures_reply_t *reply = xcb_glx_gen_textures_reply(c, xcb_glx_gen_textures(c, gc->currentContextTag, n), NULL);
4229         (void)memcpy(textures, xcb_glx_gen_textures_data(reply), xcb_glx_gen_textures_data_length(reply) * sizeof(GLuint));
4230         free(reply);
4231 #else
4232         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GenTextures, cmdlen);
4233 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
4234         (void) __glXReadReply(dpy, 4, textures, GL_TRUE);
4235         UnlockDisplay(dpy); SyncHandle();
4236 #endif /* USE_XCB */
4237     }
4238     return;
4239 }
4240 
4241 #define X_GLvop_GenTexturesEXT 13
glGenTexturesEXT(GLsizei n,GLuint * textures)4242 void glGenTexturesEXT(GLsizei n, GLuint * textures)
4243 {
4244     struct glx_context * const gc = __glXGetCurrentContext();
4245 
4246 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
4247     if (gc->isDirect) {
4248         const _glapi_proc *const disp_table = GET_DISPATCH();
4249         PFNGLGENTEXTURESEXTPROC p =
4250             (PFNGLGENTEXTURESEXTPROC) disp_table[328];
4251     p(n, textures);
4252     } else
4253 #endif
4254     {
4255     struct glx_context * const gc = __glXGetCurrentContext();
4256     Display * const dpy = gc->currentDpy;
4257     const GLuint cmdlen = 4;
4258     if (n < 0) {
4259         __glXSetError(gc, GL_INVALID_VALUE);
4260         return;
4261     }
4262     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
4263         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GenTexturesEXT, cmdlen);
4264 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
4265         (void) __glXReadReply(dpy, 4, textures, GL_TRUE);
4266         UnlockDisplay(dpy); SyncHandle();
4267     }
4268     return;
4269 }
4270 }
4271 
4272 #define X_GLsop_IsTexture 146
__indirect_glIsTexture(GLuint texture)4273 GLboolean __indirect_glIsTexture(GLuint texture)
4274 {
4275     struct glx_context * const gc = __glXGetCurrentContext();
4276     Display * const dpy = gc->currentDpy;
4277     GLboolean retval = (GLboolean) 0;
4278 #ifndef USE_XCB
4279     const GLuint cmdlen = 4;
4280 #endif
4281     if (__builtin_expect(dpy != NULL, 1)) {
4282 #ifdef USE_XCB
4283         xcb_connection_t *c = XGetXCBConnection(dpy);
4284         (void) __glXFlushRenderBuffer(gc, gc->pc);
4285         xcb_glx_is_texture_reply_t *reply = xcb_glx_is_texture_reply(c, xcb_glx_is_texture(c, gc->currentContextTag, texture), NULL);
4286         retval = reply->ret_val;
4287         free(reply);
4288 #else
4289         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_IsTexture, cmdlen);
4290 (void) memcpy((void *)(pc + 0), (void *)(&texture), 4);
4291         retval = (GLboolean) __glXReadReply(dpy, 0, NULL, GL_FALSE);
4292         UnlockDisplay(dpy); SyncHandle();
4293 #endif /* USE_XCB */
4294     }
4295     return retval;
4296 }
4297 
4298 #define X_GLvop_IsTextureEXT 14
glIsTextureEXT(GLuint texture)4299 GLboolean glIsTextureEXT(GLuint texture)
4300 {
4301     struct glx_context * const gc = __glXGetCurrentContext();
4302 
4303 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
4304     if (gc->isDirect) {
4305         const _glapi_proc *const disp_table = GET_DISPATCH();
4306         PFNGLISTEXTUREEXTPROC p =
4307             (PFNGLISTEXTUREEXTPROC) disp_table[330];
4308     return p(texture);
4309     } else
4310 #endif
4311     {
4312     struct glx_context * const gc = __glXGetCurrentContext();
4313     Display * const dpy = gc->currentDpy;
4314     GLboolean retval = (GLboolean) 0;
4315     const GLuint cmdlen = 4;
4316     if (__builtin_expect(dpy != NULL, 1)) {
4317         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_IsTextureEXT, cmdlen);
4318 (void) memcpy((void *)(pc + 0), (void *)(&texture), 4);
4319         retval = (GLboolean) __glXReadReply(dpy, 0, NULL, GL_FALSE);
4320         UnlockDisplay(dpy); SyncHandle();
4321     }
4322     return retval;
4323 }
4324 }
4325 
4326 #define X_GLrop_PrioritizeTextures 4118
__indirect_glPrioritizeTextures(GLsizei n,const GLuint * textures,const GLclampf * priorities)4327 void __indirect_glPrioritizeTextures(GLsizei n, const GLuint * textures, const GLclampf * priorities)
4328 {
4329     struct glx_context * const gc = __glXGetCurrentContext();
4330     const GLuint cmdlen = 8 + __GLX_PAD((n * 4)) + __GLX_PAD((n * 4));
4331     if (n < 0) {
4332         __glXSetError(gc, GL_INVALID_VALUE);
4333         return;
4334     }
4335     if (__builtin_expect(n >= 0, 1)) {
4336 emit_header(gc->pc, X_GLrop_PrioritizeTextures, cmdlen);
4337 (void) memcpy((void *)(gc->pc + 4), (void *)(&n), 4);
4338 (void) memcpy((void *)(gc->pc + 8), (void *)(textures), (n * 4));
4339 (void) memcpy((void *)(gc->pc + 8 + (n * 4)), (void *)(priorities), (n * 4));
4340 gc->pc += cmdlen;
4341 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4342     }
4343 }
4344 
4345 static void
__glx_TexSubImage_1D2D(unsigned opcode,unsigned dim,GLenum target,GLint level,GLint xoffset,GLint yoffset,GLsizei width,GLsizei height,GLenum format,GLenum type,const GLvoid * pixels)4346 __glx_TexSubImage_1D2D( unsigned opcode, unsigned dim, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid * pixels )
4347 {
4348     struct glx_context * const gc = __glXGetCurrentContext();
4349     const GLuint compsize = (pixels != NULL) ? __glImageSize(width, height, 1, format, type, target) : 0;
4350     const GLuint cmdlen = 60 + __GLX_PAD(compsize);
4351     if (__builtin_expect(gc->currentDpy != NULL, 1)) {
4352 if (cmdlen <= gc->maxSmallRenderCommandSize) {
4353     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
4354         (void) __glXFlushRenderBuffer(gc, gc->pc);
4355     }
4356 emit_header(gc->pc, opcode, cmdlen);
4357 (void) memcpy((void *)(gc->pc + 24), (void *)(&target), 4);
4358 (void) memcpy((void *)(gc->pc + 28), (void *)(&level), 4);
4359 (void) memcpy((void *)(gc->pc + 32), (void *)(&xoffset), 4);
4360 (void) memcpy((void *)(gc->pc + 36), (void *)(&yoffset), 4);
4361 (void) memcpy((void *)(gc->pc + 40), (void *)(&width), 4);
4362 (void) memcpy((void *)(gc->pc + 44), (void *)(&height), 4);
4363 (void) memcpy((void *)(gc->pc + 48), (void *)(&format), 4);
4364 (void) memcpy((void *)(gc->pc + 52), (void *)(&type), 4);
4365 (void) memset((void *)(gc->pc + 56), 0, 4);
4366 if (compsize > 0) {
4367     (*gc->fillImage)(gc, dim, width, height, 1, format, type, pixels, gc->pc + 60, gc->pc + 4);
4368 } else {
4369     (void) memcpy( gc->pc + 4, default_pixel_store_2D, default_pixel_store_2D_size );
4370 }
4371 gc->pc += cmdlen;
4372 if (gc->pc > gc->limit) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4373 }
4374 else {
4375 const GLint op = opcode;
4376 const GLuint cmdlenLarge = cmdlen + 4;
4377 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
4378 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
4379 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
4380 (void) memcpy((void *)(pc + 28), (void *)(&target), 4);
4381 (void) memcpy((void *)(pc + 32), (void *)(&level), 4);
4382 (void) memcpy((void *)(pc + 36), (void *)(&xoffset), 4);
4383 (void) memcpy((void *)(pc + 40), (void *)(&yoffset), 4);
4384 (void) memcpy((void *)(pc + 44), (void *)(&width), 4);
4385 (void) memcpy((void *)(pc + 48), (void *)(&height), 4);
4386 (void) memcpy((void *)(pc + 52), (void *)(&format), 4);
4387 (void) memcpy((void *)(pc + 56), (void *)(&type), 4);
4388 (void) memset((void *)(pc + 60), 0, 4);
4389 __glXSendLargeImage(gc, compsize, dim, width, height, 1, format, type, pixels, pc + 64, pc + 8);
4390 }
4391     }
4392 }
4393 
4394 #define X_GLrop_TexSubImage1D 4099
__indirect_glTexSubImage1D(GLenum target,GLint level,GLint xoffset,GLsizei width,GLenum format,GLenum type,const GLvoid * pixels)4395 void __indirect_glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid * pixels)
4396 {
4397     __glx_TexSubImage_1D2D(X_GLrop_TexSubImage1D, 1, target, level, xoffset, 1, width, 1, format, type, pixels );
4398 }
4399 
4400 #define X_GLrop_TexSubImage2D 4100
__indirect_glTexSubImage2D(GLenum target,GLint level,GLint xoffset,GLint yoffset,GLsizei width,GLsizei height,GLenum format,GLenum type,const GLvoid * pixels)4401 void __indirect_glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid * pixels)
4402 {
4403     __glx_TexSubImage_1D2D(X_GLrop_TexSubImage2D, 2, target, level, xoffset, yoffset, width, height, format, type, pixels );
4404 }
4405 
4406 #define X_GLrop_BlendColor 4096
__indirect_glBlendColor(GLclampf red,GLclampf green,GLclampf blue,GLclampf alpha)4407 void __indirect_glBlendColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha)
4408 {
4409     struct glx_context * const gc = __glXGetCurrentContext();
4410     const GLuint cmdlen = 20;
4411 emit_header(gc->pc, X_GLrop_BlendColor, cmdlen);
4412 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
4413 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
4414 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
4415 (void) memcpy((void *)(gc->pc + 16), (void *)(&alpha), 4);
4416 gc->pc += cmdlen;
4417 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4418 }
4419 
4420 #define X_GLrop_BlendEquation 4097
__indirect_glBlendEquation(GLenum mode)4421 void __indirect_glBlendEquation(GLenum mode)
4422 {
4423     struct glx_context * const gc = __glXGetCurrentContext();
4424     const GLuint cmdlen = 8;
4425 emit_header(gc->pc, X_GLrop_BlendEquation, cmdlen);
4426 (void) memcpy((void *)(gc->pc + 4), (void *)(&mode), 4);
4427 gc->pc += cmdlen;
4428 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4429 }
4430 
4431 #define X_GLrop_ColorTable 2053
__indirect_glColorTable(GLenum target,GLenum internalformat,GLsizei width,GLenum format,GLenum type,const GLvoid * table)4432 void __indirect_glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid * table)
4433 {
4434     struct glx_context * const gc = __glXGetCurrentContext();
4435     const GLuint compsize = (table != NULL) ? __glImageSize(width, 1, 1, format, type, target) : 0;
4436     const GLuint cmdlen = 44 + __GLX_PAD(compsize);
4437     if (__builtin_expect(gc->currentDpy != NULL, 1)) {
4438 if (cmdlen <= gc->maxSmallRenderCommandSize) {
4439     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
4440         (void) __glXFlushRenderBuffer(gc, gc->pc);
4441     }
4442 emit_header(gc->pc, X_GLrop_ColorTable, cmdlen);
4443 (void) memcpy((void *)(gc->pc + 24), (void *)(&target), 4);
4444 (void) memcpy((void *)(gc->pc + 28), (void *)(&internalformat), 4);
4445 (void) memcpy((void *)(gc->pc + 32), (void *)(&width), 4);
4446 (void) memcpy((void *)(gc->pc + 36), (void *)(&format), 4);
4447 (void) memcpy((void *)(gc->pc + 40), (void *)(&type), 4);
4448 if (compsize > 0) {
4449     (*gc->fillImage)(gc, 1, width, 1, 1, format, type, table, gc->pc + 44, gc->pc + 4);
4450 } else {
4451     (void) memcpy( gc->pc + 4, default_pixel_store_1D, default_pixel_store_1D_size );
4452 }
4453 gc->pc += cmdlen;
4454 if (gc->pc > gc->limit) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4455 }
4456 else {
4457 const GLint op = X_GLrop_ColorTable;
4458 const GLuint cmdlenLarge = cmdlen + 4;
4459 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
4460 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
4461 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
4462 (void) memcpy((void *)(pc + 28), (void *)(&target), 4);
4463 (void) memcpy((void *)(pc + 32), (void *)(&internalformat), 4);
4464 (void) memcpy((void *)(pc + 36), (void *)(&width), 4);
4465 (void) memcpy((void *)(pc + 40), (void *)(&format), 4);
4466 (void) memcpy((void *)(pc + 44), (void *)(&type), 4);
4467 __glXSendLargeImage(gc, compsize, 1, width, 1, 1, format, type, table, pc + 48, pc + 8);
4468 }
4469     }
4470 }
4471 
4472 #define X_GLrop_ColorTableParameterfv 2054
__indirect_glColorTableParameterfv(GLenum target,GLenum pname,const GLfloat * params)4473 void __indirect_glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat * params)
4474 {
4475     struct glx_context * const gc = __glXGetCurrentContext();
4476     const GLuint compsize = __glColorTableParameterfv_size(pname);
4477     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
4478 emit_header(gc->pc, X_GLrop_ColorTableParameterfv, cmdlen);
4479 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4480 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
4481 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
4482 gc->pc += cmdlen;
4483 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4484 }
4485 
4486 #define X_GLrop_ColorTableParameteriv 2055
__indirect_glColorTableParameteriv(GLenum target,GLenum pname,const GLint * params)4487 void __indirect_glColorTableParameteriv(GLenum target, GLenum pname, const GLint * params)
4488 {
4489     struct glx_context * const gc = __glXGetCurrentContext();
4490     const GLuint compsize = __glColorTableParameteriv_size(pname);
4491     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
4492 emit_header(gc->pc, X_GLrop_ColorTableParameteriv, cmdlen);
4493 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4494 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
4495 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
4496 gc->pc += cmdlen;
4497 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4498 }
4499 
4500 #define X_GLrop_CopyColorTable 2056
__indirect_glCopyColorTable(GLenum target,GLenum internalformat,GLint x,GLint y,GLsizei width)4501 void __indirect_glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
4502 {
4503     struct glx_context * const gc = __glXGetCurrentContext();
4504     const GLuint cmdlen = 24;
4505 emit_header(gc->pc, X_GLrop_CopyColorTable, cmdlen);
4506 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4507 (void) memcpy((void *)(gc->pc + 8), (void *)(&internalformat), 4);
4508 (void) memcpy((void *)(gc->pc + 12), (void *)(&x), 4);
4509 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 4);
4510 (void) memcpy((void *)(gc->pc + 20), (void *)(&width), 4);
4511 gc->pc += cmdlen;
4512 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4513 }
4514 
4515 #define X_GLsop_GetColorTable 147
__indirect_glGetColorTable(GLenum target,GLenum format,GLenum type,GLvoid * table)4516 void __indirect_glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid * table)
4517 {
4518     struct glx_context * const gc = __glXGetCurrentContext();
4519     const __GLXattribute * const state = gc->client_state_private;
4520     Display * const dpy = gc->currentDpy;
4521 #ifndef USE_XCB
4522     const GLuint cmdlen = 16;
4523 #endif
4524     if (__builtin_expect(dpy != NULL, 1)) {
4525 #ifdef USE_XCB
4526         xcb_connection_t *c = XGetXCBConnection(dpy);
4527         (void) __glXFlushRenderBuffer(gc, gc->pc);
4528         xcb_glx_get_color_table_reply_t *reply = xcb_glx_get_color_table_reply(c, xcb_glx_get_color_table(c, gc->currentContextTag, target, format, type, state->storePack.swapEndian), NULL);
4529         __glEmptyImage(gc, 3, reply->width, 1, 1, format, type, xcb_glx_get_color_table_data(reply), table);
4530         free(reply);
4531 #else
4532         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetColorTable, cmdlen);
4533 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
4534 (void) memcpy((void *)(pc + 4), (void *)(&format), 4);
4535 (void) memcpy((void *)(pc + 8), (void *)(&type), 4);
4536         *(int32_t *)(pc + 12) = 0;
4537         * (int8_t *)(pc + 12) = state->storePack.swapEndian;
4538         __glXReadPixelReply(dpy, gc, 1, 0, 0, 0, format, type, table, GL_TRUE);
4539         UnlockDisplay(dpy); SyncHandle();
4540 #endif /* USE_XCB */
4541     }
4542     return;
4543 }
4544 
4545 #define X_GLvop_GetColorTableSGI 4098
glGetColorTableEXT(GLenum target,GLenum format,GLenum type,GLvoid * table)4546 void glGetColorTableEXT(GLenum target, GLenum format, GLenum type, GLvoid * table)
4547 {
4548     struct glx_context * const gc = __glXGetCurrentContext();
4549 
4550 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
4551     if (gc->isDirect) {
4552         const _glapi_proc *const disp_table = GET_DISPATCH();
4553         PFNGLGETCOLORTABLESGIPROC p =
4554             (PFNGLGETCOLORTABLESGIPROC) disp_table[343];
4555     p(target, format, type, table);
4556     } else
4557 #endif
4558     {
4559     struct glx_context * const gc = __glXGetCurrentContext();
4560     const __GLXattribute * const state = gc->client_state_private;
4561     Display * const dpy = gc->currentDpy;
4562     const GLuint cmdlen = 16;
4563     if (__builtin_expect(dpy != NULL, 1)) {
4564         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetColorTableSGI, cmdlen);
4565 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
4566 (void) memcpy((void *)(pc + 4), (void *)(&format), 4);
4567 (void) memcpy((void *)(pc + 8), (void *)(&type), 4);
4568         *(int32_t *)(pc + 12) = 0;
4569         * (int8_t *)(pc + 12) = state->storePack.swapEndian;
4570         __glXReadPixelReply(dpy, gc, 1, 0, 0, 0, format, type, table, GL_TRUE);
4571         UnlockDisplay(dpy); SyncHandle();
4572     }
4573     return;
4574 }
4575 }
4576 
4577 #define X_GLsop_GetColorTableParameterfv 148
__indirect_glGetColorTableParameterfv(GLenum target,GLenum pname,GLfloat * params)4578 void __indirect_glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat * params)
4579 {
4580     struct glx_context * const gc = __glXGetCurrentContext();
4581     Display * const dpy = gc->currentDpy;
4582 #ifndef USE_XCB
4583     const GLuint cmdlen = 8;
4584 #endif
4585     if (__builtin_expect(dpy != NULL, 1)) {
4586 #ifdef USE_XCB
4587         xcb_connection_t *c = XGetXCBConnection(dpy);
4588         (void) __glXFlushRenderBuffer(gc, gc->pc);
4589         xcb_glx_get_color_table_parameterfv_reply_t *reply = xcb_glx_get_color_table_parameterfv_reply(c, xcb_glx_get_color_table_parameterfv(c, gc->currentContextTag, target, pname), NULL);
4590         if (xcb_glx_get_color_table_parameterfv_data_length(reply) == 0)
4591             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
4592         else
4593             (void)memcpy(params, xcb_glx_get_color_table_parameterfv_data(reply), xcb_glx_get_color_table_parameterfv_data_length(reply) * sizeof(GLfloat));
4594         free(reply);
4595 #else
4596         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetColorTableParameterfv, cmdlen);
4597 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
4598 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
4599         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
4600         UnlockDisplay(dpy); SyncHandle();
4601 #endif /* USE_XCB */
4602     }
4603     return;
4604 }
4605 
4606 #define X_GLvop_GetColorTableParameterfvSGI 4099
glGetColorTableParameterfvEXT(GLenum target,GLenum pname,GLfloat * params)4607 void glGetColorTableParameterfvEXT(GLenum target, GLenum pname, GLfloat * params)
4608 {
4609     struct glx_context * const gc = __glXGetCurrentContext();
4610 
4611 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
4612     if (gc->isDirect) {
4613         const _glapi_proc *const disp_table = GET_DISPATCH();
4614         PFNGLGETCOLORTABLEPARAMETERFVSGIPROC p =
4615             (PFNGLGETCOLORTABLEPARAMETERFVSGIPROC) disp_table[344];
4616     p(target, pname, params);
4617     } else
4618 #endif
4619     {
4620     struct glx_context * const gc = __glXGetCurrentContext();
4621     Display * const dpy = gc->currentDpy;
4622     const GLuint cmdlen = 8;
4623     if (__builtin_expect(dpy != NULL, 1)) {
4624         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetColorTableParameterfvSGI, cmdlen);
4625 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
4626 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
4627         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
4628         UnlockDisplay(dpy); SyncHandle();
4629     }
4630     return;
4631 }
4632 }
4633 
4634 #define X_GLsop_GetColorTableParameteriv 149
__indirect_glGetColorTableParameteriv(GLenum target,GLenum pname,GLint * params)4635 void __indirect_glGetColorTableParameteriv(GLenum target, GLenum pname, GLint * params)
4636 {
4637     struct glx_context * const gc = __glXGetCurrentContext();
4638     Display * const dpy = gc->currentDpy;
4639 #ifndef USE_XCB
4640     const GLuint cmdlen = 8;
4641 #endif
4642     if (__builtin_expect(dpy != NULL, 1)) {
4643 #ifdef USE_XCB
4644         xcb_connection_t *c = XGetXCBConnection(dpy);
4645         (void) __glXFlushRenderBuffer(gc, gc->pc);
4646         xcb_glx_get_color_table_parameteriv_reply_t *reply = xcb_glx_get_color_table_parameteriv_reply(c, xcb_glx_get_color_table_parameteriv(c, gc->currentContextTag, target, pname), NULL);
4647         if (xcb_glx_get_color_table_parameteriv_data_length(reply) == 0)
4648             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
4649         else
4650             (void)memcpy(params, xcb_glx_get_color_table_parameteriv_data(reply), xcb_glx_get_color_table_parameteriv_data_length(reply) * sizeof(GLint));
4651         free(reply);
4652 #else
4653         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetColorTableParameteriv, cmdlen);
4654 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
4655 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
4656         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
4657         UnlockDisplay(dpy); SyncHandle();
4658 #endif /* USE_XCB */
4659     }
4660     return;
4661 }
4662 
4663 #define X_GLvop_GetColorTableParameterivSGI 4100
glGetColorTableParameterivEXT(GLenum target,GLenum pname,GLint * params)4664 void glGetColorTableParameterivEXT(GLenum target, GLenum pname, GLint * params)
4665 {
4666     struct glx_context * const gc = __glXGetCurrentContext();
4667 
4668 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
4669     if (gc->isDirect) {
4670         const _glapi_proc *const disp_table = GET_DISPATCH();
4671         PFNGLGETCOLORTABLEPARAMETERIVSGIPROC p =
4672             (PFNGLGETCOLORTABLEPARAMETERIVSGIPROC) disp_table[345];
4673     p(target, pname, params);
4674     } else
4675 #endif
4676     {
4677     struct glx_context * const gc = __glXGetCurrentContext();
4678     Display * const dpy = gc->currentDpy;
4679     const GLuint cmdlen = 8;
4680     if (__builtin_expect(dpy != NULL, 1)) {
4681         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetColorTableParameterivSGI, cmdlen);
4682 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
4683 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
4684         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
4685         UnlockDisplay(dpy); SyncHandle();
4686     }
4687     return;
4688 }
4689 }
4690 
4691 #define X_GLrop_ColorSubTable 195
__indirect_glColorSubTable(GLenum target,GLsizei start,GLsizei count,GLenum format,GLenum type,const GLvoid * data)4692 void __indirect_glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid * data)
4693 {
4694     struct glx_context * const gc = __glXGetCurrentContext();
4695     const GLuint compsize = (data != NULL) ? __glImageSize(count, 1, 1, format, type, target) : 0;
4696     const GLuint cmdlen = 44 + __GLX_PAD(compsize);
4697     if (__builtin_expect(gc->currentDpy != NULL, 1)) {
4698 if (cmdlen <= gc->maxSmallRenderCommandSize) {
4699     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
4700         (void) __glXFlushRenderBuffer(gc, gc->pc);
4701     }
4702 emit_header(gc->pc, X_GLrop_ColorSubTable, cmdlen);
4703 (void) memcpy((void *)(gc->pc + 24), (void *)(&target), 4);
4704 (void) memcpy((void *)(gc->pc + 28), (void *)(&start), 4);
4705 (void) memcpy((void *)(gc->pc + 32), (void *)(&count), 4);
4706 (void) memcpy((void *)(gc->pc + 36), (void *)(&format), 4);
4707 (void) memcpy((void *)(gc->pc + 40), (void *)(&type), 4);
4708 if (compsize > 0) {
4709     (*gc->fillImage)(gc, 1, count, 1, 1, format, type, data, gc->pc + 44, gc->pc + 4);
4710 } else {
4711     (void) memcpy( gc->pc + 4, default_pixel_store_1D, default_pixel_store_1D_size );
4712 }
4713 gc->pc += cmdlen;
4714 if (gc->pc > gc->limit) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4715 }
4716 else {
4717 const GLint op = X_GLrop_ColorSubTable;
4718 const GLuint cmdlenLarge = cmdlen + 4;
4719 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
4720 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
4721 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
4722 (void) memcpy((void *)(pc + 28), (void *)(&target), 4);
4723 (void) memcpy((void *)(pc + 32), (void *)(&start), 4);
4724 (void) memcpy((void *)(pc + 36), (void *)(&count), 4);
4725 (void) memcpy((void *)(pc + 40), (void *)(&format), 4);
4726 (void) memcpy((void *)(pc + 44), (void *)(&type), 4);
4727 __glXSendLargeImage(gc, compsize, 1, count, 1, 1, format, type, data, pc + 48, pc + 8);
4728 }
4729     }
4730 }
4731 
4732 #define X_GLrop_CopyColorSubTable 196
__indirect_glCopyColorSubTable(GLenum target,GLsizei start,GLint x,GLint y,GLsizei width)4733 void __indirect_glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
4734 {
4735     struct glx_context * const gc = __glXGetCurrentContext();
4736     const GLuint cmdlen = 24;
4737 emit_header(gc->pc, X_GLrop_CopyColorSubTable, cmdlen);
4738 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4739 (void) memcpy((void *)(gc->pc + 8), (void *)(&start), 4);
4740 (void) memcpy((void *)(gc->pc + 12), (void *)(&x), 4);
4741 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 4);
4742 (void) memcpy((void *)(gc->pc + 20), (void *)(&width), 4);
4743 gc->pc += cmdlen;
4744 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4745 }
4746 
4747 static void
__glx_ConvolutionFilter_1D2D(unsigned opcode,unsigned dim,GLenum target,GLenum internalformat,GLsizei width,GLsizei height,GLenum format,GLenum type,const GLvoid * image)4748 __glx_ConvolutionFilter_1D2D( unsigned opcode, unsigned dim, GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid * image )
4749 {
4750     struct glx_context * const gc = __glXGetCurrentContext();
4751     const GLuint compsize = (image != NULL) ? __glImageSize(width, height, 1, format, type, target) : 0;
4752     const GLuint cmdlen = 48 + __GLX_PAD(compsize);
4753     if (__builtin_expect(gc->currentDpy != NULL, 1)) {
4754 if (cmdlen <= gc->maxSmallRenderCommandSize) {
4755     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
4756         (void) __glXFlushRenderBuffer(gc, gc->pc);
4757     }
4758 emit_header(gc->pc, opcode, cmdlen);
4759 (void) memcpy((void *)(gc->pc + 24), (void *)(&target), 4);
4760 (void) memcpy((void *)(gc->pc + 28), (void *)(&internalformat), 4);
4761 (void) memcpy((void *)(gc->pc + 32), (void *)(&width), 4);
4762 (void) memcpy((void *)(gc->pc + 36), (void *)(&height), 4);
4763 (void) memcpy((void *)(gc->pc + 40), (void *)(&format), 4);
4764 (void) memcpy((void *)(gc->pc + 44), (void *)(&type), 4);
4765 if (compsize > 0) {
4766     (*gc->fillImage)(gc, dim, width, height, 1, format, type, image, gc->pc + 48, gc->pc + 4);
4767 } else {
4768     (void) memcpy( gc->pc + 4, default_pixel_store_2D, default_pixel_store_2D_size );
4769 }
4770 gc->pc += cmdlen;
4771 if (gc->pc > gc->limit) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4772 }
4773 else {
4774 const GLint op = opcode;
4775 const GLuint cmdlenLarge = cmdlen + 4;
4776 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
4777 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
4778 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
4779 (void) memcpy((void *)(pc + 28), (void *)(&target), 4);
4780 (void) memcpy((void *)(pc + 32), (void *)(&internalformat), 4);
4781 (void) memcpy((void *)(pc + 36), (void *)(&width), 4);
4782 (void) memcpy((void *)(pc + 40), (void *)(&height), 4);
4783 (void) memcpy((void *)(pc + 44), (void *)(&format), 4);
4784 (void) memcpy((void *)(pc + 48), (void *)(&type), 4);
4785 __glXSendLargeImage(gc, compsize, dim, width, height, 1, format, type, image, pc + 52, pc + 8);
4786 }
4787     }
4788 }
4789 
4790 #define X_GLrop_ConvolutionFilter1D 4101
__indirect_glConvolutionFilter1D(GLenum target,GLenum internalformat,GLsizei width,GLenum format,GLenum type,const GLvoid * image)4791 void __indirect_glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid * image)
4792 {
4793     __glx_ConvolutionFilter_1D2D(X_GLrop_ConvolutionFilter1D, 1, target, internalformat, width, 1, format, type, image );
4794 }
4795 
4796 #define X_GLrop_ConvolutionFilter2D 4102
__indirect_glConvolutionFilter2D(GLenum target,GLenum internalformat,GLsizei width,GLsizei height,GLenum format,GLenum type,const GLvoid * image)4797 void __indirect_glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid * image)
4798 {
4799     __glx_ConvolutionFilter_1D2D(X_GLrop_ConvolutionFilter2D, 2, target, internalformat, width, height, format, type, image );
4800 }
4801 
4802 #define X_GLrop_ConvolutionParameterf 4103
__indirect_glConvolutionParameterf(GLenum target,GLenum pname,GLfloat params)4803 void __indirect_glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
4804 {
4805     struct glx_context * const gc = __glXGetCurrentContext();
4806     const GLuint cmdlen = 16;
4807 emit_header(gc->pc, X_GLrop_ConvolutionParameterf, cmdlen);
4808 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4809 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
4810 (void) memcpy((void *)(gc->pc + 12), (void *)(&params), 4);
4811 gc->pc += cmdlen;
4812 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4813 }
4814 
4815 #define X_GLrop_ConvolutionParameterfv 4104
__indirect_glConvolutionParameterfv(GLenum target,GLenum pname,const GLfloat * params)4816 void __indirect_glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat * params)
4817 {
4818     struct glx_context * const gc = __glXGetCurrentContext();
4819     const GLuint compsize = __glConvolutionParameterfv_size(pname);
4820     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
4821 emit_header(gc->pc, X_GLrop_ConvolutionParameterfv, cmdlen);
4822 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4823 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
4824 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
4825 gc->pc += cmdlen;
4826 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4827 }
4828 
4829 #define X_GLrop_ConvolutionParameteri 4105
__indirect_glConvolutionParameteri(GLenum target,GLenum pname,GLint params)4830 void __indirect_glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
4831 {
4832     struct glx_context * const gc = __glXGetCurrentContext();
4833     const GLuint cmdlen = 16;
4834 emit_header(gc->pc, X_GLrop_ConvolutionParameteri, cmdlen);
4835 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4836 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
4837 (void) memcpy((void *)(gc->pc + 12), (void *)(&params), 4);
4838 gc->pc += cmdlen;
4839 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4840 }
4841 
4842 #define X_GLrop_ConvolutionParameteriv 4106
__indirect_glConvolutionParameteriv(GLenum target,GLenum pname,const GLint * params)4843 void __indirect_glConvolutionParameteriv(GLenum target, GLenum pname, const GLint * params)
4844 {
4845     struct glx_context * const gc = __glXGetCurrentContext();
4846     const GLuint compsize = __glConvolutionParameteriv_size(pname);
4847     const GLuint cmdlen = 12 + __GLX_PAD((compsize * 4));
4848 emit_header(gc->pc, X_GLrop_ConvolutionParameteriv, cmdlen);
4849 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4850 (void) memcpy((void *)(gc->pc + 8), (void *)(&pname), 4);
4851 (void) memcpy((void *)(gc->pc + 12), (void *)(params), (compsize * 4));
4852 gc->pc += cmdlen;
4853 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4854 }
4855 
4856 #define X_GLrop_CopyConvolutionFilter1D 4107
__indirect_glCopyConvolutionFilter1D(GLenum target,GLenum internalformat,GLint x,GLint y,GLsizei width)4857 void __indirect_glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
4858 {
4859     struct glx_context * const gc = __glXGetCurrentContext();
4860     const GLuint cmdlen = 24;
4861 emit_header(gc->pc, X_GLrop_CopyConvolutionFilter1D, cmdlen);
4862 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4863 (void) memcpy((void *)(gc->pc + 8), (void *)(&internalformat), 4);
4864 (void) memcpy((void *)(gc->pc + 12), (void *)(&x), 4);
4865 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 4);
4866 (void) memcpy((void *)(gc->pc + 20), (void *)(&width), 4);
4867 gc->pc += cmdlen;
4868 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4869 }
4870 
4871 #define X_GLrop_CopyConvolutionFilter2D 4108
__indirect_glCopyConvolutionFilter2D(GLenum target,GLenum internalformat,GLint x,GLint y,GLsizei width,GLsizei height)4872 void __indirect_glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
4873 {
4874     struct glx_context * const gc = __glXGetCurrentContext();
4875     const GLuint cmdlen = 28;
4876 emit_header(gc->pc, X_GLrop_CopyConvolutionFilter2D, cmdlen);
4877 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
4878 (void) memcpy((void *)(gc->pc + 8), (void *)(&internalformat), 4);
4879 (void) memcpy((void *)(gc->pc + 12), (void *)(&x), 4);
4880 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 4);
4881 (void) memcpy((void *)(gc->pc + 20), (void *)(&width), 4);
4882 (void) memcpy((void *)(gc->pc + 24), (void *)(&height), 4);
4883 gc->pc += cmdlen;
4884 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
4885 }
4886 
4887 #define X_GLsop_GetConvolutionFilter 150
__indirect_glGetConvolutionFilter(GLenum target,GLenum format,GLenum type,GLvoid * image)4888 void __indirect_glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid * image)
4889 {
4890     struct glx_context * const gc = __glXGetCurrentContext();
4891     const __GLXattribute * const state = gc->client_state_private;
4892     Display * const dpy = gc->currentDpy;
4893 #ifndef USE_XCB
4894     const GLuint cmdlen = 16;
4895 #endif
4896     if (__builtin_expect(dpy != NULL, 1)) {
4897 #ifdef USE_XCB
4898         xcb_connection_t *c = XGetXCBConnection(dpy);
4899         (void) __glXFlushRenderBuffer(gc, gc->pc);
4900         xcb_glx_get_convolution_filter_reply_t *reply = xcb_glx_get_convolution_filter_reply(c, xcb_glx_get_convolution_filter(c, gc->currentContextTag, target, format, type, state->storePack.swapEndian), NULL);
4901         if (reply->height == 0) { reply->height = 1; }
4902         __glEmptyImage(gc, 3, reply->width, reply->height, 1, format, type, xcb_glx_get_convolution_filter_data(reply), image);
4903         free(reply);
4904 #else
4905         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetConvolutionFilter, cmdlen);
4906 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
4907 (void) memcpy((void *)(pc + 4), (void *)(&format), 4);
4908 (void) memcpy((void *)(pc + 8), (void *)(&type), 4);
4909         *(int32_t *)(pc + 12) = 0;
4910         * (int8_t *)(pc + 12) = state->storePack.swapEndian;
4911         __glXReadPixelReply(dpy, gc, 2, 0, 0, 0, format, type, image, GL_TRUE);
4912         UnlockDisplay(dpy); SyncHandle();
4913 #endif /* USE_XCB */
4914     }
4915     return;
4916 }
4917 
4918 #define X_GLvop_GetConvolutionFilterEXT 1
gl_dispatch_stub_356(GLenum target,GLenum format,GLenum type,GLvoid * image)4919 void gl_dispatch_stub_356(GLenum target, GLenum format, GLenum type, GLvoid * image)
4920 {
4921     struct glx_context * const gc = __glXGetCurrentContext();
4922 
4923 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
4924     if (gc->isDirect) {
4925         const _glapi_proc *const disp_table = GET_DISPATCH();
4926         PFNGLGETCONVOLUTIONFILTEREXTPROC p =
4927             (PFNGLGETCONVOLUTIONFILTEREXTPROC) disp_table[356];
4928     p(target, format, type, image);
4929     } else
4930 #endif
4931     {
4932     struct glx_context * const gc = __glXGetCurrentContext();
4933     const __GLXattribute * const state = gc->client_state_private;
4934     Display * const dpy = gc->currentDpy;
4935     const GLuint cmdlen = 16;
4936     if (__builtin_expect(dpy != NULL, 1)) {
4937         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetConvolutionFilterEXT, cmdlen);
4938 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
4939 (void) memcpy((void *)(pc + 4), (void *)(&format), 4);
4940 (void) memcpy((void *)(pc + 8), (void *)(&type), 4);
4941         *(int32_t *)(pc + 12) = 0;
4942         * (int8_t *)(pc + 12) = state->storePack.swapEndian;
4943         __glXReadPixelReply(dpy, gc, 2, 0, 0, 0, format, type, image, GL_TRUE);
4944         UnlockDisplay(dpy); SyncHandle();
4945     }
4946     return;
4947 }
4948 }
4949 
4950 #define X_GLsop_GetConvolutionParameterfv 151
__indirect_glGetConvolutionParameterfv(GLenum target,GLenum pname,GLfloat * params)4951 void __indirect_glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat * params)
4952 {
4953     struct glx_context * const gc = __glXGetCurrentContext();
4954     Display * const dpy = gc->currentDpy;
4955 #ifndef USE_XCB
4956     const GLuint cmdlen = 8;
4957 #endif
4958     if (__builtin_expect(dpy != NULL, 1)) {
4959 #ifdef USE_XCB
4960         xcb_connection_t *c = XGetXCBConnection(dpy);
4961         (void) __glXFlushRenderBuffer(gc, gc->pc);
4962         xcb_glx_get_convolution_parameterfv_reply_t *reply = xcb_glx_get_convolution_parameterfv_reply(c, xcb_glx_get_convolution_parameterfv(c, gc->currentContextTag, target, pname), NULL);
4963         if (xcb_glx_get_convolution_parameterfv_data_length(reply) == 0)
4964             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
4965         else
4966             (void)memcpy(params, xcb_glx_get_convolution_parameterfv_data(reply), xcb_glx_get_convolution_parameterfv_data_length(reply) * sizeof(GLfloat));
4967         free(reply);
4968 #else
4969         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetConvolutionParameterfv, cmdlen);
4970 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
4971 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
4972         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
4973         UnlockDisplay(dpy); SyncHandle();
4974 #endif /* USE_XCB */
4975     }
4976     return;
4977 }
4978 
4979 #define X_GLvop_GetConvolutionParameterfvEXT 2
gl_dispatch_stub_357(GLenum target,GLenum pname,GLfloat * params)4980 void gl_dispatch_stub_357(GLenum target, GLenum pname, GLfloat * params)
4981 {
4982     struct glx_context * const gc = __glXGetCurrentContext();
4983 
4984 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
4985     if (gc->isDirect) {
4986         const _glapi_proc *const disp_table = GET_DISPATCH();
4987         PFNGLGETCONVOLUTIONPARAMETERFVEXTPROC p =
4988             (PFNGLGETCONVOLUTIONPARAMETERFVEXTPROC) disp_table[357];
4989     p(target, pname, params);
4990     } else
4991 #endif
4992     {
4993     struct glx_context * const gc = __glXGetCurrentContext();
4994     Display * const dpy = gc->currentDpy;
4995     const GLuint cmdlen = 8;
4996     if (__builtin_expect(dpy != NULL, 1)) {
4997         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetConvolutionParameterfvEXT, cmdlen);
4998 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
4999 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5000         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5001         UnlockDisplay(dpy); SyncHandle();
5002     }
5003     return;
5004 }
5005 }
5006 
5007 #define X_GLsop_GetConvolutionParameteriv 152
__indirect_glGetConvolutionParameteriv(GLenum target,GLenum pname,GLint * params)5008 void __indirect_glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint * params)
5009 {
5010     struct glx_context * const gc = __glXGetCurrentContext();
5011     Display * const dpy = gc->currentDpy;
5012 #ifndef USE_XCB
5013     const GLuint cmdlen = 8;
5014 #endif
5015     if (__builtin_expect(dpy != NULL, 1)) {
5016 #ifdef USE_XCB
5017         xcb_connection_t *c = XGetXCBConnection(dpy);
5018         (void) __glXFlushRenderBuffer(gc, gc->pc);
5019         xcb_glx_get_convolution_parameteriv_reply_t *reply = xcb_glx_get_convolution_parameteriv_reply(c, xcb_glx_get_convolution_parameteriv(c, gc->currentContextTag, target, pname), NULL);
5020         if (xcb_glx_get_convolution_parameteriv_data_length(reply) == 0)
5021             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
5022         else
5023             (void)memcpy(params, xcb_glx_get_convolution_parameteriv_data(reply), xcb_glx_get_convolution_parameteriv_data_length(reply) * sizeof(GLint));
5024         free(reply);
5025 #else
5026         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetConvolutionParameteriv, cmdlen);
5027 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5028 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5029         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5030         UnlockDisplay(dpy); SyncHandle();
5031 #endif /* USE_XCB */
5032     }
5033     return;
5034 }
5035 
5036 #define X_GLvop_GetConvolutionParameterivEXT 3
gl_dispatch_stub_358(GLenum target,GLenum pname,GLint * params)5037 void gl_dispatch_stub_358(GLenum target, GLenum pname, GLint * params)
5038 {
5039     struct glx_context * const gc = __glXGetCurrentContext();
5040 
5041 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
5042     if (gc->isDirect) {
5043         const _glapi_proc *const disp_table = GET_DISPATCH();
5044         PFNGLGETCONVOLUTIONPARAMETERIVEXTPROC p =
5045             (PFNGLGETCONVOLUTIONPARAMETERIVEXTPROC) disp_table[358];
5046     p(target, pname, params);
5047     } else
5048 #endif
5049     {
5050     struct glx_context * const gc = __glXGetCurrentContext();
5051     Display * const dpy = gc->currentDpy;
5052     const GLuint cmdlen = 8;
5053     if (__builtin_expect(dpy != NULL, 1)) {
5054         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetConvolutionParameterivEXT, cmdlen);
5055 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5056 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5057         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5058         UnlockDisplay(dpy); SyncHandle();
5059     }
5060     return;
5061 }
5062 }
5063 
5064 #define X_GLsop_GetHistogram 154
__indirect_glGetHistogram(GLenum target,GLboolean reset,GLenum format,GLenum type,GLvoid * values)5065 void __indirect_glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid * values)
5066 {
5067     struct glx_context * const gc = __glXGetCurrentContext();
5068     const __GLXattribute * const state = gc->client_state_private;
5069     Display * const dpy = gc->currentDpy;
5070 #ifndef USE_XCB
5071     const GLuint cmdlen = 16;
5072 #endif
5073     if (__builtin_expect(dpy != NULL, 1)) {
5074 #ifdef USE_XCB
5075         xcb_connection_t *c = XGetXCBConnection(dpy);
5076         (void) __glXFlushRenderBuffer(gc, gc->pc);
5077         xcb_glx_get_histogram_reply_t *reply = xcb_glx_get_histogram_reply(c, xcb_glx_get_histogram(c, gc->currentContextTag, target, reset, format, type, state->storePack.swapEndian), NULL);
5078         __glEmptyImage(gc, 3, reply->width, 1, 1, format, type, xcb_glx_get_histogram_data(reply), values);
5079         free(reply);
5080 #else
5081         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetHistogram, cmdlen);
5082 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5083 (void) memcpy((void *)(pc + 4), (void *)(&format), 4);
5084 (void) memcpy((void *)(pc + 8), (void *)(&type), 4);
5085         *(int32_t *)(pc + 12) = 0;
5086         * (int8_t *)(pc + 12) = state->storePack.swapEndian;
5087         * (int8_t *)(pc + 13) = reset;
5088         __glXReadPixelReply(dpy, gc, 1, 0, 0, 0, format, type, values, GL_TRUE);
5089         UnlockDisplay(dpy); SyncHandle();
5090 #endif /* USE_XCB */
5091     }
5092     return;
5093 }
5094 
5095 #define X_GLvop_GetHistogramEXT 5
gl_dispatch_stub_361(GLenum target,GLboolean reset,GLenum format,GLenum type,GLvoid * values)5096 void gl_dispatch_stub_361(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid * values)
5097 {
5098     struct glx_context * const gc = __glXGetCurrentContext();
5099 
5100 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
5101     if (gc->isDirect) {
5102         const _glapi_proc *const disp_table = GET_DISPATCH();
5103         PFNGLGETHISTOGRAMEXTPROC p =
5104             (PFNGLGETHISTOGRAMEXTPROC) disp_table[361];
5105     p(target, reset, format, type, values);
5106     } else
5107 #endif
5108     {
5109     struct glx_context * const gc = __glXGetCurrentContext();
5110     const __GLXattribute * const state = gc->client_state_private;
5111     Display * const dpy = gc->currentDpy;
5112     const GLuint cmdlen = 16;
5113     if (__builtin_expect(dpy != NULL, 1)) {
5114         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetHistogramEXT, cmdlen);
5115 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5116 (void) memcpy((void *)(pc + 4), (void *)(&format), 4);
5117 (void) memcpy((void *)(pc + 8), (void *)(&type), 4);
5118         *(int32_t *)(pc + 12) = 0;
5119         * (int8_t *)(pc + 12) = state->storePack.swapEndian;
5120         * (int8_t *)(pc + 13) = reset;
5121         __glXReadPixelReply(dpy, gc, 1, 0, 0, 0, format, type, values, GL_TRUE);
5122         UnlockDisplay(dpy); SyncHandle();
5123     }
5124     return;
5125 }
5126 }
5127 
5128 #define X_GLsop_GetHistogramParameterfv 155
__indirect_glGetHistogramParameterfv(GLenum target,GLenum pname,GLfloat * params)5129 void __indirect_glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat * params)
5130 {
5131     struct glx_context * const gc = __glXGetCurrentContext();
5132     Display * const dpy = gc->currentDpy;
5133 #ifndef USE_XCB
5134     const GLuint cmdlen = 8;
5135 #endif
5136     if (__builtin_expect(dpy != NULL, 1)) {
5137 #ifdef USE_XCB
5138         xcb_connection_t *c = XGetXCBConnection(dpy);
5139         (void) __glXFlushRenderBuffer(gc, gc->pc);
5140         xcb_glx_get_histogram_parameterfv_reply_t *reply = xcb_glx_get_histogram_parameterfv_reply(c, xcb_glx_get_histogram_parameterfv(c, gc->currentContextTag, target, pname), NULL);
5141         if (xcb_glx_get_histogram_parameterfv_data_length(reply) == 0)
5142             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
5143         else
5144             (void)memcpy(params, xcb_glx_get_histogram_parameterfv_data(reply), xcb_glx_get_histogram_parameterfv_data_length(reply) * sizeof(GLfloat));
5145         free(reply);
5146 #else
5147         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetHistogramParameterfv, cmdlen);
5148 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5149 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5150         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5151         UnlockDisplay(dpy); SyncHandle();
5152 #endif /* USE_XCB */
5153     }
5154     return;
5155 }
5156 
5157 #define X_GLvop_GetHistogramParameterfvEXT 6
gl_dispatch_stub_362(GLenum target,GLenum pname,GLfloat * params)5158 void gl_dispatch_stub_362(GLenum target, GLenum pname, GLfloat * params)
5159 {
5160     struct glx_context * const gc = __glXGetCurrentContext();
5161 
5162 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
5163     if (gc->isDirect) {
5164         const _glapi_proc *const disp_table = GET_DISPATCH();
5165         PFNGLGETHISTOGRAMPARAMETERFVEXTPROC p =
5166             (PFNGLGETHISTOGRAMPARAMETERFVEXTPROC) disp_table[362];
5167     p(target, pname, params);
5168     } else
5169 #endif
5170     {
5171     struct glx_context * const gc = __glXGetCurrentContext();
5172     Display * const dpy = gc->currentDpy;
5173     const GLuint cmdlen = 8;
5174     if (__builtin_expect(dpy != NULL, 1)) {
5175         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetHistogramParameterfvEXT, cmdlen);
5176 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5177 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5178         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5179         UnlockDisplay(dpy); SyncHandle();
5180     }
5181     return;
5182 }
5183 }
5184 
5185 #define X_GLsop_GetHistogramParameteriv 156
__indirect_glGetHistogramParameteriv(GLenum target,GLenum pname,GLint * params)5186 void __indirect_glGetHistogramParameteriv(GLenum target, GLenum pname, GLint * params)
5187 {
5188     struct glx_context * const gc = __glXGetCurrentContext();
5189     Display * const dpy = gc->currentDpy;
5190 #ifndef USE_XCB
5191     const GLuint cmdlen = 8;
5192 #endif
5193     if (__builtin_expect(dpy != NULL, 1)) {
5194 #ifdef USE_XCB
5195         xcb_connection_t *c = XGetXCBConnection(dpy);
5196         (void) __glXFlushRenderBuffer(gc, gc->pc);
5197         xcb_glx_get_histogram_parameteriv_reply_t *reply = xcb_glx_get_histogram_parameteriv_reply(c, xcb_glx_get_histogram_parameteriv(c, gc->currentContextTag, target, pname), NULL);
5198         if (xcb_glx_get_histogram_parameteriv_data_length(reply) == 0)
5199             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
5200         else
5201             (void)memcpy(params, xcb_glx_get_histogram_parameteriv_data(reply), xcb_glx_get_histogram_parameteriv_data_length(reply) * sizeof(GLint));
5202         free(reply);
5203 #else
5204         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetHistogramParameteriv, cmdlen);
5205 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5206 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5207         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5208         UnlockDisplay(dpy); SyncHandle();
5209 #endif /* USE_XCB */
5210     }
5211     return;
5212 }
5213 
5214 #define X_GLvop_GetHistogramParameterivEXT 7
gl_dispatch_stub_363(GLenum target,GLenum pname,GLint * params)5215 void gl_dispatch_stub_363(GLenum target, GLenum pname, GLint * params)
5216 {
5217     struct glx_context * const gc = __glXGetCurrentContext();
5218 
5219 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
5220     if (gc->isDirect) {
5221         const _glapi_proc *const disp_table = GET_DISPATCH();
5222         PFNGLGETHISTOGRAMPARAMETERIVEXTPROC p =
5223             (PFNGLGETHISTOGRAMPARAMETERIVEXTPROC) disp_table[363];
5224     p(target, pname, params);
5225     } else
5226 #endif
5227     {
5228     struct glx_context * const gc = __glXGetCurrentContext();
5229     Display * const dpy = gc->currentDpy;
5230     const GLuint cmdlen = 8;
5231     if (__builtin_expect(dpy != NULL, 1)) {
5232         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetHistogramParameterivEXT, cmdlen);
5233 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5234 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5235         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5236         UnlockDisplay(dpy); SyncHandle();
5237     }
5238     return;
5239 }
5240 }
5241 
5242 #define X_GLsop_GetMinmax 157
__indirect_glGetMinmax(GLenum target,GLboolean reset,GLenum format,GLenum type,GLvoid * values)5243 void __indirect_glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid * values)
5244 {
5245     struct glx_context * const gc = __glXGetCurrentContext();
5246     const __GLXattribute * const state = gc->client_state_private;
5247     Display * const dpy = gc->currentDpy;
5248 #ifndef USE_XCB
5249     const GLuint cmdlen = 16;
5250 #endif
5251     if (__builtin_expect(dpy != NULL, 1)) {
5252 #ifdef USE_XCB
5253         xcb_connection_t *c = XGetXCBConnection(dpy);
5254         (void) __glXFlushRenderBuffer(gc, gc->pc);
5255         xcb_glx_get_minmax_reply_t *reply = xcb_glx_get_minmax_reply(c, xcb_glx_get_minmax(c, gc->currentContextTag, target, reset, format, type, state->storePack.swapEndian), NULL);
5256         __glEmptyImage(gc, 3, 2, 1, 1, format, type, xcb_glx_get_minmax_data(reply), values);
5257         free(reply);
5258 #else
5259         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetMinmax, cmdlen);
5260 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5261 (void) memcpy((void *)(pc + 4), (void *)(&format), 4);
5262 (void) memcpy((void *)(pc + 8), (void *)(&type), 4);
5263         *(int32_t *)(pc + 12) = 0;
5264         * (int8_t *)(pc + 12) = state->storePack.swapEndian;
5265         * (int8_t *)(pc + 13) = reset;
5266         __glXReadPixelReply(dpy, gc, 1, 2, 1, 1, format, type, values, GL_FALSE);
5267         UnlockDisplay(dpy); SyncHandle();
5268 #endif /* USE_XCB */
5269     }
5270     return;
5271 }
5272 
5273 #define X_GLvop_GetMinmaxEXT 8
gl_dispatch_stub_364(GLenum target,GLboolean reset,GLenum format,GLenum type,GLvoid * values)5274 void gl_dispatch_stub_364(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid * values)
5275 {
5276     struct glx_context * const gc = __glXGetCurrentContext();
5277 
5278 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
5279     if (gc->isDirect) {
5280         const _glapi_proc *const disp_table = GET_DISPATCH();
5281         PFNGLGETMINMAXEXTPROC p =
5282             (PFNGLGETMINMAXEXTPROC) disp_table[364];
5283     p(target, reset, format, type, values);
5284     } else
5285 #endif
5286     {
5287     struct glx_context * const gc = __glXGetCurrentContext();
5288     const __GLXattribute * const state = gc->client_state_private;
5289     Display * const dpy = gc->currentDpy;
5290     const GLuint cmdlen = 16;
5291     if (__builtin_expect(dpy != NULL, 1)) {
5292         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetMinmaxEXT, cmdlen);
5293 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5294 (void) memcpy((void *)(pc + 4), (void *)(&format), 4);
5295 (void) memcpy((void *)(pc + 8), (void *)(&type), 4);
5296         *(int32_t *)(pc + 12) = 0;
5297         * (int8_t *)(pc + 12) = state->storePack.swapEndian;
5298         * (int8_t *)(pc + 13) = reset;
5299         __glXReadPixelReply(dpy, gc, 1, 2, 1, 1, format, type, values, GL_FALSE);
5300         UnlockDisplay(dpy); SyncHandle();
5301     }
5302     return;
5303 }
5304 }
5305 
5306 #define X_GLsop_GetMinmaxParameterfv 158
__indirect_glGetMinmaxParameterfv(GLenum target,GLenum pname,GLfloat * params)5307 void __indirect_glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat * params)
5308 {
5309     struct glx_context * const gc = __glXGetCurrentContext();
5310     Display * const dpy = gc->currentDpy;
5311 #ifndef USE_XCB
5312     const GLuint cmdlen = 8;
5313 #endif
5314     if (__builtin_expect(dpy != NULL, 1)) {
5315 #ifdef USE_XCB
5316         xcb_connection_t *c = XGetXCBConnection(dpy);
5317         (void) __glXFlushRenderBuffer(gc, gc->pc);
5318         xcb_glx_get_minmax_parameterfv_reply_t *reply = xcb_glx_get_minmax_parameterfv_reply(c, xcb_glx_get_minmax_parameterfv(c, gc->currentContextTag, target, pname), NULL);
5319         if (xcb_glx_get_minmax_parameterfv_data_length(reply) == 0)
5320             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
5321         else
5322             (void)memcpy(params, xcb_glx_get_minmax_parameterfv_data(reply), xcb_glx_get_minmax_parameterfv_data_length(reply) * sizeof(GLfloat));
5323         free(reply);
5324 #else
5325         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetMinmaxParameterfv, cmdlen);
5326 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5327 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5328         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5329         UnlockDisplay(dpy); SyncHandle();
5330 #endif /* USE_XCB */
5331     }
5332     return;
5333 }
5334 
5335 #define X_GLvop_GetMinmaxParameterfvEXT 9
gl_dispatch_stub_365(GLenum target,GLenum pname,GLfloat * params)5336 void gl_dispatch_stub_365(GLenum target, GLenum pname, GLfloat * params)
5337 {
5338     struct glx_context * const gc = __glXGetCurrentContext();
5339 
5340 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
5341     if (gc->isDirect) {
5342         const _glapi_proc *const disp_table = GET_DISPATCH();
5343         PFNGLGETMINMAXPARAMETERFVEXTPROC p =
5344             (PFNGLGETMINMAXPARAMETERFVEXTPROC) disp_table[365];
5345     p(target, pname, params);
5346     } else
5347 #endif
5348     {
5349     struct glx_context * const gc = __glXGetCurrentContext();
5350     Display * const dpy = gc->currentDpy;
5351     const GLuint cmdlen = 8;
5352     if (__builtin_expect(dpy != NULL, 1)) {
5353         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetMinmaxParameterfvEXT, cmdlen);
5354 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5355 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5356         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5357         UnlockDisplay(dpy); SyncHandle();
5358     }
5359     return;
5360 }
5361 }
5362 
5363 #define X_GLsop_GetMinmaxParameteriv 159
__indirect_glGetMinmaxParameteriv(GLenum target,GLenum pname,GLint * params)5364 void __indirect_glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint * params)
5365 {
5366     struct glx_context * const gc = __glXGetCurrentContext();
5367     Display * const dpy = gc->currentDpy;
5368 #ifndef USE_XCB
5369     const GLuint cmdlen = 8;
5370 #endif
5371     if (__builtin_expect(dpy != NULL, 1)) {
5372 #ifdef USE_XCB
5373         xcb_connection_t *c = XGetXCBConnection(dpy);
5374         (void) __glXFlushRenderBuffer(gc, gc->pc);
5375         xcb_glx_get_minmax_parameteriv_reply_t *reply = xcb_glx_get_minmax_parameteriv_reply(c, xcb_glx_get_minmax_parameteriv(c, gc->currentContextTag, target, pname), NULL);
5376         if (xcb_glx_get_minmax_parameteriv_data_length(reply) == 0)
5377             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
5378         else
5379             (void)memcpy(params, xcb_glx_get_minmax_parameteriv_data(reply), xcb_glx_get_minmax_parameteriv_data_length(reply) * sizeof(GLint));
5380         free(reply);
5381 #else
5382         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetMinmaxParameteriv, cmdlen);
5383 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5384 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5385         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5386         UnlockDisplay(dpy); SyncHandle();
5387 #endif /* USE_XCB */
5388     }
5389     return;
5390 }
5391 
5392 #define X_GLvop_GetMinmaxParameterivEXT 10
gl_dispatch_stub_366(GLenum target,GLenum pname,GLint * params)5393 void gl_dispatch_stub_366(GLenum target, GLenum pname, GLint * params)
5394 {
5395     struct glx_context * const gc = __glXGetCurrentContext();
5396 
5397 #if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)
5398     if (gc->isDirect) {
5399         const _glapi_proc *const disp_table = GET_DISPATCH();
5400         PFNGLGETMINMAXPARAMETERIVEXTPROC p =
5401             (PFNGLGETMINMAXPARAMETERIVEXTPROC) disp_table[366];
5402     p(target, pname, params);
5403     } else
5404 #endif
5405     {
5406     struct glx_context * const gc = __glXGetCurrentContext();
5407     Display * const dpy = gc->currentDpy;
5408     const GLuint cmdlen = 8;
5409     if (__builtin_expect(dpy != NULL, 1)) {
5410         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetMinmaxParameterivEXT, cmdlen);
5411 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
5412 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
5413         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
5414         UnlockDisplay(dpy); SyncHandle();
5415     }
5416     return;
5417 }
5418 }
5419 
5420 #define X_GLrop_Histogram 4110
__indirect_glHistogram(GLenum target,GLsizei width,GLenum internalformat,GLboolean sink)5421 void __indirect_glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
5422 {
5423     struct glx_context * const gc = __glXGetCurrentContext();
5424     const GLuint cmdlen = 20;
5425 emit_header(gc->pc, X_GLrop_Histogram, cmdlen);
5426 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5427 (void) memcpy((void *)(gc->pc + 8), (void *)(&width), 4);
5428 (void) memcpy((void *)(gc->pc + 12), (void *)(&internalformat), 4);
5429 (void) memcpy((void *)(gc->pc + 16), (void *)(&sink), 1);
5430 gc->pc += cmdlen;
5431 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5432 }
5433 
5434 #define X_GLrop_Minmax 4111
__indirect_glMinmax(GLenum target,GLenum internalformat,GLboolean sink)5435 void __indirect_glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
5436 {
5437     struct glx_context * const gc = __glXGetCurrentContext();
5438     const GLuint cmdlen = 16;
5439 emit_header(gc->pc, X_GLrop_Minmax, cmdlen);
5440 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5441 (void) memcpy((void *)(gc->pc + 8), (void *)(&internalformat), 4);
5442 (void) memcpy((void *)(gc->pc + 12), (void *)(&sink), 1);
5443 gc->pc += cmdlen;
5444 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5445 }
5446 
5447 #define X_GLrop_ResetHistogram 4112
__indirect_glResetHistogram(GLenum target)5448 void __indirect_glResetHistogram(GLenum target)
5449 {
5450     struct glx_context * const gc = __glXGetCurrentContext();
5451     const GLuint cmdlen = 8;
5452 emit_header(gc->pc, X_GLrop_ResetHistogram, cmdlen);
5453 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5454 gc->pc += cmdlen;
5455 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5456 }
5457 
5458 #define X_GLrop_ResetMinmax 4113
__indirect_glResetMinmax(GLenum target)5459 void __indirect_glResetMinmax(GLenum target)
5460 {
5461     struct glx_context * const gc = __glXGetCurrentContext();
5462     const GLuint cmdlen = 8;
5463 emit_header(gc->pc, X_GLrop_ResetMinmax, cmdlen);
5464 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5465 gc->pc += cmdlen;
5466 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5467 }
5468 
5469 static void
__glx_TexImage_3D4D(unsigned opcode,unsigned dim,GLenum target,GLint level,GLint internalformat,GLsizei width,GLsizei height,GLsizei depth,GLsizei extent,GLint border,GLenum format,GLenum type,const GLvoid * pixels)5470 __glx_TexImage_3D4D( unsigned opcode, unsigned dim, GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLsizei extent, GLint border, GLenum format, GLenum type, const GLvoid * pixels )
5471 {
5472     struct glx_context * const gc = __glXGetCurrentContext();
5473     const GLuint compsize = (pixels != NULL) ? __glImageSize(width, height, depth, format, type, target) : 0;
5474     const GLuint cmdlen = 84 + __GLX_PAD(compsize);
5475     if (__builtin_expect(gc->currentDpy != NULL, 1)) {
5476 if (cmdlen <= gc->maxSmallRenderCommandSize) {
5477     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
5478         (void) __glXFlushRenderBuffer(gc, gc->pc);
5479     }
5480 emit_header(gc->pc, opcode, cmdlen);
5481 (void) memcpy((void *)(gc->pc + 40), (void *)(&target), 4);
5482 (void) memcpy((void *)(gc->pc + 44), (void *)(&level), 4);
5483 (void) memcpy((void *)(gc->pc + 48), (void *)(&internalformat), 4);
5484 (void) memcpy((void *)(gc->pc + 52), (void *)(&width), 4);
5485 (void) memcpy((void *)(gc->pc + 56), (void *)(&height), 4);
5486 (void) memcpy((void *)(gc->pc + 60), (void *)(&depth), 4);
5487 (void) memcpy((void *)(gc->pc + 64), (void *)(&extent), 4);
5488 (void) memcpy((void *)(gc->pc + 68), (void *)(&border), 4);
5489 (void) memcpy((void *)(gc->pc + 72), (void *)(&format), 4);
5490 (void) memcpy((void *)(gc->pc + 76), (void *)(&type), 4);
5491 (void) memcpy((void *)(gc->pc + 80), (void *)((pixels == NULL) ? one : zero), 4);
5492 if (compsize > 0) {
5493     (*gc->fillImage)(gc, dim, width, height, depth, format, type, pixels, gc->pc + 84, gc->pc + 4);
5494 } else {
5495     (void) memcpy( gc->pc + 4, default_pixel_store_4D, default_pixel_store_4D_size );
5496 }
5497 gc->pc += cmdlen;
5498 if (gc->pc > gc->limit) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5499 }
5500 else {
5501 const GLint op = opcode;
5502 const GLuint cmdlenLarge = cmdlen + 4;
5503 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
5504 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
5505 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
5506 (void) memcpy((void *)(pc + 44), (void *)(&target), 4);
5507 (void) memcpy((void *)(pc + 48), (void *)(&level), 4);
5508 (void) memcpy((void *)(pc + 52), (void *)(&internalformat), 4);
5509 (void) memcpy((void *)(pc + 56), (void *)(&width), 4);
5510 (void) memcpy((void *)(pc + 60), (void *)(&height), 4);
5511 (void) memcpy((void *)(pc + 64), (void *)(&depth), 4);
5512 (void) memcpy((void *)(pc + 68), (void *)(&extent), 4);
5513 (void) memcpy((void *)(pc + 72), (void *)(&border), 4);
5514 (void) memcpy((void *)(pc + 76), (void *)(&format), 4);
5515 (void) memcpy((void *)(pc + 80), (void *)(&type), 4);
5516 (void) memcpy((void *)(pc + 84), zero, 4);
5517 __glXSendLargeImage(gc, compsize, dim, width, height, depth, format, type, pixels, pc + 88, pc + 8);
5518 }
5519     }
5520 }
5521 
5522 #define X_GLrop_TexImage3D 4114
__indirect_glTexImage3D(GLenum target,GLint level,GLint internalformat,GLsizei width,GLsizei height,GLsizei depth,GLint border,GLenum format,GLenum type,const GLvoid * pixels)5523 void __indirect_glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid * pixels)
5524 {
5525     __glx_TexImage_3D4D(X_GLrop_TexImage3D, 3, target, level, internalformat, width, height, depth, 1, border, format, type, pixels );
5526 }
5527 
5528 static void
__glx_TexSubImage_3D4D(unsigned opcode,unsigned dim,GLenum target,GLint level,GLint xoffset,GLint yoffset,GLint zoffset,GLint woffset,GLsizei width,GLsizei height,GLsizei depth,GLsizei extent,GLenum format,GLenum type,const GLvoid * pixels)5529 __glx_TexSubImage_3D4D( unsigned opcode, unsigned dim, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint woffset, GLsizei width, GLsizei height, GLsizei depth, GLsizei extent, GLenum format, GLenum type, const GLvoid * pixels )
5530 {
5531     struct glx_context * const gc = __glXGetCurrentContext();
5532     const GLuint compsize = (pixels != NULL) ? __glImageSize(width, height, depth, format, type, target) : 0;
5533     const GLuint cmdlen = 92 + __GLX_PAD(compsize);
5534     if (__builtin_expect(gc->currentDpy != NULL, 1)) {
5535 if (cmdlen <= gc->maxSmallRenderCommandSize) {
5536     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
5537         (void) __glXFlushRenderBuffer(gc, gc->pc);
5538     }
5539 emit_header(gc->pc, opcode, cmdlen);
5540 (void) memcpy((void *)(gc->pc + 40), (void *)(&target), 4);
5541 (void) memcpy((void *)(gc->pc + 44), (void *)(&level), 4);
5542 (void) memcpy((void *)(gc->pc + 48), (void *)(&xoffset), 4);
5543 (void) memcpy((void *)(gc->pc + 52), (void *)(&yoffset), 4);
5544 (void) memcpy((void *)(gc->pc + 56), (void *)(&zoffset), 4);
5545 (void) memcpy((void *)(gc->pc + 60), (void *)(&woffset), 4);
5546 (void) memcpy((void *)(gc->pc + 64), (void *)(&width), 4);
5547 (void) memcpy((void *)(gc->pc + 68), (void *)(&height), 4);
5548 (void) memcpy((void *)(gc->pc + 72), (void *)(&depth), 4);
5549 (void) memcpy((void *)(gc->pc + 76), (void *)(&extent), 4);
5550 (void) memcpy((void *)(gc->pc + 80), (void *)(&format), 4);
5551 (void) memcpy((void *)(gc->pc + 84), (void *)(&type), 4);
5552 (void) memset((void *)(gc->pc + 88), 0, 4);
5553 if (compsize > 0) {
5554     (*gc->fillImage)(gc, dim, width, height, depth, format, type, pixels, gc->pc + 92, gc->pc + 4);
5555 } else {
5556     (void) memcpy( gc->pc + 4, default_pixel_store_4D, default_pixel_store_4D_size );
5557 }
5558 gc->pc += cmdlen;
5559 if (gc->pc > gc->limit) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5560 }
5561 else {
5562 const GLint op = opcode;
5563 const GLuint cmdlenLarge = cmdlen + 4;
5564 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
5565 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
5566 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
5567 (void) memcpy((void *)(pc + 44), (void *)(&target), 4);
5568 (void) memcpy((void *)(pc + 48), (void *)(&level), 4);
5569 (void) memcpy((void *)(pc + 52), (void *)(&xoffset), 4);
5570 (void) memcpy((void *)(pc + 56), (void *)(&yoffset), 4);
5571 (void) memcpy((void *)(pc + 60), (void *)(&zoffset), 4);
5572 (void) memcpy((void *)(pc + 64), (void *)(&woffset), 4);
5573 (void) memcpy((void *)(pc + 68), (void *)(&width), 4);
5574 (void) memcpy((void *)(pc + 72), (void *)(&height), 4);
5575 (void) memcpy((void *)(pc + 76), (void *)(&depth), 4);
5576 (void) memcpy((void *)(pc + 80), (void *)(&extent), 4);
5577 (void) memcpy((void *)(pc + 84), (void *)(&format), 4);
5578 (void) memcpy((void *)(pc + 88), (void *)(&type), 4);
5579 (void) memset((void *)(pc + 92), 0, 4);
5580 __glXSendLargeImage(gc, compsize, dim, width, height, depth, format, type, pixels, pc + 96, pc + 8);
5581 }
5582     }
5583 }
5584 
5585 #define X_GLrop_TexSubImage3D 4115
__indirect_glTexSubImage3D(GLenum target,GLint level,GLint xoffset,GLint yoffset,GLint zoffset,GLsizei width,GLsizei height,GLsizei depth,GLenum format,GLenum type,const GLvoid * pixels)5586 void __indirect_glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid * pixels)
5587 {
5588     __glx_TexSubImage_3D4D(X_GLrop_TexSubImage3D, 3, target, level, xoffset, yoffset, zoffset, 1, width, height, depth, 1, format, type, pixels );
5589 }
5590 
5591 #define X_GLrop_CopyTexSubImage3D 4123
__indirect_glCopyTexSubImage3D(GLenum target,GLint level,GLint xoffset,GLint yoffset,GLint zoffset,GLint x,GLint y,GLsizei width,GLsizei height)5592 void __indirect_glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
5593 {
5594     struct glx_context * const gc = __glXGetCurrentContext();
5595     const GLuint cmdlen = 40;
5596 emit_header(gc->pc, X_GLrop_CopyTexSubImage3D, cmdlen);
5597 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5598 (void) memcpy((void *)(gc->pc + 8), (void *)(&level), 4);
5599 (void) memcpy((void *)(gc->pc + 12), (void *)(&xoffset), 4);
5600 (void) memcpy((void *)(gc->pc + 16), (void *)(&yoffset), 4);
5601 (void) memcpy((void *)(gc->pc + 20), (void *)(&zoffset), 4);
5602 (void) memcpy((void *)(gc->pc + 24), (void *)(&x), 4);
5603 (void) memcpy((void *)(gc->pc + 28), (void *)(&y), 4);
5604 (void) memcpy((void *)(gc->pc + 32), (void *)(&width), 4);
5605 (void) memcpy((void *)(gc->pc + 36), (void *)(&height), 4);
5606 gc->pc += cmdlen;
5607 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5608 }
5609 
5610 #define X_GLrop_ActiveTextureARB 197
__indirect_glActiveTextureARB(GLenum texture)5611 void __indirect_glActiveTextureARB(GLenum texture)
5612 {
5613     struct glx_context * const gc = __glXGetCurrentContext();
5614     const GLuint cmdlen = 8;
5615 emit_header(gc->pc, X_GLrop_ActiveTextureARB, cmdlen);
5616 (void) memcpy((void *)(gc->pc + 4), (void *)(&texture), 4);
5617 gc->pc += cmdlen;
5618 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5619 }
5620 
5621 #define X_GLrop_MultiTexCoord1dvARB 198
__indirect_glMultiTexCoord1dARB(GLenum target,GLdouble s)5622 void __indirect_glMultiTexCoord1dARB(GLenum target, GLdouble s)
5623 {
5624     struct glx_context * const gc = __glXGetCurrentContext();
5625     const GLuint cmdlen = 16;
5626 emit_header(gc->pc, X_GLrop_MultiTexCoord1dvARB, cmdlen);
5627 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 8);
5628 (void) memcpy((void *)(gc->pc + 12), (void *)(&target), 4);
5629 gc->pc += cmdlen;
5630 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5631 }
5632 
5633 #define X_GLrop_MultiTexCoord1dvARB 198
__indirect_glMultiTexCoord1dvARB(GLenum target,const GLdouble * v)5634 void __indirect_glMultiTexCoord1dvARB(GLenum target, const GLdouble * v)
5635 {
5636     struct glx_context * const gc = __glXGetCurrentContext();
5637     const GLuint cmdlen = 16;
5638 emit_header(gc->pc, X_GLrop_MultiTexCoord1dvARB, cmdlen);
5639 (void) memcpy((void *)(gc->pc + 4), (void *)(v), 8);
5640 (void) memcpy((void *)(gc->pc + 12), (void *)(&target), 4);
5641 gc->pc += cmdlen;
5642 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5643 }
5644 
5645 #define X_GLrop_MultiTexCoord1fvARB 199
__indirect_glMultiTexCoord1fARB(GLenum target,GLfloat s)5646 void __indirect_glMultiTexCoord1fARB(GLenum target, GLfloat s)
5647 {
5648     struct glx_context * const gc = __glXGetCurrentContext();
5649     const GLuint cmdlen = 12;
5650 emit_header(gc->pc, X_GLrop_MultiTexCoord1fvARB, cmdlen);
5651 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5652 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 4);
5653 gc->pc += cmdlen;
5654 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5655 }
5656 
5657 #define X_GLrop_MultiTexCoord1fvARB 199
__indirect_glMultiTexCoord1fvARB(GLenum target,const GLfloat * v)5658 void __indirect_glMultiTexCoord1fvARB(GLenum target, const GLfloat * v)
5659 {
5660     struct glx_context * const gc = __glXGetCurrentContext();
5661     const GLuint cmdlen = 12;
5662 emit_header(gc->pc, X_GLrop_MultiTexCoord1fvARB, cmdlen);
5663 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5664 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
5665 gc->pc += cmdlen;
5666 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5667 }
5668 
5669 #define X_GLrop_MultiTexCoord1ivARB 200
__indirect_glMultiTexCoord1iARB(GLenum target,GLint s)5670 void __indirect_glMultiTexCoord1iARB(GLenum target, GLint s)
5671 {
5672     struct glx_context * const gc = __glXGetCurrentContext();
5673     const GLuint cmdlen = 12;
5674 emit_header(gc->pc, X_GLrop_MultiTexCoord1ivARB, cmdlen);
5675 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5676 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 4);
5677 gc->pc += cmdlen;
5678 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5679 }
5680 
5681 #define X_GLrop_MultiTexCoord1ivARB 200
__indirect_glMultiTexCoord1ivARB(GLenum target,const GLint * v)5682 void __indirect_glMultiTexCoord1ivARB(GLenum target, const GLint * v)
5683 {
5684     struct glx_context * const gc = __glXGetCurrentContext();
5685     const GLuint cmdlen = 12;
5686 emit_header(gc->pc, X_GLrop_MultiTexCoord1ivARB, cmdlen);
5687 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5688 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
5689 gc->pc += cmdlen;
5690 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5691 }
5692 
5693 #define X_GLrop_MultiTexCoord1svARB 201
__indirect_glMultiTexCoord1sARB(GLenum target,GLshort s)5694 void __indirect_glMultiTexCoord1sARB(GLenum target, GLshort s)
5695 {
5696     struct glx_context * const gc = __glXGetCurrentContext();
5697     const GLuint cmdlen = 12;
5698 emit_header(gc->pc, X_GLrop_MultiTexCoord1svARB, cmdlen);
5699 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5700 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 2);
5701 gc->pc += cmdlen;
5702 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5703 }
5704 
5705 #define X_GLrop_MultiTexCoord1svARB 201
__indirect_glMultiTexCoord1svARB(GLenum target,const GLshort * v)5706 void __indirect_glMultiTexCoord1svARB(GLenum target, const GLshort * v)
5707 {
5708     struct glx_context * const gc = __glXGetCurrentContext();
5709     const GLuint cmdlen = 12;
5710 emit_header(gc->pc, X_GLrop_MultiTexCoord1svARB, cmdlen);
5711 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5712 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 2);
5713 gc->pc += cmdlen;
5714 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5715 }
5716 
5717 #define X_GLrop_MultiTexCoord2dvARB 202
__indirect_glMultiTexCoord2dARB(GLenum target,GLdouble s,GLdouble t)5718 void __indirect_glMultiTexCoord2dARB(GLenum target, GLdouble s, GLdouble t)
5719 {
5720     struct glx_context * const gc = __glXGetCurrentContext();
5721     const GLuint cmdlen = 24;
5722 emit_header(gc->pc, X_GLrop_MultiTexCoord2dvARB, cmdlen);
5723 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 8);
5724 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 8);
5725 (void) memcpy((void *)(gc->pc + 20), (void *)(&target), 4);
5726 gc->pc += cmdlen;
5727 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5728 }
5729 
5730 #define X_GLrop_MultiTexCoord2dvARB 202
__indirect_glMultiTexCoord2dvARB(GLenum target,const GLdouble * v)5731 void __indirect_glMultiTexCoord2dvARB(GLenum target, const GLdouble * v)
5732 {
5733     struct glx_context * const gc = __glXGetCurrentContext();
5734     const GLuint cmdlen = 24;
5735 emit_header(gc->pc, X_GLrop_MultiTexCoord2dvARB, cmdlen);
5736 (void) memcpy((void *)(gc->pc + 4), (void *)(v), 16);
5737 (void) memcpy((void *)(gc->pc + 20), (void *)(&target), 4);
5738 gc->pc += cmdlen;
5739 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5740 }
5741 
5742 #define X_GLrop_MultiTexCoord2fvARB 203
__indirect_glMultiTexCoord2fARB(GLenum target,GLfloat s,GLfloat t)5743 void __indirect_glMultiTexCoord2fARB(GLenum target, GLfloat s, GLfloat t)
5744 {
5745     struct glx_context * const gc = __glXGetCurrentContext();
5746     const GLuint cmdlen = 16;
5747 emit_header(gc->pc, X_GLrop_MultiTexCoord2fvARB, cmdlen);
5748 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5749 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 4);
5750 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 4);
5751 gc->pc += cmdlen;
5752 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5753 }
5754 
5755 #define X_GLrop_MultiTexCoord2fvARB 203
__indirect_glMultiTexCoord2fvARB(GLenum target,const GLfloat * v)5756 void __indirect_glMultiTexCoord2fvARB(GLenum target, const GLfloat * v)
5757 {
5758     struct glx_context * const gc = __glXGetCurrentContext();
5759     const GLuint cmdlen = 16;
5760 emit_header(gc->pc, X_GLrop_MultiTexCoord2fvARB, cmdlen);
5761 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5762 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
5763 gc->pc += cmdlen;
5764 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5765 }
5766 
5767 #define X_GLrop_MultiTexCoord2ivARB 204
__indirect_glMultiTexCoord2iARB(GLenum target,GLint s,GLint t)5768 void __indirect_glMultiTexCoord2iARB(GLenum target, GLint s, GLint t)
5769 {
5770     struct glx_context * const gc = __glXGetCurrentContext();
5771     const GLuint cmdlen = 16;
5772 emit_header(gc->pc, X_GLrop_MultiTexCoord2ivARB, cmdlen);
5773 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5774 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 4);
5775 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 4);
5776 gc->pc += cmdlen;
5777 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5778 }
5779 
5780 #define X_GLrop_MultiTexCoord2ivARB 204
__indirect_glMultiTexCoord2ivARB(GLenum target,const GLint * v)5781 void __indirect_glMultiTexCoord2ivARB(GLenum target, const GLint * v)
5782 {
5783     struct glx_context * const gc = __glXGetCurrentContext();
5784     const GLuint cmdlen = 16;
5785 emit_header(gc->pc, X_GLrop_MultiTexCoord2ivARB, cmdlen);
5786 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5787 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
5788 gc->pc += cmdlen;
5789 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5790 }
5791 
5792 #define X_GLrop_MultiTexCoord2svARB 205
__indirect_glMultiTexCoord2sARB(GLenum target,GLshort s,GLshort t)5793 void __indirect_glMultiTexCoord2sARB(GLenum target, GLshort s, GLshort t)
5794 {
5795     struct glx_context * const gc = __glXGetCurrentContext();
5796     const GLuint cmdlen = 12;
5797 emit_header(gc->pc, X_GLrop_MultiTexCoord2svARB, cmdlen);
5798 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5799 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 2);
5800 (void) memcpy((void *)(gc->pc + 10), (void *)(&t), 2);
5801 gc->pc += cmdlen;
5802 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5803 }
5804 
5805 #define X_GLrop_MultiTexCoord2svARB 205
__indirect_glMultiTexCoord2svARB(GLenum target,const GLshort * v)5806 void __indirect_glMultiTexCoord2svARB(GLenum target, const GLshort * v)
5807 {
5808     struct glx_context * const gc = __glXGetCurrentContext();
5809     const GLuint cmdlen = 12;
5810 emit_header(gc->pc, X_GLrop_MultiTexCoord2svARB, cmdlen);
5811 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5812 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
5813 gc->pc += cmdlen;
5814 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5815 }
5816 
5817 #define X_GLrop_MultiTexCoord3dvARB 206
__indirect_glMultiTexCoord3dARB(GLenum target,GLdouble s,GLdouble t,GLdouble r)5818 void __indirect_glMultiTexCoord3dARB(GLenum target, GLdouble s, GLdouble t, GLdouble r)
5819 {
5820     struct glx_context * const gc = __glXGetCurrentContext();
5821     const GLuint cmdlen = 32;
5822 emit_header(gc->pc, X_GLrop_MultiTexCoord3dvARB, cmdlen);
5823 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 8);
5824 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 8);
5825 (void) memcpy((void *)(gc->pc + 20), (void *)(&r), 8);
5826 (void) memcpy((void *)(gc->pc + 28), (void *)(&target), 4);
5827 gc->pc += cmdlen;
5828 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5829 }
5830 
5831 #define X_GLrop_MultiTexCoord3dvARB 206
__indirect_glMultiTexCoord3dvARB(GLenum target,const GLdouble * v)5832 void __indirect_glMultiTexCoord3dvARB(GLenum target, const GLdouble * v)
5833 {
5834     struct glx_context * const gc = __glXGetCurrentContext();
5835     const GLuint cmdlen = 32;
5836 emit_header(gc->pc, X_GLrop_MultiTexCoord3dvARB, cmdlen);
5837 (void) memcpy((void *)(gc->pc + 4), (void *)(v), 24);
5838 (void) memcpy((void *)(gc->pc + 28), (void *)(&target), 4);
5839 gc->pc += cmdlen;
5840 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5841 }
5842 
5843 #define X_GLrop_MultiTexCoord3fvARB 207
__indirect_glMultiTexCoord3fARB(GLenum target,GLfloat s,GLfloat t,GLfloat r)5844 void __indirect_glMultiTexCoord3fARB(GLenum target, GLfloat s, GLfloat t, GLfloat r)
5845 {
5846     struct glx_context * const gc = __glXGetCurrentContext();
5847     const GLuint cmdlen = 20;
5848 emit_header(gc->pc, X_GLrop_MultiTexCoord3fvARB, cmdlen);
5849 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5850 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 4);
5851 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 4);
5852 (void) memcpy((void *)(gc->pc + 16), (void *)(&r), 4);
5853 gc->pc += cmdlen;
5854 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5855 }
5856 
5857 #define X_GLrop_MultiTexCoord3fvARB 207
__indirect_glMultiTexCoord3fvARB(GLenum target,const GLfloat * v)5858 void __indirect_glMultiTexCoord3fvARB(GLenum target, const GLfloat * v)
5859 {
5860     struct glx_context * const gc = __glXGetCurrentContext();
5861     const GLuint cmdlen = 20;
5862 emit_header(gc->pc, X_GLrop_MultiTexCoord3fvARB, cmdlen);
5863 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5864 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 12);
5865 gc->pc += cmdlen;
5866 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5867 }
5868 
5869 #define X_GLrop_MultiTexCoord3ivARB 208
__indirect_glMultiTexCoord3iARB(GLenum target,GLint s,GLint t,GLint r)5870 void __indirect_glMultiTexCoord3iARB(GLenum target, GLint s, GLint t, GLint r)
5871 {
5872     struct glx_context * const gc = __glXGetCurrentContext();
5873     const GLuint cmdlen = 20;
5874 emit_header(gc->pc, X_GLrop_MultiTexCoord3ivARB, cmdlen);
5875 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5876 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 4);
5877 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 4);
5878 (void) memcpy((void *)(gc->pc + 16), (void *)(&r), 4);
5879 gc->pc += cmdlen;
5880 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5881 }
5882 
5883 #define X_GLrop_MultiTexCoord3ivARB 208
__indirect_glMultiTexCoord3ivARB(GLenum target,const GLint * v)5884 void __indirect_glMultiTexCoord3ivARB(GLenum target, const GLint * v)
5885 {
5886     struct glx_context * const gc = __glXGetCurrentContext();
5887     const GLuint cmdlen = 20;
5888 emit_header(gc->pc, X_GLrop_MultiTexCoord3ivARB, cmdlen);
5889 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5890 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 12);
5891 gc->pc += cmdlen;
5892 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5893 }
5894 
5895 #define X_GLrop_MultiTexCoord3svARB 209
__indirect_glMultiTexCoord3sARB(GLenum target,GLshort s,GLshort t,GLshort r)5896 void __indirect_glMultiTexCoord3sARB(GLenum target, GLshort s, GLshort t, GLshort r)
5897 {
5898     struct glx_context * const gc = __glXGetCurrentContext();
5899     const GLuint cmdlen = 16;
5900 emit_header(gc->pc, X_GLrop_MultiTexCoord3svARB, cmdlen);
5901 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5902 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 2);
5903 (void) memcpy((void *)(gc->pc + 10), (void *)(&t), 2);
5904 (void) memcpy((void *)(gc->pc + 12), (void *)(&r), 2);
5905 gc->pc += cmdlen;
5906 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5907 }
5908 
5909 #define X_GLrop_MultiTexCoord3svARB 209
__indirect_glMultiTexCoord3svARB(GLenum target,const GLshort * v)5910 void __indirect_glMultiTexCoord3svARB(GLenum target, const GLshort * v)
5911 {
5912     struct glx_context * const gc = __glXGetCurrentContext();
5913     const GLuint cmdlen = 16;
5914 emit_header(gc->pc, X_GLrop_MultiTexCoord3svARB, cmdlen);
5915 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5916 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 6);
5917 gc->pc += cmdlen;
5918 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5919 }
5920 
5921 #define X_GLrop_MultiTexCoord4dvARB 210
__indirect_glMultiTexCoord4dARB(GLenum target,GLdouble s,GLdouble t,GLdouble r,GLdouble q)5922 void __indirect_glMultiTexCoord4dARB(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
5923 {
5924     struct glx_context * const gc = __glXGetCurrentContext();
5925     const GLuint cmdlen = 40;
5926 emit_header(gc->pc, X_GLrop_MultiTexCoord4dvARB, cmdlen);
5927 (void) memcpy((void *)(gc->pc + 4), (void *)(&s), 8);
5928 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 8);
5929 (void) memcpy((void *)(gc->pc + 20), (void *)(&r), 8);
5930 (void) memcpy((void *)(gc->pc + 28), (void *)(&q), 8);
5931 (void) memcpy((void *)(gc->pc + 36), (void *)(&target), 4);
5932 gc->pc += cmdlen;
5933 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5934 }
5935 
5936 #define X_GLrop_MultiTexCoord4dvARB 210
__indirect_glMultiTexCoord4dvARB(GLenum target,const GLdouble * v)5937 void __indirect_glMultiTexCoord4dvARB(GLenum target, const GLdouble * v)
5938 {
5939     struct glx_context * const gc = __glXGetCurrentContext();
5940     const GLuint cmdlen = 40;
5941 emit_header(gc->pc, X_GLrop_MultiTexCoord4dvARB, cmdlen);
5942 (void) memcpy((void *)(gc->pc + 4), (void *)(v), 32);
5943 (void) memcpy((void *)(gc->pc + 36), (void *)(&target), 4);
5944 gc->pc += cmdlen;
5945 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5946 }
5947 
5948 #define X_GLrop_MultiTexCoord4fvARB 211
__indirect_glMultiTexCoord4fARB(GLenum target,GLfloat s,GLfloat t,GLfloat r,GLfloat q)5949 void __indirect_glMultiTexCoord4fARB(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
5950 {
5951     struct glx_context * const gc = __glXGetCurrentContext();
5952     const GLuint cmdlen = 24;
5953 emit_header(gc->pc, X_GLrop_MultiTexCoord4fvARB, cmdlen);
5954 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5955 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 4);
5956 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 4);
5957 (void) memcpy((void *)(gc->pc + 16), (void *)(&r), 4);
5958 (void) memcpy((void *)(gc->pc + 20), (void *)(&q), 4);
5959 gc->pc += cmdlen;
5960 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5961 }
5962 
5963 #define X_GLrop_MultiTexCoord4fvARB 211
__indirect_glMultiTexCoord4fvARB(GLenum target,const GLfloat * v)5964 void __indirect_glMultiTexCoord4fvARB(GLenum target, const GLfloat * v)
5965 {
5966     struct glx_context * const gc = __glXGetCurrentContext();
5967     const GLuint cmdlen = 24;
5968 emit_header(gc->pc, X_GLrop_MultiTexCoord4fvARB, cmdlen);
5969 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5970 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 16);
5971 gc->pc += cmdlen;
5972 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5973 }
5974 
5975 #define X_GLrop_MultiTexCoord4ivARB 212
__indirect_glMultiTexCoord4iARB(GLenum target,GLint s,GLint t,GLint r,GLint q)5976 void __indirect_glMultiTexCoord4iARB(GLenum target, GLint s, GLint t, GLint r, GLint q)
5977 {
5978     struct glx_context * const gc = __glXGetCurrentContext();
5979     const GLuint cmdlen = 24;
5980 emit_header(gc->pc, X_GLrop_MultiTexCoord4ivARB, cmdlen);
5981 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5982 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 4);
5983 (void) memcpy((void *)(gc->pc + 12), (void *)(&t), 4);
5984 (void) memcpy((void *)(gc->pc + 16), (void *)(&r), 4);
5985 (void) memcpy((void *)(gc->pc + 20), (void *)(&q), 4);
5986 gc->pc += cmdlen;
5987 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
5988 }
5989 
5990 #define X_GLrop_MultiTexCoord4ivARB 212
__indirect_glMultiTexCoord4ivARB(GLenum target,const GLint * v)5991 void __indirect_glMultiTexCoord4ivARB(GLenum target, const GLint * v)
5992 {
5993     struct glx_context * const gc = __glXGetCurrentContext();
5994     const GLuint cmdlen = 24;
5995 emit_header(gc->pc, X_GLrop_MultiTexCoord4ivARB, cmdlen);
5996 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
5997 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 16);
5998 gc->pc += cmdlen;
5999 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6000 }
6001 
6002 #define X_GLrop_MultiTexCoord4svARB 213
__indirect_glMultiTexCoord4sARB(GLenum target,GLshort s,GLshort t,GLshort r,GLshort q)6003 void __indirect_glMultiTexCoord4sARB(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
6004 {
6005     struct glx_context * const gc = __glXGetCurrentContext();
6006     const GLuint cmdlen = 16;
6007 emit_header(gc->pc, X_GLrop_MultiTexCoord4svARB, cmdlen);
6008 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6009 (void) memcpy((void *)(gc->pc + 8), (void *)(&s), 2);
6010 (void) memcpy((void *)(gc->pc + 10), (void *)(&t), 2);
6011 (void) memcpy((void *)(gc->pc + 12), (void *)(&r), 2);
6012 (void) memcpy((void *)(gc->pc + 14), (void *)(&q), 2);
6013 gc->pc += cmdlen;
6014 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6015 }
6016 
6017 #define X_GLrop_MultiTexCoord4svARB 213
__indirect_glMultiTexCoord4svARB(GLenum target,const GLshort * v)6018 void __indirect_glMultiTexCoord4svARB(GLenum target, const GLshort * v)
6019 {
6020     struct glx_context * const gc = __glXGetCurrentContext();
6021     const GLuint cmdlen = 16;
6022 emit_header(gc->pc, X_GLrop_MultiTexCoord4svARB, cmdlen);
6023 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6024 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
6025 gc->pc += cmdlen;
6026 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6027 }
6028 
6029 #define X_GLrop_SampleCoverageARB 229
__indirect_glSampleCoverageARB(GLclampf value,GLboolean invert)6030 void __indirect_glSampleCoverageARB(GLclampf value, GLboolean invert)
6031 {
6032     struct glx_context * const gc = __glXGetCurrentContext();
6033     const GLuint cmdlen = 12;
6034 emit_header(gc->pc, X_GLrop_SampleCoverageARB, cmdlen);
6035 (void) memcpy((void *)(gc->pc + 4), (void *)(&value), 4);
6036 (void) memcpy((void *)(gc->pc + 8), (void *)(&invert), 1);
6037 gc->pc += cmdlen;
6038 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6039 }
6040 
6041 #define X_GLvop_GetProgramStringARB 1308
__indirect_glGetProgramStringARB(GLenum target,GLenum pname,GLvoid * string)6042 void __indirect_glGetProgramStringARB(GLenum target, GLenum pname, GLvoid * string)
6043 {
6044     struct glx_context * const gc = __glXGetCurrentContext();
6045     Display * const dpy = gc->currentDpy;
6046     const GLuint cmdlen = 8;
6047     if (__builtin_expect(dpy != NULL, 1)) {
6048         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetProgramStringARB, cmdlen);
6049 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
6050 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
6051         (void) __glXReadReply(dpy, 1, string, GL_TRUE);
6052         UnlockDisplay(dpy); SyncHandle();
6053     }
6054     return;
6055 }
6056 
6057 #define X_GLvop_GetProgramivARB 1307
__indirect_glGetProgramivARB(GLenum target,GLenum pname,GLint * params)6058 void __indirect_glGetProgramivARB(GLenum target, GLenum pname, GLint * params)
6059 {
6060     struct glx_context * const gc = __glXGetCurrentContext();
6061     Display * const dpy = gc->currentDpy;
6062     const GLuint cmdlen = 8;
6063     if (__builtin_expect(dpy != NULL, 1)) {
6064         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetProgramivARB, cmdlen);
6065 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
6066 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
6067         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
6068         UnlockDisplay(dpy); SyncHandle();
6069     }
6070     return;
6071 }
6072 
6073 #define X_GLrop_ProgramEnvParameter4dvARB 4185
__indirect_glProgramEnvParameter4dARB(GLenum target,GLuint index,GLdouble x,GLdouble y,GLdouble z,GLdouble w)6074 void __indirect_glProgramEnvParameter4dARB(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
6075 {
6076     struct glx_context * const gc = __glXGetCurrentContext();
6077     const GLuint cmdlen = 44;
6078 emit_header(gc->pc, X_GLrop_ProgramEnvParameter4dvARB, cmdlen);
6079 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6080 (void) memcpy((void *)(gc->pc + 8), (void *)(&index), 4);
6081 (void) memcpy((void *)(gc->pc + 12), (void *)(&x), 8);
6082 (void) memcpy((void *)(gc->pc + 20), (void *)(&y), 8);
6083 (void) memcpy((void *)(gc->pc + 28), (void *)(&z), 8);
6084 (void) memcpy((void *)(gc->pc + 36), (void *)(&w), 8);
6085 gc->pc += cmdlen;
6086 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6087 }
6088 
6089 #define X_GLrop_ProgramEnvParameter4dvARB 4185
__indirect_glProgramEnvParameter4dvARB(GLenum target,GLuint index,const GLdouble * params)6090 void __indirect_glProgramEnvParameter4dvARB(GLenum target, GLuint index, const GLdouble * params)
6091 {
6092     struct glx_context * const gc = __glXGetCurrentContext();
6093     const GLuint cmdlen = 44;
6094 emit_header(gc->pc, X_GLrop_ProgramEnvParameter4dvARB, cmdlen);
6095 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6096 (void) memcpy((void *)(gc->pc + 8), (void *)(&index), 4);
6097 (void) memcpy((void *)(gc->pc + 12), (void *)(params), 32);
6098 gc->pc += cmdlen;
6099 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6100 }
6101 
6102 #define X_GLrop_ProgramEnvParameter4fvARB 4184
__indirect_glProgramEnvParameter4fARB(GLenum target,GLuint index,GLfloat x,GLfloat y,GLfloat z,GLfloat w)6103 void __indirect_glProgramEnvParameter4fARB(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
6104 {
6105     struct glx_context * const gc = __glXGetCurrentContext();
6106     const GLuint cmdlen = 28;
6107 emit_header(gc->pc, X_GLrop_ProgramEnvParameter4fvARB, cmdlen);
6108 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6109 (void) memcpy((void *)(gc->pc + 8), (void *)(&index), 4);
6110 (void) memcpy((void *)(gc->pc + 12), (void *)(&x), 4);
6111 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 4);
6112 (void) memcpy((void *)(gc->pc + 20), (void *)(&z), 4);
6113 (void) memcpy((void *)(gc->pc + 24), (void *)(&w), 4);
6114 gc->pc += cmdlen;
6115 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6116 }
6117 
6118 #define X_GLrop_ProgramEnvParameter4fvARB 4184
__indirect_glProgramEnvParameter4fvARB(GLenum target,GLuint index,const GLfloat * params)6119 void __indirect_glProgramEnvParameter4fvARB(GLenum target, GLuint index, const GLfloat * params)
6120 {
6121     struct glx_context * const gc = __glXGetCurrentContext();
6122     const GLuint cmdlen = 28;
6123 emit_header(gc->pc, X_GLrop_ProgramEnvParameter4fvARB, cmdlen);
6124 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6125 (void) memcpy((void *)(gc->pc + 8), (void *)(&index), 4);
6126 (void) memcpy((void *)(gc->pc + 12), (void *)(params), 16);
6127 gc->pc += cmdlen;
6128 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6129 }
6130 
6131 #define X_GLrop_ProgramLocalParameter4dvARB 4216
__indirect_glProgramLocalParameter4dARB(GLenum target,GLuint index,GLdouble x,GLdouble y,GLdouble z,GLdouble w)6132 void __indirect_glProgramLocalParameter4dARB(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
6133 {
6134     struct glx_context * const gc = __glXGetCurrentContext();
6135     const GLuint cmdlen = 44;
6136 emit_header(gc->pc, X_GLrop_ProgramLocalParameter4dvARB, cmdlen);
6137 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6138 (void) memcpy((void *)(gc->pc + 8), (void *)(&index), 4);
6139 (void) memcpy((void *)(gc->pc + 12), (void *)(&x), 8);
6140 (void) memcpy((void *)(gc->pc + 20), (void *)(&y), 8);
6141 (void) memcpy((void *)(gc->pc + 28), (void *)(&z), 8);
6142 (void) memcpy((void *)(gc->pc + 36), (void *)(&w), 8);
6143 gc->pc += cmdlen;
6144 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6145 }
6146 
6147 #define X_GLrop_ProgramLocalParameter4dvARB 4216
__indirect_glProgramLocalParameter4dvARB(GLenum target,GLuint index,const GLdouble * params)6148 void __indirect_glProgramLocalParameter4dvARB(GLenum target, GLuint index, const GLdouble * params)
6149 {
6150     struct glx_context * const gc = __glXGetCurrentContext();
6151     const GLuint cmdlen = 44;
6152 emit_header(gc->pc, X_GLrop_ProgramLocalParameter4dvARB, cmdlen);
6153 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6154 (void) memcpy((void *)(gc->pc + 8), (void *)(&index), 4);
6155 (void) memcpy((void *)(gc->pc + 12), (void *)(params), 32);
6156 gc->pc += cmdlen;
6157 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6158 }
6159 
6160 #define X_GLrop_ProgramLocalParameter4fvARB 4215
__indirect_glProgramLocalParameter4fARB(GLenum target,GLuint index,GLfloat x,GLfloat y,GLfloat z,GLfloat w)6161 void __indirect_glProgramLocalParameter4fARB(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
6162 {
6163     struct glx_context * const gc = __glXGetCurrentContext();
6164     const GLuint cmdlen = 28;
6165 emit_header(gc->pc, X_GLrop_ProgramLocalParameter4fvARB, cmdlen);
6166 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6167 (void) memcpy((void *)(gc->pc + 8), (void *)(&index), 4);
6168 (void) memcpy((void *)(gc->pc + 12), (void *)(&x), 4);
6169 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 4);
6170 (void) memcpy((void *)(gc->pc + 20), (void *)(&z), 4);
6171 (void) memcpy((void *)(gc->pc + 24), (void *)(&w), 4);
6172 gc->pc += cmdlen;
6173 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6174 }
6175 
6176 #define X_GLrop_ProgramLocalParameter4fvARB 4215
__indirect_glProgramLocalParameter4fvARB(GLenum target,GLuint index,const GLfloat * params)6177 void __indirect_glProgramLocalParameter4fvARB(GLenum target, GLuint index, const GLfloat * params)
6178 {
6179     struct glx_context * const gc = __glXGetCurrentContext();
6180     const GLuint cmdlen = 28;
6181 emit_header(gc->pc, X_GLrop_ProgramLocalParameter4fvARB, cmdlen);
6182 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6183 (void) memcpy((void *)(gc->pc + 8), (void *)(&index), 4);
6184 (void) memcpy((void *)(gc->pc + 12), (void *)(params), 16);
6185 gc->pc += cmdlen;
6186 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6187 }
6188 
6189 #define X_GLrop_ProgramStringARB 4217
__indirect_glProgramStringARB(GLenum target,GLenum format,GLsizei len,const GLvoid * string)6190 void __indirect_glProgramStringARB(GLenum target, GLenum format, GLsizei len, const GLvoid * string)
6191 {
6192     struct glx_context * const gc = __glXGetCurrentContext();
6193     const GLuint cmdlen = 16 + __GLX_PAD(len);
6194     if (len < 0) {
6195         __glXSetError(gc, GL_INVALID_VALUE);
6196         return;
6197     }
6198     if (__builtin_expect((len >= 0) && (gc->currentDpy != NULL), 1)) {
6199 if (cmdlen <= gc->maxSmallRenderCommandSize) {
6200     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
6201         (void) __glXFlushRenderBuffer(gc, gc->pc);
6202     }
6203 emit_header(gc->pc, X_GLrop_ProgramStringARB, cmdlen);
6204 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6205 (void) memcpy((void *)(gc->pc + 8), (void *)(&format), 4);
6206 (void) memcpy((void *)(gc->pc + 12), (void *)(&len), 4);
6207 (void) memcpy((void *)(gc->pc + 16), (void *)(string), len);
6208 gc->pc += cmdlen;
6209 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6210 }
6211 else {
6212 const GLint op = X_GLrop_ProgramStringARB;
6213 const GLuint cmdlenLarge = cmdlen + 4;
6214 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
6215 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
6216 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
6217 (void) memcpy((void *)(pc + 8), (void *)(&target), 4);
6218 (void) memcpy((void *)(pc + 12), (void *)(&format), 4);
6219 (void) memcpy((void *)(pc + 16), (void *)(&len), 4);
6220     __glXSendLargeCommand(gc, pc, 20, string, len);
6221 }
6222     }
6223 }
6224 
6225 #define X_GLrop_VertexAttrib1dvARB 4197
__indirect_glVertexAttrib1dARB(GLuint index,GLdouble x)6226 void __indirect_glVertexAttrib1dARB(GLuint index, GLdouble x)
6227 {
6228     struct glx_context * const gc = __glXGetCurrentContext();
6229     const GLuint cmdlen = 16;
6230 emit_header(gc->pc, X_GLrop_VertexAttrib1dvARB, cmdlen);
6231 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6232 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 8);
6233 gc->pc += cmdlen;
6234 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6235 }
6236 
6237 #define X_GLrop_VertexAttrib1dvARB 4197
__indirect_glVertexAttrib1dvARB(GLuint index,const GLdouble * v)6238 void __indirect_glVertexAttrib1dvARB(GLuint index, const GLdouble * v)
6239 {
6240     struct glx_context * const gc = __glXGetCurrentContext();
6241     const GLuint cmdlen = 16;
6242 emit_header(gc->pc, X_GLrop_VertexAttrib1dvARB, cmdlen);
6243 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6244 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
6245 gc->pc += cmdlen;
6246 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6247 }
6248 
6249 #define X_GLrop_VertexAttrib1fvARB 4193
__indirect_glVertexAttrib1fARB(GLuint index,GLfloat x)6250 void __indirect_glVertexAttrib1fARB(GLuint index, GLfloat x)
6251 {
6252     struct glx_context * const gc = __glXGetCurrentContext();
6253     const GLuint cmdlen = 12;
6254 emit_header(gc->pc, X_GLrop_VertexAttrib1fvARB, cmdlen);
6255 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6256 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 4);
6257 gc->pc += cmdlen;
6258 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6259 }
6260 
6261 #define X_GLrop_VertexAttrib1fvARB 4193
__indirect_glVertexAttrib1fvARB(GLuint index,const GLfloat * v)6262 void __indirect_glVertexAttrib1fvARB(GLuint index, const GLfloat * v)
6263 {
6264     struct glx_context * const gc = __glXGetCurrentContext();
6265     const GLuint cmdlen = 12;
6266 emit_header(gc->pc, X_GLrop_VertexAttrib1fvARB, cmdlen);
6267 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6268 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
6269 gc->pc += cmdlen;
6270 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6271 }
6272 
6273 #define X_GLrop_VertexAttrib1svARB 4189
__indirect_glVertexAttrib1sARB(GLuint index,GLshort x)6274 void __indirect_glVertexAttrib1sARB(GLuint index, GLshort x)
6275 {
6276     struct glx_context * const gc = __glXGetCurrentContext();
6277     const GLuint cmdlen = 12;
6278 emit_header(gc->pc, X_GLrop_VertexAttrib1svARB, cmdlen);
6279 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6280 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 2);
6281 gc->pc += cmdlen;
6282 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6283 }
6284 
6285 #define X_GLrop_VertexAttrib1svARB 4189
__indirect_glVertexAttrib1svARB(GLuint index,const GLshort * v)6286 void __indirect_glVertexAttrib1svARB(GLuint index, const GLshort * v)
6287 {
6288     struct glx_context * const gc = __glXGetCurrentContext();
6289     const GLuint cmdlen = 12;
6290 emit_header(gc->pc, X_GLrop_VertexAttrib1svARB, cmdlen);
6291 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6292 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 2);
6293 gc->pc += cmdlen;
6294 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6295 }
6296 
6297 #define X_GLrop_VertexAttrib2dvARB 4198
__indirect_glVertexAttrib2dARB(GLuint index,GLdouble x,GLdouble y)6298 void __indirect_glVertexAttrib2dARB(GLuint index, GLdouble x, GLdouble y)
6299 {
6300     struct glx_context * const gc = __glXGetCurrentContext();
6301     const GLuint cmdlen = 24;
6302 emit_header(gc->pc, X_GLrop_VertexAttrib2dvARB, cmdlen);
6303 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6304 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 8);
6305 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 8);
6306 gc->pc += cmdlen;
6307 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6308 }
6309 
6310 #define X_GLrop_VertexAttrib2dvARB 4198
__indirect_glVertexAttrib2dvARB(GLuint index,const GLdouble * v)6311 void __indirect_glVertexAttrib2dvARB(GLuint index, const GLdouble * v)
6312 {
6313     struct glx_context * const gc = __glXGetCurrentContext();
6314     const GLuint cmdlen = 24;
6315 emit_header(gc->pc, X_GLrop_VertexAttrib2dvARB, cmdlen);
6316 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6317 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 16);
6318 gc->pc += cmdlen;
6319 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6320 }
6321 
6322 #define X_GLrop_VertexAttrib2fvARB 4194
__indirect_glVertexAttrib2fARB(GLuint index,GLfloat x,GLfloat y)6323 void __indirect_glVertexAttrib2fARB(GLuint index, GLfloat x, GLfloat y)
6324 {
6325     struct glx_context * const gc = __glXGetCurrentContext();
6326     const GLuint cmdlen = 16;
6327 emit_header(gc->pc, X_GLrop_VertexAttrib2fvARB, cmdlen);
6328 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6329 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 4);
6330 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 4);
6331 gc->pc += cmdlen;
6332 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6333 }
6334 
6335 #define X_GLrop_VertexAttrib2fvARB 4194
__indirect_glVertexAttrib2fvARB(GLuint index,const GLfloat * v)6336 void __indirect_glVertexAttrib2fvARB(GLuint index, const GLfloat * v)
6337 {
6338     struct glx_context * const gc = __glXGetCurrentContext();
6339     const GLuint cmdlen = 16;
6340 emit_header(gc->pc, X_GLrop_VertexAttrib2fvARB, cmdlen);
6341 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6342 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
6343 gc->pc += cmdlen;
6344 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6345 }
6346 
6347 #define X_GLrop_VertexAttrib2svARB 4190
__indirect_glVertexAttrib2sARB(GLuint index,GLshort x,GLshort y)6348 void __indirect_glVertexAttrib2sARB(GLuint index, GLshort x, GLshort y)
6349 {
6350     struct glx_context * const gc = __glXGetCurrentContext();
6351     const GLuint cmdlen = 12;
6352 emit_header(gc->pc, X_GLrop_VertexAttrib2svARB, cmdlen);
6353 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6354 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 2);
6355 (void) memcpy((void *)(gc->pc + 10), (void *)(&y), 2);
6356 gc->pc += cmdlen;
6357 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6358 }
6359 
6360 #define X_GLrop_VertexAttrib2svARB 4190
__indirect_glVertexAttrib2svARB(GLuint index,const GLshort * v)6361 void __indirect_glVertexAttrib2svARB(GLuint index, const GLshort * v)
6362 {
6363     struct glx_context * const gc = __glXGetCurrentContext();
6364     const GLuint cmdlen = 12;
6365 emit_header(gc->pc, X_GLrop_VertexAttrib2svARB, cmdlen);
6366 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6367 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
6368 gc->pc += cmdlen;
6369 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6370 }
6371 
6372 #define X_GLrop_VertexAttrib3dvARB 4199
__indirect_glVertexAttrib3dARB(GLuint index,GLdouble x,GLdouble y,GLdouble z)6373 void __indirect_glVertexAttrib3dARB(GLuint index, GLdouble x, GLdouble y, GLdouble z)
6374 {
6375     struct glx_context * const gc = __glXGetCurrentContext();
6376     const GLuint cmdlen = 32;
6377 emit_header(gc->pc, X_GLrop_VertexAttrib3dvARB, cmdlen);
6378 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6379 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 8);
6380 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 8);
6381 (void) memcpy((void *)(gc->pc + 24), (void *)(&z), 8);
6382 gc->pc += cmdlen;
6383 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6384 }
6385 
6386 #define X_GLrop_VertexAttrib3dvARB 4199
__indirect_glVertexAttrib3dvARB(GLuint index,const GLdouble * v)6387 void __indirect_glVertexAttrib3dvARB(GLuint index, const GLdouble * v)
6388 {
6389     struct glx_context * const gc = __glXGetCurrentContext();
6390     const GLuint cmdlen = 32;
6391 emit_header(gc->pc, X_GLrop_VertexAttrib3dvARB, cmdlen);
6392 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6393 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 24);
6394 gc->pc += cmdlen;
6395 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6396 }
6397 
6398 #define X_GLrop_VertexAttrib3fvARB 4195
__indirect_glVertexAttrib3fARB(GLuint index,GLfloat x,GLfloat y,GLfloat z)6399 void __indirect_glVertexAttrib3fARB(GLuint index, GLfloat x, GLfloat y, GLfloat z)
6400 {
6401     struct glx_context * const gc = __glXGetCurrentContext();
6402     const GLuint cmdlen = 20;
6403 emit_header(gc->pc, X_GLrop_VertexAttrib3fvARB, cmdlen);
6404 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6405 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 4);
6406 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 4);
6407 (void) memcpy((void *)(gc->pc + 16), (void *)(&z), 4);
6408 gc->pc += cmdlen;
6409 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6410 }
6411 
6412 #define X_GLrop_VertexAttrib3fvARB 4195
__indirect_glVertexAttrib3fvARB(GLuint index,const GLfloat * v)6413 void __indirect_glVertexAttrib3fvARB(GLuint index, const GLfloat * v)
6414 {
6415     struct glx_context * const gc = __glXGetCurrentContext();
6416     const GLuint cmdlen = 20;
6417 emit_header(gc->pc, X_GLrop_VertexAttrib3fvARB, cmdlen);
6418 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6419 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 12);
6420 gc->pc += cmdlen;
6421 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6422 }
6423 
6424 #define X_GLrop_VertexAttrib3svARB 4191
__indirect_glVertexAttrib3sARB(GLuint index,GLshort x,GLshort y,GLshort z)6425 void __indirect_glVertexAttrib3sARB(GLuint index, GLshort x, GLshort y, GLshort z)
6426 {
6427     struct glx_context * const gc = __glXGetCurrentContext();
6428     const GLuint cmdlen = 16;
6429 emit_header(gc->pc, X_GLrop_VertexAttrib3svARB, cmdlen);
6430 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6431 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 2);
6432 (void) memcpy((void *)(gc->pc + 10), (void *)(&y), 2);
6433 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 2);
6434 gc->pc += cmdlen;
6435 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6436 }
6437 
6438 #define X_GLrop_VertexAttrib3svARB 4191
__indirect_glVertexAttrib3svARB(GLuint index,const GLshort * v)6439 void __indirect_glVertexAttrib3svARB(GLuint index, const GLshort * v)
6440 {
6441     struct glx_context * const gc = __glXGetCurrentContext();
6442     const GLuint cmdlen = 16;
6443 emit_header(gc->pc, X_GLrop_VertexAttrib3svARB, cmdlen);
6444 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6445 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 6);
6446 gc->pc += cmdlen;
6447 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6448 }
6449 
6450 #define X_GLrop_VertexAttrib4NbvARB 4235
__indirect_glVertexAttrib4NbvARB(GLuint index,const GLbyte * v)6451 void __indirect_glVertexAttrib4NbvARB(GLuint index, const GLbyte * v)
6452 {
6453     struct glx_context * const gc = __glXGetCurrentContext();
6454     const GLuint cmdlen = 12;
6455 emit_header(gc->pc, X_GLrop_VertexAttrib4NbvARB, cmdlen);
6456 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6457 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
6458 gc->pc += cmdlen;
6459 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6460 }
6461 
6462 #define X_GLrop_VertexAttrib4NivARB 4237
__indirect_glVertexAttrib4NivARB(GLuint index,const GLint * v)6463 void __indirect_glVertexAttrib4NivARB(GLuint index, const GLint * v)
6464 {
6465     struct glx_context * const gc = __glXGetCurrentContext();
6466     const GLuint cmdlen = 24;
6467 emit_header(gc->pc, X_GLrop_VertexAttrib4NivARB, cmdlen);
6468 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6469 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 16);
6470 gc->pc += cmdlen;
6471 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6472 }
6473 
6474 #define X_GLrop_VertexAttrib4NsvARB 4236
__indirect_glVertexAttrib4NsvARB(GLuint index,const GLshort * v)6475 void __indirect_glVertexAttrib4NsvARB(GLuint index, const GLshort * v)
6476 {
6477     struct glx_context * const gc = __glXGetCurrentContext();
6478     const GLuint cmdlen = 16;
6479 emit_header(gc->pc, X_GLrop_VertexAttrib4NsvARB, cmdlen);
6480 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6481 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
6482 gc->pc += cmdlen;
6483 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6484 }
6485 
6486 #define X_GLrop_VertexAttrib4NubvARB 4201
__indirect_glVertexAttrib4NubARB(GLuint index,GLubyte x,GLubyte y,GLubyte z,GLubyte w)6487 void __indirect_glVertexAttrib4NubARB(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
6488 {
6489     struct glx_context * const gc = __glXGetCurrentContext();
6490     const GLuint cmdlen = 12;
6491 emit_header(gc->pc, X_GLrop_VertexAttrib4NubvARB, cmdlen);
6492 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6493 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 1);
6494 (void) memcpy((void *)(gc->pc + 9), (void *)(&y), 1);
6495 (void) memcpy((void *)(gc->pc + 10), (void *)(&z), 1);
6496 (void) memcpy((void *)(gc->pc + 11), (void *)(&w), 1);
6497 gc->pc += cmdlen;
6498 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6499 }
6500 
6501 #define X_GLrop_VertexAttrib4NubvARB 4201
__indirect_glVertexAttrib4NubvARB(GLuint index,const GLubyte * v)6502 void __indirect_glVertexAttrib4NubvARB(GLuint index, const GLubyte * v)
6503 {
6504     struct glx_context * const gc = __glXGetCurrentContext();
6505     const GLuint cmdlen = 12;
6506 emit_header(gc->pc, X_GLrop_VertexAttrib4NubvARB, cmdlen);
6507 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6508 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
6509 gc->pc += cmdlen;
6510 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6511 }
6512 
6513 #define X_GLrop_VertexAttrib4NuivARB 4239
__indirect_glVertexAttrib4NuivARB(GLuint index,const GLuint * v)6514 void __indirect_glVertexAttrib4NuivARB(GLuint index, const GLuint * v)
6515 {
6516     struct glx_context * const gc = __glXGetCurrentContext();
6517     const GLuint cmdlen = 24;
6518 emit_header(gc->pc, X_GLrop_VertexAttrib4NuivARB, cmdlen);
6519 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6520 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 16);
6521 gc->pc += cmdlen;
6522 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6523 }
6524 
6525 #define X_GLrop_VertexAttrib4NusvARB 4238
__indirect_glVertexAttrib4NusvARB(GLuint index,const GLushort * v)6526 void __indirect_glVertexAttrib4NusvARB(GLuint index, const GLushort * v)
6527 {
6528     struct glx_context * const gc = __glXGetCurrentContext();
6529     const GLuint cmdlen = 16;
6530 emit_header(gc->pc, X_GLrop_VertexAttrib4NusvARB, cmdlen);
6531 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6532 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
6533 gc->pc += cmdlen;
6534 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6535 }
6536 
6537 #define X_GLrop_VertexAttrib4bvARB 4230
__indirect_glVertexAttrib4bvARB(GLuint index,const GLbyte * v)6538 void __indirect_glVertexAttrib4bvARB(GLuint index, const GLbyte * v)
6539 {
6540     struct glx_context * const gc = __glXGetCurrentContext();
6541     const GLuint cmdlen = 12;
6542 emit_header(gc->pc, X_GLrop_VertexAttrib4bvARB, cmdlen);
6543 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6544 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
6545 gc->pc += cmdlen;
6546 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6547 }
6548 
6549 #define X_GLrop_VertexAttrib4dvARB 4200
__indirect_glVertexAttrib4dARB(GLuint index,GLdouble x,GLdouble y,GLdouble z,GLdouble w)6550 void __indirect_glVertexAttrib4dARB(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
6551 {
6552     struct glx_context * const gc = __glXGetCurrentContext();
6553     const GLuint cmdlen = 40;
6554 emit_header(gc->pc, X_GLrop_VertexAttrib4dvARB, cmdlen);
6555 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6556 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 8);
6557 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 8);
6558 (void) memcpy((void *)(gc->pc + 24), (void *)(&z), 8);
6559 (void) memcpy((void *)(gc->pc + 32), (void *)(&w), 8);
6560 gc->pc += cmdlen;
6561 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6562 }
6563 
6564 #define X_GLrop_VertexAttrib4dvARB 4200
__indirect_glVertexAttrib4dvARB(GLuint index,const GLdouble * v)6565 void __indirect_glVertexAttrib4dvARB(GLuint index, const GLdouble * v)
6566 {
6567     struct glx_context * const gc = __glXGetCurrentContext();
6568     const GLuint cmdlen = 40;
6569 emit_header(gc->pc, X_GLrop_VertexAttrib4dvARB, cmdlen);
6570 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6571 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 32);
6572 gc->pc += cmdlen;
6573 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6574 }
6575 
6576 #define X_GLrop_VertexAttrib4fvARB 4196
__indirect_glVertexAttrib4fARB(GLuint index,GLfloat x,GLfloat y,GLfloat z,GLfloat w)6577 void __indirect_glVertexAttrib4fARB(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
6578 {
6579     struct glx_context * const gc = __glXGetCurrentContext();
6580     const GLuint cmdlen = 24;
6581 emit_header(gc->pc, X_GLrop_VertexAttrib4fvARB, cmdlen);
6582 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6583 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 4);
6584 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 4);
6585 (void) memcpy((void *)(gc->pc + 16), (void *)(&z), 4);
6586 (void) memcpy((void *)(gc->pc + 20), (void *)(&w), 4);
6587 gc->pc += cmdlen;
6588 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6589 }
6590 
6591 #define X_GLrop_VertexAttrib4fvARB 4196
__indirect_glVertexAttrib4fvARB(GLuint index,const GLfloat * v)6592 void __indirect_glVertexAttrib4fvARB(GLuint index, const GLfloat * v)
6593 {
6594     struct glx_context * const gc = __glXGetCurrentContext();
6595     const GLuint cmdlen = 24;
6596 emit_header(gc->pc, X_GLrop_VertexAttrib4fvARB, cmdlen);
6597 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6598 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 16);
6599 gc->pc += cmdlen;
6600 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6601 }
6602 
6603 #define X_GLrop_VertexAttrib4ivARB 4231
__indirect_glVertexAttrib4ivARB(GLuint index,const GLint * v)6604 void __indirect_glVertexAttrib4ivARB(GLuint index, const GLint * v)
6605 {
6606     struct glx_context * const gc = __glXGetCurrentContext();
6607     const GLuint cmdlen = 24;
6608 emit_header(gc->pc, X_GLrop_VertexAttrib4ivARB, cmdlen);
6609 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6610 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 16);
6611 gc->pc += cmdlen;
6612 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6613 }
6614 
6615 #define X_GLrop_VertexAttrib4svARB 4192
__indirect_glVertexAttrib4sARB(GLuint index,GLshort x,GLshort y,GLshort z,GLshort w)6616 void __indirect_glVertexAttrib4sARB(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
6617 {
6618     struct glx_context * const gc = __glXGetCurrentContext();
6619     const GLuint cmdlen = 16;
6620 emit_header(gc->pc, X_GLrop_VertexAttrib4svARB, cmdlen);
6621 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6622 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 2);
6623 (void) memcpy((void *)(gc->pc + 10), (void *)(&y), 2);
6624 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 2);
6625 (void) memcpy((void *)(gc->pc + 14), (void *)(&w), 2);
6626 gc->pc += cmdlen;
6627 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6628 }
6629 
6630 #define X_GLrop_VertexAttrib4svARB 4192
__indirect_glVertexAttrib4svARB(GLuint index,const GLshort * v)6631 void __indirect_glVertexAttrib4svARB(GLuint index, const GLshort * v)
6632 {
6633     struct glx_context * const gc = __glXGetCurrentContext();
6634     const GLuint cmdlen = 16;
6635 emit_header(gc->pc, X_GLrop_VertexAttrib4svARB, cmdlen);
6636 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6637 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
6638 gc->pc += cmdlen;
6639 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6640 }
6641 
6642 #define X_GLrop_VertexAttrib4ubvARB 4232
__indirect_glVertexAttrib4ubvARB(GLuint index,const GLubyte * v)6643 void __indirect_glVertexAttrib4ubvARB(GLuint index, const GLubyte * v)
6644 {
6645     struct glx_context * const gc = __glXGetCurrentContext();
6646     const GLuint cmdlen = 12;
6647 emit_header(gc->pc, X_GLrop_VertexAttrib4ubvARB, cmdlen);
6648 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6649 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
6650 gc->pc += cmdlen;
6651 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6652 }
6653 
6654 #define X_GLrop_VertexAttrib4uivARB 4234
__indirect_glVertexAttrib4uivARB(GLuint index,const GLuint * v)6655 void __indirect_glVertexAttrib4uivARB(GLuint index, const GLuint * v)
6656 {
6657     struct glx_context * const gc = __glXGetCurrentContext();
6658     const GLuint cmdlen = 24;
6659 emit_header(gc->pc, X_GLrop_VertexAttrib4uivARB, cmdlen);
6660 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6661 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 16);
6662 gc->pc += cmdlen;
6663 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6664 }
6665 
6666 #define X_GLrop_VertexAttrib4usvARB 4233
__indirect_glVertexAttrib4usvARB(GLuint index,const GLushort * v)6667 void __indirect_glVertexAttrib4usvARB(GLuint index, const GLushort * v)
6668 {
6669     struct glx_context * const gc = __glXGetCurrentContext();
6670     const GLuint cmdlen = 16;
6671 emit_header(gc->pc, X_GLrop_VertexAttrib4usvARB, cmdlen);
6672 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
6673 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
6674 gc->pc += cmdlen;
6675 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6676 }
6677 
6678 #define X_GLrop_BeginQueryARB 231
__indirect_glBeginQueryARB(GLenum target,GLuint id)6679 void __indirect_glBeginQueryARB(GLenum target, GLuint id)
6680 {
6681     struct glx_context * const gc = __glXGetCurrentContext();
6682     const GLuint cmdlen = 12;
6683 emit_header(gc->pc, X_GLrop_BeginQueryARB, cmdlen);
6684 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6685 (void) memcpy((void *)(gc->pc + 8), (void *)(&id), 4);
6686 gc->pc += cmdlen;
6687 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6688 }
6689 
6690 #define X_GLsop_DeleteQueriesARB 161
__indirect_glDeleteQueriesARB(GLsizei n,const GLuint * ids)6691 void __indirect_glDeleteQueriesARB(GLsizei n, const GLuint * ids)
6692 {
6693     struct glx_context * const gc = __glXGetCurrentContext();
6694     Display * const dpy = gc->currentDpy;
6695 #ifndef USE_XCB
6696     const GLuint cmdlen = 4 + __GLX_PAD((n * 4));
6697 #endif
6698     if (n < 0) {
6699         __glXSetError(gc, GL_INVALID_VALUE);
6700         return;
6701     }
6702     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
6703 #ifdef USE_XCB
6704         xcb_connection_t *c = XGetXCBConnection(dpy);
6705         (void) __glXFlushRenderBuffer(gc, gc->pc);
6706         xcb_glx_delete_queries_arb(c, gc->currentContextTag, n, ids);
6707 #else
6708         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_DeleteQueriesARB, cmdlen);
6709 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
6710 (void) memcpy((void *)(pc + 4), (void *)(ids), (n * 4));
6711         UnlockDisplay(dpy); SyncHandle();
6712 #endif /* USE_XCB */
6713     }
6714     return;
6715 }
6716 
6717 #define X_GLrop_EndQueryARB 232
__indirect_glEndQueryARB(GLenum target)6718 void __indirect_glEndQueryARB(GLenum target)
6719 {
6720     struct glx_context * const gc = __glXGetCurrentContext();
6721     const GLuint cmdlen = 8;
6722 emit_header(gc->pc, X_GLrop_EndQueryARB, cmdlen);
6723 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6724 gc->pc += cmdlen;
6725 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6726 }
6727 
6728 #define X_GLsop_GenQueriesARB 162
__indirect_glGenQueriesARB(GLsizei n,GLuint * ids)6729 void __indirect_glGenQueriesARB(GLsizei n, GLuint * ids)
6730 {
6731     struct glx_context * const gc = __glXGetCurrentContext();
6732     Display * const dpy = gc->currentDpy;
6733 #ifndef USE_XCB
6734     const GLuint cmdlen = 4;
6735 #endif
6736     if (n < 0) {
6737         __glXSetError(gc, GL_INVALID_VALUE);
6738         return;
6739     }
6740     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
6741 #ifdef USE_XCB
6742         xcb_connection_t *c = XGetXCBConnection(dpy);
6743         (void) __glXFlushRenderBuffer(gc, gc->pc);
6744         xcb_glx_gen_queries_arb_reply_t *reply = xcb_glx_gen_queries_arb_reply(c, xcb_glx_gen_queries_arb(c, gc->currentContextTag, n), NULL);
6745         (void)memcpy(ids, xcb_glx_gen_queries_arb_data(reply), xcb_glx_gen_queries_arb_data_length(reply) * sizeof(GLuint));
6746         free(reply);
6747 #else
6748         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GenQueriesARB, cmdlen);
6749 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
6750         (void) __glXReadReply(dpy, 4, ids, GL_TRUE);
6751         UnlockDisplay(dpy); SyncHandle();
6752 #endif /* USE_XCB */
6753     }
6754     return;
6755 }
6756 
6757 #define X_GLsop_GetQueryObjectivARB 165
__indirect_glGetQueryObjectivARB(GLuint id,GLenum pname,GLint * params)6758 void __indirect_glGetQueryObjectivARB(GLuint id, GLenum pname, GLint * params)
6759 {
6760     struct glx_context * const gc = __glXGetCurrentContext();
6761     Display * const dpy = gc->currentDpy;
6762 #ifndef USE_XCB
6763     const GLuint cmdlen = 8;
6764 #endif
6765     if (__builtin_expect(dpy != NULL, 1)) {
6766 #ifdef USE_XCB
6767         xcb_connection_t *c = XGetXCBConnection(dpy);
6768         (void) __glXFlushRenderBuffer(gc, gc->pc);
6769         xcb_glx_get_query_objectiv_arb_reply_t *reply = xcb_glx_get_query_objectiv_arb_reply(c, xcb_glx_get_query_objectiv_arb(c, gc->currentContextTag, id, pname), NULL);
6770         if (xcb_glx_get_query_objectiv_arb_data_length(reply) == 0)
6771             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
6772         else
6773             (void)memcpy(params, xcb_glx_get_query_objectiv_arb_data(reply), xcb_glx_get_query_objectiv_arb_data_length(reply) * sizeof(GLint));
6774         free(reply);
6775 #else
6776         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetQueryObjectivARB, cmdlen);
6777 (void) memcpy((void *)(pc + 0), (void *)(&id), 4);
6778 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
6779         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
6780         UnlockDisplay(dpy); SyncHandle();
6781 #endif /* USE_XCB */
6782     }
6783     return;
6784 }
6785 
6786 #define X_GLsop_GetQueryObjectuivARB 166
__indirect_glGetQueryObjectuivARB(GLuint id,GLenum pname,GLuint * params)6787 void __indirect_glGetQueryObjectuivARB(GLuint id, GLenum pname, GLuint * params)
6788 {
6789     struct glx_context * const gc = __glXGetCurrentContext();
6790     Display * const dpy = gc->currentDpy;
6791 #ifndef USE_XCB
6792     const GLuint cmdlen = 8;
6793 #endif
6794     if (__builtin_expect(dpy != NULL, 1)) {
6795 #ifdef USE_XCB
6796         xcb_connection_t *c = XGetXCBConnection(dpy);
6797         (void) __glXFlushRenderBuffer(gc, gc->pc);
6798         xcb_glx_get_query_objectuiv_arb_reply_t *reply = xcb_glx_get_query_objectuiv_arb_reply(c, xcb_glx_get_query_objectuiv_arb(c, gc->currentContextTag, id, pname), NULL);
6799         if (xcb_glx_get_query_objectuiv_arb_data_length(reply) == 0)
6800             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
6801         else
6802             (void)memcpy(params, xcb_glx_get_query_objectuiv_arb_data(reply), xcb_glx_get_query_objectuiv_arb_data_length(reply) * sizeof(GLuint));
6803         free(reply);
6804 #else
6805         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetQueryObjectuivARB, cmdlen);
6806 (void) memcpy((void *)(pc + 0), (void *)(&id), 4);
6807 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
6808         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
6809         UnlockDisplay(dpy); SyncHandle();
6810 #endif /* USE_XCB */
6811     }
6812     return;
6813 }
6814 
6815 #define X_GLsop_GetQueryivARB 164
__indirect_glGetQueryivARB(GLenum target,GLenum pname,GLint * params)6816 void __indirect_glGetQueryivARB(GLenum target, GLenum pname, GLint * params)
6817 {
6818     struct glx_context * const gc = __glXGetCurrentContext();
6819     Display * const dpy = gc->currentDpy;
6820 #ifndef USE_XCB
6821     const GLuint cmdlen = 8;
6822 #endif
6823     if (__builtin_expect(dpy != NULL, 1)) {
6824 #ifdef USE_XCB
6825         xcb_connection_t *c = XGetXCBConnection(dpy);
6826         (void) __glXFlushRenderBuffer(gc, gc->pc);
6827         xcb_glx_get_queryiv_arb_reply_t *reply = xcb_glx_get_queryiv_arb_reply(c, xcb_glx_get_queryiv_arb(c, gc->currentContextTag, target, pname), NULL);
6828         if (xcb_glx_get_queryiv_arb_data_length(reply) == 0)
6829             (void)memcpy(params, &reply->datum, sizeof(reply->datum));
6830         else
6831             (void)memcpy(params, xcb_glx_get_queryiv_arb_data(reply), xcb_glx_get_queryiv_arb_data_length(reply) * sizeof(GLint));
6832         free(reply);
6833 #else
6834         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_GetQueryivARB, cmdlen);
6835 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
6836 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
6837         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
6838         UnlockDisplay(dpy); SyncHandle();
6839 #endif /* USE_XCB */
6840     }
6841     return;
6842 }
6843 
6844 #define X_GLsop_IsQueryARB 163
__indirect_glIsQueryARB(GLuint id)6845 GLboolean __indirect_glIsQueryARB(GLuint id)
6846 {
6847     struct glx_context * const gc = __glXGetCurrentContext();
6848     Display * const dpy = gc->currentDpy;
6849     GLboolean retval = (GLboolean) 0;
6850 #ifndef USE_XCB
6851     const GLuint cmdlen = 4;
6852 #endif
6853     if (__builtin_expect(dpy != NULL, 1)) {
6854 #ifdef USE_XCB
6855         xcb_connection_t *c = XGetXCBConnection(dpy);
6856         (void) __glXFlushRenderBuffer(gc, gc->pc);
6857         xcb_glx_is_query_arb_reply_t *reply = xcb_glx_is_query_arb_reply(c, xcb_glx_is_query_arb(c, gc->currentContextTag, id), NULL);
6858         retval = reply->ret_val;
6859         free(reply);
6860 #else
6861         GLubyte const * pc = __glXSetupSingleRequest(gc, X_GLsop_IsQueryARB, cmdlen);
6862 (void) memcpy((void *)(pc + 0), (void *)(&id), 4);
6863         retval = (GLboolean) __glXReadReply(dpy, 0, NULL, GL_FALSE);
6864         UnlockDisplay(dpy); SyncHandle();
6865 #endif /* USE_XCB */
6866     }
6867     return retval;
6868 }
6869 
6870 #define X_GLrop_DrawBuffersARB 233
__indirect_glDrawBuffersARB(GLsizei n,const GLenum * bufs)6871 void __indirect_glDrawBuffersARB(GLsizei n, const GLenum * bufs)
6872 {
6873     struct glx_context * const gc = __glXGetCurrentContext();
6874     const GLuint cmdlen = 8 + __GLX_PAD((n * 4));
6875     if (n < 0) {
6876         __glXSetError(gc, GL_INVALID_VALUE);
6877         return;
6878     }
6879     if (__builtin_expect((n >= 0) && (gc->currentDpy != NULL), 1)) {
6880 if (cmdlen <= gc->maxSmallRenderCommandSize) {
6881     if ( (gc->pc + cmdlen) > gc->bufEnd ) {
6882         (void) __glXFlushRenderBuffer(gc, gc->pc);
6883     }
6884 emit_header(gc->pc, X_GLrop_DrawBuffersARB, cmdlen);
6885 (void) memcpy((void *)(gc->pc + 4), (void *)(&n), 4);
6886 (void) memcpy((void *)(gc->pc + 8), (void *)(bufs), (n * 4));
6887 gc->pc += cmdlen;
6888 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6889 }
6890 else {
6891 const GLint op = X_GLrop_DrawBuffersARB;
6892 const GLuint cmdlenLarge = cmdlen + 4;
6893 GLubyte * const pc = __glXFlushRenderBuffer(gc, gc->pc);
6894 (void) memcpy((void *)(pc + 0), (void *)(&cmdlenLarge), 4);
6895 (void) memcpy((void *)(pc + 4), (void *)(&op), 4);
6896 (void) memcpy((void *)(pc + 8), (void *)(&n), 4);
6897     __glXSendLargeCommand(gc, pc, 12, bufs, (n * 4));
6898 }
6899     }
6900 }
6901 
6902 #define X_GLrop_ClampColorARB 234
__indirect_glClampColorARB(GLenum target,GLenum clamp)6903 void __indirect_glClampColorARB(GLenum target, GLenum clamp)
6904 {
6905     struct glx_context * const gc = __glXGetCurrentContext();
6906     const GLuint cmdlen = 12;
6907 emit_header(gc->pc, X_GLrop_ClampColorARB, cmdlen);
6908 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6909 (void) memcpy((void *)(gc->pc + 8), (void *)(&clamp), 4);
6910 gc->pc += cmdlen;
6911 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6912 }
6913 
6914 #define X_GLrop_RenderbufferStorageMultisample 4331
__indirect_glRenderbufferStorageMultisample(GLenum target,GLsizei samples,GLenum internalformat,GLsizei width,GLsizei height)6915 void __indirect_glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
6916 {
6917     struct glx_context * const gc = __glXGetCurrentContext();
6918     const GLuint cmdlen = 24;
6919 emit_header(gc->pc, X_GLrop_RenderbufferStorageMultisample, cmdlen);
6920 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
6921 (void) memcpy((void *)(gc->pc + 8), (void *)(&samples), 4);
6922 (void) memcpy((void *)(gc->pc + 12), (void *)(&internalformat), 4);
6923 (void) memcpy((void *)(gc->pc + 16), (void *)(&width), 4);
6924 (void) memcpy((void *)(gc->pc + 20), (void *)(&height), 4);
6925 gc->pc += cmdlen;
6926 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6927 }
6928 
6929 #define X_GLrop_SampleMaskSGIS 2048
__indirect_glSampleMaskSGIS(GLclampf value,GLboolean invert)6930 void __indirect_glSampleMaskSGIS(GLclampf value, GLboolean invert)
6931 {
6932     struct glx_context * const gc = __glXGetCurrentContext();
6933     const GLuint cmdlen = 12;
6934 emit_header(gc->pc, X_GLrop_SampleMaskSGIS, cmdlen);
6935 (void) memcpy((void *)(gc->pc + 4), (void *)(&value), 4);
6936 (void) memcpy((void *)(gc->pc + 8), (void *)(&invert), 1);
6937 gc->pc += cmdlen;
6938 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6939 }
6940 
6941 #define X_GLrop_SamplePatternSGIS 2049
__indirect_glSamplePatternSGIS(GLenum pattern)6942 void __indirect_glSamplePatternSGIS(GLenum pattern)
6943 {
6944     struct glx_context * const gc = __glXGetCurrentContext();
6945     const GLuint cmdlen = 8;
6946 emit_header(gc->pc, X_GLrop_SamplePatternSGIS, cmdlen);
6947 (void) memcpy((void *)(gc->pc + 4), (void *)(&pattern), 4);
6948 gc->pc += cmdlen;
6949 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6950 }
6951 
6952 #define X_GLrop_PointParameterfEXT 2065
__indirect_glPointParameterfEXT(GLenum pname,GLfloat param)6953 void __indirect_glPointParameterfEXT(GLenum pname, GLfloat param)
6954 {
6955     struct glx_context * const gc = __glXGetCurrentContext();
6956     const GLuint cmdlen = 12;
6957 emit_header(gc->pc, X_GLrop_PointParameterfEXT, cmdlen);
6958 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
6959 (void) memcpy((void *)(gc->pc + 8), (void *)(&param), 4);
6960 gc->pc += cmdlen;
6961 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6962 }
6963 
6964 #define X_GLrop_PointParameterfvEXT 2066
__indirect_glPointParameterfvEXT(GLenum pname,const GLfloat * params)6965 void __indirect_glPointParameterfvEXT(GLenum pname, const GLfloat * params)
6966 {
6967     struct glx_context * const gc = __glXGetCurrentContext();
6968     const GLuint compsize = __glPointParameterfvEXT_size(pname);
6969     const GLuint cmdlen = 8 + __GLX_PAD((compsize * 4));
6970 emit_header(gc->pc, X_GLrop_PointParameterfvEXT, cmdlen);
6971 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
6972 (void) memcpy((void *)(gc->pc + 8), (void *)(params), (compsize * 4));
6973 gc->pc += cmdlen;
6974 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6975 }
6976 
6977 #define X_GLrop_SecondaryColor3bvEXT 4126
__indirect_glSecondaryColor3bEXT(GLbyte red,GLbyte green,GLbyte blue)6978 void __indirect_glSecondaryColor3bEXT(GLbyte red, GLbyte green, GLbyte blue)
6979 {
6980     struct glx_context * const gc = __glXGetCurrentContext();
6981     const GLuint cmdlen = 8;
6982 emit_header(gc->pc, X_GLrop_SecondaryColor3bvEXT, cmdlen);
6983 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 1);
6984 (void) memcpy((void *)(gc->pc + 5), (void *)(&green), 1);
6985 (void) memcpy((void *)(gc->pc + 6), (void *)(&blue), 1);
6986 gc->pc += cmdlen;
6987 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
6988 }
6989 
6990 #define X_GLrop_SecondaryColor3bvEXT 4126
__indirect_glSecondaryColor3bvEXT(const GLbyte * v)6991 void __indirect_glSecondaryColor3bvEXT(const GLbyte * v)
6992 {
6993     generic_3_byte( X_GLrop_SecondaryColor3bvEXT, v );
6994 }
6995 
6996 #define X_GLrop_SecondaryColor3dvEXT 4130
__indirect_glSecondaryColor3dEXT(GLdouble red,GLdouble green,GLdouble blue)6997 void __indirect_glSecondaryColor3dEXT(GLdouble red, GLdouble green, GLdouble blue)
6998 {
6999     struct glx_context * const gc = __glXGetCurrentContext();
7000     const GLuint cmdlen = 28;
7001 emit_header(gc->pc, X_GLrop_SecondaryColor3dvEXT, cmdlen);
7002 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 8);
7003 (void) memcpy((void *)(gc->pc + 12), (void *)(&green), 8);
7004 (void) memcpy((void *)(gc->pc + 20), (void *)(&blue), 8);
7005 gc->pc += cmdlen;
7006 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7007 }
7008 
7009 #define X_GLrop_SecondaryColor3dvEXT 4130
__indirect_glSecondaryColor3dvEXT(const GLdouble * v)7010 void __indirect_glSecondaryColor3dvEXT(const GLdouble * v)
7011 {
7012     generic_24_byte( X_GLrop_SecondaryColor3dvEXT, v );
7013 }
7014 
7015 #define X_GLrop_SecondaryColor3fvEXT 4129
__indirect_glSecondaryColor3fEXT(GLfloat red,GLfloat green,GLfloat blue)7016 void __indirect_glSecondaryColor3fEXT(GLfloat red, GLfloat green, GLfloat blue)
7017 {
7018     struct glx_context * const gc = __glXGetCurrentContext();
7019     const GLuint cmdlen = 16;
7020 emit_header(gc->pc, X_GLrop_SecondaryColor3fvEXT, cmdlen);
7021 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
7022 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
7023 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
7024 gc->pc += cmdlen;
7025 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7026 }
7027 
7028 #define X_GLrop_SecondaryColor3fvEXT 4129
__indirect_glSecondaryColor3fvEXT(const GLfloat * v)7029 void __indirect_glSecondaryColor3fvEXT(const GLfloat * v)
7030 {
7031     generic_12_byte( X_GLrop_SecondaryColor3fvEXT, v );
7032 }
7033 
7034 #define X_GLrop_SecondaryColor3ivEXT 4128
__indirect_glSecondaryColor3iEXT(GLint red,GLint green,GLint blue)7035 void __indirect_glSecondaryColor3iEXT(GLint red, GLint green, GLint blue)
7036 {
7037     struct glx_context * const gc = __glXGetCurrentContext();
7038     const GLuint cmdlen = 16;
7039 emit_header(gc->pc, X_GLrop_SecondaryColor3ivEXT, cmdlen);
7040 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
7041 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
7042 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
7043 gc->pc += cmdlen;
7044 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7045 }
7046 
7047 #define X_GLrop_SecondaryColor3ivEXT 4128
__indirect_glSecondaryColor3ivEXT(const GLint * v)7048 void __indirect_glSecondaryColor3ivEXT(const GLint * v)
7049 {
7050     generic_12_byte( X_GLrop_SecondaryColor3ivEXT, v );
7051 }
7052 
7053 #define X_GLrop_SecondaryColor3svEXT 4127
__indirect_glSecondaryColor3sEXT(GLshort red,GLshort green,GLshort blue)7054 void __indirect_glSecondaryColor3sEXT(GLshort red, GLshort green, GLshort blue)
7055 {
7056     struct glx_context * const gc = __glXGetCurrentContext();
7057     const GLuint cmdlen = 12;
7058 emit_header(gc->pc, X_GLrop_SecondaryColor3svEXT, cmdlen);
7059 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 2);
7060 (void) memcpy((void *)(gc->pc + 6), (void *)(&green), 2);
7061 (void) memcpy((void *)(gc->pc + 8), (void *)(&blue), 2);
7062 gc->pc += cmdlen;
7063 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7064 }
7065 
7066 #define X_GLrop_SecondaryColor3svEXT 4127
__indirect_glSecondaryColor3svEXT(const GLshort * v)7067 void __indirect_glSecondaryColor3svEXT(const GLshort * v)
7068 {
7069     generic_6_byte( X_GLrop_SecondaryColor3svEXT, v );
7070 }
7071 
7072 #define X_GLrop_SecondaryColor3ubvEXT 4131
__indirect_glSecondaryColor3ubEXT(GLubyte red,GLubyte green,GLubyte blue)7073 void __indirect_glSecondaryColor3ubEXT(GLubyte red, GLubyte green, GLubyte blue)
7074 {
7075     struct glx_context * const gc = __glXGetCurrentContext();
7076     const GLuint cmdlen = 8;
7077 emit_header(gc->pc, X_GLrop_SecondaryColor3ubvEXT, cmdlen);
7078 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 1);
7079 (void) memcpy((void *)(gc->pc + 5), (void *)(&green), 1);
7080 (void) memcpy((void *)(gc->pc + 6), (void *)(&blue), 1);
7081 gc->pc += cmdlen;
7082 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7083 }
7084 
7085 #define X_GLrop_SecondaryColor3ubvEXT 4131
__indirect_glSecondaryColor3ubvEXT(const GLubyte * v)7086 void __indirect_glSecondaryColor3ubvEXT(const GLubyte * v)
7087 {
7088     generic_3_byte( X_GLrop_SecondaryColor3ubvEXT, v );
7089 }
7090 
7091 #define X_GLrop_SecondaryColor3uivEXT 4133
__indirect_glSecondaryColor3uiEXT(GLuint red,GLuint green,GLuint blue)7092 void __indirect_glSecondaryColor3uiEXT(GLuint red, GLuint green, GLuint blue)
7093 {
7094     struct glx_context * const gc = __glXGetCurrentContext();
7095     const GLuint cmdlen = 16;
7096 emit_header(gc->pc, X_GLrop_SecondaryColor3uivEXT, cmdlen);
7097 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 4);
7098 (void) memcpy((void *)(gc->pc + 8), (void *)(&green), 4);
7099 (void) memcpy((void *)(gc->pc + 12), (void *)(&blue), 4);
7100 gc->pc += cmdlen;
7101 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7102 }
7103 
7104 #define X_GLrop_SecondaryColor3uivEXT 4133
__indirect_glSecondaryColor3uivEXT(const GLuint * v)7105 void __indirect_glSecondaryColor3uivEXT(const GLuint * v)
7106 {
7107     generic_12_byte( X_GLrop_SecondaryColor3uivEXT, v );
7108 }
7109 
7110 #define X_GLrop_SecondaryColor3usvEXT 4132
__indirect_glSecondaryColor3usEXT(GLushort red,GLushort green,GLushort blue)7111 void __indirect_glSecondaryColor3usEXT(GLushort red, GLushort green, GLushort blue)
7112 {
7113     struct glx_context * const gc = __glXGetCurrentContext();
7114     const GLuint cmdlen = 12;
7115 emit_header(gc->pc, X_GLrop_SecondaryColor3usvEXT, cmdlen);
7116 (void) memcpy((void *)(gc->pc + 4), (void *)(&red), 2);
7117 (void) memcpy((void *)(gc->pc + 6), (void *)(&green), 2);
7118 (void) memcpy((void *)(gc->pc + 8), (void *)(&blue), 2);
7119 gc->pc += cmdlen;
7120 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7121 }
7122 
7123 #define X_GLrop_SecondaryColor3usvEXT 4132
__indirect_glSecondaryColor3usvEXT(const GLushort * v)7124 void __indirect_glSecondaryColor3usvEXT(const GLushort * v)
7125 {
7126     generic_6_byte( X_GLrop_SecondaryColor3usvEXT, v );
7127 }
7128 
7129 #define X_GLrop_FogCoorddvEXT 4125
__indirect_glFogCoorddEXT(GLdouble coord)7130 void __indirect_glFogCoorddEXT(GLdouble coord)
7131 {
7132     struct glx_context * const gc = __glXGetCurrentContext();
7133     const GLuint cmdlen = 12;
7134 emit_header(gc->pc, X_GLrop_FogCoorddvEXT, cmdlen);
7135 (void) memcpy((void *)(gc->pc + 4), (void *)(&coord), 8);
7136 gc->pc += cmdlen;
7137 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7138 }
7139 
7140 #define X_GLrop_FogCoorddvEXT 4125
__indirect_glFogCoorddvEXT(const GLdouble * coord)7141 void __indirect_glFogCoorddvEXT(const GLdouble * coord)
7142 {
7143     generic_8_byte( X_GLrop_FogCoorddvEXT, coord );
7144 }
7145 
7146 #define X_GLrop_FogCoordfvEXT 4124
__indirect_glFogCoordfEXT(GLfloat coord)7147 void __indirect_glFogCoordfEXT(GLfloat coord)
7148 {
7149     struct glx_context * const gc = __glXGetCurrentContext();
7150     const GLuint cmdlen = 8;
7151 emit_header(gc->pc, X_GLrop_FogCoordfvEXT, cmdlen);
7152 (void) memcpy((void *)(gc->pc + 4), (void *)(&coord), 4);
7153 gc->pc += cmdlen;
7154 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7155 }
7156 
7157 #define X_GLrop_FogCoordfvEXT 4124
__indirect_glFogCoordfvEXT(const GLfloat * coord)7158 void __indirect_glFogCoordfvEXT(const GLfloat * coord)
7159 {
7160     generic_4_byte( X_GLrop_FogCoordfvEXT, coord );
7161 }
7162 
7163 #define X_GLrop_BlendFuncSeparateEXT 4134
__indirect_glBlendFuncSeparateEXT(GLenum sfactorRGB,GLenum dfactorRGB,GLenum sfactorAlpha,GLenum dfactorAlpha)7164 void __indirect_glBlendFuncSeparateEXT(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
7165 {
7166     struct glx_context * const gc = __glXGetCurrentContext();
7167     const GLuint cmdlen = 20;
7168 emit_header(gc->pc, X_GLrop_BlendFuncSeparateEXT, cmdlen);
7169 (void) memcpy((void *)(gc->pc + 4), (void *)(&sfactorRGB), 4);
7170 (void) memcpy((void *)(gc->pc + 8), (void *)(&dfactorRGB), 4);
7171 (void) memcpy((void *)(gc->pc + 12), (void *)(&sfactorAlpha), 4);
7172 (void) memcpy((void *)(gc->pc + 16), (void *)(&dfactorAlpha), 4);
7173 gc->pc += cmdlen;
7174 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7175 }
7176 
7177 #define X_GLrop_WindowPos3fvMESA 230
__indirect_glWindowPos3fMESA(GLfloat x,GLfloat y,GLfloat z)7178 void __indirect_glWindowPos3fMESA(GLfloat x, GLfloat y, GLfloat z)
7179 {
7180     struct glx_context * const gc = __glXGetCurrentContext();
7181     const GLuint cmdlen = 16;
7182 emit_header(gc->pc, X_GLrop_WindowPos3fvMESA, cmdlen);
7183 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 4);
7184 (void) memcpy((void *)(gc->pc + 8), (void *)(&y), 4);
7185 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 4);
7186 gc->pc += cmdlen;
7187 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7188 }
7189 
7190 #define X_GLrop_WindowPos3fvMESA 230
__indirect_glWindowPos3fvMESA(const GLfloat * v)7191 void __indirect_glWindowPos3fvMESA(const GLfloat * v)
7192 {
7193     generic_12_byte( X_GLrop_WindowPos3fvMESA, v );
7194 }
7195 
7196 #define X_GLvop_AreProgramsResidentNV 1293
__indirect_glAreProgramsResidentNV(GLsizei n,const GLuint * ids,GLboolean * residences)7197 GLboolean __indirect_glAreProgramsResidentNV(GLsizei n, const GLuint * ids, GLboolean * residences)
7198 {
7199     struct glx_context * const gc = __glXGetCurrentContext();
7200     Display * const dpy = gc->currentDpy;
7201     GLboolean retval = (GLboolean) 0;
7202     const GLuint cmdlen = 4 + __GLX_PAD((n * 4));
7203     if (n < 0) {
7204         __glXSetError(gc, GL_INVALID_VALUE);
7205         return 0;
7206     }
7207     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
7208         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_AreProgramsResidentNV, cmdlen);
7209 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
7210 (void) memcpy((void *)(pc + 4), (void *)(ids), (n * 4));
7211         retval = (GLboolean) __glXReadReply(dpy, 1, residences, GL_FALSE);
7212         UnlockDisplay(dpy); SyncHandle();
7213     }
7214     return retval;
7215 }
7216 
7217 #define X_GLrop_BindProgramNV 4180
__indirect_glBindProgramNV(GLenum target,GLuint program)7218 void __indirect_glBindProgramNV(GLenum target, GLuint program)
7219 {
7220     struct glx_context * const gc = __glXGetCurrentContext();
7221     const GLuint cmdlen = 12;
7222 emit_header(gc->pc, X_GLrop_BindProgramNV, cmdlen);
7223 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
7224 (void) memcpy((void *)(gc->pc + 8), (void *)(&program), 4);
7225 gc->pc += cmdlen;
7226 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7227 }
7228 
7229 #define X_GLvop_DeleteProgramsNV 1294
__indirect_glDeleteProgramsNV(GLsizei n,const GLuint * programs)7230 void __indirect_glDeleteProgramsNV(GLsizei n, const GLuint * programs)
7231 {
7232     struct glx_context * const gc = __glXGetCurrentContext();
7233     Display * const dpy = gc->currentDpy;
7234     const GLuint cmdlen = 4 + __GLX_PAD((n * 4));
7235     if (n < 0) {
7236         __glXSetError(gc, GL_INVALID_VALUE);
7237         return;
7238     }
7239     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
7240         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivate, X_GLvop_DeleteProgramsNV, cmdlen);
7241 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
7242 (void) memcpy((void *)(pc + 4), (void *)(programs), (n * 4));
7243         UnlockDisplay(dpy); SyncHandle();
7244     }
7245     return;
7246 }
7247 
7248 #define X_GLrop_ExecuteProgramNV 4181
__indirect_glExecuteProgramNV(GLenum target,GLuint id,const GLfloat * params)7249 void __indirect_glExecuteProgramNV(GLenum target, GLuint id, const GLfloat * params)
7250 {
7251     struct glx_context * const gc = __glXGetCurrentContext();
7252     const GLuint cmdlen = 28;
7253 emit_header(gc->pc, X_GLrop_ExecuteProgramNV, cmdlen);
7254 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
7255 (void) memcpy((void *)(gc->pc + 8), (void *)(&id), 4);
7256 (void) memcpy((void *)(gc->pc + 12), (void *)(params), 16);
7257 gc->pc += cmdlen;
7258 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7259 }
7260 
7261 #define X_GLvop_GenProgramsNV 1295
__indirect_glGenProgramsNV(GLsizei n,GLuint * programs)7262 void __indirect_glGenProgramsNV(GLsizei n, GLuint * programs)
7263 {
7264     struct glx_context * const gc = __glXGetCurrentContext();
7265     Display * const dpy = gc->currentDpy;
7266     const GLuint cmdlen = 4;
7267     if (n < 0) {
7268         __glXSetError(gc, GL_INVALID_VALUE);
7269         return;
7270     }
7271     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
7272         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GenProgramsNV, cmdlen);
7273 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
7274         (void) __glXReadReply(dpy, 4, programs, GL_TRUE);
7275         UnlockDisplay(dpy); SyncHandle();
7276     }
7277     return;
7278 }
7279 
7280 #define X_GLvop_GetProgramParameterdvNV 1297
__indirect_glGetProgramParameterdvNV(GLenum target,GLuint index,GLenum pname,GLdouble * params)7281 void __indirect_glGetProgramParameterdvNV(GLenum target, GLuint index, GLenum pname, GLdouble * params)
7282 {
7283     struct glx_context * const gc = __glXGetCurrentContext();
7284     Display * const dpy = gc->currentDpy;
7285     const GLuint cmdlen = 12;
7286     if (__builtin_expect(dpy != NULL, 1)) {
7287         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetProgramParameterdvNV, cmdlen);
7288 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
7289 (void) memcpy((void *)(pc + 4), (void *)(&index), 4);
7290 (void) memcpy((void *)(pc + 8), (void *)(&pname), 4);
7291         (void) __glXReadReply(dpy, 8, params, GL_FALSE);
7292         UnlockDisplay(dpy); SyncHandle();
7293     }
7294     return;
7295 }
7296 
7297 #define X_GLvop_GetProgramParameterfvNV 1296
__indirect_glGetProgramParameterfvNV(GLenum target,GLuint index,GLenum pname,GLfloat * params)7298 void __indirect_glGetProgramParameterfvNV(GLenum target, GLuint index, GLenum pname, GLfloat * params)
7299 {
7300     struct glx_context * const gc = __glXGetCurrentContext();
7301     Display * const dpy = gc->currentDpy;
7302     const GLuint cmdlen = 12;
7303     if (__builtin_expect(dpy != NULL, 1)) {
7304         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetProgramParameterfvNV, cmdlen);
7305 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
7306 (void) memcpy((void *)(pc + 4), (void *)(&index), 4);
7307 (void) memcpy((void *)(pc + 8), (void *)(&pname), 4);
7308         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
7309         UnlockDisplay(dpy); SyncHandle();
7310     }
7311     return;
7312 }
7313 
7314 #define X_GLvop_GetProgramStringNV 1299
__indirect_glGetProgramStringNV(GLuint id,GLenum pname,GLubyte * program)7315 void __indirect_glGetProgramStringNV(GLuint id, GLenum pname, GLubyte * program)
7316 {
7317     struct glx_context * const gc = __glXGetCurrentContext();
7318     Display * const dpy = gc->currentDpy;
7319     const GLuint cmdlen = 8;
7320     if (__builtin_expect(dpy != NULL, 1)) {
7321         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetProgramStringNV, cmdlen);
7322 (void) memcpy((void *)(pc + 0), (void *)(&id), 4);
7323 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
7324         (void) __glXReadReply(dpy, 1, program, GL_TRUE);
7325         UnlockDisplay(dpy); SyncHandle();
7326     }
7327     return;
7328 }
7329 
7330 #define X_GLvop_GetProgramivNV 1298
__indirect_glGetProgramivNV(GLuint id,GLenum pname,GLint * params)7331 void __indirect_glGetProgramivNV(GLuint id, GLenum pname, GLint * params)
7332 {
7333     struct glx_context * const gc = __glXGetCurrentContext();
7334     Display * const dpy = gc->currentDpy;
7335     const GLuint cmdlen = 8;
7336     if (__builtin_expect(dpy != NULL, 1)) {
7337         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetProgramivNV, cmdlen);
7338 (void) memcpy((void *)(pc + 0), (void *)(&id), 4);
7339 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
7340         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
7341         UnlockDisplay(dpy); SyncHandle();
7342     }
7343     return;
7344 }
7345 
7346 #define X_GLvop_GetTrackMatrixivNV 1300
__indirect_glGetTrackMatrixivNV(GLenum target,GLuint address,GLenum pname,GLint * params)7347 void __indirect_glGetTrackMatrixivNV(GLenum target, GLuint address, GLenum pname, GLint * params)
7348 {
7349     struct glx_context * const gc = __glXGetCurrentContext();
7350     Display * const dpy = gc->currentDpy;
7351     const GLuint cmdlen = 12;
7352     if (__builtin_expect(dpy != NULL, 1)) {
7353         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetTrackMatrixivNV, cmdlen);
7354 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
7355 (void) memcpy((void *)(pc + 4), (void *)(&address), 4);
7356 (void) memcpy((void *)(pc + 8), (void *)(&pname), 4);
7357         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
7358         UnlockDisplay(dpy); SyncHandle();
7359     }
7360     return;
7361 }
7362 
7363 #define X_GLvop_GetVertexAttribdvNV 1301
__indirect_glGetVertexAttribdvNV(GLuint index,GLenum pname,GLdouble * params)7364 void __indirect_glGetVertexAttribdvNV(GLuint index, GLenum pname, GLdouble * params)
7365 {
7366     struct glx_context * const gc = __glXGetCurrentContext();
7367     Display * const dpy = gc->currentDpy;
7368     const GLuint cmdlen = 8;
7369     if (__builtin_expect(dpy != NULL, 1)) {
7370         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetVertexAttribdvNV, cmdlen);
7371 (void) memcpy((void *)(pc + 0), (void *)(&index), 4);
7372 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
7373         (void) __glXReadReply(dpy, 8, params, GL_FALSE);
7374         UnlockDisplay(dpy); SyncHandle();
7375     }
7376     return;
7377 }
7378 
7379 #define X_GLvop_GetVertexAttribfvNV 1302
__indirect_glGetVertexAttribfvNV(GLuint index,GLenum pname,GLfloat * params)7380 void __indirect_glGetVertexAttribfvNV(GLuint index, GLenum pname, GLfloat * params)
7381 {
7382     struct glx_context * const gc = __glXGetCurrentContext();
7383     Display * const dpy = gc->currentDpy;
7384     const GLuint cmdlen = 8;
7385     if (__builtin_expect(dpy != NULL, 1)) {
7386         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetVertexAttribfvNV, cmdlen);
7387 (void) memcpy((void *)(pc + 0), (void *)(&index), 4);
7388 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
7389         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
7390         UnlockDisplay(dpy); SyncHandle();
7391     }
7392     return;
7393 }
7394 
7395 #define X_GLvop_GetVertexAttribivNV 1303
__indirect_glGetVertexAttribivNV(GLuint index,GLenum pname,GLint * params)7396 void __indirect_glGetVertexAttribivNV(GLuint index, GLenum pname, GLint * params)
7397 {
7398     struct glx_context * const gc = __glXGetCurrentContext();
7399     Display * const dpy = gc->currentDpy;
7400     const GLuint cmdlen = 8;
7401     if (__builtin_expect(dpy != NULL, 1)) {
7402         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetVertexAttribivNV, cmdlen);
7403 (void) memcpy((void *)(pc + 0), (void *)(&index), 4);
7404 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
7405         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
7406         UnlockDisplay(dpy); SyncHandle();
7407     }
7408     return;
7409 }
7410 
7411 #define X_GLvop_IsProgramNV 1304
__indirect_glIsProgramNV(GLuint program)7412 GLboolean __indirect_glIsProgramNV(GLuint program)
7413 {
7414     struct glx_context * const gc = __glXGetCurrentContext();
7415     Display * const dpy = gc->currentDpy;
7416     GLboolean retval = (GLboolean) 0;
7417     const GLuint cmdlen = 4;
7418     if (__builtin_expect(dpy != NULL, 1)) {
7419         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_IsProgramNV, cmdlen);
7420 (void) memcpy((void *)(pc + 0), (void *)(&program), 4);
7421         retval = (GLboolean) __glXReadReply(dpy, 0, NULL, GL_FALSE);
7422         UnlockDisplay(dpy); SyncHandle();
7423     }
7424     return retval;
7425 }
7426 
7427 #define X_GLrop_LoadProgramNV 4183
__indirect_glLoadProgramNV(GLenum target,GLuint id,GLsizei len,const GLubyte * program)7428 void __indirect_glLoadProgramNV(GLenum target, GLuint id, GLsizei len, const GLubyte * program)
7429 {
7430     struct glx_context * const gc = __glXGetCurrentContext();
7431     const GLuint cmdlen = 16 + __GLX_PAD(len);
7432     if (len < 0) {
7433         __glXSetError(gc, GL_INVALID_VALUE);
7434         return;
7435     }
7436     if (__builtin_expect(len >= 0, 1)) {
7437 emit_header(gc->pc, X_GLrop_LoadProgramNV, cmdlen);
7438 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
7439 (void) memcpy((void *)(gc->pc + 8), (void *)(&id), 4);
7440 (void) memcpy((void *)(gc->pc + 12), (void *)(&len), 4);
7441 (void) memcpy((void *)(gc->pc + 16), (void *)(program), len);
7442 gc->pc += cmdlen;
7443 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7444     }
7445 }
7446 
7447 #define X_GLrop_ProgramParameters4dvNV 4187
__indirect_glProgramParameters4dvNV(GLenum target,GLuint index,GLsizei num,const GLdouble * params)7448 void __indirect_glProgramParameters4dvNV(GLenum target, GLuint index, GLsizei num, const GLdouble * params)
7449 {
7450     struct glx_context * const gc = __glXGetCurrentContext();
7451     const GLuint cmdlen = 16 + __GLX_PAD((num * 32));
7452     if (num < 0) {
7453         __glXSetError(gc, GL_INVALID_VALUE);
7454         return;
7455     }
7456     if (__builtin_expect(num >= 0, 1)) {
7457 emit_header(gc->pc, X_GLrop_ProgramParameters4dvNV, cmdlen);
7458 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
7459 (void) memcpy((void *)(gc->pc + 8), (void *)(&index), 4);
7460 (void) memcpy((void *)(gc->pc + 12), (void *)(&num), 4);
7461 (void) memcpy((void *)(gc->pc + 16), (void *)(params), (num * 32));
7462 gc->pc += cmdlen;
7463 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7464     }
7465 }
7466 
7467 #define X_GLrop_ProgramParameters4fvNV 4186
__indirect_glProgramParameters4fvNV(GLenum target,GLuint index,GLsizei num,const GLfloat * params)7468 void __indirect_glProgramParameters4fvNV(GLenum target, GLuint index, GLsizei num, const GLfloat * params)
7469 {
7470     struct glx_context * const gc = __glXGetCurrentContext();
7471     const GLuint cmdlen = 16 + __GLX_PAD((num * 16));
7472     if (num < 0) {
7473         __glXSetError(gc, GL_INVALID_VALUE);
7474         return;
7475     }
7476     if (__builtin_expect(num >= 0, 1)) {
7477 emit_header(gc->pc, X_GLrop_ProgramParameters4fvNV, cmdlen);
7478 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
7479 (void) memcpy((void *)(gc->pc + 8), (void *)(&index), 4);
7480 (void) memcpy((void *)(gc->pc + 12), (void *)(&num), 4);
7481 (void) memcpy((void *)(gc->pc + 16), (void *)(params), (num * 16));
7482 gc->pc += cmdlen;
7483 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7484     }
7485 }
7486 
7487 #define X_GLrop_RequestResidentProgramsNV 4182
__indirect_glRequestResidentProgramsNV(GLsizei n,const GLuint * ids)7488 void __indirect_glRequestResidentProgramsNV(GLsizei n, const GLuint * ids)
7489 {
7490     struct glx_context * const gc = __glXGetCurrentContext();
7491     const GLuint cmdlen = 8 + __GLX_PAD((n * 4));
7492     if (n < 0) {
7493         __glXSetError(gc, GL_INVALID_VALUE);
7494         return;
7495     }
7496     if (__builtin_expect(n >= 0, 1)) {
7497 emit_header(gc->pc, X_GLrop_RequestResidentProgramsNV, cmdlen);
7498 (void) memcpy((void *)(gc->pc + 4), (void *)(&n), 4);
7499 (void) memcpy((void *)(gc->pc + 8), (void *)(ids), (n * 4));
7500 gc->pc += cmdlen;
7501 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7502     }
7503 }
7504 
7505 #define X_GLrop_TrackMatrixNV 4188
__indirect_glTrackMatrixNV(GLenum target,GLuint address,GLenum matrix,GLenum transform)7506 void __indirect_glTrackMatrixNV(GLenum target, GLuint address, GLenum matrix, GLenum transform)
7507 {
7508     struct glx_context * const gc = __glXGetCurrentContext();
7509     const GLuint cmdlen = 20;
7510 emit_header(gc->pc, X_GLrop_TrackMatrixNV, cmdlen);
7511 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
7512 (void) memcpy((void *)(gc->pc + 8), (void *)(&address), 4);
7513 (void) memcpy((void *)(gc->pc + 12), (void *)(&matrix), 4);
7514 (void) memcpy((void *)(gc->pc + 16), (void *)(&transform), 4);
7515 gc->pc += cmdlen;
7516 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7517 }
7518 
7519 #define X_GLrop_VertexAttrib1dvNV 4273
__indirect_glVertexAttrib1dNV(GLuint index,GLdouble x)7520 void __indirect_glVertexAttrib1dNV(GLuint index, GLdouble x)
7521 {
7522     struct glx_context * const gc = __glXGetCurrentContext();
7523     const GLuint cmdlen = 16;
7524 emit_header(gc->pc, X_GLrop_VertexAttrib1dvNV, cmdlen);
7525 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7526 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 8);
7527 gc->pc += cmdlen;
7528 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7529 }
7530 
7531 #define X_GLrop_VertexAttrib1dvNV 4273
__indirect_glVertexAttrib1dvNV(GLuint index,const GLdouble * v)7532 void __indirect_glVertexAttrib1dvNV(GLuint index, const GLdouble * v)
7533 {
7534     struct glx_context * const gc = __glXGetCurrentContext();
7535     const GLuint cmdlen = 16;
7536 emit_header(gc->pc, X_GLrop_VertexAttrib1dvNV, cmdlen);
7537 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7538 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
7539 gc->pc += cmdlen;
7540 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7541 }
7542 
7543 #define X_GLrop_VertexAttrib1fvNV 4269
__indirect_glVertexAttrib1fNV(GLuint index,GLfloat x)7544 void __indirect_glVertexAttrib1fNV(GLuint index, GLfloat x)
7545 {
7546     struct glx_context * const gc = __glXGetCurrentContext();
7547     const GLuint cmdlen = 12;
7548 emit_header(gc->pc, X_GLrop_VertexAttrib1fvNV, cmdlen);
7549 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7550 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 4);
7551 gc->pc += cmdlen;
7552 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7553 }
7554 
7555 #define X_GLrop_VertexAttrib1fvNV 4269
__indirect_glVertexAttrib1fvNV(GLuint index,const GLfloat * v)7556 void __indirect_glVertexAttrib1fvNV(GLuint index, const GLfloat * v)
7557 {
7558     struct glx_context * const gc = __glXGetCurrentContext();
7559     const GLuint cmdlen = 12;
7560 emit_header(gc->pc, X_GLrop_VertexAttrib1fvNV, cmdlen);
7561 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7562 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
7563 gc->pc += cmdlen;
7564 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7565 }
7566 
7567 #define X_GLrop_VertexAttrib1svNV 4265
__indirect_glVertexAttrib1sNV(GLuint index,GLshort x)7568 void __indirect_glVertexAttrib1sNV(GLuint index, GLshort x)
7569 {
7570     struct glx_context * const gc = __glXGetCurrentContext();
7571     const GLuint cmdlen = 12;
7572 emit_header(gc->pc, X_GLrop_VertexAttrib1svNV, cmdlen);
7573 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7574 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 2);
7575 gc->pc += cmdlen;
7576 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7577 }
7578 
7579 #define X_GLrop_VertexAttrib1svNV 4265
__indirect_glVertexAttrib1svNV(GLuint index,const GLshort * v)7580 void __indirect_glVertexAttrib1svNV(GLuint index, const GLshort * v)
7581 {
7582     struct glx_context * const gc = __glXGetCurrentContext();
7583     const GLuint cmdlen = 12;
7584 emit_header(gc->pc, X_GLrop_VertexAttrib1svNV, cmdlen);
7585 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7586 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 2);
7587 gc->pc += cmdlen;
7588 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7589 }
7590 
7591 #define X_GLrop_VertexAttrib2dvNV 4274
__indirect_glVertexAttrib2dNV(GLuint index,GLdouble x,GLdouble y)7592 void __indirect_glVertexAttrib2dNV(GLuint index, GLdouble x, GLdouble y)
7593 {
7594     struct glx_context * const gc = __glXGetCurrentContext();
7595     const GLuint cmdlen = 24;
7596 emit_header(gc->pc, X_GLrop_VertexAttrib2dvNV, cmdlen);
7597 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7598 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 8);
7599 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 8);
7600 gc->pc += cmdlen;
7601 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7602 }
7603 
7604 #define X_GLrop_VertexAttrib2dvNV 4274
__indirect_glVertexAttrib2dvNV(GLuint index,const GLdouble * v)7605 void __indirect_glVertexAttrib2dvNV(GLuint index, const GLdouble * v)
7606 {
7607     struct glx_context * const gc = __glXGetCurrentContext();
7608     const GLuint cmdlen = 24;
7609 emit_header(gc->pc, X_GLrop_VertexAttrib2dvNV, cmdlen);
7610 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7611 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 16);
7612 gc->pc += cmdlen;
7613 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7614 }
7615 
7616 #define X_GLrop_VertexAttrib2fvNV 4270
__indirect_glVertexAttrib2fNV(GLuint index,GLfloat x,GLfloat y)7617 void __indirect_glVertexAttrib2fNV(GLuint index, GLfloat x, GLfloat y)
7618 {
7619     struct glx_context * const gc = __glXGetCurrentContext();
7620     const GLuint cmdlen = 16;
7621 emit_header(gc->pc, X_GLrop_VertexAttrib2fvNV, cmdlen);
7622 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7623 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 4);
7624 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 4);
7625 gc->pc += cmdlen;
7626 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7627 }
7628 
7629 #define X_GLrop_VertexAttrib2fvNV 4270
__indirect_glVertexAttrib2fvNV(GLuint index,const GLfloat * v)7630 void __indirect_glVertexAttrib2fvNV(GLuint index, const GLfloat * v)
7631 {
7632     struct glx_context * const gc = __glXGetCurrentContext();
7633     const GLuint cmdlen = 16;
7634 emit_header(gc->pc, X_GLrop_VertexAttrib2fvNV, cmdlen);
7635 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7636 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
7637 gc->pc += cmdlen;
7638 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7639 }
7640 
7641 #define X_GLrop_VertexAttrib2svNV 4266
__indirect_glVertexAttrib2sNV(GLuint index,GLshort x,GLshort y)7642 void __indirect_glVertexAttrib2sNV(GLuint index, GLshort x, GLshort y)
7643 {
7644     struct glx_context * const gc = __glXGetCurrentContext();
7645     const GLuint cmdlen = 12;
7646 emit_header(gc->pc, X_GLrop_VertexAttrib2svNV, cmdlen);
7647 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7648 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 2);
7649 (void) memcpy((void *)(gc->pc + 10), (void *)(&y), 2);
7650 gc->pc += cmdlen;
7651 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7652 }
7653 
7654 #define X_GLrop_VertexAttrib2svNV 4266
__indirect_glVertexAttrib2svNV(GLuint index,const GLshort * v)7655 void __indirect_glVertexAttrib2svNV(GLuint index, const GLshort * v)
7656 {
7657     struct glx_context * const gc = __glXGetCurrentContext();
7658     const GLuint cmdlen = 12;
7659 emit_header(gc->pc, X_GLrop_VertexAttrib2svNV, cmdlen);
7660 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7661 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
7662 gc->pc += cmdlen;
7663 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7664 }
7665 
7666 #define X_GLrop_VertexAttrib3dvNV 4275
__indirect_glVertexAttrib3dNV(GLuint index,GLdouble x,GLdouble y,GLdouble z)7667 void __indirect_glVertexAttrib3dNV(GLuint index, GLdouble x, GLdouble y, GLdouble z)
7668 {
7669     struct glx_context * const gc = __glXGetCurrentContext();
7670     const GLuint cmdlen = 32;
7671 emit_header(gc->pc, X_GLrop_VertexAttrib3dvNV, cmdlen);
7672 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7673 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 8);
7674 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 8);
7675 (void) memcpy((void *)(gc->pc + 24), (void *)(&z), 8);
7676 gc->pc += cmdlen;
7677 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7678 }
7679 
7680 #define X_GLrop_VertexAttrib3dvNV 4275
__indirect_glVertexAttrib3dvNV(GLuint index,const GLdouble * v)7681 void __indirect_glVertexAttrib3dvNV(GLuint index, const GLdouble * v)
7682 {
7683     struct glx_context * const gc = __glXGetCurrentContext();
7684     const GLuint cmdlen = 32;
7685 emit_header(gc->pc, X_GLrop_VertexAttrib3dvNV, cmdlen);
7686 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7687 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 24);
7688 gc->pc += cmdlen;
7689 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7690 }
7691 
7692 #define X_GLrop_VertexAttrib3fvNV 4271
__indirect_glVertexAttrib3fNV(GLuint index,GLfloat x,GLfloat y,GLfloat z)7693 void __indirect_glVertexAttrib3fNV(GLuint index, GLfloat x, GLfloat y, GLfloat z)
7694 {
7695     struct glx_context * const gc = __glXGetCurrentContext();
7696     const GLuint cmdlen = 20;
7697 emit_header(gc->pc, X_GLrop_VertexAttrib3fvNV, cmdlen);
7698 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7699 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 4);
7700 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 4);
7701 (void) memcpy((void *)(gc->pc + 16), (void *)(&z), 4);
7702 gc->pc += cmdlen;
7703 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7704 }
7705 
7706 #define X_GLrop_VertexAttrib3fvNV 4271
__indirect_glVertexAttrib3fvNV(GLuint index,const GLfloat * v)7707 void __indirect_glVertexAttrib3fvNV(GLuint index, const GLfloat * v)
7708 {
7709     struct glx_context * const gc = __glXGetCurrentContext();
7710     const GLuint cmdlen = 20;
7711 emit_header(gc->pc, X_GLrop_VertexAttrib3fvNV, cmdlen);
7712 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7713 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 12);
7714 gc->pc += cmdlen;
7715 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7716 }
7717 
7718 #define X_GLrop_VertexAttrib3svNV 4267
__indirect_glVertexAttrib3sNV(GLuint index,GLshort x,GLshort y,GLshort z)7719 void __indirect_glVertexAttrib3sNV(GLuint index, GLshort x, GLshort y, GLshort z)
7720 {
7721     struct glx_context * const gc = __glXGetCurrentContext();
7722     const GLuint cmdlen = 16;
7723 emit_header(gc->pc, X_GLrop_VertexAttrib3svNV, cmdlen);
7724 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7725 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 2);
7726 (void) memcpy((void *)(gc->pc + 10), (void *)(&y), 2);
7727 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 2);
7728 gc->pc += cmdlen;
7729 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7730 }
7731 
7732 #define X_GLrop_VertexAttrib3svNV 4267
__indirect_glVertexAttrib3svNV(GLuint index,const GLshort * v)7733 void __indirect_glVertexAttrib3svNV(GLuint index, const GLshort * v)
7734 {
7735     struct glx_context * const gc = __glXGetCurrentContext();
7736     const GLuint cmdlen = 16;
7737 emit_header(gc->pc, X_GLrop_VertexAttrib3svNV, cmdlen);
7738 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7739 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 6);
7740 gc->pc += cmdlen;
7741 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7742 }
7743 
7744 #define X_GLrop_VertexAttrib4dvNV 4276
__indirect_glVertexAttrib4dNV(GLuint index,GLdouble x,GLdouble y,GLdouble z,GLdouble w)7745 void __indirect_glVertexAttrib4dNV(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
7746 {
7747     struct glx_context * const gc = __glXGetCurrentContext();
7748     const GLuint cmdlen = 40;
7749 emit_header(gc->pc, X_GLrop_VertexAttrib4dvNV, cmdlen);
7750 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7751 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 8);
7752 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 8);
7753 (void) memcpy((void *)(gc->pc + 24), (void *)(&z), 8);
7754 (void) memcpy((void *)(gc->pc + 32), (void *)(&w), 8);
7755 gc->pc += cmdlen;
7756 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7757 }
7758 
7759 #define X_GLrop_VertexAttrib4dvNV 4276
__indirect_glVertexAttrib4dvNV(GLuint index,const GLdouble * v)7760 void __indirect_glVertexAttrib4dvNV(GLuint index, const GLdouble * v)
7761 {
7762     struct glx_context * const gc = __glXGetCurrentContext();
7763     const GLuint cmdlen = 40;
7764 emit_header(gc->pc, X_GLrop_VertexAttrib4dvNV, cmdlen);
7765 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7766 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 32);
7767 gc->pc += cmdlen;
7768 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7769 }
7770 
7771 #define X_GLrop_VertexAttrib4fvNV 4272
__indirect_glVertexAttrib4fNV(GLuint index,GLfloat x,GLfloat y,GLfloat z,GLfloat w)7772 void __indirect_glVertexAttrib4fNV(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
7773 {
7774     struct glx_context * const gc = __glXGetCurrentContext();
7775     const GLuint cmdlen = 24;
7776 emit_header(gc->pc, X_GLrop_VertexAttrib4fvNV, cmdlen);
7777 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7778 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 4);
7779 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 4);
7780 (void) memcpy((void *)(gc->pc + 16), (void *)(&z), 4);
7781 (void) memcpy((void *)(gc->pc + 20), (void *)(&w), 4);
7782 gc->pc += cmdlen;
7783 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7784 }
7785 
7786 #define X_GLrop_VertexAttrib4fvNV 4272
__indirect_glVertexAttrib4fvNV(GLuint index,const GLfloat * v)7787 void __indirect_glVertexAttrib4fvNV(GLuint index, const GLfloat * v)
7788 {
7789     struct glx_context * const gc = __glXGetCurrentContext();
7790     const GLuint cmdlen = 24;
7791 emit_header(gc->pc, X_GLrop_VertexAttrib4fvNV, cmdlen);
7792 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7793 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 16);
7794 gc->pc += cmdlen;
7795 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7796 }
7797 
7798 #define X_GLrop_VertexAttrib4svNV 4268
__indirect_glVertexAttrib4sNV(GLuint index,GLshort x,GLshort y,GLshort z,GLshort w)7799 void __indirect_glVertexAttrib4sNV(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
7800 {
7801     struct glx_context * const gc = __glXGetCurrentContext();
7802     const GLuint cmdlen = 16;
7803 emit_header(gc->pc, X_GLrop_VertexAttrib4svNV, cmdlen);
7804 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7805 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 2);
7806 (void) memcpy((void *)(gc->pc + 10), (void *)(&y), 2);
7807 (void) memcpy((void *)(gc->pc + 12), (void *)(&z), 2);
7808 (void) memcpy((void *)(gc->pc + 14), (void *)(&w), 2);
7809 gc->pc += cmdlen;
7810 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7811 }
7812 
7813 #define X_GLrop_VertexAttrib4svNV 4268
__indirect_glVertexAttrib4svNV(GLuint index,const GLshort * v)7814 void __indirect_glVertexAttrib4svNV(GLuint index, const GLshort * v)
7815 {
7816     struct glx_context * const gc = __glXGetCurrentContext();
7817     const GLuint cmdlen = 16;
7818 emit_header(gc->pc, X_GLrop_VertexAttrib4svNV, cmdlen);
7819 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7820 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 8);
7821 gc->pc += cmdlen;
7822 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7823 }
7824 
7825 #define X_GLrop_VertexAttrib4ubvNV 4277
__indirect_glVertexAttrib4ubNV(GLuint index,GLubyte x,GLubyte y,GLubyte z,GLubyte w)7826 void __indirect_glVertexAttrib4ubNV(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
7827 {
7828     struct glx_context * const gc = __glXGetCurrentContext();
7829     const GLuint cmdlen = 12;
7830 emit_header(gc->pc, X_GLrop_VertexAttrib4ubvNV, cmdlen);
7831 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7832 (void) memcpy((void *)(gc->pc + 8), (void *)(&x), 1);
7833 (void) memcpy((void *)(gc->pc + 9), (void *)(&y), 1);
7834 (void) memcpy((void *)(gc->pc + 10), (void *)(&z), 1);
7835 (void) memcpy((void *)(gc->pc + 11), (void *)(&w), 1);
7836 gc->pc += cmdlen;
7837 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7838 }
7839 
7840 #define X_GLrop_VertexAttrib4ubvNV 4277
__indirect_glVertexAttrib4ubvNV(GLuint index,const GLubyte * v)7841 void __indirect_glVertexAttrib4ubvNV(GLuint index, const GLubyte * v)
7842 {
7843     struct glx_context * const gc = __glXGetCurrentContext();
7844     const GLuint cmdlen = 12;
7845 emit_header(gc->pc, X_GLrop_VertexAttrib4ubvNV, cmdlen);
7846 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7847 (void) memcpy((void *)(gc->pc + 8), (void *)(v), 4);
7848 gc->pc += cmdlen;
7849 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7850 }
7851 
7852 #define X_GLrop_VertexAttribs1dvNV 4210
__indirect_glVertexAttribs1dvNV(GLuint index,GLsizei n,const GLdouble * v)7853 void __indirect_glVertexAttribs1dvNV(GLuint index, GLsizei n, const GLdouble * v)
7854 {
7855     struct glx_context * const gc = __glXGetCurrentContext();
7856     const GLuint cmdlen = 12 + __GLX_PAD((n * 8));
7857     if (n < 0) {
7858         __glXSetError(gc, GL_INVALID_VALUE);
7859         return;
7860     }
7861     if (__builtin_expect(n >= 0, 1)) {
7862 emit_header(gc->pc, X_GLrop_VertexAttribs1dvNV, cmdlen);
7863 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7864 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
7865 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 8));
7866 gc->pc += cmdlen;
7867 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7868     }
7869 }
7870 
7871 #define X_GLrop_VertexAttribs1fvNV 4206
__indirect_glVertexAttribs1fvNV(GLuint index,GLsizei n,const GLfloat * v)7872 void __indirect_glVertexAttribs1fvNV(GLuint index, GLsizei n, const GLfloat * v)
7873 {
7874     struct glx_context * const gc = __glXGetCurrentContext();
7875     const GLuint cmdlen = 12 + __GLX_PAD((n * 4));
7876     if (n < 0) {
7877         __glXSetError(gc, GL_INVALID_VALUE);
7878         return;
7879     }
7880     if (__builtin_expect(n >= 0, 1)) {
7881 emit_header(gc->pc, X_GLrop_VertexAttribs1fvNV, cmdlen);
7882 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7883 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
7884 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 4));
7885 gc->pc += cmdlen;
7886 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7887     }
7888 }
7889 
7890 #define X_GLrop_VertexAttribs1svNV 4202
__indirect_glVertexAttribs1svNV(GLuint index,GLsizei n,const GLshort * v)7891 void __indirect_glVertexAttribs1svNV(GLuint index, GLsizei n, const GLshort * v)
7892 {
7893     struct glx_context * const gc = __glXGetCurrentContext();
7894     const GLuint cmdlen = 12 + __GLX_PAD((n * 2));
7895     if (n < 0) {
7896         __glXSetError(gc, GL_INVALID_VALUE);
7897         return;
7898     }
7899     if (__builtin_expect(n >= 0, 1)) {
7900 emit_header(gc->pc, X_GLrop_VertexAttribs1svNV, cmdlen);
7901 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7902 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
7903 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 2));
7904 gc->pc += cmdlen;
7905 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7906     }
7907 }
7908 
7909 #define X_GLrop_VertexAttribs2dvNV 4211
__indirect_glVertexAttribs2dvNV(GLuint index,GLsizei n,const GLdouble * v)7910 void __indirect_glVertexAttribs2dvNV(GLuint index, GLsizei n, const GLdouble * v)
7911 {
7912     struct glx_context * const gc = __glXGetCurrentContext();
7913     const GLuint cmdlen = 12 + __GLX_PAD((n * 16));
7914     if (n < 0) {
7915         __glXSetError(gc, GL_INVALID_VALUE);
7916         return;
7917     }
7918     if (__builtin_expect(n >= 0, 1)) {
7919 emit_header(gc->pc, X_GLrop_VertexAttribs2dvNV, cmdlen);
7920 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7921 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
7922 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 16));
7923 gc->pc += cmdlen;
7924 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7925     }
7926 }
7927 
7928 #define X_GLrop_VertexAttribs2fvNV 4207
__indirect_glVertexAttribs2fvNV(GLuint index,GLsizei n,const GLfloat * v)7929 void __indirect_glVertexAttribs2fvNV(GLuint index, GLsizei n, const GLfloat * v)
7930 {
7931     struct glx_context * const gc = __glXGetCurrentContext();
7932     const GLuint cmdlen = 12 + __GLX_PAD((n * 8));
7933     if (n < 0) {
7934         __glXSetError(gc, GL_INVALID_VALUE);
7935         return;
7936     }
7937     if (__builtin_expect(n >= 0, 1)) {
7938 emit_header(gc->pc, X_GLrop_VertexAttribs2fvNV, cmdlen);
7939 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7940 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
7941 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 8));
7942 gc->pc += cmdlen;
7943 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7944     }
7945 }
7946 
7947 #define X_GLrop_VertexAttribs2svNV 4203
__indirect_glVertexAttribs2svNV(GLuint index,GLsizei n,const GLshort * v)7948 void __indirect_glVertexAttribs2svNV(GLuint index, GLsizei n, const GLshort * v)
7949 {
7950     struct glx_context * const gc = __glXGetCurrentContext();
7951     const GLuint cmdlen = 12 + __GLX_PAD((n * 4));
7952     if (n < 0) {
7953         __glXSetError(gc, GL_INVALID_VALUE);
7954         return;
7955     }
7956     if (__builtin_expect(n >= 0, 1)) {
7957 emit_header(gc->pc, X_GLrop_VertexAttribs2svNV, cmdlen);
7958 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7959 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
7960 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 4));
7961 gc->pc += cmdlen;
7962 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7963     }
7964 }
7965 
7966 #define X_GLrop_VertexAttribs3dvNV 4212
__indirect_glVertexAttribs3dvNV(GLuint index,GLsizei n,const GLdouble * v)7967 void __indirect_glVertexAttribs3dvNV(GLuint index, GLsizei n, const GLdouble * v)
7968 {
7969     struct glx_context * const gc = __glXGetCurrentContext();
7970     const GLuint cmdlen = 12 + __GLX_PAD((n * 24));
7971     if (n < 0) {
7972         __glXSetError(gc, GL_INVALID_VALUE);
7973         return;
7974     }
7975     if (__builtin_expect(n >= 0, 1)) {
7976 emit_header(gc->pc, X_GLrop_VertexAttribs3dvNV, cmdlen);
7977 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7978 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
7979 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 24));
7980 gc->pc += cmdlen;
7981 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
7982     }
7983 }
7984 
7985 #define X_GLrop_VertexAttribs3fvNV 4208
__indirect_glVertexAttribs3fvNV(GLuint index,GLsizei n,const GLfloat * v)7986 void __indirect_glVertexAttribs3fvNV(GLuint index, GLsizei n, const GLfloat * v)
7987 {
7988     struct glx_context * const gc = __glXGetCurrentContext();
7989     const GLuint cmdlen = 12 + __GLX_PAD((n * 12));
7990     if (n < 0) {
7991         __glXSetError(gc, GL_INVALID_VALUE);
7992         return;
7993     }
7994     if (__builtin_expect(n >= 0, 1)) {
7995 emit_header(gc->pc, X_GLrop_VertexAttribs3fvNV, cmdlen);
7996 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
7997 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
7998 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 12));
7999 gc->pc += cmdlen;
8000 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8001     }
8002 }
8003 
8004 #define X_GLrop_VertexAttribs3svNV 4204
__indirect_glVertexAttribs3svNV(GLuint index,GLsizei n,const GLshort * v)8005 void __indirect_glVertexAttribs3svNV(GLuint index, GLsizei n, const GLshort * v)
8006 {
8007     struct glx_context * const gc = __glXGetCurrentContext();
8008     const GLuint cmdlen = 12 + __GLX_PAD((n * 6));
8009     if (n < 0) {
8010         __glXSetError(gc, GL_INVALID_VALUE);
8011         return;
8012     }
8013     if (__builtin_expect(n >= 0, 1)) {
8014 emit_header(gc->pc, X_GLrop_VertexAttribs3svNV, cmdlen);
8015 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
8016 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
8017 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 6));
8018 gc->pc += cmdlen;
8019 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8020     }
8021 }
8022 
8023 #define X_GLrop_VertexAttribs4dvNV 4213
__indirect_glVertexAttribs4dvNV(GLuint index,GLsizei n,const GLdouble * v)8024 void __indirect_glVertexAttribs4dvNV(GLuint index, GLsizei n, const GLdouble * v)
8025 {
8026     struct glx_context * const gc = __glXGetCurrentContext();
8027     const GLuint cmdlen = 12 + __GLX_PAD((n * 32));
8028     if (n < 0) {
8029         __glXSetError(gc, GL_INVALID_VALUE);
8030         return;
8031     }
8032     if (__builtin_expect(n >= 0, 1)) {
8033 emit_header(gc->pc, X_GLrop_VertexAttribs4dvNV, cmdlen);
8034 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
8035 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
8036 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 32));
8037 gc->pc += cmdlen;
8038 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8039     }
8040 }
8041 
8042 #define X_GLrop_VertexAttribs4fvNV 4209
__indirect_glVertexAttribs4fvNV(GLuint index,GLsizei n,const GLfloat * v)8043 void __indirect_glVertexAttribs4fvNV(GLuint index, GLsizei n, const GLfloat * v)
8044 {
8045     struct glx_context * const gc = __glXGetCurrentContext();
8046     const GLuint cmdlen = 12 + __GLX_PAD((n * 16));
8047     if (n < 0) {
8048         __glXSetError(gc, GL_INVALID_VALUE);
8049         return;
8050     }
8051     if (__builtin_expect(n >= 0, 1)) {
8052 emit_header(gc->pc, X_GLrop_VertexAttribs4fvNV, cmdlen);
8053 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
8054 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
8055 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 16));
8056 gc->pc += cmdlen;
8057 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8058     }
8059 }
8060 
8061 #define X_GLrop_VertexAttribs4svNV 4205
__indirect_glVertexAttribs4svNV(GLuint index,GLsizei n,const GLshort * v)8062 void __indirect_glVertexAttribs4svNV(GLuint index, GLsizei n, const GLshort * v)
8063 {
8064     struct glx_context * const gc = __glXGetCurrentContext();
8065     const GLuint cmdlen = 12 + __GLX_PAD((n * 8));
8066     if (n < 0) {
8067         __glXSetError(gc, GL_INVALID_VALUE);
8068         return;
8069     }
8070     if (__builtin_expect(n >= 0, 1)) {
8071 emit_header(gc->pc, X_GLrop_VertexAttribs4svNV, cmdlen);
8072 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
8073 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
8074 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 8));
8075 gc->pc += cmdlen;
8076 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8077     }
8078 }
8079 
8080 #define X_GLrop_VertexAttribs4ubvNV 4214
__indirect_glVertexAttribs4ubvNV(GLuint index,GLsizei n,const GLubyte * v)8081 void __indirect_glVertexAttribs4ubvNV(GLuint index, GLsizei n, const GLubyte * v)
8082 {
8083     struct glx_context * const gc = __glXGetCurrentContext();
8084     const GLuint cmdlen = 12 + __GLX_PAD((n * 4));
8085     if (n < 0) {
8086         __glXSetError(gc, GL_INVALID_VALUE);
8087         return;
8088     }
8089     if (__builtin_expect(n >= 0, 1)) {
8090 emit_header(gc->pc, X_GLrop_VertexAttribs4ubvNV, cmdlen);
8091 (void) memcpy((void *)(gc->pc + 4), (void *)(&index), 4);
8092 (void) memcpy((void *)(gc->pc + 8), (void *)(&n), 4);
8093 (void) memcpy((void *)(gc->pc + 12), (void *)(v), (n * 4));
8094 gc->pc += cmdlen;
8095 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8096     }
8097 }
8098 
8099 #define X_GLrop_PointParameteriNV 4221
__indirect_glPointParameteriNV(GLenum pname,GLint param)8100 void __indirect_glPointParameteriNV(GLenum pname, GLint param)
8101 {
8102     struct glx_context * const gc = __glXGetCurrentContext();
8103     const GLuint cmdlen = 12;
8104 emit_header(gc->pc, X_GLrop_PointParameteriNV, cmdlen);
8105 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
8106 (void) memcpy((void *)(gc->pc + 8), (void *)(&param), 4);
8107 gc->pc += cmdlen;
8108 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8109 }
8110 
8111 #define X_GLrop_PointParameterivNV 4222
__indirect_glPointParameterivNV(GLenum pname,const GLint * params)8112 void __indirect_glPointParameterivNV(GLenum pname, const GLint * params)
8113 {
8114     struct glx_context * const gc = __glXGetCurrentContext();
8115     const GLuint compsize = __glPointParameterivNV_size(pname);
8116     const GLuint cmdlen = 8 + __GLX_PAD((compsize * 4));
8117 emit_header(gc->pc, X_GLrop_PointParameterivNV, cmdlen);
8118 (void) memcpy((void *)(gc->pc + 4), (void *)(&pname), 4);
8119 (void) memcpy((void *)(gc->pc + 8), (void *)(params), (compsize * 4));
8120 gc->pc += cmdlen;
8121 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8122 }
8123 
8124 #define X_GLrop_ActiveStencilFaceEXT 4220
__indirect_glActiveStencilFaceEXT(GLenum face)8125 void __indirect_glActiveStencilFaceEXT(GLenum face)
8126 {
8127     struct glx_context * const gc = __glXGetCurrentContext();
8128     const GLuint cmdlen = 8;
8129 emit_header(gc->pc, X_GLrop_ActiveStencilFaceEXT, cmdlen);
8130 (void) memcpy((void *)(gc->pc + 4), (void *)(&face), 4);
8131 gc->pc += cmdlen;
8132 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8133 }
8134 
8135 #define X_GLvop_GetProgramNamedParameterdvNV 1311
__indirect_glGetProgramNamedParameterdvNV(GLuint id,GLsizei len,const GLubyte * name,GLdouble * params)8136 void __indirect_glGetProgramNamedParameterdvNV(GLuint id, GLsizei len, const GLubyte * name, GLdouble * params)
8137 {
8138     struct glx_context * const gc = __glXGetCurrentContext();
8139     Display * const dpy = gc->currentDpy;
8140     const GLuint cmdlen = 8 + __GLX_PAD(len);
8141     if (len < 0) {
8142         __glXSetError(gc, GL_INVALID_VALUE);
8143         return;
8144     }
8145     if (__builtin_expect((len >= 0) && (dpy != NULL), 1)) {
8146         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetProgramNamedParameterdvNV, cmdlen);
8147 (void) memcpy((void *)(pc + 0), (void *)(&id), 4);
8148 (void) memcpy((void *)(pc + 4), (void *)(&len), 4);
8149 (void) memcpy((void *)(pc + 8), (void *)(name), len);
8150         (void) __glXReadReply(dpy, 8, params, GL_TRUE);
8151         UnlockDisplay(dpy); SyncHandle();
8152     }
8153     return;
8154 }
8155 
8156 #define X_GLvop_GetProgramNamedParameterfvNV 1310
__indirect_glGetProgramNamedParameterfvNV(GLuint id,GLsizei len,const GLubyte * name,GLfloat * params)8157 void __indirect_glGetProgramNamedParameterfvNV(GLuint id, GLsizei len, const GLubyte * name, GLfloat * params)
8158 {
8159     struct glx_context * const gc = __glXGetCurrentContext();
8160     Display * const dpy = gc->currentDpy;
8161     const GLuint cmdlen = 8 + __GLX_PAD(len);
8162     if (len < 0) {
8163         __glXSetError(gc, GL_INVALID_VALUE);
8164         return;
8165     }
8166     if (__builtin_expect((len >= 0) && (dpy != NULL), 1)) {
8167         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetProgramNamedParameterfvNV, cmdlen);
8168 (void) memcpy((void *)(pc + 0), (void *)(&id), 4);
8169 (void) memcpy((void *)(pc + 4), (void *)(&len), 4);
8170 (void) memcpy((void *)(pc + 8), (void *)(name), len);
8171         (void) __glXReadReply(dpy, 4, params, GL_TRUE);
8172         UnlockDisplay(dpy); SyncHandle();
8173     }
8174     return;
8175 }
8176 
8177 #define X_GLrop_ProgramNamedParameter4dvNV 4219
__indirect_glProgramNamedParameter4dNV(GLuint id,GLsizei len,const GLubyte * name,GLdouble x,GLdouble y,GLdouble z,GLdouble w)8178 void __indirect_glProgramNamedParameter4dNV(GLuint id, GLsizei len, const GLubyte * name, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
8179 {
8180     struct glx_context * const gc = __glXGetCurrentContext();
8181     const GLuint cmdlen = 44 + __GLX_PAD(len);
8182     if (len < 0) {
8183         __glXSetError(gc, GL_INVALID_VALUE);
8184         return;
8185     }
8186     if (__builtin_expect(len >= 0, 1)) {
8187 emit_header(gc->pc, X_GLrop_ProgramNamedParameter4dvNV, cmdlen);
8188 (void) memcpy((void *)(gc->pc + 4), (void *)(&x), 8);
8189 (void) memcpy((void *)(gc->pc + 12), (void *)(&y), 8);
8190 (void) memcpy((void *)(gc->pc + 20), (void *)(&z), 8);
8191 (void) memcpy((void *)(gc->pc + 28), (void *)(&w), 8);
8192 (void) memcpy((void *)(gc->pc + 36), (void *)(&id), 4);
8193 (void) memcpy((void *)(gc->pc + 40), (void *)(&len), 4);
8194 (void) memcpy((void *)(gc->pc + 44), (void *)(name), len);
8195 gc->pc += cmdlen;
8196 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8197     }
8198 }
8199 
8200 #define X_GLrop_ProgramNamedParameter4dvNV 4219
__indirect_glProgramNamedParameter4dvNV(GLuint id,GLsizei len,const GLubyte * name,const GLdouble * v)8201 void __indirect_glProgramNamedParameter4dvNV(GLuint id, GLsizei len, const GLubyte * name, const GLdouble * v)
8202 {
8203     struct glx_context * const gc = __glXGetCurrentContext();
8204     const GLuint cmdlen = 44 + __GLX_PAD(len);
8205     if (len < 0) {
8206         __glXSetError(gc, GL_INVALID_VALUE);
8207         return;
8208     }
8209     if (__builtin_expect(len >= 0, 1)) {
8210 emit_header(gc->pc, X_GLrop_ProgramNamedParameter4dvNV, cmdlen);
8211 (void) memcpy((void *)(gc->pc + 4), (void *)(v), 32);
8212 (void) memcpy((void *)(gc->pc + 36), (void *)(&id), 4);
8213 (void) memcpy((void *)(gc->pc + 40), (void *)(&len), 4);
8214 (void) memcpy((void *)(gc->pc + 44), (void *)(name), len);
8215 gc->pc += cmdlen;
8216 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8217     }
8218 }
8219 
8220 #define X_GLrop_ProgramNamedParameter4fvNV 4218
__indirect_glProgramNamedParameter4fNV(GLuint id,GLsizei len,const GLubyte * name,GLfloat x,GLfloat y,GLfloat z,GLfloat w)8221 void __indirect_glProgramNamedParameter4fNV(GLuint id, GLsizei len, const GLubyte * name, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
8222 {
8223     struct glx_context * const gc = __glXGetCurrentContext();
8224     const GLuint cmdlen = 28 + __GLX_PAD(len);
8225     if (len < 0) {
8226         __glXSetError(gc, GL_INVALID_VALUE);
8227         return;
8228     }
8229     if (__builtin_expect(len >= 0, 1)) {
8230 emit_header(gc->pc, X_GLrop_ProgramNamedParameter4fvNV, cmdlen);
8231 (void) memcpy((void *)(gc->pc + 4), (void *)(&id), 4);
8232 (void) memcpy((void *)(gc->pc + 8), (void *)(&len), 4);
8233 (void) memcpy((void *)(gc->pc + 12), (void *)(&x), 4);
8234 (void) memcpy((void *)(gc->pc + 16), (void *)(&y), 4);
8235 (void) memcpy((void *)(gc->pc + 20), (void *)(&z), 4);
8236 (void) memcpy((void *)(gc->pc + 24), (void *)(&w), 4);
8237 (void) memcpy((void *)(gc->pc + 28), (void *)(name), len);
8238 gc->pc += cmdlen;
8239 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8240     }
8241 }
8242 
8243 #define X_GLrop_ProgramNamedParameter4fvNV 4218
__indirect_glProgramNamedParameter4fvNV(GLuint id,GLsizei len,const GLubyte * name,const GLfloat * v)8244 void __indirect_glProgramNamedParameter4fvNV(GLuint id, GLsizei len, const GLubyte * name, const GLfloat * v)
8245 {
8246     struct glx_context * const gc = __glXGetCurrentContext();
8247     const GLuint cmdlen = 28 + __GLX_PAD(len);
8248     if (len < 0) {
8249         __glXSetError(gc, GL_INVALID_VALUE);
8250         return;
8251     }
8252     if (__builtin_expect(len >= 0, 1)) {
8253 emit_header(gc->pc, X_GLrop_ProgramNamedParameter4fvNV, cmdlen);
8254 (void) memcpy((void *)(gc->pc + 4), (void *)(&id), 4);
8255 (void) memcpy((void *)(gc->pc + 8), (void *)(&len), 4);
8256 (void) memcpy((void *)(gc->pc + 12), (void *)(v), 16);
8257 (void) memcpy((void *)(gc->pc + 28), (void *)(name), len);
8258 gc->pc += cmdlen;
8259 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8260     }
8261 }
8262 
8263 #define X_GLrop_BlendEquationSeparateEXT 4228
__indirect_glBlendEquationSeparateEXT(GLenum modeRGB,GLenum modeA)8264 void __indirect_glBlendEquationSeparateEXT(GLenum modeRGB, GLenum modeA)
8265 {
8266     struct glx_context * const gc = __glXGetCurrentContext();
8267     const GLuint cmdlen = 12;
8268 emit_header(gc->pc, X_GLrop_BlendEquationSeparateEXT, cmdlen);
8269 (void) memcpy((void *)(gc->pc + 4), (void *)(&modeRGB), 4);
8270 (void) memcpy((void *)(gc->pc + 8), (void *)(&modeA), 4);
8271 gc->pc += cmdlen;
8272 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8273 }
8274 
8275 #define X_GLrop_BindFramebufferEXT 4319
__indirect_glBindFramebufferEXT(GLenum target,GLuint framebuffer)8276 void __indirect_glBindFramebufferEXT(GLenum target, GLuint framebuffer)
8277 {
8278     struct glx_context * const gc = __glXGetCurrentContext();
8279     const GLuint cmdlen = 12;
8280 emit_header(gc->pc, X_GLrop_BindFramebufferEXT, cmdlen);
8281 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
8282 (void) memcpy((void *)(gc->pc + 8), (void *)(&framebuffer), 4);
8283 gc->pc += cmdlen;
8284 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8285 }
8286 
8287 #define X_GLrop_BindRenderbufferEXT 4316
__indirect_glBindRenderbufferEXT(GLenum target,GLuint renderbuffer)8288 void __indirect_glBindRenderbufferEXT(GLenum target, GLuint renderbuffer)
8289 {
8290     struct glx_context * const gc = __glXGetCurrentContext();
8291     const GLuint cmdlen = 12;
8292 emit_header(gc->pc, X_GLrop_BindRenderbufferEXT, cmdlen);
8293 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
8294 (void) memcpy((void *)(gc->pc + 8), (void *)(&renderbuffer), 4);
8295 gc->pc += cmdlen;
8296 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8297 }
8298 
8299 #define X_GLvop_CheckFramebufferStatusEXT 1427
__indirect_glCheckFramebufferStatusEXT(GLenum target)8300 GLenum __indirect_glCheckFramebufferStatusEXT(GLenum target)
8301 {
8302     struct glx_context * const gc = __glXGetCurrentContext();
8303     Display * const dpy = gc->currentDpy;
8304     GLenum retval = (GLenum) 0;
8305     const GLuint cmdlen = 4;
8306     if (__builtin_expect(dpy != NULL, 1)) {
8307         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_CheckFramebufferStatusEXT, cmdlen);
8308 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
8309         retval = (GLenum) __glXReadReply(dpy, 0, NULL, GL_FALSE);
8310         UnlockDisplay(dpy); SyncHandle();
8311     }
8312     return retval;
8313 }
8314 
8315 #define X_GLrop_DeleteFramebuffersEXT 4320
__indirect_glDeleteFramebuffersEXT(GLsizei n,const GLuint * framebuffers)8316 void __indirect_glDeleteFramebuffersEXT(GLsizei n, const GLuint * framebuffers)
8317 {
8318     struct glx_context * const gc = __glXGetCurrentContext();
8319     const GLuint cmdlen = 8 + __GLX_PAD((n * 4));
8320     if (n < 0) {
8321         __glXSetError(gc, GL_INVALID_VALUE);
8322         return;
8323     }
8324     if (__builtin_expect(n >= 0, 1)) {
8325 emit_header(gc->pc, X_GLrop_DeleteFramebuffersEXT, cmdlen);
8326 (void) memcpy((void *)(gc->pc + 4), (void *)(&n), 4);
8327 (void) memcpy((void *)(gc->pc + 8), (void *)(framebuffers), (n * 4));
8328 gc->pc += cmdlen;
8329 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8330     }
8331 }
8332 
8333 #define X_GLrop_DeleteRenderbuffersEXT 4317
__indirect_glDeleteRenderbuffersEXT(GLsizei n,const GLuint * renderbuffers)8334 void __indirect_glDeleteRenderbuffersEXT(GLsizei n, const GLuint * renderbuffers)
8335 {
8336     struct glx_context * const gc = __glXGetCurrentContext();
8337     const GLuint cmdlen = 8 + __GLX_PAD((n * 4));
8338     if (n < 0) {
8339         __glXSetError(gc, GL_INVALID_VALUE);
8340         return;
8341     }
8342     if (__builtin_expect(n >= 0, 1)) {
8343 emit_header(gc->pc, X_GLrop_DeleteRenderbuffersEXT, cmdlen);
8344 (void) memcpy((void *)(gc->pc + 4), (void *)(&n), 4);
8345 (void) memcpy((void *)(gc->pc + 8), (void *)(renderbuffers), (n * 4));
8346 gc->pc += cmdlen;
8347 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8348     }
8349 }
8350 
8351 #define X_GLrop_FramebufferRenderbufferEXT 4324
__indirect_glFramebufferRenderbufferEXT(GLenum target,GLenum attachment,GLenum renderbuffertarget,GLuint renderbuffer)8352 void __indirect_glFramebufferRenderbufferEXT(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
8353 {
8354     struct glx_context * const gc = __glXGetCurrentContext();
8355     const GLuint cmdlen = 20;
8356 emit_header(gc->pc, X_GLrop_FramebufferRenderbufferEXT, cmdlen);
8357 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
8358 (void) memcpy((void *)(gc->pc + 8), (void *)(&attachment), 4);
8359 (void) memcpy((void *)(gc->pc + 12), (void *)(&renderbuffertarget), 4);
8360 (void) memcpy((void *)(gc->pc + 16), (void *)(&renderbuffer), 4);
8361 gc->pc += cmdlen;
8362 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8363 }
8364 
8365 #define X_GLrop_FramebufferTexture1DEXT 4321
__indirect_glFramebufferTexture1DEXT(GLenum target,GLenum attachment,GLenum textarget,GLuint texture,GLint level)8366 void __indirect_glFramebufferTexture1DEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
8367 {
8368     struct glx_context * const gc = __glXGetCurrentContext();
8369     const GLuint cmdlen = 24;
8370 emit_header(gc->pc, X_GLrop_FramebufferTexture1DEXT, cmdlen);
8371 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
8372 (void) memcpy((void *)(gc->pc + 8), (void *)(&attachment), 4);
8373 (void) memcpy((void *)(gc->pc + 12), (void *)(&textarget), 4);
8374 (void) memcpy((void *)(gc->pc + 16), (void *)(&texture), 4);
8375 (void) memcpy((void *)(gc->pc + 20), (void *)(&level), 4);
8376 gc->pc += cmdlen;
8377 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8378 }
8379 
8380 #define X_GLrop_FramebufferTexture2DEXT 4322
__indirect_glFramebufferTexture2DEXT(GLenum target,GLenum attachment,GLenum textarget,GLuint texture,GLint level)8381 void __indirect_glFramebufferTexture2DEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
8382 {
8383     struct glx_context * const gc = __glXGetCurrentContext();
8384     const GLuint cmdlen = 24;
8385 emit_header(gc->pc, X_GLrop_FramebufferTexture2DEXT, cmdlen);
8386 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
8387 (void) memcpy((void *)(gc->pc + 8), (void *)(&attachment), 4);
8388 (void) memcpy((void *)(gc->pc + 12), (void *)(&textarget), 4);
8389 (void) memcpy((void *)(gc->pc + 16), (void *)(&texture), 4);
8390 (void) memcpy((void *)(gc->pc + 20), (void *)(&level), 4);
8391 gc->pc += cmdlen;
8392 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8393 }
8394 
8395 #define X_GLrop_FramebufferTexture3DEXT 4323
__indirect_glFramebufferTexture3DEXT(GLenum target,GLenum attachment,GLenum textarget,GLuint texture,GLint level,GLint zoffset)8396 void __indirect_glFramebufferTexture3DEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
8397 {
8398     struct glx_context * const gc = __glXGetCurrentContext();
8399     const GLuint cmdlen = 28;
8400 emit_header(gc->pc, X_GLrop_FramebufferTexture3DEXT, cmdlen);
8401 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
8402 (void) memcpy((void *)(gc->pc + 8), (void *)(&attachment), 4);
8403 (void) memcpy((void *)(gc->pc + 12), (void *)(&textarget), 4);
8404 (void) memcpy((void *)(gc->pc + 16), (void *)(&texture), 4);
8405 (void) memcpy((void *)(gc->pc + 20), (void *)(&level), 4);
8406 (void) memcpy((void *)(gc->pc + 24), (void *)(&zoffset), 4);
8407 gc->pc += cmdlen;
8408 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8409 }
8410 
8411 #define X_GLvop_GenFramebuffersEXT 1426
__indirect_glGenFramebuffersEXT(GLsizei n,GLuint * framebuffers)8412 void __indirect_glGenFramebuffersEXT(GLsizei n, GLuint * framebuffers)
8413 {
8414     struct glx_context * const gc = __glXGetCurrentContext();
8415     Display * const dpy = gc->currentDpy;
8416     const GLuint cmdlen = 4;
8417     if (n < 0) {
8418         __glXSetError(gc, GL_INVALID_VALUE);
8419         return;
8420     }
8421     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
8422         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GenFramebuffersEXT, cmdlen);
8423 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
8424         (void) __glXReadReply(dpy, 4, framebuffers, GL_TRUE);
8425         UnlockDisplay(dpy); SyncHandle();
8426     }
8427     return;
8428 }
8429 
8430 #define X_GLvop_GenRenderbuffersEXT 1423
__indirect_glGenRenderbuffersEXT(GLsizei n,GLuint * renderbuffers)8431 void __indirect_glGenRenderbuffersEXT(GLsizei n, GLuint * renderbuffers)
8432 {
8433     struct glx_context * const gc = __glXGetCurrentContext();
8434     Display * const dpy = gc->currentDpy;
8435     const GLuint cmdlen = 4;
8436     if (n < 0) {
8437         __glXSetError(gc, GL_INVALID_VALUE);
8438         return;
8439     }
8440     if (__builtin_expect((n >= 0) && (dpy != NULL), 1)) {
8441         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GenRenderbuffersEXT, cmdlen);
8442 (void) memcpy((void *)(pc + 0), (void *)(&n), 4);
8443         (void) __glXReadReply(dpy, 4, renderbuffers, GL_TRUE);
8444         UnlockDisplay(dpy); SyncHandle();
8445     }
8446     return;
8447 }
8448 
8449 #define X_GLrop_GenerateMipmapEXT 4325
__indirect_glGenerateMipmapEXT(GLenum target)8450 void __indirect_glGenerateMipmapEXT(GLenum target)
8451 {
8452     struct glx_context * const gc = __glXGetCurrentContext();
8453     const GLuint cmdlen = 8;
8454 emit_header(gc->pc, X_GLrop_GenerateMipmapEXT, cmdlen);
8455 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
8456 gc->pc += cmdlen;
8457 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8458 }
8459 
8460 #define X_GLvop_GetFramebufferAttachmentParameterivEXT 1428
__indirect_glGetFramebufferAttachmentParameterivEXT(GLenum target,GLenum attachment,GLenum pname,GLint * params)8461 void __indirect_glGetFramebufferAttachmentParameterivEXT(GLenum target, GLenum attachment, GLenum pname, GLint * params)
8462 {
8463     struct glx_context * const gc = __glXGetCurrentContext();
8464     Display * const dpy = gc->currentDpy;
8465     const GLuint cmdlen = 12;
8466     if (__builtin_expect(dpy != NULL, 1)) {
8467         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetFramebufferAttachmentParameterivEXT, cmdlen);
8468 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
8469 (void) memcpy((void *)(pc + 4), (void *)(&attachment), 4);
8470 (void) memcpy((void *)(pc + 8), (void *)(&pname), 4);
8471         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
8472         UnlockDisplay(dpy); SyncHandle();
8473     }
8474     return;
8475 }
8476 
8477 #define X_GLvop_GetRenderbufferParameterivEXT 1424
__indirect_glGetRenderbufferParameterivEXT(GLenum target,GLenum pname,GLint * params)8478 void __indirect_glGetRenderbufferParameterivEXT(GLenum target, GLenum pname, GLint * params)
8479 {
8480     struct glx_context * const gc = __glXGetCurrentContext();
8481     Display * const dpy = gc->currentDpy;
8482     const GLuint cmdlen = 8;
8483     if (__builtin_expect(dpy != NULL, 1)) {
8484         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_GetRenderbufferParameterivEXT, cmdlen);
8485 (void) memcpy((void *)(pc + 0), (void *)(&target), 4);
8486 (void) memcpy((void *)(pc + 4), (void *)(&pname), 4);
8487         (void) __glXReadReply(dpy, 4, params, GL_FALSE);
8488         UnlockDisplay(dpy); SyncHandle();
8489     }
8490     return;
8491 }
8492 
8493 #define X_GLvop_IsFramebufferEXT 1425
__indirect_glIsFramebufferEXT(GLuint framebuffer)8494 GLboolean __indirect_glIsFramebufferEXT(GLuint framebuffer)
8495 {
8496     struct glx_context * const gc = __glXGetCurrentContext();
8497     Display * const dpy = gc->currentDpy;
8498     GLboolean retval = (GLboolean) 0;
8499     const GLuint cmdlen = 4;
8500     if (__builtin_expect(dpy != NULL, 1)) {
8501         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_IsFramebufferEXT, cmdlen);
8502 (void) memcpy((void *)(pc + 0), (void *)(&framebuffer), 4);
8503         retval = (GLboolean) __glXReadReply(dpy, 0, NULL, GL_FALSE);
8504         UnlockDisplay(dpy); SyncHandle();
8505     }
8506     return retval;
8507 }
8508 
8509 #define X_GLvop_IsRenderbufferEXT 1422
__indirect_glIsRenderbufferEXT(GLuint renderbuffer)8510 GLboolean __indirect_glIsRenderbufferEXT(GLuint renderbuffer)
8511 {
8512     struct glx_context * const gc = __glXGetCurrentContext();
8513     Display * const dpy = gc->currentDpy;
8514     GLboolean retval = (GLboolean) 0;
8515     const GLuint cmdlen = 4;
8516     if (__builtin_expect(dpy != NULL, 1)) {
8517         GLubyte const * pc = __glXSetupVendorRequest(gc, X_GLXVendorPrivateWithReply, X_GLvop_IsRenderbufferEXT, cmdlen);
8518 (void) memcpy((void *)(pc + 0), (void *)(&renderbuffer), 4);
8519         retval = (GLboolean) __glXReadReply(dpy, 0, NULL, GL_FALSE);
8520         UnlockDisplay(dpy); SyncHandle();
8521     }
8522     return retval;
8523 }
8524 
8525 #define X_GLrop_RenderbufferStorageEXT 4318
__indirect_glRenderbufferStorageEXT(GLenum target,GLenum internalformat,GLsizei width,GLsizei height)8526 void __indirect_glRenderbufferStorageEXT(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
8527 {
8528     struct glx_context * const gc = __glXGetCurrentContext();
8529     const GLuint cmdlen = 20;
8530 emit_header(gc->pc, X_GLrop_RenderbufferStorageEXT, cmdlen);
8531 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
8532 (void) memcpy((void *)(gc->pc + 8), (void *)(&internalformat), 4);
8533 (void) memcpy((void *)(gc->pc + 12), (void *)(&width), 4);
8534 (void) memcpy((void *)(gc->pc + 16), (void *)(&height), 4);
8535 gc->pc += cmdlen;
8536 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8537 }
8538 
8539 #define X_GLrop_BlitFramebufferEXT 4330
__indirect_glBlitFramebufferEXT(GLint srcX0,GLint srcY0,GLint srcX1,GLint srcY1,GLint dstX0,GLint dstY0,GLint dstX1,GLint dstY1,GLbitfield mask,GLenum filter)8540 void __indirect_glBlitFramebufferEXT(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
8541 {
8542     struct glx_context * const gc = __glXGetCurrentContext();
8543     const GLuint cmdlen = 44;
8544 emit_header(gc->pc, X_GLrop_BlitFramebufferEXT, cmdlen);
8545 (void) memcpy((void *)(gc->pc + 4), (void *)(&srcX0), 4);
8546 (void) memcpy((void *)(gc->pc + 8), (void *)(&srcY0), 4);
8547 (void) memcpy((void *)(gc->pc + 12), (void *)(&srcX1), 4);
8548 (void) memcpy((void *)(gc->pc + 16), (void *)(&srcY1), 4);
8549 (void) memcpy((void *)(gc->pc + 20), (void *)(&dstX0), 4);
8550 (void) memcpy((void *)(gc->pc + 24), (void *)(&dstY0), 4);
8551 (void) memcpy((void *)(gc->pc + 28), (void *)(&dstX1), 4);
8552 (void) memcpy((void *)(gc->pc + 32), (void *)(&dstY1), 4);
8553 (void) memcpy((void *)(gc->pc + 36), (void *)(&mask), 4);
8554 (void) memcpy((void *)(gc->pc + 40), (void *)(&filter), 4);
8555 gc->pc += cmdlen;
8556 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8557 }
8558 
8559 #define X_GLrop_FramebufferTextureLayerEXT 237
__indirect_glFramebufferTextureLayerEXT(GLenum target,GLenum attachment,GLuint texture,GLint level,GLint layer)8560 void __indirect_glFramebufferTextureLayerEXT(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
8561 {
8562     struct glx_context * const gc = __glXGetCurrentContext();
8563     const GLuint cmdlen = 24;
8564 emit_header(gc->pc, X_GLrop_FramebufferTextureLayerEXT, cmdlen);
8565 (void) memcpy((void *)(gc->pc + 4), (void *)(&target), 4);
8566 (void) memcpy((void *)(gc->pc + 8), (void *)(&attachment), 4);
8567 (void) memcpy((void *)(gc->pc + 12), (void *)(&texture), 4);
8568 (void) memcpy((void *)(gc->pc + 16), (void *)(&level), 4);
8569 (void) memcpy((void *)(gc->pc + 20), (void *)(&layer), 4);
8570 gc->pc += cmdlen;
8571 if (__builtin_expect(gc->pc > gc->limit, 0)) { (void) __glXFlushRenderBuffer(gc, gc->pc); }
8572 }
8573 
8574 
8575 #ifdef GLX_SHARED_GLAPI
8576 
8577 static const struct proc_pair
8578 {
8579    const char *name;
8580    _glapi_proc proc;
8581 } proc_pairs[20] = {
8582    { "AreTexturesResidentEXT", (_glapi_proc) glAreTexturesResidentEXT },
8583    { "DeleteTexturesEXT", (_glapi_proc) glDeleteTexturesEXT },
8584    { "GenTexturesEXT", (_glapi_proc) glGenTexturesEXT },
8585    { "GetColorTableEXT", (_glapi_proc) glGetColorTableEXT },
8586    { "GetColorTableParameterfvEXT", (_glapi_proc) glGetColorTableParameterfvEXT },
8587    { "GetColorTableParameterfvSGI", (_glapi_proc) glGetColorTableParameterfvEXT },
8588    { "GetColorTableParameterivEXT", (_glapi_proc) glGetColorTableParameterivEXT },
8589    { "GetColorTableParameterivSGI", (_glapi_proc) glGetColorTableParameterivEXT },
8590    { "GetColorTableSGI", (_glapi_proc) glGetColorTableEXT },
8591    { "GetConvolutionFilterEXT", (_glapi_proc) gl_dispatch_stub_356 },
8592    { "GetConvolutionParameterfvEXT", (_glapi_proc) gl_dispatch_stub_357 },
8593    { "GetConvolutionParameterivEXT", (_glapi_proc) gl_dispatch_stub_358 },
8594    { "GetHistogramEXT", (_glapi_proc) gl_dispatch_stub_361 },
8595    { "GetHistogramParameterfvEXT", (_glapi_proc) gl_dispatch_stub_362 },
8596    { "GetHistogramParameterivEXT", (_glapi_proc) gl_dispatch_stub_363 },
8597    { "GetMinmaxEXT", (_glapi_proc) gl_dispatch_stub_364 },
8598    { "GetMinmaxParameterfvEXT", (_glapi_proc) gl_dispatch_stub_365 },
8599    { "GetMinmaxParameterivEXT", (_glapi_proc) gl_dispatch_stub_366 },
8600    { "GetSeparableFilterEXT", (_glapi_proc) gl_dispatch_stub_359 },
8601    { "IsTextureEXT", (_glapi_proc) glIsTextureEXT }
8602 };
8603 
8604 static int
__indirect_get_proc_compare(const void * key,const void * memb)8605 __indirect_get_proc_compare(const void *key, const void *memb)
8606 {
8607    const struct proc_pair *pair = (const struct proc_pair *) memb;
8608    return strcmp((const char *) key, pair->name);
8609 }
8610 
8611 _glapi_proc
__indirect_get_proc_address(const char * name)8612 __indirect_get_proc_address(const char *name)
8613 {
8614    const struct proc_pair *pair;
8615 
8616    /* skip "gl" */
8617    name += 2;
8618 
8619    pair = (const struct proc_pair *) bsearch((const void *) name,
8620       (const void *) proc_pairs, ARRAY_SIZE(proc_pairs), sizeof(proc_pairs[0]),
8621       __indirect_get_proc_compare);
8622 
8623    return (pair) ? pair->proc : NULL;
8624 }
8625 
8626 #endif /* GLX_SHARED_GLAPI */
8627 
8628 
8629 #  undef FASTCALL
8630 #  undef NOINLINE
8631