[Piglit] [PATCH] Helper function to convert an arbitrary GL enum to a string.

Jose Fonseca jfonseca at vmware.com
Thu Feb 2 07:04:39 PST 2012


(The patch was very long so I've just copy'n'pasted a snippet here.

Jose


commit 03e922dfcdcfadc5801bb027224cec9ab77b2d4d
Author: José Fonseca <jfonseca at vmware.com>
Date:   Thu Feb 2 15:02:12 2012 +0000

    util: Helper function to convert an arbitrary GL enum to a string.

diff --git a/tests/util/CMakeLists.gl.txt b/tests/util/CMakeLists.gl.txt
index 9279fb9..12b2ea5 100644
--- a/tests/util/CMakeLists.gl.txt
+++ b/tests/util/CMakeLists.gl.txt
@@ -22,6 +22,7 @@ IF(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
 		    piglit-shader-gl.c
 		    piglit-transform-feedback.c
 		    piglit-util.c
+		    piglit-util-enum.c
 		    piglit-util-gl.c
 		    piglit-glx-framework.c
 		    piglit-glx-util.c
diff --git a/tests/util/CMakeLists.txt b/tests/util/CMakeLists.txt
index 798cd8a..96964d6 100644
--- a/tests/util/CMakeLists.txt
+++ b/tests/util/CMakeLists.txt
@@ -12,6 +12,7 @@ endif(${CMAKE_SYSTEM_NAME} MATCHES "Linux")
 set(UTIL_SOURCES
 	fdo-bitmap.c
 	piglit-util.c
+	piglit-util-enum.c
 	shader-load.c
 	piglit-framework.c
 	rgb9e5.c
diff --git a/tests/util/piglit-util-enum.c b/tests/util/piglit-util-enum.c
new file mode 100644
index 0000000..745029d
--- /dev/null
+++ b/tests/util/piglit-util-enum.c
@@ -0,0 +1,2983 @@
+/*
+ * Copyright 2012, VMware, Inc.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the "Software"),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice (including the next
+ * paragraph) shall be included in all copies or substantial portions of the
+ * Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+ * DEALINGS IN THE SOFTWARE.
+ */
+
+
+#if defined(_WIN32)
+#include <windows.h>
+#endif
+
+/* Force GL defines */
+#ifndef USE_OPENGL
+#  define USE_OPENGL
+#  undef USE_OPENGL_ES1
+#  undef USE_OPENGL_ES2
+#endif
+
+#include "piglit-util.h"
+
+
+const char *
+piglit_get_gl_enum_name(GLenum param)
+{
+#define CASE(x) case x: return #x;
+
+	switch (param) {
+
+	CASE(GL_ZERO)	// 0x0000
+	CASE(GL_ONE)	// 0x0001
+
+	/* These alias with other enums and are only used in draw calls */
+	//CASE(GL_POINTS)	// 0x0000
+	//CASE(GL_LINES)	// 0x0001
+	//CASE(GL_LINE_LOOP)	// 0x0002
+	//CASE(GL_LINE_STRIP)	// 0x0003
+	//CASE(GL_TRIANGLES)	// 0x0004
+	//CASE(GL_TRIANGLE_STRIP)	// 0x0005
+	//CASE(GL_TRIANGLE_FAN)	// 0x0006
+	//CASE(GL_QUADS)	// 0x0007
+	//CASE(GL_QUAD_STRIP)	// 0x0008
+	//CASE(GL_POLYGON)	// 0x0009
+	//CASE(GL_LINES_ADJACENCY)	// 0x000A
+	//CASE(GL_LINE_STRIP_ADJACENCY)	// 0x000B
+	//CASE(GL_TRIANGLES_ADJACENCY)	// 0x000C
+	//CASE(GL_TRIANGLE_STRIP_ADJACENCY)	// 0x000D
+	//CASE(GL_PATCHES)	// 0x000E
+
+	CASE(GL_ACCUM)	// 0x0100
+	CASE(GL_LOAD)	// 0x0101
+	CASE(GL_RETURN)	// 0x0102
+	CASE(GL_MULT)	// 0x0103
+	CASE(GL_ADD)	// 0x0104
+	CASE(GL_NEVER)	// 0x0200
+	CASE(GL_LESS)	// 0x0201
+	CASE(GL_EQUAL)	// 0x0202
+	CASE(GL_LEQUAL)	// 0x0203
+	CASE(GL_GREATER)	// 0x0204
+	CASE(GL_NOTEQUAL)	// 0x0205
+	CASE(GL_GEQUAL)	// 0x0206
+	CASE(GL_ALWAYS)	// 0x0207
+	CASE(GL_SRC_COLOR)	// 0x0300
+	CASE(GL_ONE_MINUS_SRC_COLOR)	// 0x0301
[...]
+	CASE(GL_UNSIGNED_INT_5_9_9_9_REV)	// 0x8C3E
+	CASE(GL_TEXTURE_SHARED_SIZE)	// 0x8C3F
+	CASE(GL_SRGB)	// 0x8C40
+	CASE(GL_SRGB8)	// 0x8C41
+	CASE(GL_SRGB_ALPHA)	// 0x8C42
+	CASE(GL_SRGB8_ALPHA8)	// 0x8C43
+	CASE(GL_SLUMINANCE_ALPHA)	// 0x8C44
+	CASE(GL_SLUMINANCE8_ALPHA8)	// 0x8C45
+	CASE(GL_SLUMINANCE)	// 0x8C46
+	CASE(GL_SLUMINANCE8)	// 0x8C47
+	CASE(GL_COMPRESSED_SRGB)	// 0x8C48
+	CASE(GL_COMPRESSED_SRGB_ALPHA)	// 0x8C49
+	CASE(GL_COMPRESSED_SLUMINANCE)	// 0x8C4A
+	CASE(GL_COMPRESSED_SLUMINANCE_ALPHA)	// 0x8C4B
+	CASE(GL_COMPRESSED_SRGB_S3TC_DXT1_EXT)	// 0x8C4C
+	CASE(GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT)	// 0x8C4D
+	CASE(GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT)	// 0x8C4E
+	CASE(GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT)	// 0x8C4F
+	CASE(GL_COMPRESSED_LUMINANCE_LATC1_EXT)	// 0x8C70
+	CASE(GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT)	// 0x8C71
+	CASE(GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT)	// 0x8C72
+	CASE(GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT)	// 0x8C73
+	CASE(GL_TESS_CONTROL_PROGRAM_PARAMETER_BUFFER_NV)	// 0x8C74
+	CASE(GL_TESS_EVALUATION_PROGRAM_PARAMETER_BUFFER_NV)	// 0x8C75
+	CASE(GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH)	// 0x8C76
+	CASE(GL_BACK_PRIMARY_COLOR_NV)	// 0x8C77
+	CASE(GL_BACK_SECONDARY_COLOR_NV)	// 0x8C78
+	CASE(GL_TEXTURE_COORD_NV)	// 0x8C79
+	CASE(GL_CLIP_DISTANCE_NV)	// 0x8C7A
+	CASE(GL_VERTEX_ID_NV)	// 0x8C7B
+	CASE(GL_PRIMITIVE_ID_NV)	// 0x8C7C
+	CASE(GL_GENERIC_ATTRIB_NV)	// 0x8C7D
+	CASE(GL_TRANSFORM_FEEDBACK_ATTRIBS_NV)	// 0x8C7F
+	CASE(GL_TRANSFORM_FEEDBACK_BUFFER_MODE)	// 0x8C7F
+	CASE(GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS)	// 0x8C80
+	CASE(GL_ACTIVE_VARYINGS_NV)	// 0x8C81
+	CASE(GL_ACTIVE_VARYING_MAX_LENGTH_NV)	// 0x8C82
+	CASE(GL_TRANSFORM_FEEDBACK_VARYINGS)	// 0x8C83
+	CASE(GL_TRANSFORM_FEEDBACK_BUFFER_START)	// 0x8C84
+	CASE(GL_TRANSFORM_FEEDBACK_BUFFER_SIZE)	// 0x8C85
+	CASE(GL_TRANSFORM_FEEDBACK_RECORD_NV)	// 0x8C86
+	CASE(GL_PRIMITIVES_GENERATED)	// 0x8C87
+	CASE(GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN)	// 0x8C88
+	CASE(GL_RASTERIZER_DISCARD)	// 0x8C89
+	CASE(GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS)	// 0x8C8A
+	CASE(GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS)	// 0x8C8B
+	CASE(GL_INTERLEAVED_ATTRIBS)	// 0x8C8C
+	CASE(GL_SEPARATE_ATTRIBS)	// 0x8C8D
+	CASE(GL_TRANSFORM_FEEDBACK_BUFFER)	// 0x8C8E
+	CASE(GL_TRANSFORM_FEEDBACK_BUFFER_BINDING)	// 0x8C8F
+	//CASE(GL_ATC_RGB_AMD)	# 0x8C92
+	//CASE(GL_ATC_RGBA_EXPLICIT_ALPHA_AMD)	# 0x8C93
+	CASE(GL_POINT_SPRITE_COORD_ORIGIN)	// 0x8CA0
+	CASE(GL_LOWER_LEFT)	// 0x8CA1
+	CASE(GL_UPPER_LEFT)	// 0x8CA2
+	CASE(GL_STENCIL_BACK_REF)	// 0x8CA3
+	CASE(GL_STENCIL_BACK_VALUE_MASK)	// 0x8CA4
+	CASE(GL_STENCIL_BACK_WRITEMASK)	// 0x8CA5
+	CASE(GL_DRAW_FRAMEBUFFER_BINDING)	// 0x8CA6
+	CASE(GL_RENDERBUFFER_BINDING)	// 0x8CA7
+	CASE(GL_READ_FRAMEBUFFER)	// 0x8CA8
+	CASE(GL_DRAW_FRAMEBUFFER)	// 0x8CA9
+	CASE(GL_READ_FRAMEBUFFER_BINDING)	// 0x8CAA
+	CASE(GL_RENDERBUFFER_SAMPLES)	// 0x8CAB
+	CASE(GL_DEPTH_COMPONENT32F)	// 0x8CAC
+	CASE(GL_DEPTH32F_STENCIL8)	// 0x8CAD
+	CASE(GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE)	// 0x8CD0
+	CASE(GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME)	// 0x8CD1
+	CASE(GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL)	// 0x8CD2
+	CASE(GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE)	// 0x8CD3
+	CASE(GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER)	// 0x8CD4
+	CASE(GL_FRAMEBUFFER_COMPLETE)	// 0x8CD5
+	CASE(GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT)	// 0x8CD6
+	CASE(GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT)	// 0x8CD7
+	CASE(GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT)	// 0x8CD9
+	CASE(GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT)	// 0x8CDA
+	CASE(GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER)	// 0x8CDB
+	CASE(GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER)	// 0x8CDC
+	CASE(GL_FRAMEBUFFER_UNSUPPORTED)	// 0x8CDD
+	CASE(GL_MAX_COLOR_ATTACHMENTS)	// 0x8CDF
+	CASE(GL_COLOR_ATTACHMENT0)	// 0x8CE0
+	CASE(GL_COLOR_ATTACHMENT1)	// 0x8CE1
+	CASE(GL_COLOR_ATTACHMENT2)	// 0x8CE2
+	CASE(GL_COLOR_ATTACHMENT3)	// 0x8CE3
+	CASE(GL_COLOR_ATTACHMENT4)	// 0x8CE4
+	CASE(GL_COLOR_ATTACHMENT5)	// 0x8CE5
+	CASE(GL_COLOR_ATTACHMENT6)	// 0x8CE6
+	CASE(GL_COLOR_ATTACHMENT7)	// 0x8CE7
+	CASE(GL_COLOR_ATTACHMENT8)	// 0x8CE8
+	CASE(GL_COLOR_ATTACHMENT9)	// 0x8CE9
+	CASE(GL_COLOR_ATTACHMENT10)	// 0x8CEA
+	CASE(GL_COLOR_ATTACHMENT11)	// 0x8CEB
+	CASE(GL_COLOR_ATTACHMENT12)	// 0x8CEC
+	CASE(GL_COLOR_ATTACHMENT13)	// 0x8CED
+	CASE(GL_COLOR_ATTACHMENT14)	// 0x8CEE
+	CASE(GL_COLOR_ATTACHMENT15)	// 0x8CEF
+	CASE(GL_DEPTH_ATTACHMENT)	// 0x8D00
+	CASE(GL_STENCIL_ATTACHMENT)	// 0x8D20
+	CASE(GL_FRAMEBUFFER)	// 0x8D40
+	CASE(GL_RENDERBUFFER)	// 0x8D41
+	CASE(GL_RENDERBUFFER_WIDTH)	// 0x8D42
+	CASE(GL_RENDERBUFFER_HEIGHT)	// 0x8D43
+	CASE(GL_RENDERBUFFER_INTERNAL_FORMAT)	// 0x8D44
+	CASE(GL_STENCIL_INDEX1)	// 0x8D46
+	CASE(GL_STENCIL_INDEX4)	// 0x8D47
+	CASE(GL_STENCIL_INDEX8)	// 0x8D48
+	CASE(GL_STENCIL_INDEX16)	// 0x8D49
+	CASE(GL_RENDERBUFFER_RED_SIZE)	// 0x8D50
+	CASE(GL_RENDERBUFFER_GREEN_SIZE)	// 0x8D51
+	CASE(GL_RENDERBUFFER_BLUE_SIZE)	// 0x8D52
+	CASE(GL_RENDERBUFFER_ALPHA_SIZE)	// 0x8D53
+	CASE(GL_RENDERBUFFER_DEPTH_SIZE)	// 0x8D54
+	CASE(GL_RENDERBUFFER_STENCIL_SIZE)	// 0x8D55
+	CASE(GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE)	// 0x8D56
+	CASE(GL_MAX_SAMPLES)	// 0x8D57
+	//CASE(GL_TEXTURE_GEN_STR_OES)	# 0x8D60
+	//CASE(GL_HALF_FLOAT_OES)	# 0x8D61
+	//CASE(GL_RGB565_OES)	# 0x8D62
+	//CASE(GL_ETC1_RGB8_OES)	# 0x8D64
+	//CASE(GL_TEXTURE_EXTERNAL_OES)	# 0x8D65
+	//CASE(GL_SAMPLER_EXTERNAL_OES)	# 0x8D66
+	//CASE(GL_TEXTURE_BINDING_EXTERNAL_OES)	# 0x8D67
+	//CASE(GL_REQUIRED_TEXTURE_IMAGE_UNITS_OES)	# 0x8D68
+	CASE(GL_RGBA32UI)	// 0x8D70
+	CASE(GL_RGB32UI)	// 0x8D71
+	CASE(GL_ALPHA32UI_EXT)	// 0x8D72
+	CASE(GL_INTENSITY32UI_EXT)	// 0x8D73
+	CASE(GL_LUMINANCE32UI_EXT)	// 0x8D74
+	CASE(GL_LUMINANCE_ALPHA32UI_EXT)	// 0x8D75
+	CASE(GL_RGBA16UI)	// 0x8D76
+	CASE(GL_RGB16UI)	// 0x8D77
+	CASE(GL_ALPHA16UI_EXT)	// 0x8D78
+	CASE(GL_INTENSITY16UI_EXT)	// 0x8D79
+	CASE(GL_LUMINANCE16UI_EXT)	// 0x8D7A
+	CASE(GL_LUMINANCE_ALPHA16UI_EXT)	// 0x8D7B
+	CASE(GL_RGBA8UI)	// 0x8D7C
+	CASE(GL_RGB8UI)	// 0x8D7D
+	CASE(GL_ALPHA8UI_EXT)	// 0x8D7E
+	CASE(GL_INTENSITY8UI_EXT)	// 0x8D7F
+	CASE(GL_LUMINANCE8UI_EXT)	// 0x8D80
+	CASE(GL_LUMINANCE_ALPHA8UI_EXT)	// 0x8D81
+	CASE(GL_RGBA32I)	// 0x8D82
+	CASE(GL_RGB32I)	// 0x8D83
+	CASE(GL_ALPHA32I_EXT)	// 0x8D84
+	CASE(GL_INTENSITY32I_EXT)	// 0x8D85
+	CASE(GL_LUMINANCE32I_EXT)	// 0x8D86
+	CASE(GL_LUMINANCE_ALPHA32I_EXT)	// 0x8D87
+	CASE(GL_RGBA16I)	// 0x8D88
+	CASE(GL_RGB16I)	// 0x8D89
+	CASE(GL_ALPHA16I_EXT)	// 0x8D8A
+	CASE(GL_INTENSITY16I_EXT)	// 0x8D8B
+	CASE(GL_LUMINANCE16I_EXT)	// 0x8D8C
+	CASE(GL_LUMINANCE_ALPHA16I_EXT)	// 0x8D8D
+	CASE(GL_RGBA8I)	// 0x8D8E
+	CASE(GL_RGB8I)	// 0x8D8F
+	CASE(GL_ALPHA8I_EXT)	// 0x8D90
+	CASE(GL_INTENSITY8I_EXT)	// 0x8D91
+	CASE(GL_LUMINANCE8I_EXT)	// 0x8D92
+	CASE(GL_LUMINANCE_ALPHA8I_EXT)	// 0x8D93
+	CASE(GL_RED_INTEGER)	// 0x8D94
+	CASE(GL_GREEN_INTEGER)	// 0x8D95
+	CASE(GL_BLUE_INTEGER)	// 0x8D96
+	CASE(GL_ALPHA_INTEGER)	// 0x8D97
+	CASE(GL_RGB_INTEGER)	// 0x8D98
+	CASE(GL_RGBA_INTEGER)	// 0x8D99
+	CASE(GL_BGR_INTEGER)	// 0x8D9A
+	CASE(GL_BGRA_INTEGER)	// 0x8D9B
+	CASE(GL_LUMINANCE_INTEGER_EXT)	// 0x8D9C
+	CASE(GL_LUMINANCE_ALPHA_INTEGER_EXT)	// 0x8D9D
+	CASE(GL_RGBA_INTEGER_MODE_EXT)	// 0x8D9E
+	CASE(GL_INT_2_10_10_10_REV)	// 0x8D9F
+	CASE(GL_MAX_PROGRAM_PARAMETER_BUFFER_BINDINGS_NV)	// 0x8DA0
+	CASE(GL_MAX_PROGRAM_PARAMETER_BUFFER_SIZE_NV)	// 0x8DA1
+	CASE(GL_VERTEX_PROGRAM_PARAMETER_BUFFER_NV)	// 0x8DA2
+	CASE(GL_GEOMETRY_PROGRAM_PARAMETER_BUFFER_NV)	// 0x8DA3
+	CASE(GL_FRAGMENT_PROGRAM_PARAMETER_BUFFER_NV)	// 0x8DA4
+	CASE(GL_MAX_PROGRAM_GENERIC_ATTRIBS_NV)	// 0x8DA5
+	CASE(GL_MAX_PROGRAM_GENERIC_RESULTS_NV)	// 0x8DA6
+	CASE(GL_FRAMEBUFFER_ATTACHMENT_LAYERED)	// 0x8DA7
+	CASE(GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS)	// 0x8DA8
+	CASE(GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_ARB)	// 0x8DA9
+	//CASE(GL_LAYER_NV)	// 0x8DAA
+	CASE(GL_DEPTH_COMPONENT32F_NV)	// 0x8DAB
+	CASE(GL_DEPTH32F_STENCIL8_NV)	// 0x8DAC
+	CASE(GL_FLOAT_32_UNSIGNED_INT_24_8_REV)	// 0x8DAD
+	CASE(GL_SHADER_INCLUDE_ARB)	// 0x8DAE
+	CASE(GL_DEPTH_BUFFER_FLOAT_MODE_NV)	// 0x8DAF
+	CASE(GL_FRAMEBUFFER_SRGB)	// 0x8DB9
+	CASE(GL_FRAMEBUFFER_SRGB_CAPABLE_EXT)	// 0x8DBA
+	CASE(GL_COMPRESSED_RED_RGTC1)	// 0x8DBB
+	CASE(GL_COMPRESSED_SIGNED_RED_RGTC1)	// 0x8DBC
+	CASE(GL_COMPRESSED_RG_RGTC2)	// 0x8DBD
+	CASE(GL_COMPRESSED_SIGNED_RG_RGTC2)	// 0x8DBE
+	CASE(GL_SAMPLER_1D_ARRAY)	// 0x8DC0
+	CASE(GL_SAMPLER_2D_ARRAY)	// 0x8DC1
+	CASE(GL_SAMPLER_BUFFER)	// 0x8DC2
+	CASE(GL_SAMPLER_1D_ARRAY_SHADOW)	// 0x8DC3
+	CASE(GL_SAMPLER_2D_ARRAY_SHADOW)	// 0x8DC4
+	CASE(GL_SAMPLER_CUBE_SHADOW)	// 0x8DC5
+	CASE(GL_UNSIGNED_INT_VEC2)	// 0x8DC6
+	CASE(GL_UNSIGNED_INT_VEC3)	// 0x8DC7
+	CASE(GL_UNSIGNED_INT_VEC4)	// 0x8DC8
+	CASE(GL_INT_SAMPLER_1D)	// 0x8DC9
+	CASE(GL_INT_SAMPLER_2D)	// 0x8DCA
+	CASE(GL_INT_SAMPLER_3D)	// 0x8DCB
+	CASE(GL_INT_SAMPLER_CUBE)	// 0x8DCC
+	CASE(GL_INT_SAMPLER_2D_RECT)	// 0x8DCD
+	CASE(GL_INT_SAMPLER_1D_ARRAY)	// 0x8DCE
+	CASE(GL_INT_SAMPLER_2D_ARRAY)	// 0x8DCF
+	CASE(GL_INT_SAMPLER_BUFFER)	// 0x8DD0
+	CASE(GL_UNSIGNED_INT_SAMPLER_1D)	// 0x8DD1
+	CASE(GL_UNSIGNED_INT_SAMPLER_2D)	// 0x8DD2
+	CASE(GL_UNSIGNED_INT_SAMPLER_3D)	// 0x8DD3
+	CASE(GL_UNSIGNED_INT_SAMPLER_CUBE)	// 0x8DD4
+	CASE(GL_UNSIGNED_INT_SAMPLER_2D_RECT)	// 0x8DD5
+	CASE(GL_UNSIGNED_INT_SAMPLER_1D_ARRAY)	// 0x8DD6
+	CASE(GL_UNSIGNED_INT_SAMPLER_2D_ARRAY)	// 0x8DD7
+	CASE(GL_UNSIGNED_INT_SAMPLER_BUFFER)	// 0x8DD8
+	CASE(GL_GEOMETRY_SHADER)	// 0x8DD9
+	CASE(GL_GEOMETRY_VERTICES_OUT_ARB)	// 0x8DDA
+	CASE(GL_GEOMETRY_INPUT_TYPE_ARB)	// 0x8DDB
+	CASE(GL_GEOMETRY_OUTPUT_TYPE_ARB)	// 0x8DDC
+	CASE(GL_MAX_GEOMETRY_VARYING_COMPONENTS_ARB)	// 0x8DDD
+	CASE(GL_MAX_VERTEX_VARYING_COMPONENTS_ARB)	// 0x8DDE
+	CASE(GL_MAX_GEOMETRY_UNIFORM_COMPONENTS)	// 0x8DDF
+	CASE(GL_MAX_GEOMETRY_OUTPUT_VERTICES)	// 0x8DE0
+	CASE(GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS)	// 0x8DE1
+	CASE(GL_MAX_VERTEX_BINDABLE_UNIFORMS_EXT)	// 0x8DE2
+	CASE(GL_MAX_FRAGMENT_BINDABLE_UNIFORMS_EXT)	// 0x8DE3
+	CASE(GL_MAX_GEOMETRY_BINDABLE_UNIFORMS_EXT)	// 0x8DE4
+	CASE(GL_ACTIVE_SUBROUTINES)	// 0x8DE5
+	CASE(GL_ACTIVE_SUBROUTINE_UNIFORMS)	// 0x8DE6
+	CASE(GL_MAX_SUBROUTINES)	// 0x8DE7
+	CASE(GL_MAX_SUBROUTINE_UNIFORM_LOCATIONS)	// 0x8DE8
+	CASE(GL_NAMED_STRING_LENGTH_ARB)	// 0x8DE9
+	CASE(GL_NAMED_STRING_TYPE_ARB)	// 0x8DEA
+	CASE(GL_MAX_BINDABLE_UNIFORM_SIZE_EXT)	// 0x8DED
+	CASE(GL_UNIFORM_BUFFER_EXT)	// 0x8DEE
+	CASE(GL_UNIFORM_BUFFER_BINDING_EXT)	// 0x8DEF
+	CASE(GL_LOW_FLOAT)	// 0x8DF0
+	CASE(GL_MEDIUM_FLOAT)	// 0x8DF1
+	CASE(GL_HIGH_FLOAT)	// 0x8DF2
+	CASE(GL_LOW_INT)	// 0x8DF3
+	CASE(GL_MEDIUM_INT)	// 0x8DF4
+	CASE(GL_HIGH_INT)	// 0x8DF5
+	CASE(GL_NUM_SHADER_BINARY_FORMATS)	// 0x8DF9
+	CASE(GL_SHADER_COMPILER)	// 0x8DFA
+	CASE(GL_MAX_VERTEX_UNIFORM_VECTORS)	// 0x8DFB
+	CASE(GL_MAX_VARYING_VECTORS)	// 0x8DFC
+	CASE(GL_MAX_FRAGMENT_UNIFORM_VECTORS)	// 0x8DFD
+	CASE(GL_RENDERBUFFER_COLOR_SAMPLES_NV)	// 0x8E10
+	CASE(GL_MAX_MULTISAMPLE_COVERAGE_MODES_NV)	// 0x8E11
+	CASE(GL_MULTISAMPLE_COVERAGE_MODES_NV)	// 0x8E12
+	CASE(GL_QUERY_WAIT)	// 0x8E13
+	CASE(GL_QUERY_NO_WAIT)	// 0x8E14
+	CASE(GL_QUERY_BY_REGION_WAIT)	// 0x8E15
+	CASE(GL_QUERY_BY_REGION_NO_WAIT)	// 0x8E16
+	CASE(GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS)	// 0x8E1E
+	CASE(GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS)	// 0x8E1F
+	CASE(GL_COLOR_SAMPLES_NV)	// 0x8E20
+	CASE(GL_TRANSFORM_FEEDBACK)	// 0x8E22
+	CASE(GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED)	// 0x8E23
+	CASE(GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE)	// 0x8E24
+	CASE(GL_TRANSFORM_FEEDBACK_BINDING)	// 0x8E25
+	CASE(GL_FRAME_NV)	// 0x8E26
+	CASE(GL_FIELDS_NV)	// 0x8E27
+	CASE(GL_TIMESTAMP)	// 0x8E28
+	CASE(GL_NUM_FILL_STREAMS_NV)	// 0x8E29
+	CASE(GL_PRESENT_TIME_NV)	// 0x8E2A
+	CASE(GL_PRESENT_DURATION_NV)	// 0x8E2B
+	CASE(GL_PROGRAM_MATRIX_EXT)	// 0x8E2D
+	CASE(GL_TRANSPOSE_PROGRAM_MATRIX_EXT)	// 0x8E2E
+	CASE(GL_PROGRAM_MATRIX_STACK_DEPTH_EXT)	// 0x8E2F
+	CASE(GL_TEXTURE_SWIZZLE_R)	// 0x8E42
+	CASE(GL_TEXTURE_SWIZZLE_G)	// 0x8E43
+	CASE(GL_TEXTURE_SWIZZLE_B)	// 0x8E44
+	CASE(GL_TEXTURE_SWIZZLE_A)	// 0x8E45
+	CASE(GL_TEXTURE_SWIZZLE_RGBA)	// 0x8E46
+	CASE(GL_ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS)	// 0x8E47
+	CASE(GL_ACTIVE_SUBROUTINE_MAX_LENGTH)	// 0x8E48
+	CASE(GL_ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH)	// 0x8E49
+	CASE(GL_NUM_COMPATIBLE_SUBROUTINES)	// 0x8E4A
+	CASE(GL_COMPATIBLE_SUBROUTINES)	// 0x8E4B
+	CASE(GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION)	// 0x8E4C
+	CASE(GL_FIRST_VERTEX_CONVENTION)	// 0x8E4D
+	CASE(GL_LAST_VERTEX_CONVENTION)	// 0x8E4E
+	CASE(GL_PROVOKING_VERTEX)	// 0x8E4F
+	CASE(GL_SAMPLE_POSITION)	// 0x8E50
+	CASE(GL_SAMPLE_MASK)	// 0x8E51
+	CASE(GL_SAMPLE_MASK_VALUE)	// 0x8E52
+	CASE(GL_TEXTURE_BINDING_RENDERBUFFER_NV)	// 0x8E53
+	CASE(GL_TEXTURE_RENDERBUFFER_DATA_STORE_BINDING_NV)	// 0x8E54
+	CASE(GL_TEXTURE_RENDERBUFFER_NV)	// 0x8E55
+	CASE(GL_SAMPLER_RENDERBUFFER_NV)	// 0x8E56
+	CASE(GL_INT_SAMPLER_RENDERBUFFER_NV)	// 0x8E57
+	CASE(GL_UNSIGNED_INT_SAMPLER_RENDERBUFFER_NV)	// 0x8E58
+	CASE(GL_MAX_SAMPLE_MASK_WORDS)	// 0x8E59
+	CASE(GL_MAX_GEOMETRY_SHADER_INVOCATIONS)	// 0x8E5A
+	CASE(GL_MIN_FRAGMENT_INTERPOLATION_OFFSET)	// 0x8E5B
+	CASE(GL_MAX_FRAGMENT_INTERPOLATION_OFFSET)	// 0x8E5C
+	CASE(GL_FRAGMENT_INTERPOLATION_OFFSET_BITS)	// 0x8E5D
+	CASE(GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET)	// 0x8E5E
+	CASE(GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET)	// 0x8E5F
+	CASE(GL_MAX_TRANSFORM_FEEDBACK_BUFFERS)	// 0x8E70
+	CASE(GL_MAX_VERTEX_STREAMS)	// 0x8E71
+	CASE(GL_PATCH_VERTICES)	// 0x8E72
+	CASE(GL_PATCH_DEFAULT_INNER_LEVEL)	// 0x8E73
+	CASE(GL_PATCH_DEFAULT_OUTER_LEVEL)	// 0x8E74
+	CASE(GL_TESS_CONTROL_OUTPUT_VERTICES)	// 0x8E75
+	CASE(GL_TESS_GEN_MODE)	// 0x8E76
+	CASE(GL_TESS_GEN_SPACING)	// 0x8E77
+	CASE(GL_TESS_GEN_VERTEX_ORDER)	// 0x8E78
+	CASE(GL_TESS_GEN_POINT_MODE)	// 0x8E79
+	CASE(GL_ISOLINES)	// 0x8E7A
+	CASE(GL_FRACTIONAL_ODD)	// 0x8E7B
+	CASE(GL_FRACTIONAL_EVEN)	// 0x8E7C
+	CASE(GL_MAX_PATCH_VERTICES)	// 0x8E7D
+	CASE(GL_MAX_TESS_GEN_LEVEL)	// 0x8E7E
+	CASE(GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS)	// 0x8E7F
+	CASE(GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS)	// 0x8E80
+	CASE(GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS)	// 0x8E81
+	CASE(GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS)	// 0x8E82
+	CASE(GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS)	// 0x8E83
+	CASE(GL_MAX_TESS_PATCH_COMPONENTS)	// 0x8E84
+	CASE(GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS)	// 0x8E85
+	CASE(GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS)	// 0x8E86
+	CASE(GL_TESS_EVALUATION_SHADER)	// 0x8E87
+	CASE(GL_TESS_CONTROL_SHADER)	// 0x8E88
+	CASE(GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS)	// 0x8E89
+	CASE(GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS)	// 0x8E8A
+	CASE(GL_COMPRESSED_RGBA_BPTC_UNORM_ARB)	// 0x8E8C
+	CASE(GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM_ARB)	// 0x8E8D
+	CASE(GL_COMPRESSED_RGB_BPTC_SIGNED_FLOAT_ARB)	// 0x8E8E
+	CASE(GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_ARB)	// 0x8E8F
+	//CASE(GL_COVERAGE_COMPONENT_NV)	# 0x8ED0
+	//CASE(GL_COVERAGE_COMPONENT4_NV)	# 0x8ED1
+	//CASE(GL_COVERAGE_ATTACHMENT_NV)	# 0x8ED2
+	//CASE(GL_COVERAGE_BUFFERS_NV)	# 0x8ED3
+	//CASE(GL_COVERAGE_SAMPLES_NV)	# 0x8ED4
+	//CASE(GL_COVERAGE_ALL_FRAGMENTS_NV)	# 0x8ED5
+	//CASE(GL_COVERAGE_EDGE_FRAGMENTS_NV)	# 0x8ED6
+	//CASE(GL_COVERAGE_AUTOMATIC_NV)	# 0x8ED7
+	CASE(GL_BUFFER_GPU_ADDRESS_NV)	// 0x8F1D
+	CASE(GL_VERTEX_ATTRIB_ARRAY_UNIFIED_NV)	// 0x8F1E
+	CASE(GL_ELEMENT_ARRAY_UNIFIED_NV)	// 0x8F1F
+	CASE(GL_VERTEX_ATTRIB_ARRAY_ADDRESS_NV)	// 0x8F20
+	CASE(GL_VERTEX_ARRAY_ADDRESS_NV)	// 0x8F21
+	CASE(GL_NORMAL_ARRAY_ADDRESS_NV)	// 0x8F22
+	CASE(GL_COLOR_ARRAY_ADDRESS_NV)	// 0x8F23
+	CASE(GL_INDEX_ARRAY_ADDRESS_NV)	// 0x8F24
+	CASE(GL_TEXTURE_COORD_ARRAY_ADDRESS_NV)	// 0x8F25
+	CASE(GL_EDGE_FLAG_ARRAY_ADDRESS_NV)	// 0x8F26
+	CASE(GL_SECONDARY_COLOR_ARRAY_ADDRESS_NV)	// 0x8F27
+	CASE(GL_FOG_COORD_ARRAY_ADDRESS_NV)	// 0x8F28
+	CASE(GL_ELEMENT_ARRAY_ADDRESS_NV)	// 0x8F29
+	CASE(GL_VERTEX_ATTRIB_ARRAY_LENGTH_NV)	// 0x8F2A
+	CASE(GL_VERTEX_ARRAY_LENGTH_NV)	// 0x8F2B
+	CASE(GL_NORMAL_ARRAY_LENGTH_NV)	// 0x8F2C
+	CASE(GL_COLOR_ARRAY_LENGTH_NV)	// 0x8F2D
+	CASE(GL_INDEX_ARRAY_LENGTH_NV)	// 0x8F2E
+	CASE(GL_TEXTURE_COORD_ARRAY_LENGTH_NV)	// 0x8F2F
+	CASE(GL_EDGE_FLAG_ARRAY_LENGTH_NV)	// 0x8F30
+	CASE(GL_SECONDARY_COLOR_ARRAY_LENGTH_NV)	// 0x8F31
+	CASE(GL_FOG_COORD_ARRAY_LENGTH_NV)	// 0x8F32
+	CASE(GL_ELEMENT_ARRAY_LENGTH_NV)	// 0x8F33
+	CASE(GL_GPU_ADDRESS_NV)	// 0x8F34
+	CASE(GL_MAX_SHADER_BUFFER_ADDRESS_NV)	// 0x8F35
+	CASE(GL_COPY_READ_BUFFER)	// 0x8F36
+	CASE(GL_COPY_WRITE_BUFFER)	// 0x8F37
+	CASE(GL_MAX_IMAGE_UNITS)	// 0x8F38
+	CASE(GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS)	// 0x8F39
+	CASE(GL_IMAGE_BINDING_NAME)	// 0x8F3A
+	CASE(GL_IMAGE_BINDING_LEVEL)	// 0x8F3B
+	CASE(GL_IMAGE_BINDING_LAYERED)	// 0x8F3C
+	CASE(GL_IMAGE_BINDING_LAYER)	// 0x8F3D
+	CASE(GL_IMAGE_BINDING_ACCESS)	// 0x8F3E
+	CASE(GL_DRAW_INDIRECT_BUFFER)	// 0x8F3F
+	CASE(GL_DRAW_INDIRECT_UNIFIED_NV)	// 0x8F40
+	CASE(GL_DRAW_INDIRECT_ADDRESS_NV)	// 0x8F41
+	CASE(GL_DRAW_INDIRECT_LENGTH_NV)	// 0x8F42
+	CASE(GL_DRAW_INDIRECT_BUFFER_BINDING)	// 0x8F43
+	//CASE(GL_MAX_PROGRAM_SUBROUTINE_PARAMETERS_NV)	// 0x8F44
+	//CASE(GL_MAX_PROGRAM_SUBROUTINE_NUM_NV)	// 0x8F45
+	CASE(GL_DOUBLE_MAT2)	// 0x8F46
+	CASE(GL_DOUBLE_MAT3)	// 0x8F47
+	CASE(GL_DOUBLE_MAT4)	// 0x8F48
+	CASE(GL_DOUBLE_MAT2x3)	// 0x8F49
+	CASE(GL_DOUBLE_MAT2x4)	// 0x8F4A
+	CASE(GL_DOUBLE_MAT3x2)	// 0x8F4B
+	CASE(GL_DOUBLE_MAT3x4)	// 0x8F4C
+	CASE(GL_DOUBLE_MAT4x2)	// 0x8F4D
+	CASE(GL_DOUBLE_MAT4x3)	// 0x8F4E
+	//CASE(GL_MALI_SHADER_BINARY_ARM)	# 0x8F60
+	CASE(GL_RED_SNORM)	// 0x8F90
+	CASE(GL_RG_SNORM)	// 0x8F91
+	CASE(GL_RGB_SNORM)	// 0x8F92
+	CASE(GL_RGBA_SNORM)	// 0x8F93
+	CASE(GL_R8_SNORM)	// 0x8F94
+	CASE(GL_RG8_SNORM)	// 0x8F95
+	CASE(GL_RGB8_SNORM)	// 0x8F96
+	CASE(GL_RGBA8_SNORM)	// 0x8F97
+	CASE(GL_R16_SNORM)	// 0x8F98
+	CASE(GL_RG16_SNORM)	// 0x8F99
+	CASE(GL_RGB16_SNORM)	// 0x8F9A
+	CASE(GL_RGBA16_SNORM)	// 0x8F9B
+	CASE(GL_SIGNED_NORMALIZED)	// 0x8F9C
+	CASE(GL_PRIMITIVE_RESTART)	// 0x8F9D
+	CASE(GL_PRIMITIVE_RESTART_INDEX)	// 0x8F9E
+	//CASE(GL_MAX_PROGRAM_TEXTURE_GATHER_COMPONENTS)	# 0x8F9F
+	//CASE(GL_PERFMON_GLOBAL_MODE_QCOM)	# 0x8FA0
+	//CASE(GL_SHADER_BINARY_VIV)	# 0x8FC4
+	CASE(GL_INT8_NV)	// 0x8FE0
+	CASE(GL_INT8_VEC2_NV)	// 0x8FE1
+	CASE(GL_INT8_VEC3_NV)	// 0x8FE2
+	CASE(GL_INT8_VEC4_NV)	// 0x8FE3
+	CASE(GL_INT16_NV)	// 0x8FE4
+	CASE(GL_INT16_VEC2_NV)	// 0x8FE5
+	CASE(GL_INT16_VEC3_NV)	// 0x8FE6
+	CASE(GL_INT16_VEC4_NV)	// 0x8FE7
+	CASE(GL_INT64_VEC2_NV)	// 0x8FE9
+	CASE(GL_INT64_VEC3_NV)	// 0x8FEA
+	CASE(GL_INT64_VEC4_NV)	// 0x8FEB
+	CASE(GL_UNSIGNED_INT8_NV)	// 0x8FEC
+	CASE(GL_UNSIGNED_INT8_VEC2_NV)	// 0x8FED
+	CASE(GL_UNSIGNED_INT8_VEC3_NV)	// 0x8FEE
+	CASE(GL_UNSIGNED_INT8_VEC4_NV)	// 0x8FEF
+	CASE(GL_UNSIGNED_INT16_NV)	// 0x8FF0
+	CASE(GL_UNSIGNED_INT16_VEC2_NV)	// 0x8FF1
+	CASE(GL_UNSIGNED_INT16_VEC3_NV)	// 0x8FF2
+	CASE(GL_UNSIGNED_INT16_VEC4_NV)	// 0x8FF3
+	CASE(GL_UNSIGNED_INT64_VEC2_NV)	// 0x8FF5
+	CASE(GL_UNSIGNED_INT64_VEC3_NV)	// 0x8FF6
+	CASE(GL_UNSIGNED_INT64_VEC4_NV)	// 0x8FF7
+	CASE(GL_FLOAT16_NV)	// 0x8FF8
+	CASE(GL_FLOAT16_VEC2_NV)	// 0x8FF9
+	CASE(GL_FLOAT16_VEC3_NV)	// 0x8FFA
+	CASE(GL_FLOAT16_VEC4_NV)	// 0x8FFB
+	CASE(GL_DOUBLE_VEC2)	// 0x8FFC
+	CASE(GL_DOUBLE_VEC3)	// 0x8FFD
+	CASE(GL_DOUBLE_VEC4)	// 0x8FFE
+	CASE(GL_SAMPLER_BUFFER_AMD)	// 0x9001
+	CASE(GL_INT_SAMPLER_BUFFER_AMD)	// 0x9002
+	CASE(GL_UNSIGNED_INT_SAMPLER_BUFFER_AMD)	// 0x9003
+	CASE(GL_TESSELLATION_MODE_AMD)	// 0x9004
+	CASE(GL_TESSELLATION_FACTOR_AMD)	// 0x9005
+	CASE(GL_DISCRETE_AMD)	// 0x9006
+	CASE(GL_CONTINUOUS_AMD)	// 0x9007
+	CASE(GL_TEXTURE_CUBE_MAP_ARRAY)	// 0x9009
+	CASE(GL_TEXTURE_BINDING_CUBE_MAP_ARRAY)	// 0x900A
+	CASE(GL_PROXY_TEXTURE_CUBE_MAP_ARRAY)	// 0x900B
+	CASE(GL_SAMPLER_CUBE_MAP_ARRAY)	// 0x900C
+	CASE(GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW)	// 0x900D
+	CASE(GL_INT_SAMPLER_CUBE_MAP_ARRAY)	// 0x900E
+	CASE(GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY)	// 0x900F
+	CASE(GL_ALPHA_SNORM)	// 0x9010
+	CASE(GL_LUMINANCE_SNORM)	// 0x9011
+	CASE(GL_LUMINANCE_ALPHA_SNORM)	// 0x9012
+	CASE(GL_INTENSITY_SNORM)	// 0x9013
+	CASE(GL_ALPHA8_SNORM)	// 0x9014
+	CASE(GL_LUMINANCE8_SNORM)	// 0x9015
+	CASE(GL_LUMINANCE8_ALPHA8_SNORM)	// 0x9016
+	CASE(GL_INTENSITY8_SNORM)	// 0x9017
+	CASE(GL_ALPHA16_SNORM)	// 0x9018
+	CASE(GL_LUMINANCE16_SNORM)	// 0x9019
+	CASE(GL_LUMINANCE16_ALPHA16_SNORM)	// 0x901A
+	CASE(GL_INTENSITY16_SNORM)	// 0x901B
+	CASE(GL_FACTOR_MIN_AMD)	// 0x901C
+	CASE(GL_FACTOR_MAX_AMD)	// 0x901D
+	CASE(GL_DEPTH_CLAMP_NEAR_AMD)	// 0x901E
+	CASE(GL_DEPTH_CLAMP_FAR_AMD)	// 0x901F
+	CASE(GL_VIDEO_BUFFER_NV)	// 0x9020
+	CASE(GL_VIDEO_BUFFER_BINDING_NV)	// 0x9021
+	CASE(GL_FIELD_UPPER_NV)	// 0x9022
+	CASE(GL_FIELD_LOWER_NV)	// 0x9023
+	CASE(GL_NUM_VIDEO_CAPTURE_STREAMS_NV)	// 0x9024
+	CASE(GL_NEXT_VIDEO_CAPTURE_BUFFER_STATUS_NV)	// 0x9025
+	CASE(GL_VIDEO_CAPTURE_TO_422_SUPPORTED_NV)	// 0x9026
+	CASE(GL_LAST_VIDEO_CAPTURE_STATUS_NV)	// 0x9027
+	CASE(GL_VIDEO_BUFFER_PITCH_NV)	// 0x9028
+	CASE(GL_VIDEO_COLOR_CONVERSION_MATRIX_NV)	// 0x9029
+	CASE(GL_VIDEO_COLOR_CONVERSION_MAX_NV)	// 0x902A
+	CASE(GL_VIDEO_COLOR_CONVERSION_MIN_NV)	// 0x902B
+	CASE(GL_VIDEO_COLOR_CONVERSION_OFFSET_NV)	// 0x902C
+	CASE(GL_VIDEO_BUFFER_INTERNAL_FORMAT_NV)	// 0x902D
+	CASE(GL_PARTIAL_SUCCESS_NV)	// 0x902E
+	CASE(GL_SUCCESS_NV)	// 0x902F
+	CASE(GL_FAILURE_NV)	// 0x9030
+	CASE(GL_YCBYCR8_422_NV)	// 0x9031
+	CASE(GL_YCBAYCR8A_4224_NV)	// 0x9032
+	CASE(GL_Z6Y10Z6CB10Z6Y10Z6CR10_422_NV)	// 0x9033
+	CASE(GL_Z6Y10Z6CB10Z6A10Z6Y10Z6CR10Z6A10_4224_NV)	// 0x9034
+	CASE(GL_Z4Y12Z4CB12Z4Y12Z4CR12_422_NV)	// 0x9035
+	CASE(GL_Z4Y12Z4CB12Z4A12Z4Y12Z4CR12Z4A12_4224_NV)	// 0x9036
+	CASE(GL_Z4Y12Z4CB12Z4CR12_444_NV)	// 0x9037
+	CASE(GL_VIDEO_CAPTURE_FRAME_WIDTH_NV)	// 0x9038
+	CASE(GL_VIDEO_CAPTURE_FRAME_HEIGHT_NV)	// 0x9039
+	CASE(GL_VIDEO_CAPTURE_FIELD_UPPER_HEIGHT_NV)	// 0x903A
+	CASE(GL_VIDEO_CAPTURE_FIELD_LOWER_HEIGHT_NV)	// 0x903B
+	CASE(GL_VIDEO_CAPTURE_SURFACE_ORIGIN_NV)	// 0x903C
+	CASE(GL_TEXTURE_COVERAGE_SAMPLES_NV)	// 0x9045
+	CASE(GL_TEXTURE_COLOR_SAMPLES_NV)	// 0x9046
+	CASE(GL_GPU_MEMORY_INFO_DEDICATED_VIDMEM_NVX) // 0x9047
+	CASE(GL_GPU_MEMORY_INFO_TOTAL_AVAILABLE_MEMORY_NVX) // 0x9048
+	CASE(GL_GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX) // 0x9049
+	CASE(GL_GPU_MEMORY_INFO_EVICTION_COUNT_NVX) // 0x904A
+	CASE(GL_GPU_MEMORY_INFO_EVICTED_MEMORY_NVX) // 0x904B
+	CASE(GL_IMAGE_1D)	// 0x904C
+	CASE(GL_IMAGE_2D)	// 0x904D
+	CASE(GL_IMAGE_3D)	// 0x904E
+	CASE(GL_IMAGE_2D_RECT)	// 0x904F
+	CASE(GL_IMAGE_CUBE)	// 0x9050
+	CASE(GL_IMAGE_BUFFER)	// 0x9051
+	CASE(GL_IMAGE_1D_ARRAY)	// 0x9052
+	CASE(GL_IMAGE_2D_ARRAY)	// 0x9053
+	CASE(GL_IMAGE_CUBE_MAP_ARRAY)	// 0x9054
+	CASE(GL_IMAGE_2D_MULTISAMPLE)	// 0x9055
+	CASE(GL_IMAGE_2D_MULTISAMPLE_ARRAY)	// 0x9056
+	CASE(GL_INT_IMAGE_1D)	// 0x9057
+	CASE(GL_INT_IMAGE_2D)	// 0x9058
+	CASE(GL_INT_IMAGE_3D)	// 0x9059
+	CASE(GL_INT_IMAGE_2D_RECT)	// 0x905A
+	CASE(GL_INT_IMAGE_CUBE)	// 0x905B
+	CASE(GL_INT_IMAGE_BUFFER)	// 0x905C
+	CASE(GL_INT_IMAGE_1D_ARRAY)	// 0x905D
+	CASE(GL_INT_IMAGE_2D_ARRAY)	// 0x905E
+	CASE(GL_INT_IMAGE_CUBE_MAP_ARRAY)	// 0x905F
+	CASE(GL_INT_IMAGE_2D_MULTISAMPLE)	// 0x9060
+	CASE(GL_INT_IMAGE_2D_MULTISAMPLE_ARRAY)	// 0x9061
+	CASE(GL_UNSIGNED_INT_IMAGE_1D)	// 0x9062
+	CASE(GL_UNSIGNED_INT_IMAGE_2D)	// 0x9063
+	CASE(GL_UNSIGNED_INT_IMAGE_3D)	// 0x9064
+	CASE(GL_UNSIGNED_INT_IMAGE_2D_RECT)	// 0x9065
+	CASE(GL_UNSIGNED_INT_IMAGE_CUBE)	// 0x9066
+	CASE(GL_UNSIGNED_INT_IMAGE_BUFFER)	// 0x9067
+	CASE(GL_UNSIGNED_INT_IMAGE_1D_ARRAY)	// 0x9068
+	CASE(GL_UNSIGNED_INT_IMAGE_2D_ARRAY)	// 0x9069
+	CASE(GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY)	// 0x906A
+	CASE(GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE)	// 0x906B
+	CASE(GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY)	// 0x906C
+	CASE(GL_MAX_IMAGE_SAMPLES)	// 0x906D
+	CASE(GL_IMAGE_BINDING_FORMAT)	// 0x906E
+	CASE(GL_RGB10_A2UI)	// 0x906F
+	CASE(GL_SCALED_RESOLVE_FASTEST_EXT)	// 0x90BA
+	CASE(GL_SCALED_RESOLVE_NICEST_EXT)	// 0x90BB
+	CASE(GL_MIN_MAP_BUFFER_ALIGNMENT)	// 0x90BC
+	CASE(GL_IMAGE_FORMAT_COMPATIBILITY_TYPE)	// 0x90C7
+	CASE(GL_IMAGE_FORMAT_COMPATIBILITY_BY_SIZE)	// 0x90C8
+	CASE(GL_IMAGE_FORMAT_COMPATIBILITY_BY_CLASS)	// 0x90C9
+	CASE(GL_MAX_VERTEX_IMAGE_UNIFORMS)	// 0x90CA
+	CASE(GL_MAX_TESS_CONTROL_IMAGE_UNIFORMS)	// 0x90CB
+	CASE(GL_MAX_TESS_EVALUATION_IMAGE_UNIFORMS)	// 0x90CC
+	CASE(GL_MAX_GEOMETRY_IMAGE_UNIFORMS)	// 0x90CD
+	CASE(GL_MAX_FRAGMENT_IMAGE_UNIFORMS)	// 0x90CE
+	CASE(GL_MAX_COMBINED_IMAGE_UNIFORMS)	// 0x90CF
+	CASE(GL_SYNC_X11_FENCE_EXT)	// 0x90E1
+	CASE(GL_TEXTURE_2D_MULTISAMPLE)	// 0x9100
+	CASE(GL_PROXY_TEXTURE_2D_MULTISAMPLE)	// 0x9101
+	CASE(GL_TEXTURE_2D_MULTISAMPLE_ARRAY)	// 0x9102
+	CASE(GL_PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY)	// 0x9103
+	CASE(GL_TEXTURE_BINDING_2D_MULTISAMPLE)	// 0x9104
+	CASE(GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY)	// 0x9105
+	CASE(GL_TEXTURE_SAMPLES)	// 0x9106
+	CASE(GL_TEXTURE_FIXED_SAMPLE_LOCATIONS)	// 0x9107
+	CASE(GL_SAMPLER_2D_MULTISAMPLE)	// 0x9108
+	CASE(GL_INT_SAMPLER_2D_MULTISAMPLE)	// 0x9109
+	CASE(GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE)	// 0x910A
+	CASE(GL_SAMPLER_2D_MULTISAMPLE_ARRAY)	// 0x910B
+	CASE(GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY)	// 0x910C
+	CASE(GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY)	// 0x910D
+	CASE(GL_MAX_COLOR_TEXTURE_SAMPLES)	// 0x910E
+	CASE(GL_MAX_DEPTH_TEXTURE_SAMPLES)	// 0x910F
+	CASE(GL_MAX_INTEGER_SAMPLES)	// 0x9110
+	CASE(GL_MAX_SERVER_WAIT_TIMEOUT)	// 0x9111
+	CASE(GL_OBJECT_TYPE)	// 0x9112
+	CASE(GL_SYNC_CONDITION)	// 0x9113
+	CASE(GL_SYNC_STATUS)	// 0x9114
+	CASE(GL_SYNC_FLAGS)	// 0x9115
+	CASE(GL_SYNC_FENCE)	// 0x9116
+	CASE(GL_SYNC_GPU_COMMANDS_COMPLETE)	// 0x9117
+	CASE(GL_UNSIGNALED)	// 0x9118
+	CASE(GL_SIGNALED)	// 0x9119
+	CASE(GL_ALREADY_SIGNALED)	// 0x911A
+	CASE(GL_TIMEOUT_EXPIRED)	// 0x911B
+	CASE(GL_CONDITION_SATISFIED)	// 0x911C
+	CASE(GL_WAIT_FAILED)	// 0x911D
+	CASE(GL_BUFFER_ACCESS_FLAGS)	// 0x911F
+	CASE(GL_BUFFER_MAP_LENGTH)	// 0x9120
+	CASE(GL_BUFFER_MAP_OFFSET)	// 0x9121
+	CASE(GL_MAX_VERTEX_OUTPUT_COMPONENTS)	// 0x9122
+	CASE(GL_MAX_GEOMETRY_INPUT_COMPONENTS)	// 0x9123
+	CASE(GL_MAX_GEOMETRY_OUTPUT_COMPONENTS)	// 0x9124
+	CASE(GL_MAX_FRAGMENT_INPUT_COMPONENTS)	// 0x9125
+	CASE(GL_CONTEXT_PROFILE_MASK)	// 0x9126
+	CASE(GL_UNPACK_COMPRESSED_BLOCK_WIDTH)	// 0x9127
+	CASE(GL_UNPACK_COMPRESSED_BLOCK_HEIGHT)	// 0x9128
+	CASE(GL_UNPACK_COMPRESSED_BLOCK_DEPTH)	// 0x9129
+	CASE(GL_UNPACK_COMPRESSED_BLOCK_SIZE)	// 0x912A
+	CASE(GL_PACK_COMPRESSED_BLOCK_WIDTH)	// 0x912B
+	CASE(GL_PACK_COMPRESSED_BLOCK_HEIGHT)	// 0x912C
+	CASE(GL_PACK_COMPRESSED_BLOCK_DEPTH)	// 0x912D
+	CASE(GL_PACK_COMPRESSED_BLOCK_SIZE)	// 0x912E
+	CASE(GL_TEXTURE_IMMUTABLE_FORMAT)	// 0x912F
+	//CASE(GL_SGX_PROGRAM_BINARY_IMG)	# 0x9130
+	//CASE(GL_RENDERBUFFER_SAMPLES_IMG)	# 0x9133
+	//CASE(GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_IMG)	# 0x9134
+	//CASE(GL_MAX_SAMPLES_IMG)	# 0x9135
+	//CASE(GL_TEXTURE_SAMPLES_IMG)	# 0x9136
+	CASE(GL_MAX_DEBUG_MESSAGE_LENGTH_ARB)	// 0x9143
+	CASE(GL_MAX_DEBUG_LOGGED_MESSAGES_ARB)	// 0x9144
+	CASE(GL_DEBUG_LOGGED_MESSAGES_ARB)	// 0x9145
+	CASE(GL_DEBUG_SEVERITY_HIGH_ARB)	// 0x9146
+	CASE(GL_DEBUG_SEVERITY_MEDIUM_ARB)	// 0x9147
+	CASE(GL_DEBUG_SEVERITY_LOW_ARB)	// 0x9148
+	CASE(GL_DEBUG_CATEGORY_API_ERROR_AMD)	// 0x9149
+	CASE(GL_DEBUG_CATEGORY_WINDOW_SYSTEM_AMD)	// 0x914A
+	CASE(GL_DEBUG_CATEGORY_DEPRECATION_AMD)	// 0x914B
+	CASE(GL_DEBUG_CATEGORY_UNDEFINED_BEHAVIOR_AMD)	// 0x914C
+	CASE(GL_DEBUG_CATEGORY_PERFORMANCE_AMD)	// 0x914D
+	CASE(GL_DEBUG_CATEGORY_SHADER_COMPILER_AMD)	// 0x914E
+	CASE(GL_DEBUG_CATEGORY_APPLICATION_AMD)	// 0x914F
+	CASE(GL_DEBUG_CATEGORY_OTHER_AMD)	// 0x9150
+	CASE(GL_DATA_BUFFER_AMD)	// 0x9151
+	CASE(GL_PERFORMANCE_MONITOR_AMD)	// 0x9152
+	CASE(GL_QUERY_OBJECT_AMD)	// 0x9153
+	CASE(GL_VERTEX_ARRAY_OBJECT_AMD)	// 0x9154
+	CASE(GL_SAMPLER_OBJECT_AMD)	// 0x9155
+	//CASE(GL_SHADER_BINARY_DMP)	# 0x9250
+	CASE(GL_ATOMIC_COUNTER_BUFFER)	// 0x92C0
+	CASE(GL_ATOMIC_COUNTER_BUFFER_BINDING)	// 0x92C1
+	CASE(GL_ATOMIC_COUNTER_BUFFER_START)	// 0x92C2
+	CASE(GL_ATOMIC_COUNTER_BUFFER_SIZE)	// 0x92C3
+	CASE(GL_ATOMIC_COUNTER_BUFFER_DATA_SIZE)	// 0x92C4
+	CASE(GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS)	// 0x92C5
+	CASE(GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES)	// 0x92C6
+	CASE(GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER)	// 0x92C7
+	CASE(GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER)	// 0x92C8
+	CASE(GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER)	// 0x92C9
+	CASE(GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER)	// 0x92CA
+	CASE(GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER)	// 0x92CB
+	CASE(GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS)	// 0x92CC
+	CASE(GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS)	// 0x92CD
+	CASE(GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS)	// 0x92CE
+	CASE(GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS)	// 0x92CF
+	CASE(GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS)	// 0x92D0
+	CASE(GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS)	// 0x92D1
+	CASE(GL_MAX_VERTEX_ATOMIC_COUNTERS)	// 0x92D2
+	CASE(GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS)	// 0x92D3
+	CASE(GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS)	// 0x92D4
+	CASE(GL_MAX_GEOMETRY_ATOMIC_COUNTERS)	// 0x92D5
+	CASE(GL_MAX_FRAGMENT_ATOMIC_COUNTERS)	// 0x92D6
+	CASE(GL_MAX_COMBINED_ATOMIC_COUNTERS)	// 0x92D7
+	CASE(GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE)	// 0x92D8
+	CASE(GL_ACTIVE_ATOMIC_COUNTER_BUFFERS)	// 0x92D9
+	CASE(GL_UNIFORM_ATOMIC_COUNTER_BUFFER_INDEX)	// 0x92DA
+	CASE(GL_UNSIGNED_INT_ATOMIC_COUNTER)	// 0x92DB
+	CASE(GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS)	// 0x92DC
+	CASE(GL_NUM_SAMPLE_COUNTS)	// 0x9380
+	CASE(GL_INVALID_INDEX)	// 0xFFFFFFFFu
+
+	default:
+		return "(unrecognized enum)";
+	}
+
+#undef CASE
+}
+
diff --git a/tests/util/piglit-util.h b/tests/util/piglit-util.h
index 1c8c740..8e554ce 100755
--- a/tests/util/piglit-util.h
+++ b/tests/util/piglit-util.h
@@ -162,12 +162,19 @@ bool piglit_is_extension_supported(const char *name);
  * For example, given GL_INVALID_ENUM, return "GL_INVALID_ENUM".
  *
  * Return "(unrecognized error)" if the enum is not recognized.
- *
- * \todo Create a more general function that stringifies any GLenum.
  */
 const char* piglit_get_gl_error_name(GLenum error);
 
 /**
+ * \brief Convert a GL enum to a string.
+ *
+ * For example, given GL_INVALID_ENUM, return "GL_INVALID_ENUM".
+ *
+ * Return "(unrecognized enum)" if the enum is not recognized.
+ */
+const char *piglit_get_gl_enum_name(GLenum param);
+
+/**
  * \brief Check for unexpected GL errors.
  *
  * If glGetError() returns an error other than \c expected_error, then


More information about the Piglit mailing list