1 /**************************************************************************
3 * Copyright 2010 VMware, Inc.
4 * Copyright 2004 IBM Corporation
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:
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
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
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
27 **************************************************************************/
30 * Auxiliary functions to compute the size of array/blob arguments, depending.
40 #include "glimports.hpp"
44 __gl_type_size(GLenum type)
49 case GL_UNSIGNED_BYTE:
52 case GL_UNSIGNED_SHORT:
66 OS::DebugMessage("apitrace: warning: %s: unknown GLenum 0x%04X\n", __FUNCTION__, type);
72 __gl_uniform_size(GLenum type, GLenum &elemType, GLint &numElems) {
103 elemType = GL_DOUBLE;
122 case GL_UNSIGNED_INT:
123 elemType = GL_UNSIGNED_INT;
126 case GL_UNSIGNED_INT_VEC2:
127 elemType = GL_UNSIGNED_INT;
130 case GL_UNSIGNED_INT_VEC3:
131 elemType = GL_UNSIGNED_INT;
134 case GL_UNSIGNED_INT_VEC4:
135 elemType = GL_UNSIGNED_INT;
166 case GL_FLOAT_MAT2x3:
170 case GL_FLOAT_MAT2x4:
174 case GL_FLOAT_MAT3x2:
178 case GL_FLOAT_MAT3x4:
182 case GL_FLOAT_MAT4x2:
186 case GL_FLOAT_MAT4x3:
191 elemType = GL_DOUBLE;
195 elemType = GL_DOUBLE;
199 elemType = GL_DOUBLE;
202 case GL_DOUBLE_MAT2x3:
203 elemType = GL_DOUBLE;
206 case GL_DOUBLE_MAT2x4:
207 elemType = GL_DOUBLE;
210 case GL_DOUBLE_MAT3x2:
211 elemType = GL_DOUBLE;
214 case GL_DOUBLE_MAT3x4:
215 elemType = GL_DOUBLE;
218 case GL_DOUBLE_MAT4x2:
219 elemType = GL_DOUBLE;
222 case GL_DOUBLE_MAT4x3:
223 elemType = GL_DOUBLE;
229 case GL_SAMPLER_CUBE:
230 case GL_SAMPLER_1D_SHADOW:
231 case GL_SAMPLER_2D_SHADOW:
232 case GL_SAMPLER_1D_ARRAY:
233 case GL_SAMPLER_2D_ARRAY:
234 case GL_SAMPLER_CUBE_MAP_ARRAY:
235 case GL_SAMPLER_1D_ARRAY_SHADOW:
236 case GL_SAMPLER_2D_ARRAY_SHADOW:
237 case GL_SAMPLER_2D_MULTISAMPLE:
238 case GL_SAMPLER_2D_MULTISAMPLE_ARRAY:
239 case GL_SAMPLER_CUBE_SHADOW:
240 case GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW:
241 case GL_SAMPLER_BUFFER:
242 case GL_SAMPLER_2D_RECT:
243 case GL_SAMPLER_2D_RECT_SHADOW:
244 case GL_INT_SAMPLER_1D:
245 case GL_INT_SAMPLER_2D:
246 case GL_INT_SAMPLER_3D:
247 case GL_INT_SAMPLER_CUBE:
248 case GL_INT_SAMPLER_1D_ARRAY:
249 case GL_INT_SAMPLER_2D_ARRAY:
250 case GL_INT_SAMPLER_CUBE_MAP_ARRAY:
251 case GL_INT_SAMPLER_2D_MULTISAMPLE:
252 case GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY:
253 case GL_INT_SAMPLER_BUFFER:
254 case GL_INT_SAMPLER_2D_RECT:
255 case GL_UNSIGNED_INT_SAMPLER_1D:
256 case GL_UNSIGNED_INT_SAMPLER_2D:
257 case GL_UNSIGNED_INT_SAMPLER_3D:
258 case GL_UNSIGNED_INT_SAMPLER_CUBE:
259 case GL_UNSIGNED_INT_SAMPLER_1D_ARRAY:
260 case GL_UNSIGNED_INT_SAMPLER_2D_ARRAY:
261 case GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY:
262 case GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE:
263 case GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY:
264 case GL_UNSIGNED_INT_SAMPLER_BUFFER:
265 case GL_UNSIGNED_INT_SAMPLER_2D_RECT:
270 OS::DebugMessage("apitrace: warning: %s: unknown GLenum 0x%04X\n", __FUNCTION__, type);
278 __glArrayPointer_size(GLint size, GLenum type, GLsizei stride, GLsizei maxIndex)
280 size_t elementSize = size*__gl_type_size(type);
282 stride = (GLsizei)elementSize;
284 return stride*maxIndex + elementSize;
287 #define __glVertexPointer_size(size, type, stride, maxIndex) __glArrayPointer_size(size, type, stride, maxIndex)
288 #define __glNormalPointer_size(type, stride, maxIndex) __glArrayPointer_size(3, type, stride, maxIndex)
289 #define __glColorPointer_size(size, type, stride, maxIndex) __glArrayPointer_size(size, type, stride, maxIndex)
290 #define __glIndexPointer_size(type, stride, maxIndex) __glArrayPointer_size(1, type, stride, maxIndex)
291 #define __glTexCoordPointer_size(size, type, stride, maxIndex) __glArrayPointer_size(size, type, stride, maxIndex)
292 #define __glEdgeFlagPointer_size(stride, maxIndex) __glArrayPointer_size(1, GL_BOOL, stride, maxIndex)
293 #define __glFogCoordPointer_size(type, stride, maxIndex) __glArrayPointer_size(1, type, stride, maxIndex)
294 #define __glSecondaryColorPointer_size(size, type, stride, maxIndex) __glArrayPointer_size(size, type, stride, maxIndex)
295 #define __glVertexAttribPointer_size(size, type, normalized, stride, maxIndex) __glArrayPointer_size(size, type, stride, maxIndex)
296 #define __glVertexAttribPointerARB_size(size, type, normalized, stride, maxIndex) __glArrayPointer_size(size, type, stride, maxIndex)
297 #define __glVertexAttribPointerNV_size(size, type, stride, maxIndex) __glArrayPointer_size(size, type, stride, maxIndex)
300 __glDrawArrays_maxindex(GLint first, GLsizei count)
305 return first + count - 1;
308 #define __glDrawArraysEXT_maxindex __glDrawArrays_maxindex
311 __glDrawElementsBaseVertex_maxindex(GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
314 GLint __element_array_buffer = 0;
319 __glGetIntegerv(GL_ELEMENT_ARRAY_BUFFER_BINDING, &__element_array_buffer);
320 if (__element_array_buffer) {
321 // Read indices from index buffer object
322 GLintptr offset = (GLintptr)indices;
323 GLsizeiptr size = count*__gl_type_size(type);
324 GLvoid *temp = malloc(size);
328 memset(temp, 0, size);
329 __glGetBufferSubData(GL_ELEMENT_ARRAY_BUFFER, offset, size, temp);
339 if (type == GL_UNSIGNED_BYTE) {
340 const GLubyte *p = (const GLubyte *)indices;
341 for (i = 0; i < count; ++i) {
342 if (p[i] > maxindex) {
346 } else if (type == GL_UNSIGNED_SHORT) {
347 const GLushort *p = (const GLushort *)indices;
348 for (i = 0; i < count; ++i) {
349 if (p[i] > maxindex) {
353 } else if (type == GL_UNSIGNED_INT) {
354 const GLuint *p = (const GLuint *)indices;
355 for (i = 0; i < count; ++i) {
356 if (p[i] > maxindex) {
361 OS::DebugMessage("apitrace: warning: %s: unknown GLenum 0x%04X\n", __FUNCTION__, type);
364 if (__element_array_buffer) {
368 maxindex += basevertex;
373 #define __glDrawRangeElementsBaseVertex_maxindex(start, end, count, type, indices, basevertex) __glDrawElementsBaseVertex_maxindex(count, type, indices, basevertex)
375 #define __glDrawElements_maxindex(count, type, indices) __glDrawElementsBaseVertex_maxindex(count, type, indices, 0);
376 #define __glDrawRangeElements_maxindex(start, end, count, type, indices) __glDrawElements_maxindex(count, type, indices)
377 #define __glDrawRangeElementsEXT_maxindex __glDrawRangeElements_maxindex
379 #define __glDrawArraysInstanced_maxindex(first, count, primcount) __glDrawArrays_maxindex(first, count)
380 #define __glDrawElementsInstanced_maxindex(count, type, indices, primcount) __glDrawElements_maxindex(count, type, indices)
381 #define __glDrawElementsInstancedBaseVertex_maxindex(count, type, indices, primcount, basevertex) __glDrawElementsBaseVertex_maxindex(count, type, indices, basevertex)
382 #define __glDrawRangeElementsInstanced_maxindex(start, end, count, type, indices, primcount) __glDrawRangeElements_maxindex(start, end, count, type, indices)
383 #define __glDrawRangeElementsInstancedBaseVertex_maxindex(start, end, count, type, indices, primcount, basevertex) __glDrawRangeElementsBaseVertex_maxindex(start, end, count, type, indices, basevertex)
385 #define __glDrawArraysInstancedARB_maxindex __glDrawArraysInstanced_maxindex
386 #define __glDrawElementsInstancedARB_maxindex __glDrawElementsInstanced_maxindex
387 #define __glDrawArraysInstancedEXT_maxindex __glDrawArraysInstanced_maxindex
388 #define __glDrawElementsInstancedEXT_maxindex __glDrawElementsInstanced_maxindex
391 __glDrawArraysIndirect_maxindex(const GLvoid *indirect) {
392 OS::DebugMessage("apitrace: warning: %s: unsupported\n", __FUNCTION__);
397 __glDrawElementsIndirect_maxindex(GLenum type, const GLvoid *indirect) {
398 OS::DebugMessage("apitrace: warning: %s: unsupported\n", __FUNCTION__);
403 __glMultiDrawArrays_maxindex(const GLint *first, const GLsizei *count, GLsizei primcount) {
405 for (GLsizei prim = 0; prim < primcount; ++prim) {
406 GLuint maxindex_prim = __glDrawArrays_maxindex(first[prim], count[prim]);
407 maxindex = std::max(maxindex, maxindex_prim);
413 __glMultiDrawElements_maxindex(const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount) {
415 for (GLsizei prim = 0; prim < primcount; ++prim) {
416 GLuint maxindex_prim = __glDrawElements_maxindex(count[prim], type, indices[prim]);
417 maxindex = std::max(maxindex, maxindex_prim);
423 __glMultiDrawElementsBaseVertex_maxindex(const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount, const GLint * basevertex) {
425 for (GLsizei prim = 0; prim < primcount; ++prim) {
426 GLuint maxindex_prim = __glDrawElementsBaseVertex_maxindex(count[prim], type, indices[prim], basevertex[prim]);
427 maxindex = std::max(maxindex, maxindex_prim);
432 #define __glMultiDrawArraysEXT_maxindex __glMultiDrawArrays_maxindex
433 #define __glMultiDrawElementsEXT_maxindex __glMultiDrawElements_maxindex
435 #define __glMultiModeDrawArraysIBM_maxindex(first, count, primcount, modestride) __glMultiDrawArrays_maxindex(first, count, primcount)
436 #define __glMultiModeDrawElementsIBM_maxindex(count, type, indices, primcount, modestride) __glMultiDrawElements_maxindex(count, type, (const GLvoid **)indices, primcount)
440 __glCallLists_size(GLsizei n, GLenum type)
442 return n*__gl_type_size(type);
445 #define __glFogfv_size __gl_param_size
446 #define __glFogiv_size __gl_param_size
448 #define __glLightfv_size __gl_param_size
449 #define __glLightiv_size __gl_param_size
451 #define __glLightModelfv_size __gl_param_size
452 #define __glLightModeliv_size __glLightModelfv_size
454 #define __glMaterialfv_size __gl_param_size
455 #define __glMaterialiv_size __glMaterialfv_size
459 __glMap1d_size(GLenum target, GLint stride, GLint order)
468 case GL_MAP1_TEXTURE_COORD_1:
471 case GL_MAP1_TEXTURE_COORD_2:
475 case GL_MAP1_TEXTURE_COORD_3:
476 case GL_MAP1_VERTEX_3:
479 case GL_MAP1_COLOR_4:
480 case GL_MAP1_TEXTURE_COORD_4:
481 case GL_MAP1_VERTEX_4:
485 OS::DebugMessage("apitrace: warning: %s: unknown GLenum 0x%04X\n", __FUNCTION__, target);
489 if (stride < channels) {
493 return channels + stride * (order - 1);
496 #define __glMap1f_size __glMap1d_size
499 __glMap2d_size(GLenum target, GLint ustride, GLint uorder, GLint vstride, GLint vorder)
501 if (uorder < 1 || vorder < 1) {
508 case GL_MAP2_TEXTURE_COORD_1:
511 case GL_MAP2_TEXTURE_COORD_2:
515 case GL_MAP2_TEXTURE_COORD_3:
516 case GL_MAP2_VERTEX_3:
519 case GL_MAP2_COLOR_4:
520 case GL_MAP2_TEXTURE_COORD_4:
521 case GL_MAP2_VERTEX_4:
525 OS::DebugMessage("apitrace: warning: %s: unknown GLenum 0x%04X\n", __FUNCTION__, target);
529 if (ustride < channels || vstride < channels) {
534 ustride * (uorder - 1) +
535 vstride * (vorder - 1);
538 #define __glMap2f_size __glMap2d_size
540 #define __glGetBooleanv_size __gl_param_size
541 #define __glGetDoublev_size __glGetBooleanv_size
542 #define __glGetFloatv_size __glGetBooleanv_size
543 #define __glGetIntegerv_size __glGetBooleanv_size
544 #define __glGetInteger64v_size __glGetBooleanv_size
545 #define __glGetBooleani_v_size __gl_param_size
546 #define __glGetDoublei_v_size __glGetBooleanv_size
547 #define __glGetFloati_v_size __glGetBooleanv_size
548 #define __glGetIntegeri_v_size __glGetBooleani_v_size
549 #define __glGetInteger64i_v_size __glGetBooleani_v_size
551 #define __glGetLightfv_size __glLightfv_size
552 #define __glGetLightiv_size __glLightfv_size
554 #define __glGetMaterialfv_size __glMaterialfv_size
555 #define __glGetMaterialiv_size __glMaterialfv_size
558 #define __glColorTableParameterfv_size __gl_param_size
559 #define __glColorTableParameteriv_size __gl_param_size
560 #define __glGetColorTableParameterfv_size __gl_param_size
561 #define __glGetColorTableParameteriv_size __gl_param_size
563 #define __glConvolutionParameterfv_size __gl_param_size
564 #define __glConvolutionParameteriv_size __gl_param_size
565 #define __glGetConvolutionParameterfv_size __gl_param_size
566 #define __glGetConvolutionParameteriv_size __gl_param_size
568 #define __glGetHistogramParameterfv_size __gl_param_size
569 #define __glGetHistogramParameteriv_size __gl_param_size
571 #define __glGetMinmaxParameterfv_size __gl_param_size
572 #define __glGetMinmaxParameteriv_size __gl_param_size
574 #define __glGetProgramivARB_size __gl_param_size
575 #define __glGetProgramivNV_size __gl_param_size
577 #define __glGetVertexAttribdvARB_size __gl_param_size
578 #define __glGetVertexAttribfvARB_size __gl_param_size
579 #define __glGetVertexAttribivARB_size __gl_param_size
580 #define __glGetVertexAttribdvNV_size __gl_param_size
581 #define __glGetVertexAttribfvNV_size __gl_param_size
582 #define __glGetVertexAttribivNV_size __gl_param_size
584 #define __glGetQueryObjectivARB_size __gl_param_size
585 #define __glGetQueryObjectuivARB_size __glGetQueryObjectivARB_size
586 #define __glGetQueryivARB_size __gl_param_size
588 #define __glPointParameterfv_size __glPointParameterfvEXT_size
589 #define __glPointParameteriv_size __glPointParameterfvEXT_size
590 #define __glPointParameterfvARB_size __glPointParameterfvEXT_size
591 #define __glPointParameterfvEXT_size __gl_param_size
592 #define __glPointParameterivNV_size __glPointParameterfvEXT_size
594 #define __glGetFramebufferAttachmentParameteriv_size __gl_param_size
595 #define __glGetFramebufferAttachmentParameterivEXT_size __gl_param_size
597 static inline unsigned
598 __gl_format_channels(GLenum format) {
607 case GL_DEPTH_COMPONENT:
608 case GL_STENCIL_INDEX:
610 case GL_DEPTH_STENCIL:
611 case GL_LUMINANCE_ALPHA:
624 case GL_DSDT_MAG_VIB_NV:
629 OS::DebugMessage("apitrace: warning: %s: unexpected format GLenum 0x%04X\n", __FUNCTION__, format);
637 return (x & (x - 1)) == 0;
640 template<class X, class Y>
643 return (x + (y - 1)) & ~(y - 1);
647 __gl_image_size(GLenum format, GLenum type, GLsizei width, GLsizei height, GLsizei depth) {
648 unsigned num_channels = __gl_format_channels(format);
650 unsigned bits_per_pixel;
656 case GL_UNSIGNED_BYTE:
657 bits_per_pixel = 8 * num_channels;
660 case GL_UNSIGNED_SHORT:
662 bits_per_pixel = 16 * num_channels;
665 case GL_UNSIGNED_INT:
667 bits_per_pixel = 32 * num_channels;
669 case GL_UNSIGNED_BYTE_3_3_2:
670 case GL_UNSIGNED_BYTE_2_3_3_REV:
673 case GL_UNSIGNED_SHORT_4_4_4_4:
674 case GL_UNSIGNED_SHORT_4_4_4_4_REV:
675 case GL_UNSIGNED_SHORT_5_5_5_1:
676 case GL_UNSIGNED_SHORT_1_5_5_5_REV:
677 case GL_UNSIGNED_SHORT_5_6_5:
678 case GL_UNSIGNED_SHORT_5_6_5_REV:
679 case GL_UNSIGNED_SHORT_8_8_MESA:
680 case GL_UNSIGNED_SHORT_8_8_REV_MESA:
683 case GL_UNSIGNED_INT_8_8_8_8:
684 case GL_UNSIGNED_INT_8_8_8_8_REV:
685 case GL_UNSIGNED_INT_10_10_10_2:
686 case GL_UNSIGNED_INT_2_10_10_10_REV:
687 case GL_UNSIGNED_INT_24_8:
688 case GL_UNSIGNED_INT_10F_11F_11F_REV:
689 case GL_UNSIGNED_INT_5_9_9_9_REV:
690 case GL_UNSIGNED_INT_S8_S8_8_8_NV:
691 case GL_UNSIGNED_INT_8_8_S8_S8_REV_NV:
694 case GL_FLOAT_32_UNSIGNED_INT_24_8_REV:
698 OS::DebugMessage("apitrace: warning: %s: unexpected type GLenum 0x%04X\n", __FUNCTION__, type);
704 GLint row_length = 0;
705 GLint image_height = 0;
707 GLint skip_pixels = 0;
708 GLint skip_images = 0;
710 __glGetIntegerv(GL_UNPACK_ALIGNMENT, &alignment);
711 __glGetIntegerv(GL_UNPACK_ROW_LENGTH, &row_length);
712 __glGetIntegerv(GL_UNPACK_IMAGE_HEIGHT, &image_height);
713 __glGetIntegerv(GL_UNPACK_SKIP_ROWS, &skip_rows);
714 __glGetIntegerv(GL_UNPACK_SKIP_PIXELS, &skip_pixels);
715 __glGetIntegerv(GL_UNPACK_SKIP_IMAGES, &skip_images);
717 if (row_length <= 0) {
721 size_t row_stride = (row_length*bits_per_pixel + 7)/8;
723 if ((GLint)bits_per_pixel < alignment*8 &&
724 (bits_per_pixel & 7) == 0 &&
725 _is_pot(bits_per_pixel)) {
726 row_stride = _align(row_stride, alignment);
729 if (image_height <= 0) {
730 image_height = height;
733 /* XXX: GL_UNPACK_IMAGE_HEIGHT and GL_UNPACK_SKIP_IMAGES should probably
734 * not be considered for pixel rectangles. */
736 size_t image_stride = image_height*row_stride;
738 size_t size = depth*image_stride;
740 size += (skip_pixels*bits_per_pixel + 7)/8;
741 size += skip_rows*row_stride;
742 size += skip_images*image_stride;
747 #define __glTexParameterfv_size __gl_param_size
748 #define __glTexParameteriv_size __gl_param_size
749 #define __glGetTexParameterfv_size __gl_param_size
750 #define __glGetTexParameteriv_size __gl_param_size
751 #define __glGetTexLevelParameterfv_size __gl_param_size
752 #define __glGetTexLevelParameteriv_size __gl_param_size
753 #define __glTexParameterIiv_size __gl_param_size
754 #define __glTexParameterIuiv_size __gl_param_size
755 #define __glGetTexParameterIiv_size __gl_param_size
756 #define __glGetTexParameterIuiv_size __gl_param_size
758 #define __glTexEnvfv_size __gl_param_size
759 #define __glTexEnviv_size __gl_param_size
760 #define __glGetTexEnvfv_size __gl_param_size
761 #define __glGetTexEnviv_size __gl_param_size
763 #define __glTexGendv_size __gl_param_size
764 #define __glTexGenfv_size __gl_param_size
765 #define __glTexGeniv_size __gl_param_size
766 #define __glGetTexGendv_size __gl_param_size
767 #define __glGetTexGenfv_size __gl_param_size
768 #define __glGetTexGeniv_size __gl_param_size
770 #define __glTexImage3D_size(format, type, width, height, depth) __gl_image_size(format, type, width, height, depth)
771 #define __glTexImage2D_size(format, type, width, height) __gl_image_size(format, type, width, height, 1)
772 #define __glTexImage1D_size(format, type, width) __gl_image_size(format, type, width, 1, 1)
774 #define __glTexSubImage3D_size(format, type, width, height, depth) __glTexImage3D_size(format, type, width, height, depth)
775 #define __glTexSubImage2D_size(format, type, width, height) __glTexImage2D_size(format, type, width, height)
776 #define __glTexSubImage1D_size(format, type, width) __glTexImage1D_size(format, type, width)
778 #define __glTexImage3DEXT_size __glTexImage3D_size
779 #define __glTexImage2DEXT_size __glTexImage2D_size
780 #define __glTexImage1DEXT_size __glTexImage1D_size
781 #define __glTexSubImage3DEXT_size __glTexSubImage3D_size
782 #define __glTexSubImage2DEXT_size __glTexSubImage2D_size
783 #define __glTexSubImage1DEXT_size __glTexSubImage1D_size
785 #define __glTextureImage3DEXT_size __glTexImage3D_size
786 #define __glTextureImage2DEXT_size __glTexImage2D_size
787 #define __glTextureImage1DEXT_size __glTexImage1D_size
788 #define __glTextureSubImage3DEXT_size __glTexSubImage3D_size
789 #define __glTextureSubImage2DEXT_size __glTexSubImage2D_size
790 #define __glTextureSubImage1DEXT_size __glTexSubImage1D_size
792 #define __glMultiTexImage3DEXT_size __glTexImage3D_size
793 #define __glMultiTexImage2DEXT_size __glTexImage2D_size
794 #define __glMultiTexImage1DEXT_size __glTexImage1D_size
795 #define __glMultiTexSubImage3DEXT_size __glTexSubImage3D_size
796 #define __glMultiTexSubImage2DEXT_size __glTexSubImage2D_size
797 #define __glMultiTexSubImage1DEXT_size __glTexSubImage1D_size
799 #define __glDrawPixels_size(format, type, width, height) __glTexImage2D_size(format, type, width, height)
800 #define __glConvolutionFilter1D_size(format, type, width) __glTexImage1D_size(format, type, width)
801 #define __glConvolutionFilter2D_size(format, type, width, height) __glTexImage2D_size(format, type, width, height)
802 #define __glColorTable_size(format, type, width) __glTexImage1D_size(format, type, width)
803 #define __glColorSubTable_size(format, type, count) __glColorTable_size(format, type, count)
805 #define __glBitmap_size(width, height) __glTexImage2D_size(GL_COLOR_INDEX, GL_BITMAP, width, height)
806 #define __glPolygonStipple_size() __glBitmap_size(32, 32)
809 __glClearBuffer_size(GLenum buffer)
817 case GL_FRONT_AND_BACK:
823 OS::DebugMessage("apitrace: warning: %s: unexpected buffer GLenum 0x%04X\n", __FUNCTION__, buffer);
829 * 0 terminated integer/float attribute list.
833 __AttribList_size(const T *pAttribList)
840 } while (*pAttribList++);
847 #endif /* _GL_SIZE_HPP_ */