1/* DO NOT EDIT - This file generated automatically by glX_proto_recv.py (from Mesa) script */ 2 3/* 4 * (C) Copyright IBM Corporation 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#include <X11/Xmd.h> 29#include <GL/gl.h> 30#include <GL/glxproto.h> 31#include <inttypes.h> 32#include "indirect_size.h" 33#include "indirect_size_get.h" 34#include "indirect_dispatch.h" 35#include "glxserver.h" 36#include "glxbyteorder.h" 37#include "indirect_util.h" 38#include "singlesize.h" 39#include "glapi.h" 40#include "glapitable.h" 41#include "glthread.h" 42#include "dispatch.h" 43 44#define __GLX_PAD(x) (((x) + 3) & ~3) 45 46typedef struct { 47 __GLX_PIXEL_3D_HDR; 48} __GLXpixel3DHeader; 49 50extern GLboolean __glXErrorOccured( void ); 51extern void __glXClearErrorOccured( void ); 52 53static const unsigned dummy_answer[2] = {0, 0}; 54 55static GLsizei 56bswap_CARD32( const void * src ) 57{ 58 union { uint32_t dst; GLsizei ret; } x; 59 x.dst = bswap_32( *(uint32_t *) src ); 60 return x.ret; 61} 62 63static GLshort 64bswap_CARD16( const void * src ) 65{ 66 union { uint16_t dst; GLshort ret; } x; 67 x.dst = bswap_16( *(uint16_t *) src ); 68 return x.ret; 69} 70 71static GLenum 72bswap_ENUM( const void * src ) 73{ 74 union { uint32_t dst; GLenum ret; } x; 75 x.dst = bswap_32( *(uint32_t *) src ); 76 return x.ret; 77} 78 79static GLdouble 80bswap_FLOAT64( const void * src ) 81{ 82 union { uint64_t dst; GLdouble ret; } x; 83 x.dst = bswap_64( *(uint64_t *) src ); 84 return x.ret; 85} 86 87static GLfloat 88bswap_FLOAT32( const void * src ) 89{ 90 union { uint32_t dst; GLfloat ret; } x; 91 x.dst = bswap_32( *(uint32_t *) src ); 92 return x.ret; 93} 94 95static void * 96bswap_16_array( uint16_t * src, unsigned count ) 97{ 98 unsigned i; 99 100 for ( i = 0 ; i < count ; i++ ) { 101 uint16_t temp = bswap_16( src[i] ); 102 src[i] = temp; 103 } 104 105 return src; 106} 107 108static void * 109bswap_32_array( uint32_t * src, unsigned count ) 110{ 111 unsigned i; 112 113 for ( i = 0 ; i < count ; i++ ) { 114 uint32_t temp = bswap_32( src[i] ); 115 src[i] = temp; 116 } 117 118 return src; 119} 120 121static void * 122bswap_64_array( uint64_t * src, unsigned count ) 123{ 124 unsigned i; 125 126 for ( i = 0 ; i < count ; i++ ) { 127 uint64_t temp = bswap_64( src[i] ); 128 src[i] = temp; 129 } 130 131 return src; 132} 133 134int __glXDispSwap_NewList(__GLXclientState *cl, GLbyte *pc) 135{ 136 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 137 int error; 138 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 139 140 pc += __GLX_SINGLE_HDR_SIZE; 141 if ( cx != NULL ) { 142 CALL_NewList( GET_DISPATCH(), ( 143 (GLuint )bswap_CARD32 ( pc + 0 ), 144 (GLenum )bswap_ENUM ( pc + 4 ) 145 ) ); 146 error = Success; 147 } 148 149 return error; 150} 151 152int __glXDispSwap_EndList(__GLXclientState *cl, GLbyte *pc) 153{ 154 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 155 int error; 156 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 157 158 pc += __GLX_SINGLE_HDR_SIZE; 159 if ( cx != NULL ) { 160 CALL_EndList( GET_DISPATCH(), () ); 161 error = Success; 162 } 163 164 return error; 165} 166 167void __glXDispSwap_CallList(GLbyte * pc) 168{ 169 CALL_CallList( GET_DISPATCH(), ( 170 (GLuint )bswap_CARD32 ( pc + 0 ) 171 ) ); 172} 173 174void __glXDispSwap_CallLists(GLbyte * pc) 175{ 176 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 177 const GLenum type = (GLenum )bswap_ENUM ( pc + 4 ); 178 const GLvoid * lists; 179 180 switch(type) { 181 case GL_BYTE: 182 case GL_UNSIGNED_BYTE: 183 case GL_2_BYTES: 184 case GL_3_BYTES: 185 case GL_4_BYTES: 186 lists = (const GLvoid *) (pc + 8); break; 187 case GL_SHORT: 188 case GL_UNSIGNED_SHORT: 189 lists = (const GLvoid *) bswap_16_array( (uint16_t *) (pc + 8), n ); break; 190 case GL_INT: 191 case GL_UNSIGNED_INT: 192 case GL_FLOAT: 193 lists = (const GLvoid *) bswap_32_array( (uint32_t *) (pc + 8), n ); break; 194 default: 195 return; 196 } 197 198 CALL_CallLists( GET_DISPATCH(), ( 199 n, 200 type, 201 lists 202 ) ); 203} 204 205int __glXDispSwap_DeleteLists(__GLXclientState *cl, GLbyte *pc) 206{ 207 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 208 int error; 209 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 210 211 pc += __GLX_SINGLE_HDR_SIZE; 212 if ( cx != NULL ) { 213 CALL_DeleteLists( GET_DISPATCH(), ( 214 (GLuint )bswap_CARD32 ( pc + 0 ), 215 (GLsizei )bswap_CARD32 ( pc + 4 ) 216 ) ); 217 error = Success; 218 } 219 220 return error; 221} 222 223int __glXDispSwap_GenLists(__GLXclientState *cl, GLbyte *pc) 224{ 225 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 226 int error; 227 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 228 229 pc += __GLX_SINGLE_HDR_SIZE; 230 if ( cx != NULL ) { 231 GLuint retval; 232 retval = CALL_GenLists( GET_DISPATCH(), ( 233 (GLsizei )bswap_CARD32 ( pc + 0 ) 234 ) ); 235 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 236 error = Success; 237 } 238 239 return error; 240} 241 242void __glXDispSwap_ListBase(GLbyte * pc) 243{ 244 CALL_ListBase( GET_DISPATCH(), ( 245 (GLuint )bswap_CARD32 ( pc + 0 ) 246 ) ); 247} 248 249void __glXDispSwap_Begin(GLbyte * pc) 250{ 251 CALL_Begin( GET_DISPATCH(), ( 252 (GLenum )bswap_ENUM ( pc + 0 ) 253 ) ); 254} 255 256void __glXDispSwap_Bitmap(GLbyte * pc) 257{ 258 const GLubyte * const bitmap = (const GLubyte *) (pc + 44); 259 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 260 261 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 262 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 263 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 264 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 265 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 266 267 CALL_Bitmap( GET_DISPATCH(), ( 268 (GLsizei )bswap_CARD32 ( pc + 20 ), 269 (GLsizei )bswap_CARD32 ( pc + 24 ), 270 (GLfloat )bswap_FLOAT32( pc + 28 ), 271 (GLfloat )bswap_FLOAT32( pc + 32 ), 272 (GLfloat )bswap_FLOAT32( pc + 36 ), 273 (GLfloat )bswap_FLOAT32( pc + 40 ), 274 bitmap 275 ) ); 276} 277 278void __glXDispSwap_Color3bv(GLbyte * pc) 279{ 280 CALL_Color3bv( GET_DISPATCH(), ( 281 (const GLbyte *)(pc + 0) 282 ) ); 283} 284 285void __glXDispSwap_Color3dv(GLbyte * pc) 286{ 287#ifdef __GLX_ALIGN64 288 if ((unsigned long)(pc) & 7) { 289 (void) memmove(pc-4, pc, 24); 290 pc -= 4; 291 } 292#endif 293 294 CALL_Color3dv( GET_DISPATCH(), ( 295 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 3 ) 296 ) ); 297} 298 299void __glXDispSwap_Color3fv(GLbyte * pc) 300{ 301 CALL_Color3fv( GET_DISPATCH(), ( 302 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 303 ) ); 304} 305 306void __glXDispSwap_Color3iv(GLbyte * pc) 307{ 308 CALL_Color3iv( GET_DISPATCH(), ( 309 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 310 ) ); 311} 312 313void __glXDispSwap_Color3sv(GLbyte * pc) 314{ 315 CALL_Color3sv( GET_DISPATCH(), ( 316 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 3 ) 317 ) ); 318} 319 320void __glXDispSwap_Color3ubv(GLbyte * pc) 321{ 322 CALL_Color3ubv( GET_DISPATCH(), ( 323 (const GLubyte *)(pc + 0) 324 ) ); 325} 326 327void __glXDispSwap_Color3uiv(GLbyte * pc) 328{ 329 CALL_Color3uiv( GET_DISPATCH(), ( 330 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 331 ) ); 332} 333 334void __glXDispSwap_Color3usv(GLbyte * pc) 335{ 336 CALL_Color3usv( GET_DISPATCH(), ( 337 (const GLushort *)bswap_16_array( (uint16_t *) (pc + 0), 3 ) 338 ) ); 339} 340 341void __glXDispSwap_Color4bv(GLbyte * pc) 342{ 343 CALL_Color4bv( GET_DISPATCH(), ( 344 (const GLbyte *)(pc + 0) 345 ) ); 346} 347 348void __glXDispSwap_Color4dv(GLbyte * pc) 349{ 350#ifdef __GLX_ALIGN64 351 if ((unsigned long)(pc) & 7) { 352 (void) memmove(pc-4, pc, 32); 353 pc -= 4; 354 } 355#endif 356 357 CALL_Color4dv( GET_DISPATCH(), ( 358 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 4 ) 359 ) ); 360} 361 362void __glXDispSwap_Color4fv(GLbyte * pc) 363{ 364 CALL_Color4fv( GET_DISPATCH(), ( 365 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 4 ) 366 ) ); 367} 368 369void __glXDispSwap_Color4iv(GLbyte * pc) 370{ 371 CALL_Color4iv( GET_DISPATCH(), ( 372 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 4 ) 373 ) ); 374} 375 376void __glXDispSwap_Color4sv(GLbyte * pc) 377{ 378 CALL_Color4sv( GET_DISPATCH(), ( 379 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 4 ) 380 ) ); 381} 382 383void __glXDispSwap_Color4ubv(GLbyte * pc) 384{ 385 CALL_Color4ubv( GET_DISPATCH(), ( 386 (const GLubyte *)(pc + 0) 387 ) ); 388} 389 390void __glXDispSwap_Color4uiv(GLbyte * pc) 391{ 392 CALL_Color4uiv( GET_DISPATCH(), ( 393 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 0), 4 ) 394 ) ); 395} 396 397void __glXDispSwap_Color4usv(GLbyte * pc) 398{ 399 CALL_Color4usv( GET_DISPATCH(), ( 400 (const GLushort *)bswap_16_array( (uint16_t *) (pc + 0), 4 ) 401 ) ); 402} 403 404void __glXDispSwap_EdgeFlagv(GLbyte * pc) 405{ 406 CALL_EdgeFlagv( GET_DISPATCH(), ( 407 (const GLboolean *)(pc + 0) 408 ) ); 409} 410 411void __glXDispSwap_End(GLbyte * pc) 412{ 413 CALL_End( GET_DISPATCH(), () ); 414} 415 416void __glXDispSwap_Indexdv(GLbyte * pc) 417{ 418#ifdef __GLX_ALIGN64 419 if ((unsigned long)(pc) & 7) { 420 (void) memmove(pc-4, pc, 8); 421 pc -= 4; 422 } 423#endif 424 425 CALL_Indexdv( GET_DISPATCH(), ( 426 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 1 ) 427 ) ); 428} 429 430void __glXDispSwap_Indexfv(GLbyte * pc) 431{ 432 CALL_Indexfv( GET_DISPATCH(), ( 433 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 1 ) 434 ) ); 435} 436 437void __glXDispSwap_Indexiv(GLbyte * pc) 438{ 439 CALL_Indexiv( GET_DISPATCH(), ( 440 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 1 ) 441 ) ); 442} 443 444void __glXDispSwap_Indexsv(GLbyte * pc) 445{ 446 CALL_Indexsv( GET_DISPATCH(), ( 447 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 1 ) 448 ) ); 449} 450 451void __glXDispSwap_Normal3bv(GLbyte * pc) 452{ 453 CALL_Normal3bv( GET_DISPATCH(), ( 454 (const GLbyte *)(pc + 0) 455 ) ); 456} 457 458void __glXDispSwap_Normal3dv(GLbyte * pc) 459{ 460#ifdef __GLX_ALIGN64 461 if ((unsigned long)(pc) & 7) { 462 (void) memmove(pc-4, pc, 24); 463 pc -= 4; 464 } 465#endif 466 467 CALL_Normal3dv( GET_DISPATCH(), ( 468 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 3 ) 469 ) ); 470} 471 472void __glXDispSwap_Normal3fv(GLbyte * pc) 473{ 474 CALL_Normal3fv( GET_DISPATCH(), ( 475 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 476 ) ); 477} 478 479void __glXDispSwap_Normal3iv(GLbyte * pc) 480{ 481 CALL_Normal3iv( GET_DISPATCH(), ( 482 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 483 ) ); 484} 485 486void __glXDispSwap_Normal3sv(GLbyte * pc) 487{ 488 CALL_Normal3sv( GET_DISPATCH(), ( 489 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 3 ) 490 ) ); 491} 492 493void __glXDispSwap_RasterPos2dv(GLbyte * pc) 494{ 495#ifdef __GLX_ALIGN64 496 if ((unsigned long)(pc) & 7) { 497 (void) memmove(pc-4, pc, 16); 498 pc -= 4; 499 } 500#endif 501 502 CALL_RasterPos2dv( GET_DISPATCH(), ( 503 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 2 ) 504 ) ); 505} 506 507void __glXDispSwap_RasterPos2fv(GLbyte * pc) 508{ 509 CALL_RasterPos2fv( GET_DISPATCH(), ( 510 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 2 ) 511 ) ); 512} 513 514void __glXDispSwap_RasterPos2iv(GLbyte * pc) 515{ 516 CALL_RasterPos2iv( GET_DISPATCH(), ( 517 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 2 ) 518 ) ); 519} 520 521void __glXDispSwap_RasterPos2sv(GLbyte * pc) 522{ 523 CALL_RasterPos2sv( GET_DISPATCH(), ( 524 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 2 ) 525 ) ); 526} 527 528void __glXDispSwap_RasterPos3dv(GLbyte * pc) 529{ 530#ifdef __GLX_ALIGN64 531 if ((unsigned long)(pc) & 7) { 532 (void) memmove(pc-4, pc, 24); 533 pc -= 4; 534 } 535#endif 536 537 CALL_RasterPos3dv( GET_DISPATCH(), ( 538 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 3 ) 539 ) ); 540} 541 542void __glXDispSwap_RasterPos3fv(GLbyte * pc) 543{ 544 CALL_RasterPos3fv( GET_DISPATCH(), ( 545 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 546 ) ); 547} 548 549void __glXDispSwap_RasterPos3iv(GLbyte * pc) 550{ 551 CALL_RasterPos3iv( GET_DISPATCH(), ( 552 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 553 ) ); 554} 555 556void __glXDispSwap_RasterPos3sv(GLbyte * pc) 557{ 558 CALL_RasterPos3sv( GET_DISPATCH(), ( 559 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 3 ) 560 ) ); 561} 562 563void __glXDispSwap_RasterPos4dv(GLbyte * pc) 564{ 565#ifdef __GLX_ALIGN64 566 if ((unsigned long)(pc) & 7) { 567 (void) memmove(pc-4, pc, 32); 568 pc -= 4; 569 } 570#endif 571 572 CALL_RasterPos4dv( GET_DISPATCH(), ( 573 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 4 ) 574 ) ); 575} 576 577void __glXDispSwap_RasterPos4fv(GLbyte * pc) 578{ 579 CALL_RasterPos4fv( GET_DISPATCH(), ( 580 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 4 ) 581 ) ); 582} 583 584void __glXDispSwap_RasterPos4iv(GLbyte * pc) 585{ 586 CALL_RasterPos4iv( GET_DISPATCH(), ( 587 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 4 ) 588 ) ); 589} 590 591void __glXDispSwap_RasterPos4sv(GLbyte * pc) 592{ 593 CALL_RasterPos4sv( GET_DISPATCH(), ( 594 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 4 ) 595 ) ); 596} 597 598void __glXDispSwap_Rectdv(GLbyte * pc) 599{ 600#ifdef __GLX_ALIGN64 601 if ((unsigned long)(pc) & 7) { 602 (void) memmove(pc-4, pc, 32); 603 pc -= 4; 604 } 605#endif 606 607 CALL_Rectdv( GET_DISPATCH(), ( 608 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 2 ), 609 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 16), 2 ) 610 ) ); 611} 612 613void __glXDispSwap_Rectfv(GLbyte * pc) 614{ 615 CALL_Rectfv( GET_DISPATCH(), ( 616 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 2 ), 617 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 8), 2 ) 618 ) ); 619} 620 621void __glXDispSwap_Rectiv(GLbyte * pc) 622{ 623 CALL_Rectiv( GET_DISPATCH(), ( 624 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 2 ), 625 (const GLint *)bswap_32_array( (uint32_t *) (pc + 8), 2 ) 626 ) ); 627} 628 629void __glXDispSwap_Rectsv(GLbyte * pc) 630{ 631 CALL_Rectsv( GET_DISPATCH(), ( 632 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 2 ), 633 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 2 ) 634 ) ); 635} 636 637void __glXDispSwap_TexCoord1dv(GLbyte * pc) 638{ 639#ifdef __GLX_ALIGN64 640 if ((unsigned long)(pc) & 7) { 641 (void) memmove(pc-4, pc, 8); 642 pc -= 4; 643 } 644#endif 645 646 CALL_TexCoord1dv( GET_DISPATCH(), ( 647 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 1 ) 648 ) ); 649} 650 651void __glXDispSwap_TexCoord1fv(GLbyte * pc) 652{ 653 CALL_TexCoord1fv( GET_DISPATCH(), ( 654 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 1 ) 655 ) ); 656} 657 658void __glXDispSwap_TexCoord1iv(GLbyte * pc) 659{ 660 CALL_TexCoord1iv( GET_DISPATCH(), ( 661 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 1 ) 662 ) ); 663} 664 665void __glXDispSwap_TexCoord1sv(GLbyte * pc) 666{ 667 CALL_TexCoord1sv( GET_DISPATCH(), ( 668 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 1 ) 669 ) ); 670} 671 672void __glXDispSwap_TexCoord2dv(GLbyte * pc) 673{ 674#ifdef __GLX_ALIGN64 675 if ((unsigned long)(pc) & 7) { 676 (void) memmove(pc-4, pc, 16); 677 pc -= 4; 678 } 679#endif 680 681 CALL_TexCoord2dv( GET_DISPATCH(), ( 682 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 2 ) 683 ) ); 684} 685 686void __glXDispSwap_TexCoord2fv(GLbyte * pc) 687{ 688 CALL_TexCoord2fv( GET_DISPATCH(), ( 689 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 2 ) 690 ) ); 691} 692 693void __glXDispSwap_TexCoord2iv(GLbyte * pc) 694{ 695 CALL_TexCoord2iv( GET_DISPATCH(), ( 696 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 2 ) 697 ) ); 698} 699 700void __glXDispSwap_TexCoord2sv(GLbyte * pc) 701{ 702 CALL_TexCoord2sv( GET_DISPATCH(), ( 703 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 2 ) 704 ) ); 705} 706 707void __glXDispSwap_TexCoord3dv(GLbyte * pc) 708{ 709#ifdef __GLX_ALIGN64 710 if ((unsigned long)(pc) & 7) { 711 (void) memmove(pc-4, pc, 24); 712 pc -= 4; 713 } 714#endif 715 716 CALL_TexCoord3dv( GET_DISPATCH(), ( 717 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 3 ) 718 ) ); 719} 720 721void __glXDispSwap_TexCoord3fv(GLbyte * pc) 722{ 723 CALL_TexCoord3fv( GET_DISPATCH(), ( 724 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 725 ) ); 726} 727 728void __glXDispSwap_TexCoord3iv(GLbyte * pc) 729{ 730 CALL_TexCoord3iv( GET_DISPATCH(), ( 731 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 732 ) ); 733} 734 735void __glXDispSwap_TexCoord3sv(GLbyte * pc) 736{ 737 CALL_TexCoord3sv( GET_DISPATCH(), ( 738 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 3 ) 739 ) ); 740} 741 742void __glXDispSwap_TexCoord4dv(GLbyte * pc) 743{ 744#ifdef __GLX_ALIGN64 745 if ((unsigned long)(pc) & 7) { 746 (void) memmove(pc-4, pc, 32); 747 pc -= 4; 748 } 749#endif 750 751 CALL_TexCoord4dv( GET_DISPATCH(), ( 752 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 4 ) 753 ) ); 754} 755 756void __glXDispSwap_TexCoord4fv(GLbyte * pc) 757{ 758 CALL_TexCoord4fv( GET_DISPATCH(), ( 759 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 4 ) 760 ) ); 761} 762 763void __glXDispSwap_TexCoord4iv(GLbyte * pc) 764{ 765 CALL_TexCoord4iv( GET_DISPATCH(), ( 766 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 4 ) 767 ) ); 768} 769 770void __glXDispSwap_TexCoord4sv(GLbyte * pc) 771{ 772 CALL_TexCoord4sv( GET_DISPATCH(), ( 773 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 4 ) 774 ) ); 775} 776 777void __glXDispSwap_Vertex2dv(GLbyte * pc) 778{ 779#ifdef __GLX_ALIGN64 780 if ((unsigned long)(pc) & 7) { 781 (void) memmove(pc-4, pc, 16); 782 pc -= 4; 783 } 784#endif 785 786 CALL_Vertex2dv( GET_DISPATCH(), ( 787 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 2 ) 788 ) ); 789} 790 791void __glXDispSwap_Vertex2fv(GLbyte * pc) 792{ 793 CALL_Vertex2fv( GET_DISPATCH(), ( 794 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 2 ) 795 ) ); 796} 797 798void __glXDispSwap_Vertex2iv(GLbyte * pc) 799{ 800 CALL_Vertex2iv( GET_DISPATCH(), ( 801 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 2 ) 802 ) ); 803} 804 805void __glXDispSwap_Vertex2sv(GLbyte * pc) 806{ 807 CALL_Vertex2sv( GET_DISPATCH(), ( 808 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 2 ) 809 ) ); 810} 811 812void __glXDispSwap_Vertex3dv(GLbyte * pc) 813{ 814#ifdef __GLX_ALIGN64 815 if ((unsigned long)(pc) & 7) { 816 (void) memmove(pc-4, pc, 24); 817 pc -= 4; 818 } 819#endif 820 821 CALL_Vertex3dv( GET_DISPATCH(), ( 822 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 3 ) 823 ) ); 824} 825 826void __glXDispSwap_Vertex3fv(GLbyte * pc) 827{ 828 CALL_Vertex3fv( GET_DISPATCH(), ( 829 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 830 ) ); 831} 832 833void __glXDispSwap_Vertex3iv(GLbyte * pc) 834{ 835 CALL_Vertex3iv( GET_DISPATCH(), ( 836 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 837 ) ); 838} 839 840void __glXDispSwap_Vertex3sv(GLbyte * pc) 841{ 842 CALL_Vertex3sv( GET_DISPATCH(), ( 843 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 3 ) 844 ) ); 845} 846 847void __glXDispSwap_Vertex4dv(GLbyte * pc) 848{ 849#ifdef __GLX_ALIGN64 850 if ((unsigned long)(pc) & 7) { 851 (void) memmove(pc-4, pc, 32); 852 pc -= 4; 853 } 854#endif 855 856 CALL_Vertex4dv( GET_DISPATCH(), ( 857 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 4 ) 858 ) ); 859} 860 861void __glXDispSwap_Vertex4fv(GLbyte * pc) 862{ 863 CALL_Vertex4fv( GET_DISPATCH(), ( 864 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 4 ) 865 ) ); 866} 867 868void __glXDispSwap_Vertex4iv(GLbyte * pc) 869{ 870 CALL_Vertex4iv( GET_DISPATCH(), ( 871 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 4 ) 872 ) ); 873} 874 875void __glXDispSwap_Vertex4sv(GLbyte * pc) 876{ 877 CALL_Vertex4sv( GET_DISPATCH(), ( 878 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 4 ) 879 ) ); 880} 881 882void __glXDispSwap_ClipPlane(GLbyte * pc) 883{ 884#ifdef __GLX_ALIGN64 885 if ((unsigned long)(pc) & 7) { 886 (void) memmove(pc-4, pc, 36); 887 pc -= 4; 888 } 889#endif 890 891 CALL_ClipPlane( GET_DISPATCH(), ( 892 (GLenum )bswap_ENUM ( pc + 32 ), 893 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 4 ) 894 ) ); 895} 896 897void __glXDispSwap_ColorMaterial(GLbyte * pc) 898{ 899 CALL_ColorMaterial( GET_DISPATCH(), ( 900 (GLenum )bswap_ENUM ( pc + 0 ), 901 (GLenum )bswap_ENUM ( pc + 4 ) 902 ) ); 903} 904 905void __glXDispSwap_CullFace(GLbyte * pc) 906{ 907 CALL_CullFace( GET_DISPATCH(), ( 908 (GLenum )bswap_ENUM ( pc + 0 ) 909 ) ); 910} 911 912void __glXDispSwap_Fogf(GLbyte * pc) 913{ 914 CALL_Fogf( GET_DISPATCH(), ( 915 (GLenum )bswap_ENUM ( pc + 0 ), 916 (GLfloat )bswap_FLOAT32( pc + 4 ) 917 ) ); 918} 919 920void __glXDispSwap_Fogfv(GLbyte * pc) 921{ 922 const GLenum pname = (GLenum )bswap_ENUM ( pc + 0 ); 923 const GLfloat * params; 924 925 params = (const GLfloat *) bswap_32_array( (uint32_t *) (pc + 4), __glFogfv_size(pname) ); 926 927 CALL_Fogfv( GET_DISPATCH(), ( 928 pname, 929 params 930 ) ); 931} 932 933void __glXDispSwap_Fogi(GLbyte * pc) 934{ 935 CALL_Fogi( GET_DISPATCH(), ( 936 (GLenum )bswap_ENUM ( pc + 0 ), 937 (GLint )bswap_CARD32 ( pc + 4 ) 938 ) ); 939} 940 941void __glXDispSwap_Fogiv(GLbyte * pc) 942{ 943 const GLenum pname = (GLenum )bswap_ENUM ( pc + 0 ); 944 const GLint * params; 945 946 params = (const GLint *) bswap_32_array( (uint32_t *) (pc + 4), __glFogiv_size(pname) ); 947 948 CALL_Fogiv( GET_DISPATCH(), ( 949 pname, 950 params 951 ) ); 952} 953 954void __glXDispSwap_FrontFace(GLbyte * pc) 955{ 956 CALL_FrontFace( GET_DISPATCH(), ( 957 (GLenum )bswap_ENUM ( pc + 0 ) 958 ) ); 959} 960 961void __glXDispSwap_Hint(GLbyte * pc) 962{ 963 CALL_Hint( GET_DISPATCH(), ( 964 (GLenum )bswap_ENUM ( pc + 0 ), 965 (GLenum )bswap_ENUM ( pc + 4 ) 966 ) ); 967} 968 969void __glXDispSwap_Lightf(GLbyte * pc) 970{ 971 CALL_Lightf( GET_DISPATCH(), ( 972 (GLenum )bswap_ENUM ( pc + 0 ), 973 (GLenum )bswap_ENUM ( pc + 4 ), 974 (GLfloat )bswap_FLOAT32( pc + 8 ) 975 ) ); 976} 977 978void __glXDispSwap_Lightfv(GLbyte * pc) 979{ 980 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 981 const GLfloat * params; 982 983 params = (const GLfloat *) bswap_32_array( (uint32_t *) (pc + 8), __glLightfv_size(pname) ); 984 985 CALL_Lightfv( GET_DISPATCH(), ( 986 (GLenum )bswap_ENUM ( pc + 0 ), 987 pname, 988 params 989 ) ); 990} 991 992void __glXDispSwap_Lighti(GLbyte * pc) 993{ 994 CALL_Lighti( GET_DISPATCH(), ( 995 (GLenum )bswap_ENUM ( pc + 0 ), 996 (GLenum )bswap_ENUM ( pc + 4 ), 997 (GLint )bswap_CARD32 ( pc + 8 ) 998 ) ); 999} 1000 1001void __glXDispSwap_Lightiv(GLbyte * pc) 1002{ 1003 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 1004 const GLint * params; 1005 1006 params = (const GLint *) bswap_32_array( (uint32_t *) (pc + 8), __glLightiv_size(pname) ); 1007 1008 CALL_Lightiv( GET_DISPATCH(), ( 1009 (GLenum )bswap_ENUM ( pc + 0 ), 1010 pname, 1011 params 1012 ) ); 1013} 1014 1015void __glXDispSwap_LightModelf(GLbyte * pc) 1016{ 1017 CALL_LightModelf( GET_DISPATCH(), ( 1018 (GLenum )bswap_ENUM ( pc + 0 ), 1019 (GLfloat )bswap_FLOAT32( pc + 4 ) 1020 ) ); 1021} 1022 1023void __glXDispSwap_LightModelfv(GLbyte * pc) 1024{ 1025 const GLenum pname = (GLenum )bswap_ENUM ( pc + 0 ); 1026 const GLfloat * params; 1027 1028 params = (const GLfloat *) bswap_32_array( (uint32_t *) (pc + 4), __glLightModelfv_size(pname) ); 1029 1030 CALL_LightModelfv( GET_DISPATCH(), ( 1031 pname, 1032 params 1033 ) ); 1034} 1035 1036void __glXDispSwap_LightModeli(GLbyte * pc) 1037{ 1038 CALL_LightModeli( GET_DISPATCH(), ( 1039 (GLenum )bswap_ENUM ( pc + 0 ), 1040 (GLint )bswap_CARD32 ( pc + 4 ) 1041 ) ); 1042} 1043 1044void __glXDispSwap_LightModeliv(GLbyte * pc) 1045{ 1046 const GLenum pname = (GLenum )bswap_ENUM ( pc + 0 ); 1047 const GLint * params; 1048 1049 params = (const GLint *) bswap_32_array( (uint32_t *) (pc + 4), __glLightModeliv_size(pname) ); 1050 1051 CALL_LightModeliv( GET_DISPATCH(), ( 1052 pname, 1053 params 1054 ) ); 1055} 1056 1057void __glXDispSwap_LineStipple(GLbyte * pc) 1058{ 1059 CALL_LineStipple( GET_DISPATCH(), ( 1060 (GLint )bswap_CARD32 ( pc + 0 ), 1061 (GLushort)bswap_CARD16 ( pc + 4 ) 1062 ) ); 1063} 1064 1065void __glXDispSwap_LineWidth(GLbyte * pc) 1066{ 1067 CALL_LineWidth( GET_DISPATCH(), ( 1068 (GLfloat )bswap_FLOAT32( pc + 0 ) 1069 ) ); 1070} 1071 1072void __glXDispSwap_Materialf(GLbyte * pc) 1073{ 1074 CALL_Materialf( GET_DISPATCH(), ( 1075 (GLenum )bswap_ENUM ( pc + 0 ), 1076 (GLenum )bswap_ENUM ( pc + 4 ), 1077 (GLfloat )bswap_FLOAT32( pc + 8 ) 1078 ) ); 1079} 1080 1081void __glXDispSwap_Materialfv(GLbyte * pc) 1082{ 1083 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 1084 const GLfloat * params; 1085 1086 params = (const GLfloat *) bswap_32_array( (uint32_t *) (pc + 8), __glMaterialfv_size(pname) ); 1087 1088 CALL_Materialfv( GET_DISPATCH(), ( 1089 (GLenum )bswap_ENUM ( pc + 0 ), 1090 pname, 1091 params 1092 ) ); 1093} 1094 1095void __glXDispSwap_Materiali(GLbyte * pc) 1096{ 1097 CALL_Materiali( GET_DISPATCH(), ( 1098 (GLenum )bswap_ENUM ( pc + 0 ), 1099 (GLenum )bswap_ENUM ( pc + 4 ), 1100 (GLint )bswap_CARD32 ( pc + 8 ) 1101 ) ); 1102} 1103 1104void __glXDispSwap_Materialiv(GLbyte * pc) 1105{ 1106 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 1107 const GLint * params; 1108 1109 params = (const GLint *) bswap_32_array( (uint32_t *) (pc + 8), __glMaterialiv_size(pname) ); 1110 1111 CALL_Materialiv( GET_DISPATCH(), ( 1112 (GLenum )bswap_ENUM ( pc + 0 ), 1113 pname, 1114 params 1115 ) ); 1116} 1117 1118void __glXDispSwap_PointSize(GLbyte * pc) 1119{ 1120 CALL_PointSize( GET_DISPATCH(), ( 1121 (GLfloat )bswap_FLOAT32( pc + 0 ) 1122 ) ); 1123} 1124 1125void __glXDispSwap_PolygonMode(GLbyte * pc) 1126{ 1127 CALL_PolygonMode( GET_DISPATCH(), ( 1128 (GLenum )bswap_ENUM ( pc + 0 ), 1129 (GLenum )bswap_ENUM ( pc + 4 ) 1130 ) ); 1131} 1132 1133void __glXDispSwap_PolygonStipple(GLbyte * pc) 1134{ 1135 const GLubyte * const mask = (const GLubyte *) (pc + 20); 1136 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 1137 1138 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 1139 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 1140 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 1141 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 1142 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 1143 1144 CALL_PolygonStipple( GET_DISPATCH(), ( 1145 mask 1146 ) ); 1147} 1148 1149void __glXDispSwap_Scissor(GLbyte * pc) 1150{ 1151 CALL_Scissor( GET_DISPATCH(), ( 1152 (GLint )bswap_CARD32 ( pc + 0 ), 1153 (GLint )bswap_CARD32 ( pc + 4 ), 1154 (GLsizei )bswap_CARD32 ( pc + 8 ), 1155 (GLsizei )bswap_CARD32 ( pc + 12 ) 1156 ) ); 1157} 1158 1159void __glXDispSwap_ShadeModel(GLbyte * pc) 1160{ 1161 CALL_ShadeModel( GET_DISPATCH(), ( 1162 (GLenum )bswap_ENUM ( pc + 0 ) 1163 ) ); 1164} 1165 1166void __glXDispSwap_TexParameterf(GLbyte * pc) 1167{ 1168 CALL_TexParameterf( GET_DISPATCH(), ( 1169 (GLenum )bswap_ENUM ( pc + 0 ), 1170 (GLenum )bswap_ENUM ( pc + 4 ), 1171 (GLfloat )bswap_FLOAT32( pc + 8 ) 1172 ) ); 1173} 1174 1175void __glXDispSwap_TexParameterfv(GLbyte * pc) 1176{ 1177 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 1178 const GLfloat * params; 1179 1180 params = (const GLfloat *) bswap_32_array( (uint32_t *) (pc + 8), __glTexParameterfv_size(pname) ); 1181 1182 CALL_TexParameterfv( GET_DISPATCH(), ( 1183 (GLenum )bswap_ENUM ( pc + 0 ), 1184 pname, 1185 params 1186 ) ); 1187} 1188 1189void __glXDispSwap_TexParameteri(GLbyte * pc) 1190{ 1191 CALL_TexParameteri( GET_DISPATCH(), ( 1192 (GLenum )bswap_ENUM ( pc + 0 ), 1193 (GLenum )bswap_ENUM ( pc + 4 ), 1194 (GLint )bswap_CARD32 ( pc + 8 ) 1195 ) ); 1196} 1197 1198void __glXDispSwap_TexParameteriv(GLbyte * pc) 1199{ 1200 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 1201 const GLint * params; 1202 1203 params = (const GLint *) bswap_32_array( (uint32_t *) (pc + 8), __glTexParameteriv_size(pname) ); 1204 1205 CALL_TexParameteriv( GET_DISPATCH(), ( 1206 (GLenum )bswap_ENUM ( pc + 0 ), 1207 pname, 1208 params 1209 ) ); 1210} 1211 1212void __glXDispSwap_TexImage1D(GLbyte * pc) 1213{ 1214 const GLvoid * const pixels = (const GLvoid *) (pc + 52); 1215 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 1216 1217 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 1218 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 1219 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 1220 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 1221 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 1222 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 1223 1224 CALL_TexImage1D( GET_DISPATCH(), ( 1225 (GLenum )bswap_ENUM ( pc + 20 ), 1226 (GLint )bswap_CARD32 ( pc + 24 ), 1227 (GLint )bswap_CARD32 ( pc + 28 ), 1228 (GLsizei )bswap_CARD32 ( pc + 32 ), 1229 (GLint )bswap_CARD32 ( pc + 40 ), 1230 (GLenum )bswap_ENUM ( pc + 44 ), 1231 (GLenum )bswap_ENUM ( pc + 48 ), 1232 pixels 1233 ) ); 1234} 1235 1236void __glXDispSwap_TexImage2D(GLbyte * pc) 1237{ 1238 const GLvoid * const pixels = (const GLvoid *) (pc + 52); 1239 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 1240 1241 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 1242 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 1243 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 1244 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 1245 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 1246 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 1247 1248 CALL_TexImage2D( GET_DISPATCH(), ( 1249 (GLenum )bswap_ENUM ( pc + 20 ), 1250 (GLint )bswap_CARD32 ( pc + 24 ), 1251 (GLint )bswap_CARD32 ( pc + 28 ), 1252 (GLsizei )bswap_CARD32 ( pc + 32 ), 1253 (GLsizei )bswap_CARD32 ( pc + 36 ), 1254 (GLint )bswap_CARD32 ( pc + 40 ), 1255 (GLenum )bswap_ENUM ( pc + 44 ), 1256 (GLenum )bswap_ENUM ( pc + 48 ), 1257 pixels 1258 ) ); 1259} 1260 1261void __glXDispSwap_TexEnvf(GLbyte * pc) 1262{ 1263 CALL_TexEnvf( GET_DISPATCH(), ( 1264 (GLenum )bswap_ENUM ( pc + 0 ), 1265 (GLenum )bswap_ENUM ( pc + 4 ), 1266 (GLfloat )bswap_FLOAT32( pc + 8 ) 1267 ) ); 1268} 1269 1270void __glXDispSwap_TexEnvfv(GLbyte * pc) 1271{ 1272 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 1273 const GLfloat * params; 1274 1275 params = (const GLfloat *) bswap_32_array( (uint32_t *) (pc + 8), __glTexEnvfv_size(pname) ); 1276 1277 CALL_TexEnvfv( GET_DISPATCH(), ( 1278 (GLenum )bswap_ENUM ( pc + 0 ), 1279 pname, 1280 params 1281 ) ); 1282} 1283 1284void __glXDispSwap_TexEnvi(GLbyte * pc) 1285{ 1286 CALL_TexEnvi( GET_DISPATCH(), ( 1287 (GLenum )bswap_ENUM ( pc + 0 ), 1288 (GLenum )bswap_ENUM ( pc + 4 ), 1289 (GLint )bswap_CARD32 ( pc + 8 ) 1290 ) ); 1291} 1292 1293void __glXDispSwap_TexEnviv(GLbyte * pc) 1294{ 1295 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 1296 const GLint * params; 1297 1298 params = (const GLint *) bswap_32_array( (uint32_t *) (pc + 8), __glTexEnviv_size(pname) ); 1299 1300 CALL_TexEnviv( GET_DISPATCH(), ( 1301 (GLenum )bswap_ENUM ( pc + 0 ), 1302 pname, 1303 params 1304 ) ); 1305} 1306 1307void __glXDispSwap_TexGend(GLbyte * pc) 1308{ 1309#ifdef __GLX_ALIGN64 1310 if ((unsigned long)(pc) & 7) { 1311 (void) memmove(pc-4, pc, 16); 1312 pc -= 4; 1313 } 1314#endif 1315 1316 CALL_TexGend( GET_DISPATCH(), ( 1317 (GLenum )bswap_ENUM ( pc + 8 ), 1318 (GLenum )bswap_ENUM ( pc + 12 ), 1319 (GLdouble)bswap_FLOAT64( pc + 0 ) 1320 ) ); 1321} 1322 1323void __glXDispSwap_TexGendv(GLbyte * pc) 1324{ 1325 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 1326 const GLdouble * params; 1327 1328#ifdef __GLX_ALIGN64 1329 const GLuint compsize = __glTexGendv_size(pname); 1330 const GLuint cmdlen = 12 + __GLX_PAD((compsize * 8)) - 4; 1331 if ((unsigned long)(pc) & 7) { 1332 (void) memmove(pc-4, pc, cmdlen); 1333 pc -= 4; 1334 } 1335#endif 1336 1337 params = (const GLdouble *) bswap_64_array( (uint64_t *) (pc + 8), __glTexGendv_size(pname) ); 1338 1339 CALL_TexGendv( GET_DISPATCH(), ( 1340 (GLenum )bswap_ENUM ( pc + 0 ), 1341 pname, 1342 params 1343 ) ); 1344} 1345 1346void __glXDispSwap_TexGenf(GLbyte * pc) 1347{ 1348 CALL_TexGenf( GET_DISPATCH(), ( 1349 (GLenum )bswap_ENUM ( pc + 0 ), 1350 (GLenum )bswap_ENUM ( pc + 4 ), 1351 (GLfloat )bswap_FLOAT32( pc + 8 ) 1352 ) ); 1353} 1354 1355void __glXDispSwap_TexGenfv(GLbyte * pc) 1356{ 1357 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 1358 const GLfloat * params; 1359 1360 params = (const GLfloat *) bswap_32_array( (uint32_t *) (pc + 8), __glTexGenfv_size(pname) ); 1361 1362 CALL_TexGenfv( GET_DISPATCH(), ( 1363 (GLenum )bswap_ENUM ( pc + 0 ), 1364 pname, 1365 params 1366 ) ); 1367} 1368 1369void __glXDispSwap_TexGeni(GLbyte * pc) 1370{ 1371 CALL_TexGeni( GET_DISPATCH(), ( 1372 (GLenum )bswap_ENUM ( pc + 0 ), 1373 (GLenum )bswap_ENUM ( pc + 4 ), 1374 (GLint )bswap_CARD32 ( pc + 8 ) 1375 ) ); 1376} 1377 1378void __glXDispSwap_TexGeniv(GLbyte * pc) 1379{ 1380 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 1381 const GLint * params; 1382 1383 params = (const GLint *) bswap_32_array( (uint32_t *) (pc + 8), __glTexGeniv_size(pname) ); 1384 1385 CALL_TexGeniv( GET_DISPATCH(), ( 1386 (GLenum )bswap_ENUM ( pc + 0 ), 1387 pname, 1388 params 1389 ) ); 1390} 1391 1392void __glXDispSwap_InitNames(GLbyte * pc) 1393{ 1394 CALL_InitNames( GET_DISPATCH(), () ); 1395} 1396 1397void __glXDispSwap_LoadName(GLbyte * pc) 1398{ 1399 CALL_LoadName( GET_DISPATCH(), ( 1400 (GLuint )bswap_CARD32 ( pc + 0 ) 1401 ) ); 1402} 1403 1404void __glXDispSwap_PassThrough(GLbyte * pc) 1405{ 1406 CALL_PassThrough( GET_DISPATCH(), ( 1407 (GLfloat )bswap_FLOAT32( pc + 0 ) 1408 ) ); 1409} 1410 1411void __glXDispSwap_PopName(GLbyte * pc) 1412{ 1413 CALL_PopName( GET_DISPATCH(), () ); 1414} 1415 1416void __glXDispSwap_PushName(GLbyte * pc) 1417{ 1418 CALL_PushName( GET_DISPATCH(), ( 1419 (GLuint )bswap_CARD32 ( pc + 0 ) 1420 ) ); 1421} 1422 1423void __glXDispSwap_DrawBuffer(GLbyte * pc) 1424{ 1425 CALL_DrawBuffer( GET_DISPATCH(), ( 1426 (GLenum )bswap_ENUM ( pc + 0 ) 1427 ) ); 1428} 1429 1430void __glXDispSwap_Clear(GLbyte * pc) 1431{ 1432 CALL_Clear( GET_DISPATCH(), ( 1433 (GLbitfield)bswap_CARD32 ( pc + 0 ) 1434 ) ); 1435} 1436 1437void __glXDispSwap_ClearAccum(GLbyte * pc) 1438{ 1439 CALL_ClearAccum( GET_DISPATCH(), ( 1440 (GLfloat )bswap_FLOAT32( pc + 0 ), 1441 (GLfloat )bswap_FLOAT32( pc + 4 ), 1442 (GLfloat )bswap_FLOAT32( pc + 8 ), 1443 (GLfloat )bswap_FLOAT32( pc + 12 ) 1444 ) ); 1445} 1446 1447void __glXDispSwap_ClearIndex(GLbyte * pc) 1448{ 1449 CALL_ClearIndex( GET_DISPATCH(), ( 1450 (GLfloat )bswap_FLOAT32( pc + 0 ) 1451 ) ); 1452} 1453 1454void __glXDispSwap_ClearColor(GLbyte * pc) 1455{ 1456 CALL_ClearColor( GET_DISPATCH(), ( 1457 (GLclampf)bswap_FLOAT32( pc + 0 ), 1458 (GLclampf)bswap_FLOAT32( pc + 4 ), 1459 (GLclampf)bswap_FLOAT32( pc + 8 ), 1460 (GLclampf)bswap_FLOAT32( pc + 12 ) 1461 ) ); 1462} 1463 1464void __glXDispSwap_ClearStencil(GLbyte * pc) 1465{ 1466 CALL_ClearStencil( GET_DISPATCH(), ( 1467 (GLint )bswap_CARD32 ( pc + 0 ) 1468 ) ); 1469} 1470 1471void __glXDispSwap_ClearDepth(GLbyte * pc) 1472{ 1473#ifdef __GLX_ALIGN64 1474 if ((unsigned long)(pc) & 7) { 1475 (void) memmove(pc-4, pc, 8); 1476 pc -= 4; 1477 } 1478#endif 1479 1480 CALL_ClearDepth( GET_DISPATCH(), ( 1481 (GLclampd)bswap_FLOAT64( pc + 0 ) 1482 ) ); 1483} 1484 1485void __glXDispSwap_StencilMask(GLbyte * pc) 1486{ 1487 CALL_StencilMask( GET_DISPATCH(), ( 1488 (GLuint )bswap_CARD32 ( pc + 0 ) 1489 ) ); 1490} 1491 1492void __glXDispSwap_ColorMask(GLbyte * pc) 1493{ 1494 CALL_ColorMask( GET_DISPATCH(), ( 1495 *(GLboolean *)(pc + 0), 1496 *(GLboolean *)(pc + 1), 1497 *(GLboolean *)(pc + 2), 1498 *(GLboolean *)(pc + 3) 1499 ) ); 1500} 1501 1502void __glXDispSwap_DepthMask(GLbyte * pc) 1503{ 1504 CALL_DepthMask( GET_DISPATCH(), ( 1505 *(GLboolean *)(pc + 0) 1506 ) ); 1507} 1508 1509void __glXDispSwap_IndexMask(GLbyte * pc) 1510{ 1511 CALL_IndexMask( GET_DISPATCH(), ( 1512 (GLuint )bswap_CARD32 ( pc + 0 ) 1513 ) ); 1514} 1515 1516void __glXDispSwap_Accum(GLbyte * pc) 1517{ 1518 CALL_Accum( GET_DISPATCH(), ( 1519 (GLenum )bswap_ENUM ( pc + 0 ), 1520 (GLfloat )bswap_FLOAT32( pc + 4 ) 1521 ) ); 1522} 1523 1524void __glXDispSwap_Disable(GLbyte * pc) 1525{ 1526 CALL_Disable( GET_DISPATCH(), ( 1527 (GLenum )bswap_ENUM ( pc + 0 ) 1528 ) ); 1529} 1530 1531void __glXDispSwap_Enable(GLbyte * pc) 1532{ 1533 CALL_Enable( GET_DISPATCH(), ( 1534 (GLenum )bswap_ENUM ( pc + 0 ) 1535 ) ); 1536} 1537 1538void __glXDispSwap_PopAttrib(GLbyte * pc) 1539{ 1540 CALL_PopAttrib( GET_DISPATCH(), () ); 1541} 1542 1543void __glXDispSwap_PushAttrib(GLbyte * pc) 1544{ 1545 CALL_PushAttrib( GET_DISPATCH(), ( 1546 (GLbitfield)bswap_CARD32 ( pc + 0 ) 1547 ) ); 1548} 1549 1550void __glXDispSwap_MapGrid1d(GLbyte * pc) 1551{ 1552#ifdef __GLX_ALIGN64 1553 if ((unsigned long)(pc) & 7) { 1554 (void) memmove(pc-4, pc, 20); 1555 pc -= 4; 1556 } 1557#endif 1558 1559 CALL_MapGrid1d( GET_DISPATCH(), ( 1560 (GLint )bswap_CARD32 ( pc + 16 ), 1561 (GLdouble)bswap_FLOAT64( pc + 0 ), 1562 (GLdouble)bswap_FLOAT64( pc + 8 ) 1563 ) ); 1564} 1565 1566void __glXDispSwap_MapGrid1f(GLbyte * pc) 1567{ 1568 CALL_MapGrid1f( GET_DISPATCH(), ( 1569 (GLint )bswap_CARD32 ( pc + 0 ), 1570 (GLfloat )bswap_FLOAT32( pc + 4 ), 1571 (GLfloat )bswap_FLOAT32( pc + 8 ) 1572 ) ); 1573} 1574 1575void __glXDispSwap_MapGrid2d(GLbyte * pc) 1576{ 1577#ifdef __GLX_ALIGN64 1578 if ((unsigned long)(pc) & 7) { 1579 (void) memmove(pc-4, pc, 40); 1580 pc -= 4; 1581 } 1582#endif 1583 1584 CALL_MapGrid2d( GET_DISPATCH(), ( 1585 (GLint )bswap_CARD32 ( pc + 32 ), 1586 (GLdouble)bswap_FLOAT64( pc + 0 ), 1587 (GLdouble)bswap_FLOAT64( pc + 8 ), 1588 (GLint )bswap_CARD32 ( pc + 36 ), 1589 (GLdouble)bswap_FLOAT64( pc + 16 ), 1590 (GLdouble)bswap_FLOAT64( pc + 24 ) 1591 ) ); 1592} 1593 1594void __glXDispSwap_MapGrid2f(GLbyte * pc) 1595{ 1596 CALL_MapGrid2f( GET_DISPATCH(), ( 1597 (GLint )bswap_CARD32 ( pc + 0 ), 1598 (GLfloat )bswap_FLOAT32( pc + 4 ), 1599 (GLfloat )bswap_FLOAT32( pc + 8 ), 1600 (GLint )bswap_CARD32 ( pc + 12 ), 1601 (GLfloat )bswap_FLOAT32( pc + 16 ), 1602 (GLfloat )bswap_FLOAT32( pc + 20 ) 1603 ) ); 1604} 1605 1606void __glXDispSwap_EvalCoord1dv(GLbyte * pc) 1607{ 1608#ifdef __GLX_ALIGN64 1609 if ((unsigned long)(pc) & 7) { 1610 (void) memmove(pc-4, pc, 8); 1611 pc -= 4; 1612 } 1613#endif 1614 1615 CALL_EvalCoord1dv( GET_DISPATCH(), ( 1616 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 1 ) 1617 ) ); 1618} 1619 1620void __glXDispSwap_EvalCoord1fv(GLbyte * pc) 1621{ 1622 CALL_EvalCoord1fv( GET_DISPATCH(), ( 1623 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 1 ) 1624 ) ); 1625} 1626 1627void __glXDispSwap_EvalCoord2dv(GLbyte * pc) 1628{ 1629#ifdef __GLX_ALIGN64 1630 if ((unsigned long)(pc) & 7) { 1631 (void) memmove(pc-4, pc, 16); 1632 pc -= 4; 1633 } 1634#endif 1635 1636 CALL_EvalCoord2dv( GET_DISPATCH(), ( 1637 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 2 ) 1638 ) ); 1639} 1640 1641void __glXDispSwap_EvalCoord2fv(GLbyte * pc) 1642{ 1643 CALL_EvalCoord2fv( GET_DISPATCH(), ( 1644 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 2 ) 1645 ) ); 1646} 1647 1648void __glXDispSwap_EvalMesh1(GLbyte * pc) 1649{ 1650 CALL_EvalMesh1( GET_DISPATCH(), ( 1651 (GLenum )bswap_ENUM ( pc + 0 ), 1652 (GLint )bswap_CARD32 ( pc + 4 ), 1653 (GLint )bswap_CARD32 ( pc + 8 ) 1654 ) ); 1655} 1656 1657void __glXDispSwap_EvalPoint1(GLbyte * pc) 1658{ 1659 CALL_EvalPoint1( GET_DISPATCH(), ( 1660 (GLint )bswap_CARD32 ( pc + 0 ) 1661 ) ); 1662} 1663 1664void __glXDispSwap_EvalMesh2(GLbyte * pc) 1665{ 1666 CALL_EvalMesh2( GET_DISPATCH(), ( 1667 (GLenum )bswap_ENUM ( pc + 0 ), 1668 (GLint )bswap_CARD32 ( pc + 4 ), 1669 (GLint )bswap_CARD32 ( pc + 8 ), 1670 (GLint )bswap_CARD32 ( pc + 12 ), 1671 (GLint )bswap_CARD32 ( pc + 16 ) 1672 ) ); 1673} 1674 1675void __glXDispSwap_EvalPoint2(GLbyte * pc) 1676{ 1677 CALL_EvalPoint2( GET_DISPATCH(), ( 1678 (GLint )bswap_CARD32 ( pc + 0 ), 1679 (GLint )bswap_CARD32 ( pc + 4 ) 1680 ) ); 1681} 1682 1683void __glXDispSwap_AlphaFunc(GLbyte * pc) 1684{ 1685 CALL_AlphaFunc( GET_DISPATCH(), ( 1686 (GLenum )bswap_ENUM ( pc + 0 ), 1687 (GLclampf)bswap_FLOAT32( pc + 4 ) 1688 ) ); 1689} 1690 1691void __glXDispSwap_BlendFunc(GLbyte * pc) 1692{ 1693 CALL_BlendFunc( GET_DISPATCH(), ( 1694 (GLenum )bswap_ENUM ( pc + 0 ), 1695 (GLenum )bswap_ENUM ( pc + 4 ) 1696 ) ); 1697} 1698 1699void __glXDispSwap_LogicOp(GLbyte * pc) 1700{ 1701 CALL_LogicOp( GET_DISPATCH(), ( 1702 (GLenum )bswap_ENUM ( pc + 0 ) 1703 ) ); 1704} 1705 1706void __glXDispSwap_StencilFunc(GLbyte * pc) 1707{ 1708 CALL_StencilFunc( GET_DISPATCH(), ( 1709 (GLenum )bswap_ENUM ( pc + 0 ), 1710 (GLint )bswap_CARD32 ( pc + 4 ), 1711 (GLuint )bswap_CARD32 ( pc + 8 ) 1712 ) ); 1713} 1714 1715void __glXDispSwap_StencilOp(GLbyte * pc) 1716{ 1717 CALL_StencilOp( GET_DISPATCH(), ( 1718 (GLenum )bswap_ENUM ( pc + 0 ), 1719 (GLenum )bswap_ENUM ( pc + 4 ), 1720 (GLenum )bswap_ENUM ( pc + 8 ) 1721 ) ); 1722} 1723 1724void __glXDispSwap_DepthFunc(GLbyte * pc) 1725{ 1726 CALL_DepthFunc( GET_DISPATCH(), ( 1727 (GLenum )bswap_ENUM ( pc + 0 ) 1728 ) ); 1729} 1730 1731void __glXDispSwap_PixelZoom(GLbyte * pc) 1732{ 1733 CALL_PixelZoom( GET_DISPATCH(), ( 1734 (GLfloat )bswap_FLOAT32( pc + 0 ), 1735 (GLfloat )bswap_FLOAT32( pc + 4 ) 1736 ) ); 1737} 1738 1739void __glXDispSwap_PixelTransferf(GLbyte * pc) 1740{ 1741 CALL_PixelTransferf( GET_DISPATCH(), ( 1742 (GLenum )bswap_ENUM ( pc + 0 ), 1743 (GLfloat )bswap_FLOAT32( pc + 4 ) 1744 ) ); 1745} 1746 1747void __glXDispSwap_PixelTransferi(GLbyte * pc) 1748{ 1749 CALL_PixelTransferi( GET_DISPATCH(), ( 1750 (GLenum )bswap_ENUM ( pc + 0 ), 1751 (GLint )bswap_CARD32 ( pc + 4 ) 1752 ) ); 1753} 1754 1755int __glXDispSwap_PixelStoref(__GLXclientState *cl, GLbyte *pc) 1756{ 1757 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 1758 int error; 1759 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 1760 1761 pc += __GLX_SINGLE_HDR_SIZE; 1762 if ( cx != NULL ) { 1763 CALL_PixelStoref( GET_DISPATCH(), ( 1764 (GLenum )bswap_ENUM ( pc + 0 ), 1765 (GLfloat )bswap_FLOAT32( pc + 4 ) 1766 ) ); 1767 error = Success; 1768 } 1769 1770 return error; 1771} 1772 1773int __glXDispSwap_PixelStorei(__GLXclientState *cl, GLbyte *pc) 1774{ 1775 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 1776 int error; 1777 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 1778 1779 pc += __GLX_SINGLE_HDR_SIZE; 1780 if ( cx != NULL ) { 1781 CALL_PixelStorei( GET_DISPATCH(), ( 1782 (GLenum )bswap_ENUM ( pc + 0 ), 1783 (GLint )bswap_CARD32 ( pc + 4 ) 1784 ) ); 1785 error = Success; 1786 } 1787 1788 return error; 1789} 1790 1791void __glXDispSwap_PixelMapfv(GLbyte * pc) 1792{ 1793 const GLsizei mapsize = (GLsizei )bswap_CARD32 ( pc + 4 ); 1794 1795 CALL_PixelMapfv( GET_DISPATCH(), ( 1796 (GLenum )bswap_ENUM ( pc + 0 ), 1797 mapsize, 1798 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 8), 0 ) 1799 ) ); 1800} 1801 1802void __glXDispSwap_PixelMapuiv(GLbyte * pc) 1803{ 1804 const GLsizei mapsize = (GLsizei )bswap_CARD32 ( pc + 4 ); 1805 1806 CALL_PixelMapuiv( GET_DISPATCH(), ( 1807 (GLenum )bswap_ENUM ( pc + 0 ), 1808 mapsize, 1809 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 8), 0 ) 1810 ) ); 1811} 1812 1813void __glXDispSwap_PixelMapusv(GLbyte * pc) 1814{ 1815 const GLsizei mapsize = (GLsizei )bswap_CARD32 ( pc + 4 ); 1816 1817 CALL_PixelMapusv( GET_DISPATCH(), ( 1818 (GLenum )bswap_ENUM ( pc + 0 ), 1819 mapsize, 1820 (const GLushort *)bswap_16_array( (uint16_t *) (pc + 8), 0 ) 1821 ) ); 1822} 1823 1824void __glXDispSwap_ReadBuffer(GLbyte * pc) 1825{ 1826 CALL_ReadBuffer( GET_DISPATCH(), ( 1827 (GLenum )bswap_ENUM ( pc + 0 ) 1828 ) ); 1829} 1830 1831void __glXDispSwap_CopyPixels(GLbyte * pc) 1832{ 1833 CALL_CopyPixels( GET_DISPATCH(), ( 1834 (GLint )bswap_CARD32 ( pc + 0 ), 1835 (GLint )bswap_CARD32 ( pc + 4 ), 1836 (GLsizei )bswap_CARD32 ( pc + 8 ), 1837 (GLsizei )bswap_CARD32 ( pc + 12 ), 1838 (GLenum )bswap_ENUM ( pc + 16 ) 1839 ) ); 1840} 1841 1842void __glXDispSwap_DrawPixels(GLbyte * pc) 1843{ 1844 const GLvoid * const pixels = (const GLvoid *) (pc + 36); 1845 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 1846 1847 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 1848 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 1849 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 1850 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 1851 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 1852 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 1853 1854 CALL_DrawPixels( GET_DISPATCH(), ( 1855 (GLsizei )bswap_CARD32 ( pc + 20 ), 1856 (GLsizei )bswap_CARD32 ( pc + 24 ), 1857 (GLenum )bswap_ENUM ( pc + 28 ), 1858 (GLenum )bswap_ENUM ( pc + 32 ), 1859 pixels 1860 ) ); 1861} 1862 1863int __glXDispSwap_GetBooleanv(__GLXclientState *cl, GLbyte *pc) 1864{ 1865 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 1866 int error; 1867 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 1868 1869 pc += __GLX_SINGLE_HDR_SIZE; 1870 if ( cx != NULL ) { 1871 const GLenum pname = (GLenum )bswap_ENUM ( pc + 0 ); 1872 1873 const GLuint compsize = __glGetBooleanv_size(pname); 1874 GLboolean answerBuffer[200]; 1875 GLboolean * params = __glXGetAnswerBuffer(cl, compsize, answerBuffer, sizeof(answerBuffer), 1); 1876 1877 if (params == NULL) return BadAlloc; 1878 __glXClearErrorOccured(); 1879 1880 CALL_GetBooleanv( GET_DISPATCH(), ( 1881 pname, 1882 params 1883 ) ); 1884 __glXSendReplySwap(cl->client, params, compsize, 1, GL_FALSE, 0); 1885 error = Success; 1886 } 1887 1888 return error; 1889} 1890 1891int __glXDispSwap_GetClipPlane(__GLXclientState *cl, GLbyte *pc) 1892{ 1893 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 1894 int error; 1895 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 1896 1897 pc += __GLX_SINGLE_HDR_SIZE; 1898 if ( cx != NULL ) { 1899 GLdouble equation[4]; 1900 CALL_GetClipPlane( GET_DISPATCH(), ( 1901 (GLenum )bswap_ENUM ( pc + 0 ), 1902 equation 1903 ) ); 1904 (void) bswap_64_array( (uint64_t *) equation, 4 ); 1905 __glXSendReplySwap(cl->client, equation, 4, 8, GL_TRUE, 0); 1906 error = Success; 1907 } 1908 1909 return error; 1910} 1911 1912int __glXDispSwap_GetDoublev(__GLXclientState *cl, GLbyte *pc) 1913{ 1914 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 1915 int error; 1916 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 1917 1918 pc += __GLX_SINGLE_HDR_SIZE; 1919 if ( cx != NULL ) { 1920 const GLenum pname = (GLenum )bswap_ENUM ( pc + 0 ); 1921 1922 const GLuint compsize = __glGetDoublev_size(pname); 1923 GLdouble answerBuffer[200]; 1924 GLdouble * params = __glXGetAnswerBuffer(cl, compsize * 8, answerBuffer, sizeof(answerBuffer), 8); 1925 1926 if (params == NULL) return BadAlloc; 1927 __glXClearErrorOccured(); 1928 1929 CALL_GetDoublev( GET_DISPATCH(), ( 1930 pname, 1931 params 1932 ) ); 1933 (void) bswap_64_array( (uint64_t *) params, compsize ); 1934 __glXSendReplySwap(cl->client, params, compsize, 8, GL_FALSE, 0); 1935 error = Success; 1936 } 1937 1938 return error; 1939} 1940 1941int __glXDispSwap_GetError(__GLXclientState *cl, GLbyte *pc) 1942{ 1943 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 1944 int error; 1945 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 1946 1947 pc += __GLX_SINGLE_HDR_SIZE; 1948 if ( cx != NULL ) { 1949 GLenum retval; 1950 retval = CALL_GetError( GET_DISPATCH(), () ); 1951 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 1952 error = Success; 1953 } 1954 1955 return error; 1956} 1957 1958int __glXDispSwap_GetFloatv(__GLXclientState *cl, GLbyte *pc) 1959{ 1960 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 1961 int error; 1962 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 1963 1964 pc += __GLX_SINGLE_HDR_SIZE; 1965 if ( cx != NULL ) { 1966 const GLenum pname = (GLenum )bswap_ENUM ( pc + 0 ); 1967 1968 const GLuint compsize = __glGetFloatv_size(pname); 1969 GLfloat answerBuffer[200]; 1970 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 1971 1972 if (params == NULL) return BadAlloc; 1973 __glXClearErrorOccured(); 1974 1975 CALL_GetFloatv( GET_DISPATCH(), ( 1976 pname, 1977 params 1978 ) ); 1979 (void) bswap_32_array( (uint32_t *) params, compsize ); 1980 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 1981 error = Success; 1982 } 1983 1984 return error; 1985} 1986 1987int __glXDispSwap_GetIntegerv(__GLXclientState *cl, GLbyte *pc) 1988{ 1989 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 1990 int error; 1991 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 1992 1993 pc += __GLX_SINGLE_HDR_SIZE; 1994 if ( cx != NULL ) { 1995 const GLenum pname = (GLenum )bswap_ENUM ( pc + 0 ); 1996 1997 const GLuint compsize = __glGetIntegerv_size(pname); 1998 GLint answerBuffer[200]; 1999 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2000 2001 if (params == NULL) return BadAlloc; 2002 __glXClearErrorOccured(); 2003 2004 CALL_GetIntegerv( GET_DISPATCH(), ( 2005 pname, 2006 params 2007 ) ); 2008 (void) bswap_32_array( (uint32_t *) params, compsize ); 2009 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2010 error = Success; 2011 } 2012 2013 return error; 2014} 2015 2016int __glXDispSwap_GetLightfv(__GLXclientState *cl, GLbyte *pc) 2017{ 2018 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2019 int error; 2020 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2021 2022 pc += __GLX_SINGLE_HDR_SIZE; 2023 if ( cx != NULL ) { 2024 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2025 2026 const GLuint compsize = __glGetLightfv_size(pname); 2027 GLfloat answerBuffer[200]; 2028 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2029 2030 if (params == NULL) return BadAlloc; 2031 __glXClearErrorOccured(); 2032 2033 CALL_GetLightfv( GET_DISPATCH(), ( 2034 (GLenum )bswap_ENUM ( pc + 0 ), 2035 pname, 2036 params 2037 ) ); 2038 (void) bswap_32_array( (uint32_t *) params, compsize ); 2039 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2040 error = Success; 2041 } 2042 2043 return error; 2044} 2045 2046int __glXDispSwap_GetLightiv(__GLXclientState *cl, GLbyte *pc) 2047{ 2048 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2049 int error; 2050 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2051 2052 pc += __GLX_SINGLE_HDR_SIZE; 2053 if ( cx != NULL ) { 2054 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2055 2056 const GLuint compsize = __glGetLightiv_size(pname); 2057 GLint answerBuffer[200]; 2058 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2059 2060 if (params == NULL) return BadAlloc; 2061 __glXClearErrorOccured(); 2062 2063 CALL_GetLightiv( GET_DISPATCH(), ( 2064 (GLenum )bswap_ENUM ( pc + 0 ), 2065 pname, 2066 params 2067 ) ); 2068 (void) bswap_32_array( (uint32_t *) params, compsize ); 2069 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2070 error = Success; 2071 } 2072 2073 return error; 2074} 2075 2076int __glXDispSwap_GetMapdv(__GLXclientState *cl, GLbyte *pc) 2077{ 2078 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2079 int error; 2080 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2081 2082 pc += __GLX_SINGLE_HDR_SIZE; 2083 if ( cx != NULL ) { 2084 const GLenum target = (GLenum )bswap_ENUM ( pc + 0 ); 2085 const GLenum query = (GLenum )bswap_ENUM ( pc + 4 ); 2086 2087 const GLuint compsize = __glGetMapdv_size(target,query); 2088 GLdouble answerBuffer[200]; 2089 GLdouble * v = __glXGetAnswerBuffer(cl, compsize * 8, answerBuffer, sizeof(answerBuffer), 8); 2090 2091 if (v == NULL) return BadAlloc; 2092 __glXClearErrorOccured(); 2093 2094 CALL_GetMapdv( GET_DISPATCH(), ( 2095 target, 2096 query, 2097 v 2098 ) ); 2099 (void) bswap_64_array( (uint64_t *) v, compsize ); 2100 __glXSendReplySwap(cl->client, v, compsize, 8, GL_FALSE, 0); 2101 error = Success; 2102 } 2103 2104 return error; 2105} 2106 2107int __glXDispSwap_GetMapfv(__GLXclientState *cl, GLbyte *pc) 2108{ 2109 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2110 int error; 2111 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2112 2113 pc += __GLX_SINGLE_HDR_SIZE; 2114 if ( cx != NULL ) { 2115 const GLenum target = (GLenum )bswap_ENUM ( pc + 0 ); 2116 const GLenum query = (GLenum )bswap_ENUM ( pc + 4 ); 2117 2118 const GLuint compsize = __glGetMapfv_size(target,query); 2119 GLfloat answerBuffer[200]; 2120 GLfloat * v = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2121 2122 if (v == NULL) return BadAlloc; 2123 __glXClearErrorOccured(); 2124 2125 CALL_GetMapfv( GET_DISPATCH(), ( 2126 target, 2127 query, 2128 v 2129 ) ); 2130 (void) bswap_32_array( (uint32_t *) v, compsize ); 2131 __glXSendReplySwap(cl->client, v, compsize, 4, GL_FALSE, 0); 2132 error = Success; 2133 } 2134 2135 return error; 2136} 2137 2138int __glXDispSwap_GetMapiv(__GLXclientState *cl, GLbyte *pc) 2139{ 2140 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2141 int error; 2142 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2143 2144 pc += __GLX_SINGLE_HDR_SIZE; 2145 if ( cx != NULL ) { 2146 const GLenum target = (GLenum )bswap_ENUM ( pc + 0 ); 2147 const GLenum query = (GLenum )bswap_ENUM ( pc + 4 ); 2148 2149 const GLuint compsize = __glGetMapiv_size(target,query); 2150 GLint answerBuffer[200]; 2151 GLint * v = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2152 2153 if (v == NULL) return BadAlloc; 2154 __glXClearErrorOccured(); 2155 2156 CALL_GetMapiv( GET_DISPATCH(), ( 2157 target, 2158 query, 2159 v 2160 ) ); 2161 (void) bswap_32_array( (uint32_t *) v, compsize ); 2162 __glXSendReplySwap(cl->client, v, compsize, 4, GL_FALSE, 0); 2163 error = Success; 2164 } 2165 2166 return error; 2167} 2168 2169int __glXDispSwap_GetMaterialfv(__GLXclientState *cl, GLbyte *pc) 2170{ 2171 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2172 int error; 2173 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2174 2175 pc += __GLX_SINGLE_HDR_SIZE; 2176 if ( cx != NULL ) { 2177 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2178 2179 const GLuint compsize = __glGetMaterialfv_size(pname); 2180 GLfloat answerBuffer[200]; 2181 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2182 2183 if (params == NULL) return BadAlloc; 2184 __glXClearErrorOccured(); 2185 2186 CALL_GetMaterialfv( GET_DISPATCH(), ( 2187 (GLenum )bswap_ENUM ( pc + 0 ), 2188 pname, 2189 params 2190 ) ); 2191 (void) bswap_32_array( (uint32_t *) params, compsize ); 2192 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2193 error = Success; 2194 } 2195 2196 return error; 2197} 2198 2199int __glXDispSwap_GetMaterialiv(__GLXclientState *cl, GLbyte *pc) 2200{ 2201 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2202 int error; 2203 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2204 2205 pc += __GLX_SINGLE_HDR_SIZE; 2206 if ( cx != NULL ) { 2207 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2208 2209 const GLuint compsize = __glGetMaterialiv_size(pname); 2210 GLint answerBuffer[200]; 2211 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2212 2213 if (params == NULL) return BadAlloc; 2214 __glXClearErrorOccured(); 2215 2216 CALL_GetMaterialiv( GET_DISPATCH(), ( 2217 (GLenum )bswap_ENUM ( pc + 0 ), 2218 pname, 2219 params 2220 ) ); 2221 (void) bswap_32_array( (uint32_t *) params, compsize ); 2222 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2223 error = Success; 2224 } 2225 2226 return error; 2227} 2228 2229int __glXDispSwap_GetPixelMapfv(__GLXclientState *cl, GLbyte *pc) 2230{ 2231 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2232 int error; 2233 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2234 2235 pc += __GLX_SINGLE_HDR_SIZE; 2236 if ( cx != NULL ) { 2237 const GLenum map = (GLenum )bswap_ENUM ( pc + 0 ); 2238 2239 const GLuint compsize = __glGetPixelMapfv_size(map); 2240 GLfloat answerBuffer[200]; 2241 GLfloat * values = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2242 2243 if (values == NULL) return BadAlloc; 2244 __glXClearErrorOccured(); 2245 2246 CALL_GetPixelMapfv( GET_DISPATCH(), ( 2247 map, 2248 values 2249 ) ); 2250 (void) bswap_32_array( (uint32_t *) values, compsize ); 2251 __glXSendReplySwap(cl->client, values, compsize, 4, GL_FALSE, 0); 2252 error = Success; 2253 } 2254 2255 return error; 2256} 2257 2258int __glXDispSwap_GetPixelMapuiv(__GLXclientState *cl, GLbyte *pc) 2259{ 2260 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2261 int error; 2262 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2263 2264 pc += __GLX_SINGLE_HDR_SIZE; 2265 if ( cx != NULL ) { 2266 const GLenum map = (GLenum )bswap_ENUM ( pc + 0 ); 2267 2268 const GLuint compsize = __glGetPixelMapuiv_size(map); 2269 GLuint answerBuffer[200]; 2270 GLuint * values = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2271 2272 if (values == NULL) return BadAlloc; 2273 __glXClearErrorOccured(); 2274 2275 CALL_GetPixelMapuiv( GET_DISPATCH(), ( 2276 map, 2277 values 2278 ) ); 2279 (void) bswap_32_array( (uint32_t *) values, compsize ); 2280 __glXSendReplySwap(cl->client, values, compsize, 4, GL_FALSE, 0); 2281 error = Success; 2282 } 2283 2284 return error; 2285} 2286 2287int __glXDispSwap_GetPixelMapusv(__GLXclientState *cl, GLbyte *pc) 2288{ 2289 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2290 int error; 2291 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2292 2293 pc += __GLX_SINGLE_HDR_SIZE; 2294 if ( cx != NULL ) { 2295 const GLenum map = (GLenum )bswap_ENUM ( pc + 0 ); 2296 2297 const GLuint compsize = __glGetPixelMapusv_size(map); 2298 GLushort answerBuffer[200]; 2299 GLushort * values = __glXGetAnswerBuffer(cl, compsize * 2, answerBuffer, sizeof(answerBuffer), 2); 2300 2301 if (values == NULL) return BadAlloc; 2302 __glXClearErrorOccured(); 2303 2304 CALL_GetPixelMapusv( GET_DISPATCH(), ( 2305 map, 2306 values 2307 ) ); 2308 (void) bswap_16_array( (uint16_t *) values, compsize ); 2309 __glXSendReplySwap(cl->client, values, compsize, 2, GL_FALSE, 0); 2310 error = Success; 2311 } 2312 2313 return error; 2314} 2315 2316int __glXDispSwap_GetTexEnvfv(__GLXclientState *cl, GLbyte *pc) 2317{ 2318 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2319 int error; 2320 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2321 2322 pc += __GLX_SINGLE_HDR_SIZE; 2323 if ( cx != NULL ) { 2324 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2325 2326 const GLuint compsize = __glGetTexEnvfv_size(pname); 2327 GLfloat answerBuffer[200]; 2328 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2329 2330 if (params == NULL) return BadAlloc; 2331 __glXClearErrorOccured(); 2332 2333 CALL_GetTexEnvfv( GET_DISPATCH(), ( 2334 (GLenum )bswap_ENUM ( pc + 0 ), 2335 pname, 2336 params 2337 ) ); 2338 (void) bswap_32_array( (uint32_t *) params, compsize ); 2339 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2340 error = Success; 2341 } 2342 2343 return error; 2344} 2345 2346int __glXDispSwap_GetTexEnviv(__GLXclientState *cl, GLbyte *pc) 2347{ 2348 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2349 int error; 2350 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2351 2352 pc += __GLX_SINGLE_HDR_SIZE; 2353 if ( cx != NULL ) { 2354 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2355 2356 const GLuint compsize = __glGetTexEnviv_size(pname); 2357 GLint answerBuffer[200]; 2358 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2359 2360 if (params == NULL) return BadAlloc; 2361 __glXClearErrorOccured(); 2362 2363 CALL_GetTexEnviv( GET_DISPATCH(), ( 2364 (GLenum )bswap_ENUM ( pc + 0 ), 2365 pname, 2366 params 2367 ) ); 2368 (void) bswap_32_array( (uint32_t *) params, compsize ); 2369 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2370 error = Success; 2371 } 2372 2373 return error; 2374} 2375 2376int __glXDispSwap_GetTexGendv(__GLXclientState *cl, GLbyte *pc) 2377{ 2378 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2379 int error; 2380 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2381 2382 pc += __GLX_SINGLE_HDR_SIZE; 2383 if ( cx != NULL ) { 2384 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2385 2386 const GLuint compsize = __glGetTexGendv_size(pname); 2387 GLdouble answerBuffer[200]; 2388 GLdouble * params = __glXGetAnswerBuffer(cl, compsize * 8, answerBuffer, sizeof(answerBuffer), 8); 2389 2390 if (params == NULL) return BadAlloc; 2391 __glXClearErrorOccured(); 2392 2393 CALL_GetTexGendv( GET_DISPATCH(), ( 2394 (GLenum )bswap_ENUM ( pc + 0 ), 2395 pname, 2396 params 2397 ) ); 2398 (void) bswap_64_array( (uint64_t *) params, compsize ); 2399 __glXSendReplySwap(cl->client, params, compsize, 8, GL_FALSE, 0); 2400 error = Success; 2401 } 2402 2403 return error; 2404} 2405 2406int __glXDispSwap_GetTexGenfv(__GLXclientState *cl, GLbyte *pc) 2407{ 2408 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2409 int error; 2410 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2411 2412 pc += __GLX_SINGLE_HDR_SIZE; 2413 if ( cx != NULL ) { 2414 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2415 2416 const GLuint compsize = __glGetTexGenfv_size(pname); 2417 GLfloat answerBuffer[200]; 2418 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2419 2420 if (params == NULL) return BadAlloc; 2421 __glXClearErrorOccured(); 2422 2423 CALL_GetTexGenfv( GET_DISPATCH(), ( 2424 (GLenum )bswap_ENUM ( pc + 0 ), 2425 pname, 2426 params 2427 ) ); 2428 (void) bswap_32_array( (uint32_t *) params, compsize ); 2429 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2430 error = Success; 2431 } 2432 2433 return error; 2434} 2435 2436int __glXDispSwap_GetTexGeniv(__GLXclientState *cl, GLbyte *pc) 2437{ 2438 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2439 int error; 2440 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2441 2442 pc += __GLX_SINGLE_HDR_SIZE; 2443 if ( cx != NULL ) { 2444 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2445 2446 const GLuint compsize = __glGetTexGeniv_size(pname); 2447 GLint answerBuffer[200]; 2448 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2449 2450 if (params == NULL) return BadAlloc; 2451 __glXClearErrorOccured(); 2452 2453 CALL_GetTexGeniv( GET_DISPATCH(), ( 2454 (GLenum )bswap_ENUM ( pc + 0 ), 2455 pname, 2456 params 2457 ) ); 2458 (void) bswap_32_array( (uint32_t *) params, compsize ); 2459 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2460 error = Success; 2461 } 2462 2463 return error; 2464} 2465 2466int __glXDispSwap_GetTexParameterfv(__GLXclientState *cl, GLbyte *pc) 2467{ 2468 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2469 int error; 2470 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2471 2472 pc += __GLX_SINGLE_HDR_SIZE; 2473 if ( cx != NULL ) { 2474 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2475 2476 const GLuint compsize = __glGetTexParameterfv_size(pname); 2477 GLfloat answerBuffer[200]; 2478 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2479 2480 if (params == NULL) return BadAlloc; 2481 __glXClearErrorOccured(); 2482 2483 CALL_GetTexParameterfv( GET_DISPATCH(), ( 2484 (GLenum )bswap_ENUM ( pc + 0 ), 2485 pname, 2486 params 2487 ) ); 2488 (void) bswap_32_array( (uint32_t *) params, compsize ); 2489 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2490 error = Success; 2491 } 2492 2493 return error; 2494} 2495 2496int __glXDispSwap_GetTexParameteriv(__GLXclientState *cl, GLbyte *pc) 2497{ 2498 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2499 int error; 2500 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2501 2502 pc += __GLX_SINGLE_HDR_SIZE; 2503 if ( cx != NULL ) { 2504 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 2505 2506 const GLuint compsize = __glGetTexParameteriv_size(pname); 2507 GLint answerBuffer[200]; 2508 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2509 2510 if (params == NULL) return BadAlloc; 2511 __glXClearErrorOccured(); 2512 2513 CALL_GetTexParameteriv( GET_DISPATCH(), ( 2514 (GLenum )bswap_ENUM ( pc + 0 ), 2515 pname, 2516 params 2517 ) ); 2518 (void) bswap_32_array( (uint32_t *) params, compsize ); 2519 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2520 error = Success; 2521 } 2522 2523 return error; 2524} 2525 2526int __glXDispSwap_GetTexLevelParameterfv(__GLXclientState *cl, GLbyte *pc) 2527{ 2528 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2529 int error; 2530 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2531 2532 pc += __GLX_SINGLE_HDR_SIZE; 2533 if ( cx != NULL ) { 2534 const GLenum pname = (GLenum )bswap_ENUM ( pc + 8 ); 2535 2536 const GLuint compsize = __glGetTexLevelParameterfv_size(pname); 2537 GLfloat answerBuffer[200]; 2538 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2539 2540 if (params == NULL) return BadAlloc; 2541 __glXClearErrorOccured(); 2542 2543 CALL_GetTexLevelParameterfv( GET_DISPATCH(), ( 2544 (GLenum )bswap_ENUM ( pc + 0 ), 2545 (GLint )bswap_CARD32 ( pc + 4 ), 2546 pname, 2547 params 2548 ) ); 2549 (void) bswap_32_array( (uint32_t *) params, compsize ); 2550 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2551 error = Success; 2552 } 2553 2554 return error; 2555} 2556 2557int __glXDispSwap_GetTexLevelParameteriv(__GLXclientState *cl, GLbyte *pc) 2558{ 2559 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2560 int error; 2561 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2562 2563 pc += __GLX_SINGLE_HDR_SIZE; 2564 if ( cx != NULL ) { 2565 const GLenum pname = (GLenum )bswap_ENUM ( pc + 8 ); 2566 2567 const GLuint compsize = __glGetTexLevelParameteriv_size(pname); 2568 GLint answerBuffer[200]; 2569 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 2570 2571 if (params == NULL) return BadAlloc; 2572 __glXClearErrorOccured(); 2573 2574 CALL_GetTexLevelParameteriv( GET_DISPATCH(), ( 2575 (GLenum )bswap_ENUM ( pc + 0 ), 2576 (GLint )bswap_CARD32 ( pc + 4 ), 2577 pname, 2578 params 2579 ) ); 2580 (void) bswap_32_array( (uint32_t *) params, compsize ); 2581 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 2582 error = Success; 2583 } 2584 2585 return error; 2586} 2587 2588int __glXDispSwap_IsEnabled(__GLXclientState *cl, GLbyte *pc) 2589{ 2590 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2591 int error; 2592 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2593 2594 pc += __GLX_SINGLE_HDR_SIZE; 2595 if ( cx != NULL ) { 2596 GLboolean retval; 2597 retval = CALL_IsEnabled( GET_DISPATCH(), ( 2598 (GLenum )bswap_ENUM ( pc + 0 ) 2599 ) ); 2600 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 2601 error = Success; 2602 } 2603 2604 return error; 2605} 2606 2607int __glXDispSwap_IsList(__GLXclientState *cl, GLbyte *pc) 2608{ 2609 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2610 int error; 2611 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2612 2613 pc += __GLX_SINGLE_HDR_SIZE; 2614 if ( cx != NULL ) { 2615 GLboolean retval; 2616 retval = CALL_IsList( GET_DISPATCH(), ( 2617 (GLuint )bswap_CARD32 ( pc + 0 ) 2618 ) ); 2619 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 2620 error = Success; 2621 } 2622 2623 return error; 2624} 2625 2626void __glXDispSwap_DepthRange(GLbyte * pc) 2627{ 2628#ifdef __GLX_ALIGN64 2629 if ((unsigned long)(pc) & 7) { 2630 (void) memmove(pc-4, pc, 16); 2631 pc -= 4; 2632 } 2633#endif 2634 2635 CALL_DepthRange( GET_DISPATCH(), ( 2636 (GLclampd)bswap_FLOAT64( pc + 0 ), 2637 (GLclampd)bswap_FLOAT64( pc + 8 ) 2638 ) ); 2639} 2640 2641void __glXDispSwap_Frustum(GLbyte * pc) 2642{ 2643#ifdef __GLX_ALIGN64 2644 if ((unsigned long)(pc) & 7) { 2645 (void) memmove(pc-4, pc, 48); 2646 pc -= 4; 2647 } 2648#endif 2649 2650 CALL_Frustum( GET_DISPATCH(), ( 2651 (GLdouble)bswap_FLOAT64( pc + 0 ), 2652 (GLdouble)bswap_FLOAT64( pc + 8 ), 2653 (GLdouble)bswap_FLOAT64( pc + 16 ), 2654 (GLdouble)bswap_FLOAT64( pc + 24 ), 2655 (GLdouble)bswap_FLOAT64( pc + 32 ), 2656 (GLdouble)bswap_FLOAT64( pc + 40 ) 2657 ) ); 2658} 2659 2660void __glXDispSwap_LoadIdentity(GLbyte * pc) 2661{ 2662 CALL_LoadIdentity( GET_DISPATCH(), () ); 2663} 2664 2665void __glXDispSwap_LoadMatrixf(GLbyte * pc) 2666{ 2667 CALL_LoadMatrixf( GET_DISPATCH(), ( 2668 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 16 ) 2669 ) ); 2670} 2671 2672void __glXDispSwap_LoadMatrixd(GLbyte * pc) 2673{ 2674#ifdef __GLX_ALIGN64 2675 if ((unsigned long)(pc) & 7) { 2676 (void) memmove(pc-4, pc, 128); 2677 pc -= 4; 2678 } 2679#endif 2680 2681 CALL_LoadMatrixd( GET_DISPATCH(), ( 2682 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 16 ) 2683 ) ); 2684} 2685 2686void __glXDispSwap_MatrixMode(GLbyte * pc) 2687{ 2688 CALL_MatrixMode( GET_DISPATCH(), ( 2689 (GLenum )bswap_ENUM ( pc + 0 ) 2690 ) ); 2691} 2692 2693void __glXDispSwap_MultMatrixf(GLbyte * pc) 2694{ 2695 CALL_MultMatrixf( GET_DISPATCH(), ( 2696 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 16 ) 2697 ) ); 2698} 2699 2700void __glXDispSwap_MultMatrixd(GLbyte * pc) 2701{ 2702#ifdef __GLX_ALIGN64 2703 if ((unsigned long)(pc) & 7) { 2704 (void) memmove(pc-4, pc, 128); 2705 pc -= 4; 2706 } 2707#endif 2708 2709 CALL_MultMatrixd( GET_DISPATCH(), ( 2710 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 16 ) 2711 ) ); 2712} 2713 2714void __glXDispSwap_Ortho(GLbyte * pc) 2715{ 2716#ifdef __GLX_ALIGN64 2717 if ((unsigned long)(pc) & 7) { 2718 (void) memmove(pc-4, pc, 48); 2719 pc -= 4; 2720 } 2721#endif 2722 2723 CALL_Ortho( GET_DISPATCH(), ( 2724 (GLdouble)bswap_FLOAT64( pc + 0 ), 2725 (GLdouble)bswap_FLOAT64( pc + 8 ), 2726 (GLdouble)bswap_FLOAT64( pc + 16 ), 2727 (GLdouble)bswap_FLOAT64( pc + 24 ), 2728 (GLdouble)bswap_FLOAT64( pc + 32 ), 2729 (GLdouble)bswap_FLOAT64( pc + 40 ) 2730 ) ); 2731} 2732 2733void __glXDispSwap_PopMatrix(GLbyte * pc) 2734{ 2735 CALL_PopMatrix( GET_DISPATCH(), () ); 2736} 2737 2738void __glXDispSwap_PushMatrix(GLbyte * pc) 2739{ 2740 CALL_PushMatrix( GET_DISPATCH(), () ); 2741} 2742 2743void __glXDispSwap_Rotated(GLbyte * pc) 2744{ 2745#ifdef __GLX_ALIGN64 2746 if ((unsigned long)(pc) & 7) { 2747 (void) memmove(pc-4, pc, 32); 2748 pc -= 4; 2749 } 2750#endif 2751 2752 CALL_Rotated( GET_DISPATCH(), ( 2753 (GLdouble)bswap_FLOAT64( pc + 0 ), 2754 (GLdouble)bswap_FLOAT64( pc + 8 ), 2755 (GLdouble)bswap_FLOAT64( pc + 16 ), 2756 (GLdouble)bswap_FLOAT64( pc + 24 ) 2757 ) ); 2758} 2759 2760void __glXDispSwap_Rotatef(GLbyte * pc) 2761{ 2762 CALL_Rotatef( GET_DISPATCH(), ( 2763 (GLfloat )bswap_FLOAT32( pc + 0 ), 2764 (GLfloat )bswap_FLOAT32( pc + 4 ), 2765 (GLfloat )bswap_FLOAT32( pc + 8 ), 2766 (GLfloat )bswap_FLOAT32( pc + 12 ) 2767 ) ); 2768} 2769 2770void __glXDispSwap_Scaled(GLbyte * pc) 2771{ 2772#ifdef __GLX_ALIGN64 2773 if ((unsigned long)(pc) & 7) { 2774 (void) memmove(pc-4, pc, 24); 2775 pc -= 4; 2776 } 2777#endif 2778 2779 CALL_Scaled( GET_DISPATCH(), ( 2780 (GLdouble)bswap_FLOAT64( pc + 0 ), 2781 (GLdouble)bswap_FLOAT64( pc + 8 ), 2782 (GLdouble)bswap_FLOAT64( pc + 16 ) 2783 ) ); 2784} 2785 2786void __glXDispSwap_Scalef(GLbyte * pc) 2787{ 2788 CALL_Scalef( GET_DISPATCH(), ( 2789 (GLfloat )bswap_FLOAT32( pc + 0 ), 2790 (GLfloat )bswap_FLOAT32( pc + 4 ), 2791 (GLfloat )bswap_FLOAT32( pc + 8 ) 2792 ) ); 2793} 2794 2795void __glXDispSwap_Translated(GLbyte * pc) 2796{ 2797#ifdef __GLX_ALIGN64 2798 if ((unsigned long)(pc) & 7) { 2799 (void) memmove(pc-4, pc, 24); 2800 pc -= 4; 2801 } 2802#endif 2803 2804 CALL_Translated( GET_DISPATCH(), ( 2805 (GLdouble)bswap_FLOAT64( pc + 0 ), 2806 (GLdouble)bswap_FLOAT64( pc + 8 ), 2807 (GLdouble)bswap_FLOAT64( pc + 16 ) 2808 ) ); 2809} 2810 2811void __glXDispSwap_Translatef(GLbyte * pc) 2812{ 2813 CALL_Translatef( GET_DISPATCH(), ( 2814 (GLfloat )bswap_FLOAT32( pc + 0 ), 2815 (GLfloat )bswap_FLOAT32( pc + 4 ), 2816 (GLfloat )bswap_FLOAT32( pc + 8 ) 2817 ) ); 2818} 2819 2820void __glXDispSwap_Viewport(GLbyte * pc) 2821{ 2822 CALL_Viewport( GET_DISPATCH(), ( 2823 (GLint )bswap_CARD32 ( pc + 0 ), 2824 (GLint )bswap_CARD32 ( pc + 4 ), 2825 (GLsizei )bswap_CARD32 ( pc + 8 ), 2826 (GLsizei )bswap_CARD32 ( pc + 12 ) 2827 ) ); 2828} 2829 2830void __glXDispSwap_BindTexture(GLbyte * pc) 2831{ 2832 CALL_BindTexture( GET_DISPATCH(), ( 2833 (GLenum )bswap_ENUM ( pc + 0 ), 2834 (GLuint )bswap_CARD32 ( pc + 4 ) 2835 ) ); 2836} 2837 2838void __glXDispSwap_Indexubv(GLbyte * pc) 2839{ 2840 CALL_Indexubv( GET_DISPATCH(), ( 2841 (const GLubyte *)(pc + 0) 2842 ) ); 2843} 2844 2845void __glXDispSwap_PolygonOffset(GLbyte * pc) 2846{ 2847 CALL_PolygonOffset( GET_DISPATCH(), ( 2848 (GLfloat )bswap_FLOAT32( pc + 0 ), 2849 (GLfloat )bswap_FLOAT32( pc + 4 ) 2850 ) ); 2851} 2852 2853int __glXDispSwap_AreTexturesResident(__GLXclientState *cl, GLbyte *pc) 2854{ 2855 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2856 int error; 2857 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2858 2859 pc += __GLX_SINGLE_HDR_SIZE; 2860 if ( cx != NULL ) { 2861 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 2862 2863 GLboolean retval; 2864 GLboolean answerBuffer[200]; 2865 GLboolean * residences = __glXGetAnswerBuffer(cl, n, answerBuffer, sizeof(answerBuffer), 1); 2866 retval = CALL_AreTexturesResident( GET_DISPATCH(), ( 2867 n, 2868 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ), 2869 residences 2870 ) ); 2871 __glXSendReplySwap(cl->client, residences, n, 1, GL_TRUE, retval); 2872 error = Success; 2873 } 2874 2875 return error; 2876} 2877 2878int __glXDispSwap_AreTexturesResidentEXT(__GLXclientState *cl, GLbyte *pc) 2879{ 2880 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 2881 int error; 2882 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2883 2884 pc += __GLX_VENDPRIV_HDR_SIZE; 2885 if ( cx != NULL ) { 2886 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 2887 2888 GLboolean retval; 2889 GLboolean answerBuffer[200]; 2890 GLboolean * residences = __glXGetAnswerBuffer(cl, n, answerBuffer, sizeof(answerBuffer), 1); 2891 retval = CALL_AreTexturesResident( GET_DISPATCH(), ( 2892 n, 2893 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ), 2894 residences 2895 ) ); 2896 __glXSendReplySwap(cl->client, residences, n, 1, GL_TRUE, retval); 2897 error = Success; 2898 } 2899 2900 return error; 2901} 2902 2903void __glXDispSwap_CopyTexImage1D(GLbyte * pc) 2904{ 2905 CALL_CopyTexImage1D( GET_DISPATCH(), ( 2906 (GLenum )bswap_ENUM ( pc + 0 ), 2907 (GLint )bswap_CARD32 ( pc + 4 ), 2908 (GLenum )bswap_ENUM ( pc + 8 ), 2909 (GLint )bswap_CARD32 ( pc + 12 ), 2910 (GLint )bswap_CARD32 ( pc + 16 ), 2911 (GLsizei )bswap_CARD32 ( pc + 20 ), 2912 (GLint )bswap_CARD32 ( pc + 24 ) 2913 ) ); 2914} 2915 2916void __glXDispSwap_CopyTexImage2D(GLbyte * pc) 2917{ 2918 CALL_CopyTexImage2D( GET_DISPATCH(), ( 2919 (GLenum )bswap_ENUM ( pc + 0 ), 2920 (GLint )bswap_CARD32 ( pc + 4 ), 2921 (GLenum )bswap_ENUM ( pc + 8 ), 2922 (GLint )bswap_CARD32 ( pc + 12 ), 2923 (GLint )bswap_CARD32 ( pc + 16 ), 2924 (GLsizei )bswap_CARD32 ( pc + 20 ), 2925 (GLsizei )bswap_CARD32 ( pc + 24 ), 2926 (GLint )bswap_CARD32 ( pc + 28 ) 2927 ) ); 2928} 2929 2930void __glXDispSwap_CopyTexSubImage1D(GLbyte * pc) 2931{ 2932 CALL_CopyTexSubImage1D( GET_DISPATCH(), ( 2933 (GLenum )bswap_ENUM ( pc + 0 ), 2934 (GLint )bswap_CARD32 ( pc + 4 ), 2935 (GLint )bswap_CARD32 ( pc + 8 ), 2936 (GLint )bswap_CARD32 ( pc + 12 ), 2937 (GLint )bswap_CARD32 ( pc + 16 ), 2938 (GLsizei )bswap_CARD32 ( pc + 20 ) 2939 ) ); 2940} 2941 2942void __glXDispSwap_CopyTexSubImage2D(GLbyte * pc) 2943{ 2944 CALL_CopyTexSubImage2D( GET_DISPATCH(), ( 2945 (GLenum )bswap_ENUM ( pc + 0 ), 2946 (GLint )bswap_CARD32 ( pc + 4 ), 2947 (GLint )bswap_CARD32 ( pc + 8 ), 2948 (GLint )bswap_CARD32 ( pc + 12 ), 2949 (GLint )bswap_CARD32 ( pc + 16 ), 2950 (GLint )bswap_CARD32 ( pc + 20 ), 2951 (GLsizei )bswap_CARD32 ( pc + 24 ), 2952 (GLsizei )bswap_CARD32 ( pc + 28 ) 2953 ) ); 2954} 2955 2956int __glXDispSwap_DeleteTextures(__GLXclientState *cl, GLbyte *pc) 2957{ 2958 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2959 int error; 2960 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2961 2962 pc += __GLX_SINGLE_HDR_SIZE; 2963 if ( cx != NULL ) { 2964 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 2965 2966 CALL_DeleteTextures( GET_DISPATCH(), ( 2967 n, 2968 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ) 2969 ) ); 2970 error = Success; 2971 } 2972 2973 return error; 2974} 2975 2976int __glXDispSwap_DeleteTexturesEXT(__GLXclientState *cl, GLbyte *pc) 2977{ 2978 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 2979 int error; 2980 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 2981 2982 pc += __GLX_VENDPRIV_HDR_SIZE; 2983 if ( cx != NULL ) { 2984 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 2985 2986 CALL_DeleteTextures( GET_DISPATCH(), ( 2987 n, 2988 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ) 2989 ) ); 2990 error = Success; 2991 } 2992 2993 return error; 2994} 2995 2996int __glXDispSwap_GenTextures(__GLXclientState *cl, GLbyte *pc) 2997{ 2998 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 2999 int error; 3000 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3001 3002 pc += __GLX_SINGLE_HDR_SIZE; 3003 if ( cx != NULL ) { 3004 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 3005 3006 GLuint answerBuffer[200]; 3007 GLuint * textures = __glXGetAnswerBuffer(cl, n * 4, answerBuffer, sizeof(answerBuffer), 4); 3008 CALL_GenTextures( GET_DISPATCH(), ( 3009 n, 3010 textures 3011 ) ); 3012 (void) bswap_32_array( (uint32_t *) textures, n ); 3013 __glXSendReplySwap(cl->client, textures, n, 4, GL_TRUE, 0); 3014 error = Success; 3015 } 3016 3017 return error; 3018} 3019 3020int __glXDispSwap_GenTexturesEXT(__GLXclientState *cl, GLbyte *pc) 3021{ 3022 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 3023 int error; 3024 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3025 3026 pc += __GLX_VENDPRIV_HDR_SIZE; 3027 if ( cx != NULL ) { 3028 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 3029 3030 GLuint answerBuffer[200]; 3031 GLuint * textures = __glXGetAnswerBuffer(cl, n * 4, answerBuffer, sizeof(answerBuffer), 4); 3032 CALL_GenTextures( GET_DISPATCH(), ( 3033 n, 3034 textures 3035 ) ); 3036 (void) bswap_32_array( (uint32_t *) textures, n ); 3037 __glXSendReplySwap(cl->client, textures, n, 4, GL_TRUE, 0); 3038 error = Success; 3039 } 3040 3041 return error; 3042} 3043 3044int __glXDispSwap_IsTexture(__GLXclientState *cl, GLbyte *pc) 3045{ 3046 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 3047 int error; 3048 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3049 3050 pc += __GLX_SINGLE_HDR_SIZE; 3051 if ( cx != NULL ) { 3052 GLboolean retval; 3053 retval = CALL_IsTexture( GET_DISPATCH(), ( 3054 (GLuint )bswap_CARD32 ( pc + 0 ) 3055 ) ); 3056 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 3057 error = Success; 3058 } 3059 3060 return error; 3061} 3062 3063int __glXDispSwap_IsTextureEXT(__GLXclientState *cl, GLbyte *pc) 3064{ 3065 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 3066 int error; 3067 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3068 3069 pc += __GLX_VENDPRIV_HDR_SIZE; 3070 if ( cx != NULL ) { 3071 GLboolean retval; 3072 retval = CALL_IsTexture( GET_DISPATCH(), ( 3073 (GLuint )bswap_CARD32 ( pc + 0 ) 3074 ) ); 3075 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 3076 error = Success; 3077 } 3078 3079 return error; 3080} 3081 3082void __glXDispSwap_PrioritizeTextures(GLbyte * pc) 3083{ 3084 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 3085 3086 CALL_PrioritizeTextures( GET_DISPATCH(), ( 3087 n, 3088 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ), 3089 (const GLclampf *)bswap_32_array( (uint32_t *) (pc + 4), 0 ) 3090 ) ); 3091} 3092 3093void __glXDispSwap_TexSubImage1D(GLbyte * pc) 3094{ 3095 const GLvoid * const pixels = (const GLvoid *) (pc + 56); 3096 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 3097 3098 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 3099 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 3100 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 3101 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 3102 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 3103 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 3104 3105 CALL_TexSubImage1D( GET_DISPATCH(), ( 3106 (GLenum )bswap_ENUM ( pc + 20 ), 3107 (GLint )bswap_CARD32 ( pc + 24 ), 3108 (GLint )bswap_CARD32 ( pc + 28 ), 3109 (GLsizei )bswap_CARD32 ( pc + 36 ), 3110 (GLenum )bswap_ENUM ( pc + 44 ), 3111 (GLenum )bswap_ENUM ( pc + 48 ), 3112 pixels 3113 ) ); 3114} 3115 3116void __glXDispSwap_TexSubImage2D(GLbyte * pc) 3117{ 3118 const GLvoid * const pixels = (const GLvoid *) (pc + 56); 3119 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 3120 3121 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 3122 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 3123 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 3124 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 3125 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 3126 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 3127 3128 CALL_TexSubImage2D( GET_DISPATCH(), ( 3129 (GLenum )bswap_ENUM ( pc + 20 ), 3130 (GLint )bswap_CARD32 ( pc + 24 ), 3131 (GLint )bswap_CARD32 ( pc + 28 ), 3132 (GLint )bswap_CARD32 ( pc + 32 ), 3133 (GLsizei )bswap_CARD32 ( pc + 36 ), 3134 (GLsizei )bswap_CARD32 ( pc + 40 ), 3135 (GLenum )bswap_ENUM ( pc + 44 ), 3136 (GLenum )bswap_ENUM ( pc + 48 ), 3137 pixels 3138 ) ); 3139} 3140 3141void __glXDispSwap_BlendColor(GLbyte * pc) 3142{ 3143 CALL_BlendColor( GET_DISPATCH(), ( 3144 (GLclampf)bswap_FLOAT32( pc + 0 ), 3145 (GLclampf)bswap_FLOAT32( pc + 4 ), 3146 (GLclampf)bswap_FLOAT32( pc + 8 ), 3147 (GLclampf)bswap_FLOAT32( pc + 12 ) 3148 ) ); 3149} 3150 3151void __glXDispSwap_BlendEquation(GLbyte * pc) 3152{ 3153 CALL_BlendEquation( GET_DISPATCH(), ( 3154 (GLenum )bswap_ENUM ( pc + 0 ) 3155 ) ); 3156} 3157 3158void __glXDispSwap_ColorTable(GLbyte * pc) 3159{ 3160 const GLvoid * const table = (const GLvoid *) (pc + 40); 3161 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 3162 3163 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 3164 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 3165 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 3166 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 3167 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 3168 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 3169 3170 CALL_ColorTable( GET_DISPATCH(), ( 3171 (GLenum )bswap_ENUM ( pc + 20 ), 3172 (GLenum )bswap_ENUM ( pc + 24 ), 3173 (GLsizei )bswap_CARD32 ( pc + 28 ), 3174 (GLenum )bswap_ENUM ( pc + 32 ), 3175 (GLenum )bswap_ENUM ( pc + 36 ), 3176 table 3177 ) ); 3178} 3179 3180void __glXDispSwap_ColorTableParameterfv(GLbyte * pc) 3181{ 3182 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3183 const GLfloat * params; 3184 3185 params = (const GLfloat *) bswap_32_array( (uint32_t *) (pc + 8), __glColorTableParameterfv_size(pname) ); 3186 3187 CALL_ColorTableParameterfv( GET_DISPATCH(), ( 3188 (GLenum )bswap_ENUM ( pc + 0 ), 3189 pname, 3190 params 3191 ) ); 3192} 3193 3194void __glXDispSwap_ColorTableParameteriv(GLbyte * pc) 3195{ 3196 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3197 const GLint * params; 3198 3199 params = (const GLint *) bswap_32_array( (uint32_t *) (pc + 8), __glColorTableParameteriv_size(pname) ); 3200 3201 CALL_ColorTableParameteriv( GET_DISPATCH(), ( 3202 (GLenum )bswap_ENUM ( pc + 0 ), 3203 pname, 3204 params 3205 ) ); 3206} 3207 3208void __glXDispSwap_CopyColorTable(GLbyte * pc) 3209{ 3210 CALL_CopyColorTable( GET_DISPATCH(), ( 3211 (GLenum )bswap_ENUM ( pc + 0 ), 3212 (GLenum )bswap_ENUM ( pc + 4 ), 3213 (GLint )bswap_CARD32 ( pc + 8 ), 3214 (GLint )bswap_CARD32 ( pc + 12 ), 3215 (GLsizei )bswap_CARD32 ( pc + 16 ) 3216 ) ); 3217} 3218 3219int __glXDispSwap_GetColorTableParameterfv(__GLXclientState *cl, GLbyte *pc) 3220{ 3221 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 3222 int error; 3223 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3224 3225 pc += __GLX_SINGLE_HDR_SIZE; 3226 if ( cx != NULL ) { 3227 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3228 3229 const GLuint compsize = __glGetColorTableParameterfv_size(pname); 3230 GLfloat answerBuffer[200]; 3231 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3232 3233 if (params == NULL) return BadAlloc; 3234 __glXClearErrorOccured(); 3235 3236 CALL_GetColorTableParameterfv( GET_DISPATCH(), ( 3237 (GLenum )bswap_ENUM ( pc + 0 ), 3238 pname, 3239 params 3240 ) ); 3241 (void) bswap_32_array( (uint32_t *) params, compsize ); 3242 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3243 error = Success; 3244 } 3245 3246 return error; 3247} 3248 3249int __glXDispSwap_GetColorTableParameterfvSGI(__GLXclientState *cl, GLbyte *pc) 3250{ 3251 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 3252 int error; 3253 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3254 3255 pc += __GLX_VENDPRIV_HDR_SIZE; 3256 if ( cx != NULL ) { 3257 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3258 3259 const GLuint compsize = __glGetColorTableParameterfv_size(pname); 3260 GLfloat answerBuffer[200]; 3261 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3262 3263 if (params == NULL) return BadAlloc; 3264 __glXClearErrorOccured(); 3265 3266 CALL_GetColorTableParameterfv( GET_DISPATCH(), ( 3267 (GLenum )bswap_ENUM ( pc + 0 ), 3268 pname, 3269 params 3270 ) ); 3271 (void) bswap_32_array( (uint32_t *) params, compsize ); 3272 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3273 error = Success; 3274 } 3275 3276 return error; 3277} 3278 3279int __glXDispSwap_GetColorTableParameteriv(__GLXclientState *cl, GLbyte *pc) 3280{ 3281 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 3282 int error; 3283 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3284 3285 pc += __GLX_SINGLE_HDR_SIZE; 3286 if ( cx != NULL ) { 3287 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3288 3289 const GLuint compsize = __glGetColorTableParameteriv_size(pname); 3290 GLint answerBuffer[200]; 3291 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3292 3293 if (params == NULL) return BadAlloc; 3294 __glXClearErrorOccured(); 3295 3296 CALL_GetColorTableParameteriv( GET_DISPATCH(), ( 3297 (GLenum )bswap_ENUM ( pc + 0 ), 3298 pname, 3299 params 3300 ) ); 3301 (void) bswap_32_array( (uint32_t *) params, compsize ); 3302 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3303 error = Success; 3304 } 3305 3306 return error; 3307} 3308 3309int __glXDispSwap_GetColorTableParameterivSGI(__GLXclientState *cl, GLbyte *pc) 3310{ 3311 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 3312 int error; 3313 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3314 3315 pc += __GLX_VENDPRIV_HDR_SIZE; 3316 if ( cx != NULL ) { 3317 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3318 3319 const GLuint compsize = __glGetColorTableParameteriv_size(pname); 3320 GLint answerBuffer[200]; 3321 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3322 3323 if (params == NULL) return BadAlloc; 3324 __glXClearErrorOccured(); 3325 3326 CALL_GetColorTableParameteriv( GET_DISPATCH(), ( 3327 (GLenum )bswap_ENUM ( pc + 0 ), 3328 pname, 3329 params 3330 ) ); 3331 (void) bswap_32_array( (uint32_t *) params, compsize ); 3332 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3333 error = Success; 3334 } 3335 3336 return error; 3337} 3338 3339void __glXDispSwap_ColorSubTable(GLbyte * pc) 3340{ 3341 const GLvoid * const data = (const GLvoid *) (pc + 40); 3342 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 3343 3344 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 3345 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 3346 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 3347 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 3348 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 3349 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 3350 3351 CALL_ColorSubTable( GET_DISPATCH(), ( 3352 (GLenum )bswap_ENUM ( pc + 20 ), 3353 (GLsizei )bswap_CARD32 ( pc + 24 ), 3354 (GLsizei )bswap_CARD32 ( pc + 28 ), 3355 (GLenum )bswap_ENUM ( pc + 32 ), 3356 (GLenum )bswap_ENUM ( pc + 36 ), 3357 data 3358 ) ); 3359} 3360 3361void __glXDispSwap_CopyColorSubTable(GLbyte * pc) 3362{ 3363 CALL_CopyColorSubTable( GET_DISPATCH(), ( 3364 (GLenum )bswap_ENUM ( pc + 0 ), 3365 (GLsizei )bswap_CARD32 ( pc + 4 ), 3366 (GLint )bswap_CARD32 ( pc + 8 ), 3367 (GLint )bswap_CARD32 ( pc + 12 ), 3368 (GLsizei )bswap_CARD32 ( pc + 16 ) 3369 ) ); 3370} 3371 3372void __glXDispSwap_ConvolutionFilter1D(GLbyte * pc) 3373{ 3374 const GLvoid * const image = (const GLvoid *) (pc + 44); 3375 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 3376 3377 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 3378 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 3379 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 3380 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 3381 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 3382 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 3383 3384 CALL_ConvolutionFilter1D( GET_DISPATCH(), ( 3385 (GLenum )bswap_ENUM ( pc + 20 ), 3386 (GLenum )bswap_ENUM ( pc + 24 ), 3387 (GLsizei )bswap_CARD32 ( pc + 28 ), 3388 (GLenum )bswap_ENUM ( pc + 36 ), 3389 (GLenum )bswap_ENUM ( pc + 40 ), 3390 image 3391 ) ); 3392} 3393 3394void __glXDispSwap_ConvolutionFilter2D(GLbyte * pc) 3395{ 3396 const GLvoid * const image = (const GLvoid *) (pc + 44); 3397 __GLXpixelHeader * const hdr = (__GLXpixelHeader *)(pc); 3398 3399 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 3400 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 3401 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 3402 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 3403 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 3404 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 3405 3406 CALL_ConvolutionFilter2D( GET_DISPATCH(), ( 3407 (GLenum )bswap_ENUM ( pc + 20 ), 3408 (GLenum )bswap_ENUM ( pc + 24 ), 3409 (GLsizei )bswap_CARD32 ( pc + 28 ), 3410 (GLsizei )bswap_CARD32 ( pc + 32 ), 3411 (GLenum )bswap_ENUM ( pc + 36 ), 3412 (GLenum )bswap_ENUM ( pc + 40 ), 3413 image 3414 ) ); 3415} 3416 3417void __glXDispSwap_ConvolutionParameterf(GLbyte * pc) 3418{ 3419 CALL_ConvolutionParameterf( GET_DISPATCH(), ( 3420 (GLenum )bswap_ENUM ( pc + 0 ), 3421 (GLenum )bswap_ENUM ( pc + 4 ), 3422 (GLfloat )bswap_FLOAT32( pc + 8 ) 3423 ) ); 3424} 3425 3426void __glXDispSwap_ConvolutionParameterfv(GLbyte * pc) 3427{ 3428 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3429 const GLfloat * params; 3430 3431 params = (const GLfloat *) bswap_32_array( (uint32_t *) (pc + 8), __glConvolutionParameterfv_size(pname) ); 3432 3433 CALL_ConvolutionParameterfv( GET_DISPATCH(), ( 3434 (GLenum )bswap_ENUM ( pc + 0 ), 3435 pname, 3436 params 3437 ) ); 3438} 3439 3440void __glXDispSwap_ConvolutionParameteri(GLbyte * pc) 3441{ 3442 CALL_ConvolutionParameteri( GET_DISPATCH(), ( 3443 (GLenum )bswap_ENUM ( pc + 0 ), 3444 (GLenum )bswap_ENUM ( pc + 4 ), 3445 (GLint )bswap_CARD32 ( pc + 8 ) 3446 ) ); 3447} 3448 3449void __glXDispSwap_ConvolutionParameteriv(GLbyte * pc) 3450{ 3451 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3452 const GLint * params; 3453 3454 params = (const GLint *) bswap_32_array( (uint32_t *) (pc + 8), __glConvolutionParameteriv_size(pname) ); 3455 3456 CALL_ConvolutionParameteriv( GET_DISPATCH(), ( 3457 (GLenum )bswap_ENUM ( pc + 0 ), 3458 pname, 3459 params 3460 ) ); 3461} 3462 3463void __glXDispSwap_CopyConvolutionFilter1D(GLbyte * pc) 3464{ 3465 CALL_CopyConvolutionFilter1D( GET_DISPATCH(), ( 3466 (GLenum )bswap_ENUM ( pc + 0 ), 3467 (GLenum )bswap_ENUM ( pc + 4 ), 3468 (GLint )bswap_CARD32 ( pc + 8 ), 3469 (GLint )bswap_CARD32 ( pc + 12 ), 3470 (GLsizei )bswap_CARD32 ( pc + 16 ) 3471 ) ); 3472} 3473 3474void __glXDispSwap_CopyConvolutionFilter2D(GLbyte * pc) 3475{ 3476 CALL_CopyConvolutionFilter2D( GET_DISPATCH(), ( 3477 (GLenum )bswap_ENUM ( pc + 0 ), 3478 (GLenum )bswap_ENUM ( pc + 4 ), 3479 (GLint )bswap_CARD32 ( pc + 8 ), 3480 (GLint )bswap_CARD32 ( pc + 12 ), 3481 (GLsizei )bswap_CARD32 ( pc + 16 ), 3482 (GLsizei )bswap_CARD32 ( pc + 20 ) 3483 ) ); 3484} 3485 3486int __glXDispSwap_GetConvolutionParameterfv(__GLXclientState *cl, GLbyte *pc) 3487{ 3488 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 3489 int error; 3490 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3491 3492 pc += __GLX_SINGLE_HDR_SIZE; 3493 if ( cx != NULL ) { 3494 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3495 3496 const GLuint compsize = __glGetConvolutionParameterfv_size(pname); 3497 GLfloat answerBuffer[200]; 3498 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3499 3500 if (params == NULL) return BadAlloc; 3501 __glXClearErrorOccured(); 3502 3503 CALL_GetConvolutionParameterfv( GET_DISPATCH(), ( 3504 (GLenum )bswap_ENUM ( pc + 0 ), 3505 pname, 3506 params 3507 ) ); 3508 (void) bswap_32_array( (uint32_t *) params, compsize ); 3509 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3510 error = Success; 3511 } 3512 3513 return error; 3514} 3515 3516int __glXDispSwap_GetConvolutionParameterfvEXT(__GLXclientState *cl, GLbyte *pc) 3517{ 3518 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 3519 int error; 3520 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3521 3522 pc += __GLX_VENDPRIV_HDR_SIZE; 3523 if ( cx != NULL ) { 3524 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3525 3526 const GLuint compsize = __glGetConvolutionParameterfv_size(pname); 3527 GLfloat answerBuffer[200]; 3528 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3529 3530 if (params == NULL) return BadAlloc; 3531 __glXClearErrorOccured(); 3532 3533 CALL_GetConvolutionParameterfv( GET_DISPATCH(), ( 3534 (GLenum )bswap_ENUM ( pc + 0 ), 3535 pname, 3536 params 3537 ) ); 3538 (void) bswap_32_array( (uint32_t *) params, compsize ); 3539 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3540 error = Success; 3541 } 3542 3543 return error; 3544} 3545 3546int __glXDispSwap_GetConvolutionParameteriv(__GLXclientState *cl, GLbyte *pc) 3547{ 3548 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 3549 int error; 3550 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3551 3552 pc += __GLX_SINGLE_HDR_SIZE; 3553 if ( cx != NULL ) { 3554 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3555 3556 const GLuint compsize = __glGetConvolutionParameteriv_size(pname); 3557 GLint answerBuffer[200]; 3558 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3559 3560 if (params == NULL) return BadAlloc; 3561 __glXClearErrorOccured(); 3562 3563 CALL_GetConvolutionParameteriv( GET_DISPATCH(), ( 3564 (GLenum )bswap_ENUM ( pc + 0 ), 3565 pname, 3566 params 3567 ) ); 3568 (void) bswap_32_array( (uint32_t *) params, compsize ); 3569 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3570 error = Success; 3571 } 3572 3573 return error; 3574} 3575 3576int __glXDispSwap_GetConvolutionParameterivEXT(__GLXclientState *cl, GLbyte *pc) 3577{ 3578 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 3579 int error; 3580 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3581 3582 pc += __GLX_VENDPRIV_HDR_SIZE; 3583 if ( cx != NULL ) { 3584 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3585 3586 const GLuint compsize = __glGetConvolutionParameteriv_size(pname); 3587 GLint answerBuffer[200]; 3588 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3589 3590 if (params == NULL) return BadAlloc; 3591 __glXClearErrorOccured(); 3592 3593 CALL_GetConvolutionParameteriv( GET_DISPATCH(), ( 3594 (GLenum )bswap_ENUM ( pc + 0 ), 3595 pname, 3596 params 3597 ) ); 3598 (void) bswap_32_array( (uint32_t *) params, compsize ); 3599 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3600 error = Success; 3601 } 3602 3603 return error; 3604} 3605 3606int __glXDispSwap_GetHistogramParameterfv(__GLXclientState *cl, GLbyte *pc) 3607{ 3608 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 3609 int error; 3610 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3611 3612 pc += __GLX_SINGLE_HDR_SIZE; 3613 if ( cx != NULL ) { 3614 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3615 3616 const GLuint compsize = __glGetHistogramParameterfv_size(pname); 3617 GLfloat answerBuffer[200]; 3618 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3619 3620 if (params == NULL) return BadAlloc; 3621 __glXClearErrorOccured(); 3622 3623 CALL_GetHistogramParameterfv( GET_DISPATCH(), ( 3624 (GLenum )bswap_ENUM ( pc + 0 ), 3625 pname, 3626 params 3627 ) ); 3628 (void) bswap_32_array( (uint32_t *) params, compsize ); 3629 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3630 error = Success; 3631 } 3632 3633 return error; 3634} 3635 3636int __glXDispSwap_GetHistogramParameterfvEXT(__GLXclientState *cl, GLbyte *pc) 3637{ 3638 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 3639 int error; 3640 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3641 3642 pc += __GLX_VENDPRIV_HDR_SIZE; 3643 if ( cx != NULL ) { 3644 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3645 3646 const GLuint compsize = __glGetHistogramParameterfv_size(pname); 3647 GLfloat answerBuffer[200]; 3648 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3649 3650 if (params == NULL) return BadAlloc; 3651 __glXClearErrorOccured(); 3652 3653 CALL_GetHistogramParameterfv( GET_DISPATCH(), ( 3654 (GLenum )bswap_ENUM ( pc + 0 ), 3655 pname, 3656 params 3657 ) ); 3658 (void) bswap_32_array( (uint32_t *) params, compsize ); 3659 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3660 error = Success; 3661 } 3662 3663 return error; 3664} 3665 3666int __glXDispSwap_GetHistogramParameteriv(__GLXclientState *cl, GLbyte *pc) 3667{ 3668 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 3669 int error; 3670 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3671 3672 pc += __GLX_SINGLE_HDR_SIZE; 3673 if ( cx != NULL ) { 3674 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3675 3676 const GLuint compsize = __glGetHistogramParameteriv_size(pname); 3677 GLint answerBuffer[200]; 3678 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3679 3680 if (params == NULL) return BadAlloc; 3681 __glXClearErrorOccured(); 3682 3683 CALL_GetHistogramParameteriv( GET_DISPATCH(), ( 3684 (GLenum )bswap_ENUM ( pc + 0 ), 3685 pname, 3686 params 3687 ) ); 3688 (void) bswap_32_array( (uint32_t *) params, compsize ); 3689 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3690 error = Success; 3691 } 3692 3693 return error; 3694} 3695 3696int __glXDispSwap_GetHistogramParameterivEXT(__GLXclientState *cl, GLbyte *pc) 3697{ 3698 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 3699 int error; 3700 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3701 3702 pc += __GLX_VENDPRIV_HDR_SIZE; 3703 if ( cx != NULL ) { 3704 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3705 3706 const GLuint compsize = __glGetHistogramParameteriv_size(pname); 3707 GLint answerBuffer[200]; 3708 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3709 3710 if (params == NULL) return BadAlloc; 3711 __glXClearErrorOccured(); 3712 3713 CALL_GetHistogramParameteriv( GET_DISPATCH(), ( 3714 (GLenum )bswap_ENUM ( pc + 0 ), 3715 pname, 3716 params 3717 ) ); 3718 (void) bswap_32_array( (uint32_t *) params, compsize ); 3719 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3720 error = Success; 3721 } 3722 3723 return error; 3724} 3725 3726int __glXDispSwap_GetMinmaxParameterfv(__GLXclientState *cl, GLbyte *pc) 3727{ 3728 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 3729 int error; 3730 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3731 3732 pc += __GLX_SINGLE_HDR_SIZE; 3733 if ( cx != NULL ) { 3734 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3735 3736 const GLuint compsize = __glGetMinmaxParameterfv_size(pname); 3737 GLfloat answerBuffer[200]; 3738 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3739 3740 if (params == NULL) return BadAlloc; 3741 __glXClearErrorOccured(); 3742 3743 CALL_GetMinmaxParameterfv( GET_DISPATCH(), ( 3744 (GLenum )bswap_ENUM ( pc + 0 ), 3745 pname, 3746 params 3747 ) ); 3748 (void) bswap_32_array( (uint32_t *) params, compsize ); 3749 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3750 error = Success; 3751 } 3752 3753 return error; 3754} 3755 3756int __glXDispSwap_GetMinmaxParameterfvEXT(__GLXclientState *cl, GLbyte *pc) 3757{ 3758 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 3759 int error; 3760 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3761 3762 pc += __GLX_VENDPRIV_HDR_SIZE; 3763 if ( cx != NULL ) { 3764 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3765 3766 const GLuint compsize = __glGetMinmaxParameterfv_size(pname); 3767 GLfloat answerBuffer[200]; 3768 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3769 3770 if (params == NULL) return BadAlloc; 3771 __glXClearErrorOccured(); 3772 3773 CALL_GetMinmaxParameterfv( GET_DISPATCH(), ( 3774 (GLenum )bswap_ENUM ( pc + 0 ), 3775 pname, 3776 params 3777 ) ); 3778 (void) bswap_32_array( (uint32_t *) params, compsize ); 3779 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3780 error = Success; 3781 } 3782 3783 return error; 3784} 3785 3786int __glXDispSwap_GetMinmaxParameteriv(__GLXclientState *cl, GLbyte *pc) 3787{ 3788 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 3789 int error; 3790 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3791 3792 pc += __GLX_SINGLE_HDR_SIZE; 3793 if ( cx != NULL ) { 3794 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3795 3796 const GLuint compsize = __glGetMinmaxParameteriv_size(pname); 3797 GLint answerBuffer[200]; 3798 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3799 3800 if (params == NULL) return BadAlloc; 3801 __glXClearErrorOccured(); 3802 3803 CALL_GetMinmaxParameteriv( GET_DISPATCH(), ( 3804 (GLenum )bswap_ENUM ( pc + 0 ), 3805 pname, 3806 params 3807 ) ); 3808 (void) bswap_32_array( (uint32_t *) params, compsize ); 3809 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3810 error = Success; 3811 } 3812 3813 return error; 3814} 3815 3816int __glXDispSwap_GetMinmaxParameterivEXT(__GLXclientState *cl, GLbyte *pc) 3817{ 3818 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 3819 int error; 3820 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 3821 3822 pc += __GLX_VENDPRIV_HDR_SIZE; 3823 if ( cx != NULL ) { 3824 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 3825 3826 const GLuint compsize = __glGetMinmaxParameteriv_size(pname); 3827 GLint answerBuffer[200]; 3828 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 3829 3830 if (params == NULL) return BadAlloc; 3831 __glXClearErrorOccured(); 3832 3833 CALL_GetMinmaxParameteriv( GET_DISPATCH(), ( 3834 (GLenum )bswap_ENUM ( pc + 0 ), 3835 pname, 3836 params 3837 ) ); 3838 (void) bswap_32_array( (uint32_t *) params, compsize ); 3839 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 3840 error = Success; 3841 } 3842 3843 return error; 3844} 3845 3846void __glXDispSwap_Histogram(GLbyte * pc) 3847{ 3848 CALL_Histogram( GET_DISPATCH(), ( 3849 (GLenum )bswap_ENUM ( pc + 0 ), 3850 (GLsizei )bswap_CARD32 ( pc + 4 ), 3851 (GLenum )bswap_ENUM ( pc + 8 ), 3852 *(GLboolean *)(pc + 12) 3853 ) ); 3854} 3855 3856void __glXDispSwap_Minmax(GLbyte * pc) 3857{ 3858 CALL_Minmax( GET_DISPATCH(), ( 3859 (GLenum )bswap_ENUM ( pc + 0 ), 3860 (GLenum )bswap_ENUM ( pc + 4 ), 3861 *(GLboolean *)(pc + 8) 3862 ) ); 3863} 3864 3865void __glXDispSwap_ResetHistogram(GLbyte * pc) 3866{ 3867 CALL_ResetHistogram( GET_DISPATCH(), ( 3868 (GLenum )bswap_ENUM ( pc + 0 ) 3869 ) ); 3870} 3871 3872void __glXDispSwap_ResetMinmax(GLbyte * pc) 3873{ 3874 CALL_ResetMinmax( GET_DISPATCH(), ( 3875 (GLenum )bswap_ENUM ( pc + 0 ) 3876 ) ); 3877} 3878 3879void __glXDispSwap_TexImage3D(GLbyte * pc) 3880{ 3881 const CARD32 ptr_is_null = *(CARD32 *)(pc + 76); 3882 const GLvoid * const pixels = (const GLvoid *) ((ptr_is_null != 0) ? NULL : (pc + 80)); 3883 __GLXpixel3DHeader * const hdr = (__GLXpixel3DHeader *)(pc); 3884 3885 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 3886 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 3887 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 3888 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_IMAGE_HEIGHT, (GLint) bswap_CARD32( & hdr->imageHeight )) ); 3889 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 3890 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_IMAGES, (GLint) bswap_CARD32( & hdr->skipImages )) ); 3891 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 3892 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 3893 3894 CALL_TexImage3D( GET_DISPATCH(), ( 3895 (GLenum )bswap_ENUM ( pc + 36 ), 3896 (GLint )bswap_CARD32 ( pc + 40 ), 3897 (GLint )bswap_CARD32 ( pc + 44 ), 3898 (GLsizei )bswap_CARD32 ( pc + 48 ), 3899 (GLsizei )bswap_CARD32 ( pc + 52 ), 3900 (GLsizei )bswap_CARD32 ( pc + 56 ), 3901 (GLint )bswap_CARD32 ( pc + 64 ), 3902 (GLenum )bswap_ENUM ( pc + 68 ), 3903 (GLenum )bswap_ENUM ( pc + 72 ), 3904 pixels 3905 ) ); 3906} 3907 3908void __glXDispSwap_TexSubImage3D(GLbyte * pc) 3909{ 3910 const GLvoid * const pixels = (const GLvoid *) (pc + 88); 3911 __GLXpixel3DHeader * const hdr = (__GLXpixel3DHeader *)(pc); 3912 3913 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SWAP_BYTES, hdr->swapBytes) ); 3914 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_LSB_FIRST, hdr->lsbFirst) ); 3915 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, (GLint) bswap_CARD32( & hdr->rowLength )) ); 3916 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_IMAGE_HEIGHT, (GLint) bswap_CARD32( & hdr->imageHeight )) ); 3917 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, (GLint) bswap_CARD32( & hdr->skipRows )) ); 3918 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_IMAGES, (GLint) bswap_CARD32( & hdr->skipImages )) ); 3919 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, (GLint) bswap_CARD32( & hdr->skipPixels )) ); 3920 CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ALIGNMENT, (GLint) bswap_CARD32( & hdr->alignment )) ); 3921 3922 CALL_TexSubImage3D( GET_DISPATCH(), ( 3923 (GLenum )bswap_ENUM ( pc + 36 ), 3924 (GLint )bswap_CARD32 ( pc + 40 ), 3925 (GLint )bswap_CARD32 ( pc + 44 ), 3926 (GLint )bswap_CARD32 ( pc + 48 ), 3927 (GLint )bswap_CARD32 ( pc + 52 ), 3928 (GLsizei )bswap_CARD32 ( pc + 60 ), 3929 (GLsizei )bswap_CARD32 ( pc + 64 ), 3930 (GLsizei )bswap_CARD32 ( pc + 68 ), 3931 (GLenum )bswap_ENUM ( pc + 76 ), 3932 (GLenum )bswap_ENUM ( pc + 80 ), 3933 pixels 3934 ) ); 3935} 3936 3937void __glXDispSwap_CopyTexSubImage3D(GLbyte * pc) 3938{ 3939 CALL_CopyTexSubImage3D( GET_DISPATCH(), ( 3940 (GLenum )bswap_ENUM ( pc + 0 ), 3941 (GLint )bswap_CARD32 ( pc + 4 ), 3942 (GLint )bswap_CARD32 ( pc + 8 ), 3943 (GLint )bswap_CARD32 ( pc + 12 ), 3944 (GLint )bswap_CARD32 ( pc + 16 ), 3945 (GLint )bswap_CARD32 ( pc + 20 ), 3946 (GLint )bswap_CARD32 ( pc + 24 ), 3947 (GLsizei )bswap_CARD32 ( pc + 28 ), 3948 (GLsizei )bswap_CARD32 ( pc + 32 ) 3949 ) ); 3950} 3951 3952void __glXDispSwap_ActiveTextureARB(GLbyte * pc) 3953{ 3954 CALL_ActiveTextureARB( GET_DISPATCH(), ( 3955 (GLenum )bswap_ENUM ( pc + 0 ) 3956 ) ); 3957} 3958 3959void __glXDispSwap_MultiTexCoord1dvARB(GLbyte * pc) 3960{ 3961#ifdef __GLX_ALIGN64 3962 if ((unsigned long)(pc) & 7) { 3963 (void) memmove(pc-4, pc, 12); 3964 pc -= 4; 3965 } 3966#endif 3967 3968 CALL_MultiTexCoord1dvARB( GET_DISPATCH(), ( 3969 (GLenum )bswap_ENUM ( pc + 8 ), 3970 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 1 ) 3971 ) ); 3972} 3973 3974void __glXDispSwap_MultiTexCoord1fvARB(GLbyte * pc) 3975{ 3976 CALL_MultiTexCoord1fvARB( GET_DISPATCH(), ( 3977 (GLenum )bswap_ENUM ( pc + 0 ), 3978 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 1 ) 3979 ) ); 3980} 3981 3982void __glXDispSwap_MultiTexCoord1ivARB(GLbyte * pc) 3983{ 3984 CALL_MultiTexCoord1ivARB( GET_DISPATCH(), ( 3985 (GLenum )bswap_ENUM ( pc + 0 ), 3986 (const GLint *)bswap_32_array( (uint32_t *) (pc + 4), 1 ) 3987 ) ); 3988} 3989 3990void __glXDispSwap_MultiTexCoord1svARB(GLbyte * pc) 3991{ 3992 CALL_MultiTexCoord1svARB( GET_DISPATCH(), ( 3993 (GLenum )bswap_ENUM ( pc + 0 ), 3994 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 1 ) 3995 ) ); 3996} 3997 3998void __glXDispSwap_MultiTexCoord2dvARB(GLbyte * pc) 3999{ 4000#ifdef __GLX_ALIGN64 4001 if ((unsigned long)(pc) & 7) { 4002 (void) memmove(pc-4, pc, 20); 4003 pc -= 4; 4004 } 4005#endif 4006 4007 CALL_MultiTexCoord2dvARB( GET_DISPATCH(), ( 4008 (GLenum )bswap_ENUM ( pc + 16 ), 4009 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 2 ) 4010 ) ); 4011} 4012 4013void __glXDispSwap_MultiTexCoord2fvARB(GLbyte * pc) 4014{ 4015 CALL_MultiTexCoord2fvARB( GET_DISPATCH(), ( 4016 (GLenum )bswap_ENUM ( pc + 0 ), 4017 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 2 ) 4018 ) ); 4019} 4020 4021void __glXDispSwap_MultiTexCoord2ivARB(GLbyte * pc) 4022{ 4023 CALL_MultiTexCoord2ivARB( GET_DISPATCH(), ( 4024 (GLenum )bswap_ENUM ( pc + 0 ), 4025 (const GLint *)bswap_32_array( (uint32_t *) (pc + 4), 2 ) 4026 ) ); 4027} 4028 4029void __glXDispSwap_MultiTexCoord2svARB(GLbyte * pc) 4030{ 4031 CALL_MultiTexCoord2svARB( GET_DISPATCH(), ( 4032 (GLenum )bswap_ENUM ( pc + 0 ), 4033 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 2 ) 4034 ) ); 4035} 4036 4037void __glXDispSwap_MultiTexCoord3dvARB(GLbyte * pc) 4038{ 4039#ifdef __GLX_ALIGN64 4040 if ((unsigned long)(pc) & 7) { 4041 (void) memmove(pc-4, pc, 28); 4042 pc -= 4; 4043 } 4044#endif 4045 4046 CALL_MultiTexCoord3dvARB( GET_DISPATCH(), ( 4047 (GLenum )bswap_ENUM ( pc + 24 ), 4048 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 3 ) 4049 ) ); 4050} 4051 4052void __glXDispSwap_MultiTexCoord3fvARB(GLbyte * pc) 4053{ 4054 CALL_MultiTexCoord3fvARB( GET_DISPATCH(), ( 4055 (GLenum )bswap_ENUM ( pc + 0 ), 4056 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 3 ) 4057 ) ); 4058} 4059 4060void __glXDispSwap_MultiTexCoord3ivARB(GLbyte * pc) 4061{ 4062 CALL_MultiTexCoord3ivARB( GET_DISPATCH(), ( 4063 (GLenum )bswap_ENUM ( pc + 0 ), 4064 (const GLint *)bswap_32_array( (uint32_t *) (pc + 4), 3 ) 4065 ) ); 4066} 4067 4068void __glXDispSwap_MultiTexCoord3svARB(GLbyte * pc) 4069{ 4070 CALL_MultiTexCoord3svARB( GET_DISPATCH(), ( 4071 (GLenum )bswap_ENUM ( pc + 0 ), 4072 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 3 ) 4073 ) ); 4074} 4075 4076void __glXDispSwap_MultiTexCoord4dvARB(GLbyte * pc) 4077{ 4078#ifdef __GLX_ALIGN64 4079 if ((unsigned long)(pc) & 7) { 4080 (void) memmove(pc-4, pc, 36); 4081 pc -= 4; 4082 } 4083#endif 4084 4085 CALL_MultiTexCoord4dvARB( GET_DISPATCH(), ( 4086 (GLenum )bswap_ENUM ( pc + 32 ), 4087 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 4 ) 4088 ) ); 4089} 4090 4091void __glXDispSwap_MultiTexCoord4fvARB(GLbyte * pc) 4092{ 4093 CALL_MultiTexCoord4fvARB( GET_DISPATCH(), ( 4094 (GLenum )bswap_ENUM ( pc + 0 ), 4095 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 4 ) 4096 ) ); 4097} 4098 4099void __glXDispSwap_MultiTexCoord4ivARB(GLbyte * pc) 4100{ 4101 CALL_MultiTexCoord4ivARB( GET_DISPATCH(), ( 4102 (GLenum )bswap_ENUM ( pc + 0 ), 4103 (const GLint *)bswap_32_array( (uint32_t *) (pc + 4), 4 ) 4104 ) ); 4105} 4106 4107void __glXDispSwap_MultiTexCoord4svARB(GLbyte * pc) 4108{ 4109 CALL_MultiTexCoord4svARB( GET_DISPATCH(), ( 4110 (GLenum )bswap_ENUM ( pc + 0 ), 4111 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 4 ) 4112 ) ); 4113} 4114 4115void __glXDispSwap_SampleCoverageARB(GLbyte * pc) 4116{ 4117 CALL_SampleCoverageARB( GET_DISPATCH(), ( 4118 (GLclampf)bswap_FLOAT32( pc + 0 ), 4119 *(GLboolean *)(pc + 4) 4120 ) ); 4121} 4122 4123void __glXDispSwap_CompressedTexImage1DARB(GLbyte * pc) 4124{ 4125 const GLsizei imageSize = (GLsizei )bswap_CARD32 ( pc + 20 ); 4126 4127 CALL_CompressedTexImage1DARB( GET_DISPATCH(), ( 4128 (GLenum )bswap_ENUM ( pc + 0 ), 4129 (GLint )bswap_CARD32 ( pc + 4 ), 4130 (GLenum )bswap_ENUM ( pc + 8 ), 4131 (GLsizei )bswap_CARD32 ( pc + 12 ), 4132 (GLint )bswap_CARD32 ( pc + 16 ), 4133 imageSize, 4134 (const GLvoid *)(pc + 24) 4135 ) ); 4136} 4137 4138void __glXDispSwap_CompressedTexImage2DARB(GLbyte * pc) 4139{ 4140 const GLsizei imageSize = (GLsizei )bswap_CARD32 ( pc + 24 ); 4141 4142 CALL_CompressedTexImage2DARB( GET_DISPATCH(), ( 4143 (GLenum )bswap_ENUM ( pc + 0 ), 4144 (GLint )bswap_CARD32 ( pc + 4 ), 4145 (GLenum )bswap_ENUM ( pc + 8 ), 4146 (GLsizei )bswap_CARD32 ( pc + 12 ), 4147 (GLsizei )bswap_CARD32 ( pc + 16 ), 4148 (GLint )bswap_CARD32 ( pc + 20 ), 4149 imageSize, 4150 (const GLvoid *)(pc + 28) 4151 ) ); 4152} 4153 4154void __glXDispSwap_CompressedTexImage3DARB(GLbyte * pc) 4155{ 4156 const GLsizei imageSize = (GLsizei )bswap_CARD32 ( pc + 28 ); 4157 4158 CALL_CompressedTexImage3DARB( GET_DISPATCH(), ( 4159 (GLenum )bswap_ENUM ( pc + 0 ), 4160 (GLint )bswap_CARD32 ( pc + 4 ), 4161 (GLenum )bswap_ENUM ( pc + 8 ), 4162 (GLsizei )bswap_CARD32 ( pc + 12 ), 4163 (GLsizei )bswap_CARD32 ( pc + 16 ), 4164 (GLsizei )bswap_CARD32 ( pc + 20 ), 4165 (GLint )bswap_CARD32 ( pc + 24 ), 4166 imageSize, 4167 (const GLvoid *)(pc + 32) 4168 ) ); 4169} 4170 4171void __glXDispSwap_CompressedTexSubImage1DARB(GLbyte * pc) 4172{ 4173 const GLsizei imageSize = (GLsizei )bswap_CARD32 ( pc + 20 ); 4174 4175 CALL_CompressedTexSubImage1DARB( GET_DISPATCH(), ( 4176 (GLenum )bswap_ENUM ( pc + 0 ), 4177 (GLint )bswap_CARD32 ( pc + 4 ), 4178 (GLint )bswap_CARD32 ( pc + 8 ), 4179 (GLsizei )bswap_CARD32 ( pc + 12 ), 4180 (GLenum )bswap_ENUM ( pc + 16 ), 4181 imageSize, 4182 (const GLvoid *)(pc + 24) 4183 ) ); 4184} 4185 4186void __glXDispSwap_CompressedTexSubImage2DARB(GLbyte * pc) 4187{ 4188 const GLsizei imageSize = (GLsizei )bswap_CARD32 ( pc + 28 ); 4189 4190 CALL_CompressedTexSubImage2DARB( GET_DISPATCH(), ( 4191 (GLenum )bswap_ENUM ( pc + 0 ), 4192 (GLint )bswap_CARD32 ( pc + 4 ), 4193 (GLint )bswap_CARD32 ( pc + 8 ), 4194 (GLint )bswap_CARD32 ( pc + 12 ), 4195 (GLsizei )bswap_CARD32 ( pc + 16 ), 4196 (GLsizei )bswap_CARD32 ( pc + 20 ), 4197 (GLenum )bswap_ENUM ( pc + 24 ), 4198 imageSize, 4199 (const GLvoid *)(pc + 32) 4200 ) ); 4201} 4202 4203void __glXDispSwap_CompressedTexSubImage3DARB(GLbyte * pc) 4204{ 4205 const GLsizei imageSize = (GLsizei )bswap_CARD32 ( pc + 36 ); 4206 4207 CALL_CompressedTexSubImage3DARB( GET_DISPATCH(), ( 4208 (GLenum )bswap_ENUM ( pc + 0 ), 4209 (GLint )bswap_CARD32 ( pc + 4 ), 4210 (GLint )bswap_CARD32 ( pc + 8 ), 4211 (GLint )bswap_CARD32 ( pc + 12 ), 4212 (GLint )bswap_CARD32 ( pc + 16 ), 4213 (GLsizei )bswap_CARD32 ( pc + 20 ), 4214 (GLsizei )bswap_CARD32 ( pc + 24 ), 4215 (GLsizei )bswap_CARD32 ( pc + 28 ), 4216 (GLenum )bswap_ENUM ( pc + 32 ), 4217 imageSize, 4218 (const GLvoid *)(pc + 40) 4219 ) ); 4220} 4221 4222int __glXDispSwap_GetProgramEnvParameterdvARB(__GLXclientState *cl, GLbyte *pc) 4223{ 4224 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 4225 int error; 4226 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4227 4228 pc += __GLX_VENDPRIV_HDR_SIZE; 4229 if ( cx != NULL ) { 4230 GLdouble params[4]; 4231 CALL_GetProgramEnvParameterdvARB( GET_DISPATCH(), ( 4232 (GLenum )bswap_ENUM ( pc + 0 ), 4233 (GLuint )bswap_CARD32 ( pc + 4 ), 4234 params 4235 ) ); 4236 (void) bswap_64_array( (uint64_t *) params, 4 ); 4237 __glXSendReplySwap(cl->client, params, 4, 8, GL_FALSE, 0); 4238 error = Success; 4239 } 4240 4241 return error; 4242} 4243 4244int __glXDispSwap_GetProgramEnvParameterfvARB(__GLXclientState *cl, GLbyte *pc) 4245{ 4246 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 4247 int error; 4248 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4249 4250 pc += __GLX_VENDPRIV_HDR_SIZE; 4251 if ( cx != NULL ) { 4252 GLfloat params[4]; 4253 CALL_GetProgramEnvParameterfvARB( GET_DISPATCH(), ( 4254 (GLenum )bswap_ENUM ( pc + 0 ), 4255 (GLuint )bswap_CARD32 ( pc + 4 ), 4256 params 4257 ) ); 4258 (void) bswap_32_array( (uint32_t *) params, 4 ); 4259 __glXSendReplySwap(cl->client, params, 4, 4, GL_FALSE, 0); 4260 error = Success; 4261 } 4262 4263 return error; 4264} 4265 4266int __glXDispSwap_GetProgramLocalParameterdvARB(__GLXclientState *cl, GLbyte *pc) 4267{ 4268 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 4269 int error; 4270 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4271 4272 pc += __GLX_VENDPRIV_HDR_SIZE; 4273 if ( cx != NULL ) { 4274 GLdouble params[4]; 4275 CALL_GetProgramLocalParameterdvARB( GET_DISPATCH(), ( 4276 (GLenum )bswap_ENUM ( pc + 0 ), 4277 (GLuint )bswap_CARD32 ( pc + 4 ), 4278 params 4279 ) ); 4280 (void) bswap_64_array( (uint64_t *) params, 4 ); 4281 __glXSendReplySwap(cl->client, params, 4, 8, GL_FALSE, 0); 4282 error = Success; 4283 } 4284 4285 return error; 4286} 4287 4288int __glXDispSwap_GetProgramLocalParameterfvARB(__GLXclientState *cl, GLbyte *pc) 4289{ 4290 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 4291 int error; 4292 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4293 4294 pc += __GLX_VENDPRIV_HDR_SIZE; 4295 if ( cx != NULL ) { 4296 GLfloat params[4]; 4297 CALL_GetProgramLocalParameterfvARB( GET_DISPATCH(), ( 4298 (GLenum )bswap_ENUM ( pc + 0 ), 4299 (GLuint )bswap_CARD32 ( pc + 4 ), 4300 params 4301 ) ); 4302 (void) bswap_32_array( (uint32_t *) params, 4 ); 4303 __glXSendReplySwap(cl->client, params, 4, 4, GL_FALSE, 0); 4304 error = Success; 4305 } 4306 4307 return error; 4308} 4309 4310int __glXDispSwap_GetProgramivARB(__GLXclientState *cl, GLbyte *pc) 4311{ 4312 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 4313 int error; 4314 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4315 4316 pc += __GLX_VENDPRIV_HDR_SIZE; 4317 if ( cx != NULL ) { 4318 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 4319 4320 const GLuint compsize = __glGetProgramivARB_size(pname); 4321 GLint answerBuffer[200]; 4322 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 4323 4324 if (params == NULL) return BadAlloc; 4325 __glXClearErrorOccured(); 4326 4327 CALL_GetProgramivARB( GET_DISPATCH(), ( 4328 (GLenum )bswap_ENUM ( pc + 0 ), 4329 pname, 4330 params 4331 ) ); 4332 (void) bswap_32_array( (uint32_t *) params, compsize ); 4333 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 4334 error = Success; 4335 } 4336 4337 return error; 4338} 4339 4340int __glXDispSwap_GetVertexAttribdvARB(__GLXclientState *cl, GLbyte *pc) 4341{ 4342 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 4343 int error; 4344 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4345 4346 pc += __GLX_VENDPRIV_HDR_SIZE; 4347 if ( cx != NULL ) { 4348 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 4349 4350 const GLuint compsize = __glGetVertexAttribdvARB_size(pname); 4351 GLdouble answerBuffer[200]; 4352 GLdouble * params = __glXGetAnswerBuffer(cl, compsize * 8, answerBuffer, sizeof(answerBuffer), 8); 4353 4354 if (params == NULL) return BadAlloc; 4355 __glXClearErrorOccured(); 4356 4357 CALL_GetVertexAttribdvARB( GET_DISPATCH(), ( 4358 (GLuint )bswap_CARD32 ( pc + 0 ), 4359 pname, 4360 params 4361 ) ); 4362 (void) bswap_64_array( (uint64_t *) params, compsize ); 4363 __glXSendReplySwap(cl->client, params, compsize, 8, GL_FALSE, 0); 4364 error = Success; 4365 } 4366 4367 return error; 4368} 4369 4370int __glXDispSwap_GetVertexAttribfvARB(__GLXclientState *cl, GLbyte *pc) 4371{ 4372 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 4373 int error; 4374 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4375 4376 pc += __GLX_VENDPRIV_HDR_SIZE; 4377 if ( cx != NULL ) { 4378 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 4379 4380 const GLuint compsize = __glGetVertexAttribfvARB_size(pname); 4381 GLfloat answerBuffer[200]; 4382 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 4383 4384 if (params == NULL) return BadAlloc; 4385 __glXClearErrorOccured(); 4386 4387 CALL_GetVertexAttribfvARB( GET_DISPATCH(), ( 4388 (GLuint )bswap_CARD32 ( pc + 0 ), 4389 pname, 4390 params 4391 ) ); 4392 (void) bswap_32_array( (uint32_t *) params, compsize ); 4393 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 4394 error = Success; 4395 } 4396 4397 return error; 4398} 4399 4400int __glXDispSwap_GetVertexAttribivARB(__GLXclientState *cl, GLbyte *pc) 4401{ 4402 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 4403 int error; 4404 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4405 4406 pc += __GLX_VENDPRIV_HDR_SIZE; 4407 if ( cx != NULL ) { 4408 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 4409 4410 const GLuint compsize = __glGetVertexAttribivARB_size(pname); 4411 GLint answerBuffer[200]; 4412 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 4413 4414 if (params == NULL) return BadAlloc; 4415 __glXClearErrorOccured(); 4416 4417 CALL_GetVertexAttribivARB( GET_DISPATCH(), ( 4418 (GLuint )bswap_CARD32 ( pc + 0 ), 4419 pname, 4420 params 4421 ) ); 4422 (void) bswap_32_array( (uint32_t *) params, compsize ); 4423 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 4424 error = Success; 4425 } 4426 4427 return error; 4428} 4429 4430void __glXDispSwap_ProgramEnvParameter4dvARB(GLbyte * pc) 4431{ 4432#ifdef __GLX_ALIGN64 4433 if ((unsigned long)(pc) & 7) { 4434 (void) memmove(pc-4, pc, 40); 4435 pc -= 4; 4436 } 4437#endif 4438 4439 CALL_ProgramEnvParameter4dvARB( GET_DISPATCH(), ( 4440 (GLenum )bswap_ENUM ( pc + 0 ), 4441 (GLuint )bswap_CARD32 ( pc + 4 ), 4442 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 8), 4 ) 4443 ) ); 4444} 4445 4446void __glXDispSwap_ProgramEnvParameter4fvARB(GLbyte * pc) 4447{ 4448 CALL_ProgramEnvParameter4fvARB( GET_DISPATCH(), ( 4449 (GLenum )bswap_ENUM ( pc + 0 ), 4450 (GLuint )bswap_CARD32 ( pc + 4 ), 4451 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 8), 4 ) 4452 ) ); 4453} 4454 4455void __glXDispSwap_ProgramLocalParameter4dvARB(GLbyte * pc) 4456{ 4457#ifdef __GLX_ALIGN64 4458 if ((unsigned long)(pc) & 7) { 4459 (void) memmove(pc-4, pc, 40); 4460 pc -= 4; 4461 } 4462#endif 4463 4464 CALL_ProgramLocalParameter4dvARB( GET_DISPATCH(), ( 4465 (GLenum )bswap_ENUM ( pc + 0 ), 4466 (GLuint )bswap_CARD32 ( pc + 4 ), 4467 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 8), 4 ) 4468 ) ); 4469} 4470 4471void __glXDispSwap_ProgramLocalParameter4fvARB(GLbyte * pc) 4472{ 4473 CALL_ProgramLocalParameter4fvARB( GET_DISPATCH(), ( 4474 (GLenum )bswap_ENUM ( pc + 0 ), 4475 (GLuint )bswap_CARD32 ( pc + 4 ), 4476 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 8), 4 ) 4477 ) ); 4478} 4479 4480void __glXDispSwap_ProgramStringARB(GLbyte * pc) 4481{ 4482 const GLsizei len = (GLsizei )bswap_CARD32 ( pc + 8 ); 4483 4484 CALL_ProgramStringARB( GET_DISPATCH(), ( 4485 (GLenum )bswap_ENUM ( pc + 0 ), 4486 (GLenum )bswap_ENUM ( pc + 4 ), 4487 len, 4488 (const GLvoid *)(pc + 12) 4489 ) ); 4490} 4491 4492void __glXDispSwap_VertexAttrib1dvARB(GLbyte * pc) 4493{ 4494#ifdef __GLX_ALIGN64 4495 if ((unsigned long)(pc) & 7) { 4496 (void) memmove(pc-4, pc, 12); 4497 pc -= 4; 4498 } 4499#endif 4500 4501 CALL_VertexAttrib1dvARB( GET_DISPATCH(), ( 4502 (GLuint )bswap_CARD32 ( pc + 0 ), 4503 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 4), 1 ) 4504 ) ); 4505} 4506 4507void __glXDispSwap_VertexAttrib1fvARB(GLbyte * pc) 4508{ 4509 CALL_VertexAttrib1fvARB( GET_DISPATCH(), ( 4510 (GLuint )bswap_CARD32 ( pc + 0 ), 4511 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 1 ) 4512 ) ); 4513} 4514 4515void __glXDispSwap_VertexAttrib1svARB(GLbyte * pc) 4516{ 4517 CALL_VertexAttrib1svARB( GET_DISPATCH(), ( 4518 (GLuint )bswap_CARD32 ( pc + 0 ), 4519 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 1 ) 4520 ) ); 4521} 4522 4523void __glXDispSwap_VertexAttrib2dvARB(GLbyte * pc) 4524{ 4525#ifdef __GLX_ALIGN64 4526 if ((unsigned long)(pc) & 7) { 4527 (void) memmove(pc-4, pc, 20); 4528 pc -= 4; 4529 } 4530#endif 4531 4532 CALL_VertexAttrib2dvARB( GET_DISPATCH(), ( 4533 (GLuint )bswap_CARD32 ( pc + 0 ), 4534 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 4), 2 ) 4535 ) ); 4536} 4537 4538void __glXDispSwap_VertexAttrib2fvARB(GLbyte * pc) 4539{ 4540 CALL_VertexAttrib2fvARB( GET_DISPATCH(), ( 4541 (GLuint )bswap_CARD32 ( pc + 0 ), 4542 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 2 ) 4543 ) ); 4544} 4545 4546void __glXDispSwap_VertexAttrib2svARB(GLbyte * pc) 4547{ 4548 CALL_VertexAttrib2svARB( GET_DISPATCH(), ( 4549 (GLuint )bswap_CARD32 ( pc + 0 ), 4550 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 2 ) 4551 ) ); 4552} 4553 4554void __glXDispSwap_VertexAttrib3dvARB(GLbyte * pc) 4555{ 4556#ifdef __GLX_ALIGN64 4557 if ((unsigned long)(pc) & 7) { 4558 (void) memmove(pc-4, pc, 28); 4559 pc -= 4; 4560 } 4561#endif 4562 4563 CALL_VertexAttrib3dvARB( GET_DISPATCH(), ( 4564 (GLuint )bswap_CARD32 ( pc + 0 ), 4565 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 4), 3 ) 4566 ) ); 4567} 4568 4569void __glXDispSwap_VertexAttrib3fvARB(GLbyte * pc) 4570{ 4571 CALL_VertexAttrib3fvARB( GET_DISPATCH(), ( 4572 (GLuint )bswap_CARD32 ( pc + 0 ), 4573 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 3 ) 4574 ) ); 4575} 4576 4577void __glXDispSwap_VertexAttrib3svARB(GLbyte * pc) 4578{ 4579 CALL_VertexAttrib3svARB( GET_DISPATCH(), ( 4580 (GLuint )bswap_CARD32 ( pc + 0 ), 4581 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 3 ) 4582 ) ); 4583} 4584 4585void __glXDispSwap_VertexAttrib4NbvARB(GLbyte * pc) 4586{ 4587 CALL_VertexAttrib4NbvARB( GET_DISPATCH(), ( 4588 (GLuint )bswap_CARD32 ( pc + 0 ), 4589 (const GLbyte *)(pc + 4) 4590 ) ); 4591} 4592 4593void __glXDispSwap_VertexAttrib4NivARB(GLbyte * pc) 4594{ 4595 CALL_VertexAttrib4NivARB( GET_DISPATCH(), ( 4596 (GLuint )bswap_CARD32 ( pc + 0 ), 4597 (const GLint *)bswap_32_array( (uint32_t *) (pc + 4), 4 ) 4598 ) ); 4599} 4600 4601void __glXDispSwap_VertexAttrib4NsvARB(GLbyte * pc) 4602{ 4603 CALL_VertexAttrib4NsvARB( GET_DISPATCH(), ( 4604 (GLuint )bswap_CARD32 ( pc + 0 ), 4605 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 4 ) 4606 ) ); 4607} 4608 4609void __glXDispSwap_VertexAttrib4NubvARB(GLbyte * pc) 4610{ 4611 CALL_VertexAttrib4NubvARB( GET_DISPATCH(), ( 4612 (GLuint )bswap_CARD32 ( pc + 0 ), 4613 (const GLubyte *)(pc + 4) 4614 ) ); 4615} 4616 4617void __glXDispSwap_VertexAttrib4NuivARB(GLbyte * pc) 4618{ 4619 CALL_VertexAttrib4NuivARB( GET_DISPATCH(), ( 4620 (GLuint )bswap_CARD32 ( pc + 0 ), 4621 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 4 ) 4622 ) ); 4623} 4624 4625void __glXDispSwap_VertexAttrib4NusvARB(GLbyte * pc) 4626{ 4627 CALL_VertexAttrib4NusvARB( GET_DISPATCH(), ( 4628 (GLuint )bswap_CARD32 ( pc + 0 ), 4629 (const GLushort *)bswap_16_array( (uint16_t *) (pc + 4), 4 ) 4630 ) ); 4631} 4632 4633void __glXDispSwap_VertexAttrib4bvARB(GLbyte * pc) 4634{ 4635 CALL_VertexAttrib4bvARB( GET_DISPATCH(), ( 4636 (GLuint )bswap_CARD32 ( pc + 0 ), 4637 (const GLbyte *)(pc + 4) 4638 ) ); 4639} 4640 4641void __glXDispSwap_VertexAttrib4dvARB(GLbyte * pc) 4642{ 4643#ifdef __GLX_ALIGN64 4644 if ((unsigned long)(pc) & 7) { 4645 (void) memmove(pc-4, pc, 36); 4646 pc -= 4; 4647 } 4648#endif 4649 4650 CALL_VertexAttrib4dvARB( GET_DISPATCH(), ( 4651 (GLuint )bswap_CARD32 ( pc + 0 ), 4652 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 4), 4 ) 4653 ) ); 4654} 4655 4656void __glXDispSwap_VertexAttrib4fvARB(GLbyte * pc) 4657{ 4658 CALL_VertexAttrib4fvARB( GET_DISPATCH(), ( 4659 (GLuint )bswap_CARD32 ( pc + 0 ), 4660 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 4 ) 4661 ) ); 4662} 4663 4664void __glXDispSwap_VertexAttrib4ivARB(GLbyte * pc) 4665{ 4666 CALL_VertexAttrib4ivARB( GET_DISPATCH(), ( 4667 (GLuint )bswap_CARD32 ( pc + 0 ), 4668 (const GLint *)bswap_32_array( (uint32_t *) (pc + 4), 4 ) 4669 ) ); 4670} 4671 4672void __glXDispSwap_VertexAttrib4svARB(GLbyte * pc) 4673{ 4674 CALL_VertexAttrib4svARB( GET_DISPATCH(), ( 4675 (GLuint )bswap_CARD32 ( pc + 0 ), 4676 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 4 ) 4677 ) ); 4678} 4679 4680void __glXDispSwap_VertexAttrib4ubvARB(GLbyte * pc) 4681{ 4682 CALL_VertexAttrib4ubvARB( GET_DISPATCH(), ( 4683 (GLuint )bswap_CARD32 ( pc + 0 ), 4684 (const GLubyte *)(pc + 4) 4685 ) ); 4686} 4687 4688void __glXDispSwap_VertexAttrib4uivARB(GLbyte * pc) 4689{ 4690 CALL_VertexAttrib4uivARB( GET_DISPATCH(), ( 4691 (GLuint )bswap_CARD32 ( pc + 0 ), 4692 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 4 ) 4693 ) ); 4694} 4695 4696void __glXDispSwap_VertexAttrib4usvARB(GLbyte * pc) 4697{ 4698 CALL_VertexAttrib4usvARB( GET_DISPATCH(), ( 4699 (GLuint )bswap_CARD32 ( pc + 0 ), 4700 (const GLushort *)bswap_16_array( (uint16_t *) (pc + 4), 4 ) 4701 ) ); 4702} 4703 4704void __glXDispSwap_BeginQueryARB(GLbyte * pc) 4705{ 4706 CALL_BeginQueryARB( GET_DISPATCH(), ( 4707 (GLenum )bswap_ENUM ( pc + 0 ), 4708 (GLuint )bswap_CARD32 ( pc + 4 ) 4709 ) ); 4710} 4711 4712int __glXDispSwap_DeleteQueriesARB(__GLXclientState *cl, GLbyte *pc) 4713{ 4714 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 4715 int error; 4716 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4717 4718 pc += __GLX_SINGLE_HDR_SIZE; 4719 if ( cx != NULL ) { 4720 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 4721 4722 CALL_DeleteQueriesARB( GET_DISPATCH(), ( 4723 n, 4724 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ) 4725 ) ); 4726 error = Success; 4727 } 4728 4729 return error; 4730} 4731 4732void __glXDispSwap_EndQueryARB(GLbyte * pc) 4733{ 4734 CALL_EndQueryARB( GET_DISPATCH(), ( 4735 (GLenum )bswap_ENUM ( pc + 0 ) 4736 ) ); 4737} 4738 4739int __glXDispSwap_GenQueriesARB(__GLXclientState *cl, GLbyte *pc) 4740{ 4741 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 4742 int error; 4743 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4744 4745 pc += __GLX_SINGLE_HDR_SIZE; 4746 if ( cx != NULL ) { 4747 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 4748 4749 GLuint answerBuffer[200]; 4750 GLuint * ids = __glXGetAnswerBuffer(cl, n * 4, answerBuffer, sizeof(answerBuffer), 4); 4751 CALL_GenQueriesARB( GET_DISPATCH(), ( 4752 n, 4753 ids 4754 ) ); 4755 (void) bswap_32_array( (uint32_t *) ids, n ); 4756 __glXSendReplySwap(cl->client, ids, n, 4, GL_TRUE, 0); 4757 error = Success; 4758 } 4759 4760 return error; 4761} 4762 4763int __glXDispSwap_GetQueryObjectivARB(__GLXclientState *cl, GLbyte *pc) 4764{ 4765 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 4766 int error; 4767 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4768 4769 pc += __GLX_SINGLE_HDR_SIZE; 4770 if ( cx != NULL ) { 4771 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 4772 4773 const GLuint compsize = __glGetQueryObjectivARB_size(pname); 4774 GLint answerBuffer[200]; 4775 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 4776 4777 if (params == NULL) return BadAlloc; 4778 __glXClearErrorOccured(); 4779 4780 CALL_GetQueryObjectivARB( GET_DISPATCH(), ( 4781 (GLuint )bswap_CARD32 ( pc + 0 ), 4782 pname, 4783 params 4784 ) ); 4785 (void) bswap_32_array( (uint32_t *) params, compsize ); 4786 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 4787 error = Success; 4788 } 4789 4790 return error; 4791} 4792 4793int __glXDispSwap_GetQueryObjectuivARB(__GLXclientState *cl, GLbyte *pc) 4794{ 4795 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 4796 int error; 4797 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4798 4799 pc += __GLX_SINGLE_HDR_SIZE; 4800 if ( cx != NULL ) { 4801 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 4802 4803 const GLuint compsize = __glGetQueryObjectuivARB_size(pname); 4804 GLuint answerBuffer[200]; 4805 GLuint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 4806 4807 if (params == NULL) return BadAlloc; 4808 __glXClearErrorOccured(); 4809 4810 CALL_GetQueryObjectuivARB( GET_DISPATCH(), ( 4811 (GLuint )bswap_CARD32 ( pc + 0 ), 4812 pname, 4813 params 4814 ) ); 4815 (void) bswap_32_array( (uint32_t *) params, compsize ); 4816 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 4817 error = Success; 4818 } 4819 4820 return error; 4821} 4822 4823int __glXDispSwap_GetQueryivARB(__GLXclientState *cl, GLbyte *pc) 4824{ 4825 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 4826 int error; 4827 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4828 4829 pc += __GLX_SINGLE_HDR_SIZE; 4830 if ( cx != NULL ) { 4831 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 4832 4833 const GLuint compsize = __glGetQueryivARB_size(pname); 4834 GLint answerBuffer[200]; 4835 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 4836 4837 if (params == NULL) return BadAlloc; 4838 __glXClearErrorOccured(); 4839 4840 CALL_GetQueryivARB( GET_DISPATCH(), ( 4841 (GLenum )bswap_ENUM ( pc + 0 ), 4842 pname, 4843 params 4844 ) ); 4845 (void) bswap_32_array( (uint32_t *) params, compsize ); 4846 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 4847 error = Success; 4848 } 4849 4850 return error; 4851} 4852 4853int __glXDispSwap_IsQueryARB(__GLXclientState *cl, GLbyte *pc) 4854{ 4855 xGLXSingleReq * const req = (xGLXSingleReq *) pc; 4856 int error; 4857 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 4858 4859 pc += __GLX_SINGLE_HDR_SIZE; 4860 if ( cx != NULL ) { 4861 GLboolean retval; 4862 retval = CALL_IsQueryARB( GET_DISPATCH(), ( 4863 (GLuint )bswap_CARD32 ( pc + 0 ) 4864 ) ); 4865 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 4866 error = Success; 4867 } 4868 4869 return error; 4870} 4871 4872void __glXDispSwap_DrawBuffersARB(GLbyte * pc) 4873{ 4874 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 4875 4876 CALL_DrawBuffersARB( GET_DISPATCH(), ( 4877 n, 4878 (const GLenum *)bswap_32_array( (uint32_t *) (pc + 4), 0 ) 4879 ) ); 4880} 4881 4882void __glXDispSwap_SampleMaskSGIS(GLbyte * pc) 4883{ 4884 CALL_SampleMaskSGIS( GET_DISPATCH(), ( 4885 (GLclampf)bswap_FLOAT32( pc + 0 ), 4886 *(GLboolean *)(pc + 4) 4887 ) ); 4888} 4889 4890void __glXDispSwap_SamplePatternSGIS(GLbyte * pc) 4891{ 4892 CALL_SamplePatternSGIS( GET_DISPATCH(), ( 4893 (GLenum )bswap_ENUM ( pc + 0 ) 4894 ) ); 4895} 4896 4897void __glXDispSwap_PointParameterfEXT(GLbyte * pc) 4898{ 4899 CALL_PointParameterfEXT( GET_DISPATCH(), ( 4900 (GLenum )bswap_ENUM ( pc + 0 ), 4901 (GLfloat )bswap_FLOAT32( pc + 4 ) 4902 ) ); 4903} 4904 4905void __glXDispSwap_PointParameterfvEXT(GLbyte * pc) 4906{ 4907 const GLenum pname = (GLenum )bswap_ENUM ( pc + 0 ); 4908 const GLfloat * params; 4909 4910 params = (const GLfloat *) bswap_32_array( (uint32_t *) (pc + 4), __glPointParameterfvEXT_size(pname) ); 4911 4912 CALL_PointParameterfvEXT( GET_DISPATCH(), ( 4913 pname, 4914 params 4915 ) ); 4916} 4917 4918void __glXDispSwap_SecondaryColor3bvEXT(GLbyte * pc) 4919{ 4920 CALL_SecondaryColor3bvEXT( GET_DISPATCH(), ( 4921 (const GLbyte *)(pc + 0) 4922 ) ); 4923} 4924 4925void __glXDispSwap_SecondaryColor3dvEXT(GLbyte * pc) 4926{ 4927#ifdef __GLX_ALIGN64 4928 if ((unsigned long)(pc) & 7) { 4929 (void) memmove(pc-4, pc, 24); 4930 pc -= 4; 4931 } 4932#endif 4933 4934 CALL_SecondaryColor3dvEXT( GET_DISPATCH(), ( 4935 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 3 ) 4936 ) ); 4937} 4938 4939void __glXDispSwap_SecondaryColor3fvEXT(GLbyte * pc) 4940{ 4941 CALL_SecondaryColor3fvEXT( GET_DISPATCH(), ( 4942 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 4943 ) ); 4944} 4945 4946void __glXDispSwap_SecondaryColor3ivEXT(GLbyte * pc) 4947{ 4948 CALL_SecondaryColor3ivEXT( GET_DISPATCH(), ( 4949 (const GLint *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 4950 ) ); 4951} 4952 4953void __glXDispSwap_SecondaryColor3svEXT(GLbyte * pc) 4954{ 4955 CALL_SecondaryColor3svEXT( GET_DISPATCH(), ( 4956 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 0), 3 ) 4957 ) ); 4958} 4959 4960void __glXDispSwap_SecondaryColor3ubvEXT(GLbyte * pc) 4961{ 4962 CALL_SecondaryColor3ubvEXT( GET_DISPATCH(), ( 4963 (const GLubyte *)(pc + 0) 4964 ) ); 4965} 4966 4967void __glXDispSwap_SecondaryColor3uivEXT(GLbyte * pc) 4968{ 4969 CALL_SecondaryColor3uivEXT( GET_DISPATCH(), ( 4970 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 4971 ) ); 4972} 4973 4974void __glXDispSwap_SecondaryColor3usvEXT(GLbyte * pc) 4975{ 4976 CALL_SecondaryColor3usvEXT( GET_DISPATCH(), ( 4977 (const GLushort *)bswap_16_array( (uint16_t *) (pc + 0), 3 ) 4978 ) ); 4979} 4980 4981void __glXDispSwap_FogCoorddvEXT(GLbyte * pc) 4982{ 4983#ifdef __GLX_ALIGN64 4984 if ((unsigned long)(pc) & 7) { 4985 (void) memmove(pc-4, pc, 8); 4986 pc -= 4; 4987 } 4988#endif 4989 4990 CALL_FogCoorddvEXT( GET_DISPATCH(), ( 4991 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 1 ) 4992 ) ); 4993} 4994 4995void __glXDispSwap_FogCoordfvEXT(GLbyte * pc) 4996{ 4997 CALL_FogCoordfvEXT( GET_DISPATCH(), ( 4998 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 1 ) 4999 ) ); 5000} 5001 5002void __glXDispSwap_BlendFuncSeparateEXT(GLbyte * pc) 5003{ 5004 CALL_BlendFuncSeparateEXT( GET_DISPATCH(), ( 5005 (GLenum )bswap_ENUM ( pc + 0 ), 5006 (GLenum )bswap_ENUM ( pc + 4 ), 5007 (GLenum )bswap_ENUM ( pc + 8 ), 5008 (GLenum )bswap_ENUM ( pc + 12 ) 5009 ) ); 5010} 5011 5012void __glXDispSwap_WindowPos3fvMESA(GLbyte * pc) 5013{ 5014 CALL_WindowPos3fvMESA( GET_DISPATCH(), ( 5015 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 0), 3 ) 5016 ) ); 5017} 5018 5019int __glXDispSwap_AreProgramsResidentNV(__GLXclientState *cl, GLbyte *pc) 5020{ 5021 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5022 int error; 5023 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5024 5025 pc += __GLX_VENDPRIV_HDR_SIZE; 5026 if ( cx != NULL ) { 5027 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 5028 5029 GLboolean retval; 5030 GLboolean answerBuffer[200]; 5031 GLboolean * residences = __glXGetAnswerBuffer(cl, n, answerBuffer, sizeof(answerBuffer), 1); 5032 retval = CALL_AreProgramsResidentNV( GET_DISPATCH(), ( 5033 n, 5034 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ), 5035 residences 5036 ) ); 5037 __glXSendReplySwap(cl->client, residences, n, 1, GL_FALSE, retval); 5038 error = Success; 5039 } 5040 5041 return error; 5042} 5043 5044void __glXDispSwap_BindProgramNV(GLbyte * pc) 5045{ 5046 CALL_BindProgramNV( GET_DISPATCH(), ( 5047 (GLenum )bswap_ENUM ( pc + 0 ), 5048 (GLuint )bswap_CARD32 ( pc + 4 ) 5049 ) ); 5050} 5051 5052int __glXDispSwap_DeleteProgramsNV(__GLXclientState *cl, GLbyte *pc) 5053{ 5054 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5055 int error; 5056 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5057 5058 pc += __GLX_VENDPRIV_HDR_SIZE; 5059 if ( cx != NULL ) { 5060 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 5061 5062 CALL_DeleteProgramsNV( GET_DISPATCH(), ( 5063 n, 5064 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ) 5065 ) ); 5066 error = Success; 5067 } 5068 5069 return error; 5070} 5071 5072void __glXDispSwap_ExecuteProgramNV(GLbyte * pc) 5073{ 5074 CALL_ExecuteProgramNV( GET_DISPATCH(), ( 5075 (GLenum )bswap_ENUM ( pc + 0 ), 5076 (GLuint )bswap_CARD32 ( pc + 4 ), 5077 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 8), 4 ) 5078 ) ); 5079} 5080 5081int __glXDispSwap_GenProgramsNV(__GLXclientState *cl, GLbyte *pc) 5082{ 5083 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5084 int error; 5085 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5086 5087 pc += __GLX_VENDPRIV_HDR_SIZE; 5088 if ( cx != NULL ) { 5089 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 5090 5091 GLuint answerBuffer[200]; 5092 GLuint * programs = __glXGetAnswerBuffer(cl, n * 4, answerBuffer, sizeof(answerBuffer), 4); 5093 CALL_GenProgramsNV( GET_DISPATCH(), ( 5094 n, 5095 programs 5096 ) ); 5097 (void) bswap_32_array( (uint32_t *) programs, n ); 5098 __glXSendReplySwap(cl->client, programs, n, 4, GL_TRUE, 0); 5099 error = Success; 5100 } 5101 5102 return error; 5103} 5104 5105int __glXDispSwap_GetProgramParameterdvNV(__GLXclientState *cl, GLbyte *pc) 5106{ 5107 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5108 int error; 5109 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5110 5111 pc += __GLX_VENDPRIV_HDR_SIZE; 5112 if ( cx != NULL ) { 5113 GLdouble params[4]; 5114 CALL_GetProgramParameterdvNV( GET_DISPATCH(), ( 5115 (GLenum )bswap_ENUM ( pc + 0 ), 5116 (GLuint )bswap_CARD32 ( pc + 4 ), 5117 (GLenum )bswap_ENUM ( pc + 8 ), 5118 params 5119 ) ); 5120 (void) bswap_64_array( (uint64_t *) params, 4 ); 5121 __glXSendReplySwap(cl->client, params, 4, 8, GL_FALSE, 0); 5122 error = Success; 5123 } 5124 5125 return error; 5126} 5127 5128int __glXDispSwap_GetProgramParameterfvNV(__GLXclientState *cl, GLbyte *pc) 5129{ 5130 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5131 int error; 5132 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5133 5134 pc += __GLX_VENDPRIV_HDR_SIZE; 5135 if ( cx != NULL ) { 5136 GLfloat params[4]; 5137 CALL_GetProgramParameterfvNV( GET_DISPATCH(), ( 5138 (GLenum )bswap_ENUM ( pc + 0 ), 5139 (GLuint )bswap_CARD32 ( pc + 4 ), 5140 (GLenum )bswap_ENUM ( pc + 8 ), 5141 params 5142 ) ); 5143 (void) bswap_32_array( (uint32_t *) params, 4 ); 5144 __glXSendReplySwap(cl->client, params, 4, 4, GL_FALSE, 0); 5145 error = Success; 5146 } 5147 5148 return error; 5149} 5150 5151int __glXDispSwap_GetProgramivNV(__GLXclientState *cl, GLbyte *pc) 5152{ 5153 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5154 int error; 5155 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5156 5157 pc += __GLX_VENDPRIV_HDR_SIZE; 5158 if ( cx != NULL ) { 5159 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 5160 5161 const GLuint compsize = __glGetProgramivNV_size(pname); 5162 GLint answerBuffer[200]; 5163 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 5164 5165 if (params == NULL) return BadAlloc; 5166 __glXClearErrorOccured(); 5167 5168 CALL_GetProgramivNV( GET_DISPATCH(), ( 5169 (GLuint )bswap_CARD32 ( pc + 0 ), 5170 pname, 5171 params 5172 ) ); 5173 (void) bswap_32_array( (uint32_t *) params, compsize ); 5174 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 5175 error = Success; 5176 } 5177 5178 return error; 5179} 5180 5181int __glXDispSwap_GetTrackMatrixivNV(__GLXclientState *cl, GLbyte *pc) 5182{ 5183 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5184 int error; 5185 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5186 5187 pc += __GLX_VENDPRIV_HDR_SIZE; 5188 if ( cx != NULL ) { 5189 GLint params[1]; 5190 CALL_GetTrackMatrixivNV( GET_DISPATCH(), ( 5191 (GLenum )bswap_ENUM ( pc + 0 ), 5192 (GLuint )bswap_CARD32 ( pc + 4 ), 5193 (GLenum )bswap_ENUM ( pc + 8 ), 5194 params 5195 ) ); 5196 (void) bswap_32_array( (uint32_t *) params, 1 ); 5197 __glXSendReplySwap(cl->client, params, 1, 4, GL_FALSE, 0); 5198 error = Success; 5199 } 5200 5201 return error; 5202} 5203 5204int __glXDispSwap_GetVertexAttribdvNV(__GLXclientState *cl, GLbyte *pc) 5205{ 5206 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5207 int error; 5208 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5209 5210 pc += __GLX_VENDPRIV_HDR_SIZE; 5211 if ( cx != NULL ) { 5212 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 5213 5214 const GLuint compsize = __glGetVertexAttribdvNV_size(pname); 5215 GLdouble answerBuffer[200]; 5216 GLdouble * params = __glXGetAnswerBuffer(cl, compsize * 8, answerBuffer, sizeof(answerBuffer), 8); 5217 5218 if (params == NULL) return BadAlloc; 5219 __glXClearErrorOccured(); 5220 5221 CALL_GetVertexAttribdvNV( GET_DISPATCH(), ( 5222 (GLuint )bswap_CARD32 ( pc + 0 ), 5223 pname, 5224 params 5225 ) ); 5226 (void) bswap_64_array( (uint64_t *) params, compsize ); 5227 __glXSendReplySwap(cl->client, params, compsize, 8, GL_FALSE, 0); 5228 error = Success; 5229 } 5230 5231 return error; 5232} 5233 5234int __glXDispSwap_GetVertexAttribfvNV(__GLXclientState *cl, GLbyte *pc) 5235{ 5236 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5237 int error; 5238 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5239 5240 pc += __GLX_VENDPRIV_HDR_SIZE; 5241 if ( cx != NULL ) { 5242 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 5243 5244 const GLuint compsize = __glGetVertexAttribfvNV_size(pname); 5245 GLfloat answerBuffer[200]; 5246 GLfloat * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 5247 5248 if (params == NULL) return BadAlloc; 5249 __glXClearErrorOccured(); 5250 5251 CALL_GetVertexAttribfvNV( GET_DISPATCH(), ( 5252 (GLuint )bswap_CARD32 ( pc + 0 ), 5253 pname, 5254 params 5255 ) ); 5256 (void) bswap_32_array( (uint32_t *) params, compsize ); 5257 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 5258 error = Success; 5259 } 5260 5261 return error; 5262} 5263 5264int __glXDispSwap_GetVertexAttribivNV(__GLXclientState *cl, GLbyte *pc) 5265{ 5266 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5267 int error; 5268 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5269 5270 pc += __GLX_VENDPRIV_HDR_SIZE; 5271 if ( cx != NULL ) { 5272 const GLenum pname = (GLenum )bswap_ENUM ( pc + 4 ); 5273 5274 const GLuint compsize = __glGetVertexAttribivNV_size(pname); 5275 GLint answerBuffer[200]; 5276 GLint * params = __glXGetAnswerBuffer(cl, compsize * 4, answerBuffer, sizeof(answerBuffer), 4); 5277 5278 if (params == NULL) return BadAlloc; 5279 __glXClearErrorOccured(); 5280 5281 CALL_GetVertexAttribivNV( GET_DISPATCH(), ( 5282 (GLuint )bswap_CARD32 ( pc + 0 ), 5283 pname, 5284 params 5285 ) ); 5286 (void) bswap_32_array( (uint32_t *) params, compsize ); 5287 __glXSendReplySwap(cl->client, params, compsize, 4, GL_FALSE, 0); 5288 error = Success; 5289 } 5290 5291 return error; 5292} 5293 5294int __glXDispSwap_IsProgramNV(__GLXclientState *cl, GLbyte *pc) 5295{ 5296 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5297 int error; 5298 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5299 5300 pc += __GLX_VENDPRIV_HDR_SIZE; 5301 if ( cx != NULL ) { 5302 GLboolean retval; 5303 retval = CALL_IsProgramNV( GET_DISPATCH(), ( 5304 (GLuint )bswap_CARD32 ( pc + 0 ) 5305 ) ); 5306 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 5307 error = Success; 5308 } 5309 5310 return error; 5311} 5312 5313void __glXDispSwap_LoadProgramNV(GLbyte * pc) 5314{ 5315 const GLsizei len = (GLsizei )bswap_CARD32 ( pc + 8 ); 5316 5317 CALL_LoadProgramNV( GET_DISPATCH(), ( 5318 (GLenum )bswap_ENUM ( pc + 0 ), 5319 (GLuint )bswap_CARD32 ( pc + 4 ), 5320 len, 5321 (const GLubyte *)(pc + 12) 5322 ) ); 5323} 5324 5325void __glXDispSwap_ProgramParameters4dvNV(GLbyte * pc) 5326{ 5327 const GLuint num = (GLuint )bswap_CARD32 ( pc + 8 ); 5328 5329#ifdef __GLX_ALIGN64 5330 const GLuint cmdlen = 16 + __GLX_PAD((num * 32)) - 4; 5331 if ((unsigned long)(pc) & 7) { 5332 (void) memmove(pc-4, pc, cmdlen); 5333 pc -= 4; 5334 } 5335#endif 5336 5337 CALL_ProgramParameters4dvNV( GET_DISPATCH(), ( 5338 (GLenum )bswap_ENUM ( pc + 0 ), 5339 (GLuint )bswap_CARD32 ( pc + 4 ), 5340 num, 5341 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 12), 0 ) 5342 ) ); 5343} 5344 5345void __glXDispSwap_ProgramParameters4fvNV(GLbyte * pc) 5346{ 5347 const GLuint num = (GLuint )bswap_CARD32 ( pc + 8 ); 5348 5349 CALL_ProgramParameters4fvNV( GET_DISPATCH(), ( 5350 (GLenum )bswap_ENUM ( pc + 0 ), 5351 (GLuint )bswap_CARD32 ( pc + 4 ), 5352 num, 5353 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 12), 0 ) 5354 ) ); 5355} 5356 5357void __glXDispSwap_RequestResidentProgramsNV(GLbyte * pc) 5358{ 5359 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 5360 5361 CALL_RequestResidentProgramsNV( GET_DISPATCH(), ( 5362 n, 5363 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ) 5364 ) ); 5365} 5366 5367void __glXDispSwap_TrackMatrixNV(GLbyte * pc) 5368{ 5369 CALL_TrackMatrixNV( GET_DISPATCH(), ( 5370 (GLenum )bswap_ENUM ( pc + 0 ), 5371 (GLuint )bswap_CARD32 ( pc + 4 ), 5372 (GLenum )bswap_ENUM ( pc + 8 ), 5373 (GLenum )bswap_ENUM ( pc + 12 ) 5374 ) ); 5375} 5376 5377void __glXDispSwap_VertexAttrib1dvNV(GLbyte * pc) 5378{ 5379#ifdef __GLX_ALIGN64 5380 if ((unsigned long)(pc) & 7) { 5381 (void) memmove(pc-4, pc, 12); 5382 pc -= 4; 5383 } 5384#endif 5385 5386 CALL_VertexAttrib1dvNV( GET_DISPATCH(), ( 5387 (GLuint )bswap_CARD32 ( pc + 0 ), 5388 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 4), 1 ) 5389 ) ); 5390} 5391 5392void __glXDispSwap_VertexAttrib1fvNV(GLbyte * pc) 5393{ 5394 CALL_VertexAttrib1fvNV( GET_DISPATCH(), ( 5395 (GLuint )bswap_CARD32 ( pc + 0 ), 5396 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 1 ) 5397 ) ); 5398} 5399 5400void __glXDispSwap_VertexAttrib1svNV(GLbyte * pc) 5401{ 5402 CALL_VertexAttrib1svNV( GET_DISPATCH(), ( 5403 (GLuint )bswap_CARD32 ( pc + 0 ), 5404 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 1 ) 5405 ) ); 5406} 5407 5408void __glXDispSwap_VertexAttrib2dvNV(GLbyte * pc) 5409{ 5410#ifdef __GLX_ALIGN64 5411 if ((unsigned long)(pc) & 7) { 5412 (void) memmove(pc-4, pc, 20); 5413 pc -= 4; 5414 } 5415#endif 5416 5417 CALL_VertexAttrib2dvNV( GET_DISPATCH(), ( 5418 (GLuint )bswap_CARD32 ( pc + 0 ), 5419 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 4), 2 ) 5420 ) ); 5421} 5422 5423void __glXDispSwap_VertexAttrib2fvNV(GLbyte * pc) 5424{ 5425 CALL_VertexAttrib2fvNV( GET_DISPATCH(), ( 5426 (GLuint )bswap_CARD32 ( pc + 0 ), 5427 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 2 ) 5428 ) ); 5429} 5430 5431void __glXDispSwap_VertexAttrib2svNV(GLbyte * pc) 5432{ 5433 CALL_VertexAttrib2svNV( GET_DISPATCH(), ( 5434 (GLuint )bswap_CARD32 ( pc + 0 ), 5435 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 2 ) 5436 ) ); 5437} 5438 5439void __glXDispSwap_VertexAttrib3dvNV(GLbyte * pc) 5440{ 5441#ifdef __GLX_ALIGN64 5442 if ((unsigned long)(pc) & 7) { 5443 (void) memmove(pc-4, pc, 28); 5444 pc -= 4; 5445 } 5446#endif 5447 5448 CALL_VertexAttrib3dvNV( GET_DISPATCH(), ( 5449 (GLuint )bswap_CARD32 ( pc + 0 ), 5450 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 4), 3 ) 5451 ) ); 5452} 5453 5454void __glXDispSwap_VertexAttrib3fvNV(GLbyte * pc) 5455{ 5456 CALL_VertexAttrib3fvNV( GET_DISPATCH(), ( 5457 (GLuint )bswap_CARD32 ( pc + 0 ), 5458 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 3 ) 5459 ) ); 5460} 5461 5462void __glXDispSwap_VertexAttrib3svNV(GLbyte * pc) 5463{ 5464 CALL_VertexAttrib3svNV( GET_DISPATCH(), ( 5465 (GLuint )bswap_CARD32 ( pc + 0 ), 5466 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 3 ) 5467 ) ); 5468} 5469 5470void __glXDispSwap_VertexAttrib4dvNV(GLbyte * pc) 5471{ 5472#ifdef __GLX_ALIGN64 5473 if ((unsigned long)(pc) & 7) { 5474 (void) memmove(pc-4, pc, 36); 5475 pc -= 4; 5476 } 5477#endif 5478 5479 CALL_VertexAttrib4dvNV( GET_DISPATCH(), ( 5480 (GLuint )bswap_CARD32 ( pc + 0 ), 5481 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 4), 4 ) 5482 ) ); 5483} 5484 5485void __glXDispSwap_VertexAttrib4fvNV(GLbyte * pc) 5486{ 5487 CALL_VertexAttrib4fvNV( GET_DISPATCH(), ( 5488 (GLuint )bswap_CARD32 ( pc + 0 ), 5489 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 4), 4 ) 5490 ) ); 5491} 5492 5493void __glXDispSwap_VertexAttrib4svNV(GLbyte * pc) 5494{ 5495 CALL_VertexAttrib4svNV( GET_DISPATCH(), ( 5496 (GLuint )bswap_CARD32 ( pc + 0 ), 5497 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 4), 4 ) 5498 ) ); 5499} 5500 5501void __glXDispSwap_VertexAttrib4ubvNV(GLbyte * pc) 5502{ 5503 CALL_VertexAttrib4ubvNV( GET_DISPATCH(), ( 5504 (GLuint )bswap_CARD32 ( pc + 0 ), 5505 (const GLubyte *)(pc + 4) 5506 ) ); 5507} 5508 5509void __glXDispSwap_VertexAttribs1dvNV(GLbyte * pc) 5510{ 5511 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5512 5513#ifdef __GLX_ALIGN64 5514 const GLuint cmdlen = 12 + __GLX_PAD((n * 8)) - 4; 5515 if ((unsigned long)(pc) & 7) { 5516 (void) memmove(pc-4, pc, cmdlen); 5517 pc -= 4; 5518 } 5519#endif 5520 5521 CALL_VertexAttribs1dvNV( GET_DISPATCH(), ( 5522 (GLuint )bswap_CARD32 ( pc + 0 ), 5523 n, 5524 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 8), 0 ) 5525 ) ); 5526} 5527 5528void __glXDispSwap_VertexAttribs1fvNV(GLbyte * pc) 5529{ 5530 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5531 5532 CALL_VertexAttribs1fvNV( GET_DISPATCH(), ( 5533 (GLuint )bswap_CARD32 ( pc + 0 ), 5534 n, 5535 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 8), 0 ) 5536 ) ); 5537} 5538 5539void __glXDispSwap_VertexAttribs1svNV(GLbyte * pc) 5540{ 5541 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5542 5543 CALL_VertexAttribs1svNV( GET_DISPATCH(), ( 5544 (GLuint )bswap_CARD32 ( pc + 0 ), 5545 n, 5546 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 8), 0 ) 5547 ) ); 5548} 5549 5550void __glXDispSwap_VertexAttribs2dvNV(GLbyte * pc) 5551{ 5552 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5553 5554#ifdef __GLX_ALIGN64 5555 const GLuint cmdlen = 12 + __GLX_PAD((n * 16)) - 4; 5556 if ((unsigned long)(pc) & 7) { 5557 (void) memmove(pc-4, pc, cmdlen); 5558 pc -= 4; 5559 } 5560#endif 5561 5562 CALL_VertexAttribs2dvNV( GET_DISPATCH(), ( 5563 (GLuint )bswap_CARD32 ( pc + 0 ), 5564 n, 5565 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 8), 0 ) 5566 ) ); 5567} 5568 5569void __glXDispSwap_VertexAttribs2fvNV(GLbyte * pc) 5570{ 5571 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5572 5573 CALL_VertexAttribs2fvNV( GET_DISPATCH(), ( 5574 (GLuint )bswap_CARD32 ( pc + 0 ), 5575 n, 5576 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 8), 0 ) 5577 ) ); 5578} 5579 5580void __glXDispSwap_VertexAttribs2svNV(GLbyte * pc) 5581{ 5582 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5583 5584 CALL_VertexAttribs2svNV( GET_DISPATCH(), ( 5585 (GLuint )bswap_CARD32 ( pc + 0 ), 5586 n, 5587 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 8), 0 ) 5588 ) ); 5589} 5590 5591void __glXDispSwap_VertexAttribs3dvNV(GLbyte * pc) 5592{ 5593 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5594 5595#ifdef __GLX_ALIGN64 5596 const GLuint cmdlen = 12 + __GLX_PAD((n * 24)) - 4; 5597 if ((unsigned long)(pc) & 7) { 5598 (void) memmove(pc-4, pc, cmdlen); 5599 pc -= 4; 5600 } 5601#endif 5602 5603 CALL_VertexAttribs3dvNV( GET_DISPATCH(), ( 5604 (GLuint )bswap_CARD32 ( pc + 0 ), 5605 n, 5606 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 8), 0 ) 5607 ) ); 5608} 5609 5610void __glXDispSwap_VertexAttribs3fvNV(GLbyte * pc) 5611{ 5612 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5613 5614 CALL_VertexAttribs3fvNV( GET_DISPATCH(), ( 5615 (GLuint )bswap_CARD32 ( pc + 0 ), 5616 n, 5617 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 8), 0 ) 5618 ) ); 5619} 5620 5621void __glXDispSwap_VertexAttribs3svNV(GLbyte * pc) 5622{ 5623 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5624 5625 CALL_VertexAttribs3svNV( GET_DISPATCH(), ( 5626 (GLuint )bswap_CARD32 ( pc + 0 ), 5627 n, 5628 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 8), 0 ) 5629 ) ); 5630} 5631 5632void __glXDispSwap_VertexAttribs4dvNV(GLbyte * pc) 5633{ 5634 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5635 5636#ifdef __GLX_ALIGN64 5637 const GLuint cmdlen = 12 + __GLX_PAD((n * 32)) - 4; 5638 if ((unsigned long)(pc) & 7) { 5639 (void) memmove(pc-4, pc, cmdlen); 5640 pc -= 4; 5641 } 5642#endif 5643 5644 CALL_VertexAttribs4dvNV( GET_DISPATCH(), ( 5645 (GLuint )bswap_CARD32 ( pc + 0 ), 5646 n, 5647 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 8), 0 ) 5648 ) ); 5649} 5650 5651void __glXDispSwap_VertexAttribs4fvNV(GLbyte * pc) 5652{ 5653 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5654 5655 CALL_VertexAttribs4fvNV( GET_DISPATCH(), ( 5656 (GLuint )bswap_CARD32 ( pc + 0 ), 5657 n, 5658 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 8), 0 ) 5659 ) ); 5660} 5661 5662void __glXDispSwap_VertexAttribs4svNV(GLbyte * pc) 5663{ 5664 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5665 5666 CALL_VertexAttribs4svNV( GET_DISPATCH(), ( 5667 (GLuint )bswap_CARD32 ( pc + 0 ), 5668 n, 5669 (const GLshort *)bswap_16_array( (uint16_t *) (pc + 8), 0 ) 5670 ) ); 5671} 5672 5673void __glXDispSwap_VertexAttribs4ubvNV(GLbyte * pc) 5674{ 5675 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 4 ); 5676 5677 CALL_VertexAttribs4ubvNV( GET_DISPATCH(), ( 5678 (GLuint )bswap_CARD32 ( pc + 0 ), 5679 n, 5680 (const GLubyte *)(pc + 8) 5681 ) ); 5682} 5683 5684void __glXDispSwap_PointParameteriNV(GLbyte * pc) 5685{ 5686 CALL_PointParameteriNV( GET_DISPATCH(), ( 5687 (GLenum )bswap_ENUM ( pc + 0 ), 5688 (GLint )bswap_CARD32 ( pc + 4 ) 5689 ) ); 5690} 5691 5692void __glXDispSwap_PointParameterivNV(GLbyte * pc) 5693{ 5694 const GLenum pname = (GLenum )bswap_ENUM ( pc + 0 ); 5695 const GLint * params; 5696 5697 params = (const GLint *) bswap_32_array( (uint32_t *) (pc + 4), __glPointParameterivNV_size(pname) ); 5698 5699 CALL_PointParameterivNV( GET_DISPATCH(), ( 5700 pname, 5701 params 5702 ) ); 5703} 5704 5705void __glXDispSwap_ActiveStencilFaceEXT(GLbyte * pc) 5706{ 5707 CALL_ActiveStencilFaceEXT( GET_DISPATCH(), ( 5708 (GLenum )bswap_ENUM ( pc + 0 ) 5709 ) ); 5710} 5711 5712int __glXDispSwap_GetProgramNamedParameterdvNV(__GLXclientState *cl, GLbyte *pc) 5713{ 5714 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5715 int error; 5716 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5717 5718 pc += __GLX_VENDPRIV_HDR_SIZE; 5719 if ( cx != NULL ) { 5720 const GLsizei len = (GLsizei )bswap_CARD32 ( pc + 4 ); 5721 5722 GLdouble params[4]; 5723 CALL_GetProgramNamedParameterdvNV( GET_DISPATCH(), ( 5724 (GLuint )bswap_CARD32 ( pc + 0 ), 5725 len, 5726 (const GLubyte *)(pc + 8), 5727 params 5728 ) ); 5729 (void) bswap_64_array( (uint64_t *) params, 4 ); 5730 __glXSendReplySwap(cl->client, params, 4, 8, GL_TRUE, 0); 5731 error = Success; 5732 } 5733 5734 return error; 5735} 5736 5737int __glXDispSwap_GetProgramNamedParameterfvNV(__GLXclientState *cl, GLbyte *pc) 5738{ 5739 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5740 int error; 5741 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5742 5743 pc += __GLX_VENDPRIV_HDR_SIZE; 5744 if ( cx != NULL ) { 5745 const GLsizei len = (GLsizei )bswap_CARD32 ( pc + 4 ); 5746 5747 GLfloat params[4]; 5748 CALL_GetProgramNamedParameterfvNV( GET_DISPATCH(), ( 5749 (GLuint )bswap_CARD32 ( pc + 0 ), 5750 len, 5751 (const GLubyte *)(pc + 8), 5752 params 5753 ) ); 5754 (void) bswap_32_array( (uint32_t *) params, 4 ); 5755 __glXSendReplySwap(cl->client, params, 4, 4, GL_TRUE, 0); 5756 error = Success; 5757 } 5758 5759 return error; 5760} 5761 5762void __glXDispSwap_ProgramNamedParameter4dvNV(GLbyte * pc) 5763{ 5764 const GLsizei len = (GLsizei )bswap_CARD32 ( pc + 36 ); 5765 5766#ifdef __GLX_ALIGN64 5767 const GLuint cmdlen = 44 + __GLX_PAD(len) - 4; 5768 if ((unsigned long)(pc) & 7) { 5769 (void) memmove(pc-4, pc, cmdlen); 5770 pc -= 4; 5771 } 5772#endif 5773 5774 CALL_ProgramNamedParameter4dvNV( GET_DISPATCH(), ( 5775 (GLuint )bswap_CARD32 ( pc + 32 ), 5776 len, 5777 (const GLubyte *)(pc + 40), 5778 (const GLdouble *)bswap_64_array( (uint64_t *) (pc + 0), 4 ) 5779 ) ); 5780} 5781 5782void __glXDispSwap_ProgramNamedParameter4fvNV(GLbyte * pc) 5783{ 5784 const GLsizei len = (GLsizei )bswap_CARD32 ( pc + 4 ); 5785 5786 CALL_ProgramNamedParameter4fvNV( GET_DISPATCH(), ( 5787 (GLuint )bswap_CARD32 ( pc + 0 ), 5788 len, 5789 (const GLubyte *)(pc + 24), 5790 (const GLfloat *)bswap_32_array( (uint32_t *) (pc + 8), 4 ) 5791 ) ); 5792} 5793 5794void __glXDispSwap_BlendEquationSeparateEXT(GLbyte * pc) 5795{ 5796 CALL_BlendEquationSeparateEXT( GET_DISPATCH(), ( 5797 (GLenum )bswap_ENUM ( pc + 0 ), 5798 (GLenum )bswap_ENUM ( pc + 4 ) 5799 ) ); 5800} 5801 5802void __glXDispSwap_BindFramebufferEXT(GLbyte * pc) 5803{ 5804 CALL_BindFramebufferEXT( GET_DISPATCH(), ( 5805 (GLenum )bswap_ENUM ( pc + 0 ), 5806 (GLuint )bswap_CARD32 ( pc + 4 ) 5807 ) ); 5808} 5809 5810void __glXDispSwap_BindRenderbufferEXT(GLbyte * pc) 5811{ 5812 CALL_BindRenderbufferEXT( GET_DISPATCH(), ( 5813 (GLenum )bswap_ENUM ( pc + 0 ), 5814 (GLuint )bswap_CARD32 ( pc + 4 ) 5815 ) ); 5816} 5817 5818int __glXDispSwap_CheckFramebufferStatusEXT(__GLXclientState *cl, GLbyte *pc) 5819{ 5820 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5821 int error; 5822 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5823 5824 pc += __GLX_VENDPRIV_HDR_SIZE; 5825 if ( cx != NULL ) { 5826 GLenum retval; 5827 retval = CALL_CheckFramebufferStatusEXT( GET_DISPATCH(), ( 5828 (GLenum )bswap_ENUM ( pc + 0 ) 5829 ) ); 5830 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 5831 error = Success; 5832 } 5833 5834 return error; 5835} 5836 5837void __glXDispSwap_DeleteFramebuffersEXT(GLbyte * pc) 5838{ 5839 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 5840 5841 CALL_DeleteFramebuffersEXT( GET_DISPATCH(), ( 5842 n, 5843 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ) 5844 ) ); 5845} 5846 5847void __glXDispSwap_DeleteRenderbuffersEXT(GLbyte * pc) 5848{ 5849 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 5850 5851 CALL_DeleteRenderbuffersEXT( GET_DISPATCH(), ( 5852 n, 5853 (const GLuint *)bswap_32_array( (uint32_t *) (pc + 4), 0 ) 5854 ) ); 5855} 5856 5857void __glXDispSwap_FramebufferRenderbufferEXT(GLbyte * pc) 5858{ 5859 CALL_FramebufferRenderbufferEXT( GET_DISPATCH(), ( 5860 (GLenum )bswap_ENUM ( pc + 0 ), 5861 (GLenum )bswap_ENUM ( pc + 4 ), 5862 (GLenum )bswap_ENUM ( pc + 8 ), 5863 (GLuint )bswap_CARD32 ( pc + 12 ) 5864 ) ); 5865} 5866 5867void __glXDispSwap_FramebufferTexture1DEXT(GLbyte * pc) 5868{ 5869 CALL_FramebufferTexture1DEXT( GET_DISPATCH(), ( 5870 (GLenum )bswap_ENUM ( pc + 0 ), 5871 (GLenum )bswap_ENUM ( pc + 4 ), 5872 (GLenum )bswap_ENUM ( pc + 8 ), 5873 (GLuint )bswap_CARD32 ( pc + 12 ), 5874 (GLint )bswap_CARD32 ( pc + 16 ) 5875 ) ); 5876} 5877 5878void __glXDispSwap_FramebufferTexture2DEXT(GLbyte * pc) 5879{ 5880 CALL_FramebufferTexture2DEXT( GET_DISPATCH(), ( 5881 (GLenum )bswap_ENUM ( pc + 0 ), 5882 (GLenum )bswap_ENUM ( pc + 4 ), 5883 (GLenum )bswap_ENUM ( pc + 8 ), 5884 (GLuint )bswap_CARD32 ( pc + 12 ), 5885 (GLint )bswap_CARD32 ( pc + 16 ) 5886 ) ); 5887} 5888 5889void __glXDispSwap_FramebufferTexture3DEXT(GLbyte * pc) 5890{ 5891 CALL_FramebufferTexture3DEXT( GET_DISPATCH(), ( 5892 (GLenum )bswap_ENUM ( pc + 0 ), 5893 (GLenum )bswap_ENUM ( pc + 4 ), 5894 (GLenum )bswap_ENUM ( pc + 8 ), 5895 (GLuint )bswap_CARD32 ( pc + 12 ), 5896 (GLint )bswap_CARD32 ( pc + 16 ), 5897 (GLint )bswap_CARD32 ( pc + 20 ) 5898 ) ); 5899} 5900 5901int __glXDispSwap_GenFramebuffersEXT(__GLXclientState *cl, GLbyte *pc) 5902{ 5903 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5904 int error; 5905 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5906 5907 pc += __GLX_VENDPRIV_HDR_SIZE; 5908 if ( cx != NULL ) { 5909 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 5910 5911 GLuint answerBuffer[200]; 5912 GLuint * framebuffers = __glXGetAnswerBuffer(cl, n * 4, answerBuffer, sizeof(answerBuffer), 4); 5913 CALL_GenFramebuffersEXT( GET_DISPATCH(), ( 5914 n, 5915 framebuffers 5916 ) ); 5917 (void) bswap_32_array( (uint32_t *) framebuffers, n ); 5918 __glXSendReplySwap(cl->client, framebuffers, n, 4, GL_TRUE, 0); 5919 error = Success; 5920 } 5921 5922 return error; 5923} 5924 5925int __glXDispSwap_GenRenderbuffersEXT(__GLXclientState *cl, GLbyte *pc) 5926{ 5927 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5928 int error; 5929 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5930 5931 pc += __GLX_VENDPRIV_HDR_SIZE; 5932 if ( cx != NULL ) { 5933 const GLsizei n = (GLsizei )bswap_CARD32 ( pc + 0 ); 5934 5935 GLuint answerBuffer[200]; 5936 GLuint * renderbuffers = __glXGetAnswerBuffer(cl, n * 4, answerBuffer, sizeof(answerBuffer), 4); 5937 CALL_GenRenderbuffersEXT( GET_DISPATCH(), ( 5938 n, 5939 renderbuffers 5940 ) ); 5941 (void) bswap_32_array( (uint32_t *) renderbuffers, n ); 5942 __glXSendReplySwap(cl->client, renderbuffers, n, 4, GL_TRUE, 0); 5943 error = Success; 5944 } 5945 5946 return error; 5947} 5948 5949void __glXDispSwap_GenerateMipmapEXT(GLbyte * pc) 5950{ 5951 CALL_GenerateMipmapEXT( GET_DISPATCH(), ( 5952 (GLenum )bswap_ENUM ( pc + 0 ) 5953 ) ); 5954} 5955 5956int __glXDispSwap_GetFramebufferAttachmentParameterivEXT(__GLXclientState *cl, GLbyte *pc) 5957{ 5958 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5959 int error; 5960 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5961 5962 pc += __GLX_VENDPRIV_HDR_SIZE; 5963 if ( cx != NULL ) { 5964 GLint params[1]; 5965 CALL_GetFramebufferAttachmentParameterivEXT( GET_DISPATCH(), ( 5966 (GLenum )bswap_ENUM ( pc + 0 ), 5967 (GLenum )bswap_ENUM ( pc + 4 ), 5968 (GLenum )bswap_ENUM ( pc + 8 ), 5969 params 5970 ) ); 5971 (void) bswap_32_array( (uint32_t *) params, 1 ); 5972 __glXSendReplySwap(cl->client, params, 1, 4, GL_FALSE, 0); 5973 error = Success; 5974 } 5975 5976 return error; 5977} 5978 5979int __glXDispSwap_GetRenderbufferParameterivEXT(__GLXclientState *cl, GLbyte *pc) 5980{ 5981 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 5982 int error; 5983 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 5984 5985 pc += __GLX_VENDPRIV_HDR_SIZE; 5986 if ( cx != NULL ) { 5987 GLint params[1]; 5988 CALL_GetRenderbufferParameterivEXT( GET_DISPATCH(), ( 5989 (GLenum )bswap_ENUM ( pc + 0 ), 5990 (GLenum )bswap_ENUM ( pc + 4 ), 5991 params 5992 ) ); 5993 (void) bswap_32_array( (uint32_t *) params, 1 ); 5994 __glXSendReplySwap(cl->client, params, 1, 4, GL_FALSE, 0); 5995 error = Success; 5996 } 5997 5998 return error; 5999} 6000 6001int __glXDispSwap_IsFramebufferEXT(__GLXclientState *cl, GLbyte *pc) 6002{ 6003 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 6004 int error; 6005 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 6006 6007 pc += __GLX_VENDPRIV_HDR_SIZE; 6008 if ( cx != NULL ) { 6009 GLboolean retval; 6010 retval = CALL_IsFramebufferEXT( GET_DISPATCH(), ( 6011 (GLuint )bswap_CARD32 ( pc + 0 ) 6012 ) ); 6013 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 6014 error = Success; 6015 } 6016 6017 return error; 6018} 6019 6020int __glXDispSwap_IsRenderbufferEXT(__GLXclientState *cl, GLbyte *pc) 6021{ 6022 xGLXVendorPrivateReq * const req = (xGLXVendorPrivateReq *) pc; 6023 int error; 6024 __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error); 6025 6026 pc += __GLX_VENDPRIV_HDR_SIZE; 6027 if ( cx != NULL ) { 6028 GLboolean retval; 6029 retval = CALL_IsRenderbufferEXT( GET_DISPATCH(), ( 6030 (GLuint )bswap_CARD32 ( pc + 0 ) 6031 ) ); 6032 __glXSendReplySwap(cl->client, dummy_answer, 0, 0, GL_FALSE, retval); 6033 error = Success; 6034 } 6035 6036 return error; 6037} 6038 6039void __glXDispSwap_RenderbufferStorageEXT(GLbyte * pc) 6040{ 6041 CALL_RenderbufferStorageEXT( GET_DISPATCH(), ( 6042 (GLenum )bswap_ENUM ( pc + 0 ), 6043 (GLenum )bswap_ENUM ( pc + 4 ), 6044 (GLsizei )bswap_CARD32 ( pc + 8 ), 6045 (GLsizei )bswap_CARD32 ( pc + 12 ) 6046 ) ); 6047} 6048 6049