diff options
author | marha <marha@users.sourceforge.net> | 2010-11-29 22:05:53 +0000 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2010-11-29 22:05:53 +0000 |
commit | fed109d6a33c0871291d1bb2f3f6b7a3d1a3e9d7 (patch) | |
tree | fa1ba494685a71e28a096990a8707680c7cb378b /mesalib/src/mapi/glapi/gen | |
parent | ae340911c1ba1f98b418bd8f1a487fa4d79491b0 (diff) | |
parent | 6fda93be42ace9eeab0e82ceebb6798961c9105c (diff) | |
download | vcxsrv-fed109d6a33c0871291d1bb2f3f6b7a3d1a3e9d7.tar.gz vcxsrv-fed109d6a33c0871291d1bb2f3f6b7a3d1a3e9d7.tar.bz2 vcxsrv-fed109d6a33c0871291d1bb2f3f6b7a3d1a3e9d7.zip |
svn merge ^/branches/released .
Diffstat (limited to 'mesalib/src/mapi/glapi/gen')
-rw-r--r-- | mesalib/src/mapi/glapi/gen/ARB_draw_instanced.xml | 69 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/ARB_geometry_shader4.xml | 57 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/ARB_seamless_cube_map.xml | 2 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/EXT_transform_feedback.xml | 163 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/GL3.xml | 581 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/Makefile | 208 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/glX_proto_recv.py | 4 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/glX_proto_send.py | 28 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/glX_proto_size.py | 2 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/gl_API.xml | 14 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/gl_enums.py | 29 | ||||
-rw-r--r-- | mesalib/src/mapi/glapi/gen/remap_helper.py | 12 |
12 files changed, 1125 insertions, 44 deletions
diff --git a/mesalib/src/mapi/glapi/gen/ARB_draw_instanced.xml b/mesalib/src/mapi/glapi/gen/ARB_draw_instanced.xml new file mode 100644 index 000000000..5741a588c --- /dev/null +++ b/mesalib/src/mapi/glapi/gen/ARB_draw_instanced.xml @@ -0,0 +1,69 @@ +<?xml version="1.0"?> +<!DOCTYPE OpenGLAPI SYSTEM "gl_API.dtd"> + +<!-- Note: no GLX protocol info yet. --> + + +<OpenGLAPI> + +<category name="3.1"> + + <function name="DrawArraysInstanced" offset="assign"> + <param name="mode" type="GLenum"/> + <param name="first" type="GLint"/> + <param name="count" type="GLsizei"/> + <param name="primcount" type="GLsizei"/> + </function> + + <function name="DrawElementsInstanced" offset="assign"> + <param name="mode" type="GLenum"/> + <param name="count" type="GLsizei"/> + <param name="type" type="GLenum"/> + <param name="indices" type="const GLvoid *"/> + <param name="primcount" type="GLsizei"/> + </function> + +</category> + + +<category name="GL_ARB_draw_instanced" number="44"> + + <function name="DrawArraysInstancedARB" alias="DrawArraysInstanced"> + <param name="mode" type="GLenum"/> + <param name="first" type="GLint"/> + <param name="count" type="GLsizei"/> + <param name="primcount" type="GLsizei"/> + </function> + + <function name="DrawElementsInstancedARB" alias="DrawElementsInstanced"> + <param name="mode" type="GLenum"/> + <param name="count" type="GLsizei"/> + <param name="type" type="GLenum"/> + <param name="indices" type="const GLvoid *"/> + <param name="primcount" type="GLsizei"/> + </function> + +</category> + + +<category name="GL_EXT_draw_instanced" number="327"> + + <function name="DrawArraysInstancedEXT" alias="DrawArraysInstanced"> + <param name="mode" type="GLenum"/> + <param name="first" type="GLint"/> + <param name="count" type="GLsizei"/> + <param name="primcount" type="GLsizei"/> + </function> + + <function name="DrawElementsInstancedEXT" alias="DrawElementsInstanced"> + <param name="mode" type="GLenum"/> + <param name="count" type="GLsizei"/> + <param name="type" type="GLenum"/> + <param name="indices" type="const GLvoid *"/> + <param name="primcount" type="GLsizei"/> + </function> + +</category> + + +</OpenGLAPI> diff --git a/mesalib/src/mapi/glapi/gen/ARB_geometry_shader4.xml b/mesalib/src/mapi/glapi/gen/ARB_geometry_shader4.xml new file mode 100644 index 000000000..ca9a101a0 --- /dev/null +++ b/mesalib/src/mapi/glapi/gen/ARB_geometry_shader4.xml @@ -0,0 +1,57 @@ +<?xml version="1.0"?> +<!DOCTYPE OpenGLAPI SYSTEM "gl_API.dtd"> + +<!-- Note: no GLX protocol info yet. --> + +<OpenGLAPI> + + +<category name="GL_ARB_geometry_shader4" number="47"> + <enum name="GEOMETRY_SHADER_ARB" value="0x8DD9"/> + <enum name="GEOMETRY_VERTICES_OUT_ARB" value="0x8DDA"/> + <enum name="GEOMETRY_INPUT_TYPE_ARB" value="0x8DDB"/> + <enum name="GEOMETRY_OUTPUT_TYPE_ARB" value="0x8DDC"/> + <enum name="MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_ARB" value="0x8C29"/> + <enum name="MAX_GEOMETRY_VARYING_COMPONENTS_ARB" value="0x8DDD"/> + <enum name="MAX_VERTEX_VARYING_COMPONENTS_ARB" value="0x8DDE"/> + <enum name="MAX_VARYING_COMPONENTS" value="0x8B4B"/> + <enum name="MAX_GEOMETRY_UNIFORM_COMPONENTS_ARB" value="0x8DDF"/> + <enum name="MAX_GEOMETRY_OUTPUT_VERTICES_ARB" value="0x8DE0"/> + <enum name="MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_ARB" value="0x8DE1"/> + <enum name="LINES_ADJACENCY_ARB" value="0xA"/> + <enum name="LINE_STRIP_ADJACENCY_ARB" value="0xB"/> + <enum name="TRIANGLES_ADJACENCY_ARB" value="0xC"/> + <enum name="TRIANGLE_STRIP_ADJACENCY_ARB" value="0xD"/> + <enum name="FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_ARB" value="0x8DA8"/> + <enum name="FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_ARB" value="0x8DA9"/> + <enum name="FRAMEBUFFER_ATTACHMENT_LAYERED_ARB" value="0x8DA7"/> + <enum name="FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER" value="0x8CD4"/> + <enum name="PROGRAM_POINT_SIZE_ARB" value="0x8642"/> + <function name="ProgramParameteriARB" offset="assign"> + <param name="program" type="GLuint"/> + <param name="pname" type="GLenum"/> + <param name="value" type="GLint"/> + </function> + <function name="FramebufferTextureARB" offset="assign"> + <param name="target" type="GLenum"/> + <param name="attachment" type="GLenum"/> + <param name="texture" type="GLuint"/> + <param name="level" type="GLint"/> + </function> + <function name="FramebufferTextureLayerARB" alias="FramebufferTextureLayer"> + <param name="target" type="GLenum"/> + <param name="attachment" type="GLenum"/> + <param name="texture" type="GLuint"/> + <param name="level" type="GLint"/> + <param name="layer" type="GLint"/> + </function> + <function name="FramebufferTextureFaceARB" offset="assign"> + <param name="target" type="GLenum"/> + <param name="attachment" type="GLenum"/> + <param name="texture" type="GLuint"/> + <param name="level" type="GLint"/> + <param name="face" type="GLenum"/> + </function> +</category> + +</OpenGLAPI> diff --git a/mesalib/src/mapi/glapi/gen/ARB_seamless_cube_map.xml b/mesalib/src/mapi/glapi/gen/ARB_seamless_cube_map.xml index 3cdc84d2b..8dc827c5a 100644 --- a/mesalib/src/mapi/glapi/gen/ARB_seamless_cube_map.xml +++ b/mesalib/src/mapi/glapi/gen/ARB_seamless_cube_map.xml @@ -3,7 +3,7 @@ <OpenGLAPI> -<category name="GL_ARB_seamless_cubemap" number="65"> +<category name="GL_ARB_seamless_cube_map" number="65"> <enum name="TEXTURE_CUBE_MAP_SEAMLESS" count="1" value="0x88F4"> <size name="Get" mode="get"/> </enum> diff --git a/mesalib/src/mapi/glapi/gen/EXT_transform_feedback.xml b/mesalib/src/mapi/glapi/gen/EXT_transform_feedback.xml new file mode 100644 index 000000000..06deafce4 --- /dev/null +++ b/mesalib/src/mapi/glapi/gen/EXT_transform_feedback.xml @@ -0,0 +1,163 @@ +<?xml version="1.0"?> +<!DOCTYPE OpenGLAPI SYSTEM "gl_API.dtd"> + +<!-- Note: no GLX protocol info yet. --> + + +<OpenGLAPI> + +<category name="GL_EXT_transform_feedback" number="352"> + + <enum name="TRANSFORM_FEEDBACK_BUFFER_EXT" value="0x8C8E"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER_START_EXT" value="0x8C84"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER_SIZE_EXT" value="0x8C85"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER_BINDING_EXT" value="0x8C8F"/> + <enum name="INTERLEAVED_ATTRIBS_EXT" value="0x8C8C"/> + <enum name="SEPARATE_ATTRIBS_EXT" value="0x8C8D"/> + <enum name="PRIMITIVES_GENERATED_EXT" value="0x8C87"/> + <enum name="TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_EXT" value="0x8C88"/> + <enum name="RASTERIZER_DISCARD_EXT" value="0x8C89"/> + <enum name="MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_EXT" value="0x8C8A"/> + <enum name="MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_EXT" value="0x8C8B"/> + <enum name="MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_EXT" value="0x8C80"/> + <enum name="TRANSFORM_FEEDBACK_VARYINGS_EXT" value="0x8C83"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER_MODE_EXT" value="0x8C7F"/> + <enum name="TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH_EXT" value="0x8C76"/> + + <function name="BindBufferRangeEXT" offset="assign"> + <param name="target" type="GLenum"/> + <param name="index" type="GLuint"/> + <param name="buffer" type="GLuint"/> + <param name="offset" type="GLintptr"/> + <param name="size" type="GLsizeiptr"/> + </function> + + <function name="BindBufferOffsetEXT" offset="assign"> + <param name="target" type="GLenum"/> + <param name="index" type="GLuint"/> + <param name="buffer" type="GLuint"/> + <param name="offset" type="GLintptr"/> + </function> + + <function name="BindBufferBaseEXT" offset="assign"> + <param name="target" type="GLenum"/> + <param name="index" type="GLuint"/> + <param name="buffer" type="GLuint"/> + </function> + + <function name="BeginTransformFeedbackEXT" offset="assign"> + <param name="mode" type="GLenum"/> + </function> + + <function name="EndTransformFeedbackEXT" offset="assign"> + </function> + + <function name="TransformFeedbackVaryingsEXT" offset="assign"> + <param name="program" type="GLuint"/> + <param name="count" type="GLsizei"/> + <param name="varyings" type="const char **"/> + <param name="bufferMode" type="GLenum"/> + </function> + + <function name="GetTransformFeedbackVaryingEXT" offset="assign"> + <param name="program" type="GLuint"/> + <param name="index" type="GLuint"/> + <param name="bufSize" type="GLsizei"/> + <param name="length" type="GLsizei *"/> + <param name="size" type="GLsizei *"/> + <param name="type" type="GLenum *"/> + <param name="name" type="GLchar *"/> + </function> + + <!-- Note: the glGetIntegerIndexedvEXT() and glGetBooleanIndexedvEXT + functions are defined in the EXT_draw_buffers2.xml file --> + +</category> + + +<!-- Note: these 3.0 entrypoints might get moved to a new file --> + +<category name="3.0"> + + <function name="BindBufferRange" alias="BindBufferRangeEXT"> + <param name="target" type="GLenum"/> + <param name="index" type="GLuint"/> + <param name="buffer" type="GLuint"/> + <param name="offset" type="GLintptr"/> + <param name="size" type="GLsizeiptr"/> + </function> + + <function name="BindBufferBase" alias="BindBufferBaseEXT"> + <param name="target" type="GLenum"/> + <param name="index" type="GLuint"/> + <param name="buffer" type="GLuint"/> + </function> + + <function name="BeginTransformFeedback" alias="BeginTransformFeedbackEXT"> + <param name="mode" type="GLenum"/> + </function> + + <function name="EndTransformFeedback" alias="EndTransformFeedbackEXT"> + </function> + + <function name="TransformFeedbackVaryings" alias="TransformFeedbackVaryingsEXT"> + <param name="program" type="GLuint"/> + <param name="count" type="GLsizei"/> + <param name="varyings" type="const char **"/> + <param name="bufferMode" type="GLenum"/> + </function> + + <function name="GetTransformFeedbackVarying" alias="GetTransformFeedbackVaryingEXT"> + <param name="program" type="GLuint"/> + <param name="index" type="GLuint"/> + <param name="bufSize" type="GLsizei"/> + <param name="length" type="GLsizei *"/> + <param name="size" type="GLsizei *"/> + <param name="type" type="GLenum *"/> + <param name="name" type="GLchar *"/> + </function> + +</category> + + +<category name="GL_ARB_transform_feedback2" number="93"> + + <enum name="TRANSFORM_FEEDBACK" value="0x8E22"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER_PAUSED" value="0x8E23"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER_ACTIVE" value="0x8E24"/> + <enum name="TRANSFORM_FEEDBACK_BINDING" value="0x8E25"/> + + <function name="BindTransformFeedback" offset="assign"> + <param name="target" type="GLenum"/> + <param name="id" type="GLuint"/> + </function> + + <function name="DeleteTransformFeedbacks" offset="assign"> + <param name="n" type="GLsizei"/> + <param name="ids" type="const GLuint *"/> + </function> + + <function name="GenTransformFeedbacks" offset="assign"> + <param name="n" type="GLsizei"/> + <param name="ids" type="GLuint *"/> + </function> + + <function name="IsTransformFeedback" offset="assign"> + <param name="id" type="GLuint"/> + <return type="GLboolean"/> + </function> + + <function name="PauseTransformFeedback" offset="assign"> + </function> + + <function name="ResumeTransformFeedback" offset="assign"> + </function> + + <function name="DrawTransformFeedback" offset="assign"> + <param name="mode" type="GLenum"/> + <param name="id" type="GLuint"/> + </function> + +</category> + +</OpenGLAPI> diff --git a/mesalib/src/mapi/glapi/gen/GL3.xml b/mesalib/src/mapi/glapi/gen/GL3.xml new file mode 100644 index 000000000..0d8d935f0 --- /dev/null +++ b/mesalib/src/mapi/glapi/gen/GL3.xml @@ -0,0 +1,581 @@ +<?xml version="1.0"?> +<!DOCTYPE OpenGLAPI SYSTEM "gl_API.dtd"> + +<!-- Note: no GLX protocol info yet. --> + + +<OpenGLAPI> + +<category name="3.0"> + + <enum name="COMPARE_REF_TO_TEXTURE" value="0x884E"/> + <enum name="CLIP_DISTANCE0" value="0x3000"/> + <enum name="CLIP_DISTANCE1" value="0x3001"/> + <enum name="CLIP_DISTANCE2" value="0x3002"/> + <enum name="CLIP_DISTANCE3" value="0x3003"/> + <enum name="CLIP_DISTANCE4" value="0x3004"/> + <enum name="CLIP_DISTANCE5" value="0x3005"/> + <enum name="CLIP_DISTANCE6" value="0x3006"/> + <enum name="CLIP_DISTANCE7" value="0x3007"/> + <enum name="MAX_CLIP_DISTANCES" value="0x0D32"/> + <enum name="MAJOR_VERSION" value="0x821B"/> + <enum name="MINOR_VERSION" value="0x821C"/> + <enum name="NUM_EXTENSIONS" value="0x821D"/> + <enum name="CONTEXT_FLAGS" value="0x821E"/> + <enum name="DEPTH_BUFFER" value="0x8223"/> + <enum name="STENCIL_BUFFER" value="0x8224"/> + <enum name="COMPRESSED_RED" value="0x8225"/> + <enum name="COMPRESSED_RG" value="0x8226"/> + <enum name="CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT" value="0x0001"/> + <enum name="RGBA32F" value="0x8814"/> + <enum name="RGB32F" value="0x8815"/> + <enum name="RGBA16F" value="0x881A"/> + <enum name="RGB16F" value="0x881B"/> + <enum name="VERTEX_ATTRIB_ARRAY_INTEGER" value="0x88FD"/> + <enum name="MAX_ARRAY_TEXTURE_LAYERS" value="0x88FF"/> + <enum name="MIN_PROGRAM_TEXEL_OFFSET" value="0x8904"/> + <enum name="MAX_PROGRAM_TEXEL_OFFSET" value="0x8905"/> + <enum name="CLAMP_READ_COLOR" value="0x891C"/> + <enum name="FIXED_ONLY" value="0x891D"/> + <enum name="MAX_VARYING_COMPONENTS" value="0x8B4B"/> + <enum name="TEXTURE_1D_ARRAY" value="0x8C18"/> + <enum name="PROXY_TEXTURE_1D_ARRAY" value="0x8C19"/> + <enum name="TEXTURE_2D_ARRAY" value="0x8C1A"/> + <enum name="PROXY_TEXTURE_2D_ARRAY" value="0x8C1B"/> + <enum name="TEXTURE_BINDING_1D_ARRAY" value="0x8C1C"/> + <enum name="TEXTURE_BINDING_2D_ARRAY" value="0x8C1D"/> + <enum name="R11F_G11F_B10F" value="0x8C3A"/> + <enum name="UNSIGNED_INT_10F_11F_11F_REV" value="0x8C3B"/> + <enum name="RGB9_E5" value="0x8C3D"/> + <enum name="UNSIGNED_INT_5_9_9_9_REV" value="0x8C3E"/> + <enum name="TEXTURE_SHARED_SIZE" value="0x8C3F"/> + <enum name="TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH" value="0x8C76"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER_MODE" value="0x8C7F"/> + <enum name="MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS" value="0x8C80"/> + <enum name="TRANSFORM_FEEDBACK_VARYINGS" value="0x8C83"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER_START" value="0x8C84"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER_SIZE" value="0x8C85"/> + <enum name="PRIMITIVES_GENERATED" value="0x8C87"/> + <enum name="TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN" value="0x8C88"/> + <enum name="RASTERIZER_DISCARD" value="0x8C89"/> + <enum name="MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS" value="0x8C8A"/> + <enum name="MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS" value="0x8C8B"/> + <enum name="INTERLEAVED_ATTRIBS" value="0x8C8C"/> + <enum name="SEPARATE_ATTRIBS" value="0x8C8D"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER" value="0x8C8E"/> + <enum name="TRANSFORM_FEEDBACK_BUFFER_BINDING" value="0x8C8F"/> + <enum name="RGBA32UI" value="0x8D70"/> + <enum name="RGB32UI" value="0x8D71"/> + <enum name="RGBA16UI" value="0x8D76"/> + <enum name="RGB16UI" value="0x8D77"/> + <enum name="RGBA8UI" value="0x8D7C"/> + <enum name="RGB8UI" value="0x8D7D"/> + <enum name="RGBA32I" value="0x8D82"/> + <enum name="RGB32I" value="0x8D83"/> + <enum name="RGBA16I" value="0x8D88"/> + <enum name="RGB16I" value="0x8D89"/> + <enum name="RGBA8I" value="0x8D8E"/> + <enum name="RGB8I" value="0x8D8F"/> + <enum name="RED_INTEGER" value="0x8D94"/> + <enum name="GREEN_INTEGER" value="0x8D95"/> + <enum name="BLUE_INTEGER" value="0x8D96"/> + <enum name="RGB_INTEGER" value="0x8D98"/> + <enum name="RGBA_INTEGER" value="0x8D99"/> + <enum name="BGR_INTEGER" value="0x8D9A"/> + <enum name="BGRA_INTEGER" value="0x8D9B"/> + <enum name="SAMPLER_1D_ARRAY" value="0x8DC0"/> + <enum name="SAMPLER_2D_ARRAY" value="0x8DC1"/> + <enum name="SAMPLER_1D_ARRAY_SHADOW" value="0x8DC3"/> + <enum name="SAMPLER_2D_ARRAY_SHADOW" value="0x8DC4"/> + <enum name="SAMPLER_CUBE_SHADOW" value="0x8DC5"/> + <enum name="UNSIGNED_INT_VEC2" value="0x8DC6"/> + <enum name="UNSIGNED_INT_VEC3" value="0x8DC7"/> + <enum name="UNSIGNED_INT_VEC4" value="0x8DC8"/> + <enum name="INT_SAMPLER_1D" value="0x8DC9"/> + <enum name="INT_SAMPLER_2D" value="0x8DCA"/> + <enum name="INT_SAMPLER_3D" value="0x8DCB"/> + <enum name="INT_SAMPLER_CUBE" value="0x8DCC"/> + <enum name="INT_SAMPLER_1D_ARRAY" value="0x8DCE"/> + <enum name="INT_SAMPLER_2D_ARRAY" value="0x8DCF"/> + <enum name="UNSIGNED_INT_SAMPLER_1D" value="0x8DD1"/> + <enum name="UNSIGNED_INT_SAMPLER_2D" value="0x8DD2"/> + <enum name="UNSIGNED_INT_SAMPLER_3D" value="0x8DD3"/> + <enum name="UNSIGNED_INT_SAMPLER_CUBE" value="0x8DD4"/> + <enum name="UNSIGNED_INT_SAMPLER_1D_ARRAY" value="0x8DD6"/> + <enum name="UNSIGNED_INT_SAMPLER_2D_ARRAY" value="0x8DD7"/> + <enum name="QUERY_WAIT" value="0x8E13"/> + <enum name="QUERY_NO_WAIT" value="0x8E14"/> + <enum name="QUERY_BY_REGION_WAIT" value="0x8E15"/> + <enum name="QUERY_BY_REGION_NO_WAIT" value="0x8E16"/> + <enum name="BUFFER_ACCESS_FLAGS" value="0x911F"/> + <enum name="BUFFER_MAP_LENGTH" value="0x9120"/> + <enum name="BUFFER_MAP_OFFSET" value="0x9121"/> + + <function name="ClearBufferiv" offset="assign"> + <param name="buffer" type="GLenum"/> + <param name="drawbuffer" type="GLint"/> + <param name="value" type="const GLint *"/> + </function> + + <function name="ClearBufferuiv" offset="assign"> + <param name="buffer" type="GLenum"/> + <param name="drawbuffer" type="GLint"/> + <param name="value" type="const GLuint *"/> + </function> + + <function name="ClearBufferfv" offset="assign"> + <param name="buffer" type="GLenum"/> + <param name="drawbuffer" type="GLint"/> + <param name="value" type="const GLfloat *"/> + </function> + + <function name="ClearBufferfi" offset="assign"> + <param name="buffer" type="GLenum"/> + <param name="drawbuffer" type="GLint"/> + <param name="depth" type="const GLfloat"/> + <param name="stencil" type="const GLint"/> + </function> + + <function name="GetStringi" offset="assign"> + <param name="name" type="GLenum"/> + <param name="index" type="GLuint"/> + <return type="const GLubyte *"/> + </function> + + <function name="IsEnabledi" offset="assign"> + <param name="cap" type="GLenum"/> + <param name="index" type="GLuint"/> + <return type="GLboolean"/> + </function> + + <function name="GetFragDataLocation" offset="assign"> + <param name="program" type="GLuint"/> + <param name="name" type="const GLchar *"/> + <return type="GLint"/> + </function> + + <function name="BindFragDataLocation" offset="assign"> + <param name="program" type="GLuint"/> + <param name="color" type="GLuint"/> + <param name="name" type="const GLchar *"/> + </function> + + <function name="ColorMaski" offset="assign"> + <param name="index" type="GLuint"/> + <param name="r" type="GLboolean"/> + <param name="g" type="GLboolean"/> + <param name="b" type="GLboolean"/> + <param name="a" type="GLboolean"/> + </function> + + <function name="GetBooleani_v" offset="assign"> + <param name="cap" type="GLenum"/> + <param name="index" type="GLuint"/> + <param name="value" type="GLboolean *"/> + </function> + + <function name="GetIntegeri_v" offset="assign"> + <param name="cap" type="GLenum"/> + <param name="index" type="GLuint"/> + <param name="value" type="GLint *"/> + </function> + + <function name="Enablei" offset="assign"> + <param name="cap" type="GLenum"/> + <param name="index" type="GLuint"/> + </function> + + <function name="Disablei" offset="assign"> + <param name="cap" type="GLenum"/> + <param name="index" type="GLuint"/> + </function> + + <function name="BeginTransformFeedback" offset="assign"> + <param name="mode" type="GLenum"/> + </function> + + <function name="EndTransformFeedback" offset="assign"> + </function> + + <function name="BindBufferRange" offset="assign"> + <param name="target" type="GLenum"/> + <param name="index" type="GLuint"/> + <param name="buffer" type="GLuint"/> + <param name="offset" type="GLintptr"/> + <param name="size" type="GLsizeiptr"/> + </function> + + <function name="BindBufferBase" offset="assign"> + <param name="target" type="GLenum"/> + <param name="index" type="GLuint"/> + <param name="buffer" type="GLuint"/> + </function> + + <function name="TransformFeedbackVaryings" offset="assign"> + <param name="program" type="GLuint"/> + <param name="count" type="GLsizei"/> + <param name="varyings" type="const GLchar* *"/> + <param name="bufferMode" type="GLenum"/> + </function> + + <function name="GetTransformFeedbackVarying" offset="assign"> + <param name="program" type="GLuint"/> + <param name="index" type="GLuint"/> + <param name="bufSize" type="GLsizei"/> + <param name="length" type="GLsizei *"/> + <param name="size" type="GLsizei *"/> + <param name="type" type="GLenum *"/> + <param name="name" type="GLchar *"/> + </function> + + <function name="ClampColor" offset="assign"> + <param name="target" type="GLenum"/> + <param name="clamp" type="GLenum"/> + </function> + + <function name="BeginConditionalRender" offset="assign"> + <param name="id" type="GLuint"/> + <param name="mode" type="GLenum"/> + </function> + + <function name="EndConditionalRender" offset="assign"> + </function> + + <function name="VertexAttribIPointer" offset="assign"> + <param name="index" type="GLuint"/> + <param name="size" type="GLint"/> + <param name="type" type="GLenum"/> + <param name="stride" type="GLsizei"/> + <param name="pointer" type="const GLvoid *"/> + </function> + + <function name="GetVertexAttribIiv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="pname" type="GLenum"/> + <param name="params" type="GLint *"/> + </function> + + <function name="GetVertexAttribIuiv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="pname" type="GLenum"/> + <param name="params" type="GLuint *"/> + </function> + + <function name="VertexAttribI1i" offset="assign"> + <param name="index" type="GLuint"/> + <param name="x" type="GLint"/> + </function> + + <function name="VertexAttribI2i" offset="assign"> + <param name="index" type="GLuint"/> + <param name="x" type="GLint"/> + <param name="y" type="GLint"/> + </function> + + <function name="VertexAttribI3i" offset="assign"> + <param name="index" type="GLuint"/> + <param name="x" type="GLint"/> + <param name="y" type="GLint"/> + <param name="z" type="GLint"/> + </function> + + <function name="VertexAttribI4i" offset="assign"> + <param name="index" type="GLuint"/> + <param name="x" type="GLint"/> + <param name="y" type="GLint"/> + <param name="z" type="GLint"/> + <param name="w" type="GLint"/> + </function> + + <function name="VertexAttribI1ui" offset="assign"> + <param name="index" type="GLuint"/> + <param name="x" type="GLuint"/> + </function> + + <function name="VertexAttribI2ui" offset="assign"> + <param name="index" type="GLuint"/> + <param name="x" type="GLuint"/> + <param name="y" type="GLuint"/> + </function> + + <function name="VertexAttribI3ui" offset="assign"> + <param name="index" type="GLuint"/> + <param name="x" type="GLuint"/> + <param name="y" type="GLuint"/> + <param name="z" type="GLuint"/> + </function> + + <function name="VertexAttribI4ui" offset="assign"> + <param name="index" type="GLuint"/> + <param name="x" type="GLuint"/> + <param name="y" type="GLuint"/> + <param name="z" type="GLuint"/> + <param name="w" type="GLuint"/> + </function> + + <function name="VertexAttribI1iv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLint *"/> + </function> + + <function name="VertexAttribI2iv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLint *"/> + </function> + + <function name="VertexAttribI3iv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLint *"/> + </function> + + <function name="VertexAttribI4iv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLint *"/> + </function> + + <function name="VertexAttribI1uiv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLuint *"/> + </function> + + <function name="VertexAttribI2uiv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLuint *"/> + </function> + + <function name="VertexAttribI3uiv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLuint *"/> + </function> + + <function name="VertexAttribI4uiv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLuint *"/> + </function> + + <function name="VertexAttribI4bv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLbyte *"/> + </function> + + <function name="VertexAttribI4sv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLshort *"/> + </function> + + <function name="VertexAttribI4ubv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLubyte *"/> + </function> + + <function name="VertexAttribI4usv" offset="assign"> + <param name="index" type="GLuint"/> + <param name="v" type="const GLushort *"/> + </function> + + <function name="GetUniformuiv" offset="assign"> + <param name="program" type="GLuint"/> + <param name="location" type="GLint"/> + <param name="params" type="GLuint *"/> + </function> + + <function name="Uniform1ui" offset="assign"> + <param name="locatoin" type="GLint"/> + <param name="x" type="GLuint"/> + </function> + + <function name="Uniform2ui" offset="assign"> + <param name="location" type="GLint"/> + <param name="x" type="GLuint"/> + <param name="y" type="GLuint"/> + </function> + + <function name="Uniform3ui" offset="assign"> + <param name="location" type="GLint"/> + <param name="x" type="GLuint"/> + <param name="y" type="GLuint"/> + <param name="z" type="GLuint"/> + </function> + + <function name="Uniform4ui" offset="assign"> + <param name="location" type="GLint"/> + <param name="x" type="GLuint"/> + <param name="y" type="GLuint"/> + <param name="z" type="GLuint"/> + <param name="w" type="GLuint"/> + </function> + + <function name="Uniform1uiv" offset="assign"> + <param name="location" type="GLint"/> + <param name="count" type="GLsizei"/> + <param name="value" type="const GLuint *"/> + </function> + + <function name="Uniform2uiv" offset="assign"> + <param name="location" type="GLint"/> + <param name="count" type="GLsizei"/> + <param name="value" type="const GLuint *"/> + </function> + + <function name="Uniform3uiv" offset="assign"> + <param name="location" type="GLint"/> + <param name="count" type="GLsizei"/> + <param name="value" type="const GLuint *"/> + </function> + + <function name="Uniform4uiv" offset="assign"> + <param name="location" type="GLint"/> + <param name="count" type="GLsizei"/> + <param name="value" type="const GLuint *"/> + </function> + + <function name="TexParameterIiv" offset="assign"> + <param name="target" type="GLenum"/> + <param name="pname" type="GLenum"/> + <param name="value" type="const GLint *"/> + </function> + + <function name="TexParameterIuiv" offset="assign"> + <param name="target" type="GLenum"/> + <param name="pname" type="GLenum"/> + <param name="value" type="const GLuint *"/> + </function> + + <function name="GetTexParameterIiv" offset="assign"> + <param name="target" type="GLenum"/> + <param name="pname" type="GLenum"/> + <param name="value" type="GLint *"/> + </function> + + <function name="GetTexParameterIuiv" offset="assign"> + <param name="target" type="GLenum"/> + <param name="pname" type="GLenum"/> + <param name="value" type="GLuint *"/> + </function> + +</category> + + +<category name="3.1"> + + <enum name="SAMPLER_2D_RECT" value="0x8B63"/> + <enum name="SAMPLER_2D_RECT_SHADOW" value="0x8B64"/> + <enum name="SAMPLER_BUFFER" value="0x8DC2"/> + <enum name="INT_SAMPLER_2D_RECT" value="0x8DCD"/> + <enum name="INT_SAMPLER_BUFFER" value="0x8DD0"/> + <enum name="UNSIGNED_INT_SAMPLER_2D_RECT" value="0x8DD5"/> + <enum name="UNSIGNED_INT_SAMPLER_BUFFER" value="0x8DD8"/> + <enum name="TEXTURE_BUFFER" value="0x8C2A"/> + <enum name="MAX_TEXTURE_BUFFER_SIZE" value="0x8C2B"/> + <enum name="TEXTURE_BINDING_BUFFER" value="0x8C2C"/> + <enum name="TEXTURE_BUFFER_DATA_STORE_BINDING" value="0x8C2D"/> + <enum name="TEXTURE_BUFFER_FORMAT" value="0x8C2E"/> + <enum name="TEXTURE_RECTANGLE" value="0x84F5"/> + <enum name="TEXTURE_BINDING_RECTANGLE" value="0x84F6"/> + <enum name="PROXY_TEXTURE_RECTANGLE" value="0x84F7"/> + <enum name="MAX_RECTANGLE_TEXTURE_SIZE" value="0x84F8"/> + <enum name="RED_SNORM" value="0x8F90"/> + <enum name="RG_SNORM" value="0x8F91"/> + <enum name="RGB_SNORM" value="0x8F92"/> + <enum name="RGBA_SNORM" value="0x8F93"/> + <enum name="R8_SNORM" value="0x8F94"/> + <enum name="RG8_SNORM" value="0x8F95"/> + <enum name="RGB8_SNORM" value="0x8F96"/> + <enum name="RGBA8_SNORM" value="0x8F97"/> + <enum name="R16_SNORM" value="0x8F98"/> + <enum name="RG16_SNORM" value="0x8F99"/> + <enum name="RGB16_SNORM" value="0x8F9A"/> + <enum name="RGBA16_SNORM" value="0x8F9B"/> + <enum name="SIGNED_NORMALIZED" value="0x8F9C"/> + <enum name="PRIMITIVE_RESTART" value="0x8F9D"/> + <enum name="PRIMITIVE_RESTART_INDEX" value="0x8F9E"/> + + <function name="DrawArraysInstanced" offset="assign"> + <param name="mode" type="GLenum"/> + <param name="first" type="GLint"/> + <param name="count" type="GLsizei"/> + <param name="primcount" type="GLsizei"/> + </function> + + <function name="DrawElementsInstanced" offset="assign"> + <param name="mode" type="GLenum"/> + <param name="count" type="GLsizei"/> + <param name="type" type="GLenum"/> + <param name="indices" type="const GLvoid *"/> + <param name="primcount" type="GLsizei"/> + </function> + + <function name="TexBuffer" offset="assign"> + <param name="target" type="GLenum"/> + <param name="internalFormat" type="GLenum"/> + <param name="buffer" type="GLuint"/> + </function> + + <function name="glPrimitiveRestartIndex" offset="assign"> + <param name="index" type="GLuint"/> + </function> + +</category> + + +<category name="3.2"> + + <enum name="CONTEXT_CORE_PROFILE_BIT" value="0x00000001"/> + <enum name="CONTEXT_COMPATIBILITY_PROFILE_BIT" value="0x00000002"/> + <enum name="LINES_ADJACENCY" value="0x000A"/> + <enum name="LINE_STRIP_ADJACENCY" value="0x000B"/> + <enum name="TRIANGLES_ADJACENCY" value="0x000C"/> + <enum name="TRIANGLE_STRIP_ADJACENCY" value="0x000D"/> + <enum name="PROGRAM_POINT_SIZE" value="0x8642"/> + <enum name="MAX_GEOMETRY_TEXTURE_IMAGE_UNITS" value="0x8C29"/> + <enum name="FRAMEBUFFER_ATTACHMENT_LAYERED" value="0x8DA7"/> + <enum name="FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS" value="0x8DA8"/> + <enum name="GEOMETRY_SHADER" value="0x8DD9"/> + <enum name="GEOMETRY_VERTICES_OUT" value="0x8916"/> + <enum name="GEOMETRY_INPUT_TYPE" value="0x8917"/> + <enum name="GEOMETRY_OUTPUT_TYPE" value="0x8918"/> + <enum name="MAX_GEOMETRY_UNIFORM_COMPONENTS" value="0x8DDF"/> + <enum name="MAX_GEOMETRY_OUTPUT_VERTICES" value="0x8DE0"/> + <enum name="MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS" value="0x8DE1"/> + <enum name="MAX_VERTEX_OUTPUT_COMPONENTS" value="0x9122"/> + <enum name="MAX_GEOMETRY_INPUT_COMPONENTS" value="0x9123"/> + <enum name="MAX_GEOMETRY_OUTPUT_COMPONENTS" value="0x9124"/> + <enum name="MAX_FRAGMENT_INPUT_COMPONENTS" value="0x9125"/> + <enum name="CONTEXT_PROFILE_MASK" value="0x9126"/> + + <function name="GetInteger64i_v" offset="assign"> + <param name="cap" type="GLenum"/> + <param name="index" type="GLuint"/> + <param name="data" type="GLint64 *"/> + </function> + + <function name="GetBufferParameteri64v" offset="assign"> + <param name="target" type="GLenum"/> + <param name="pname" type="GLenum"/> + <param name="params" type="GLint64 *"/> + </function> + + <function name="ProgramParameteri" offset="assign"> + <param name="program" type="GLuint"/> + <param name="pname" type="GLenum"/> + <param name="value" type="GLint"/> + </function> + + <function name="FramebufferTexture" offset="assign"> + <param name="target" type="GLenum"/> + <param name="attachment" type="GLenum"/> + <param name="texture" type="GLuint"/> + <param name="level" type="GLint"/> + </function> + + <function name="FramebufferTextureFace" offset="assign"> + <param name="target" type="GLenum"/> + <param name="attachment" type="GLenum"/> + <param name="texture" type="GLuint"/> + <param name="level" type="GLint"/> + <param name="face" type="GLenum"/> + </function> + +</category> + +</OpenGLAPI> diff --git a/mesalib/src/mapi/glapi/gen/Makefile b/mesalib/src/mapi/glapi/gen/Makefile new file mode 100644 index 000000000..41640b3b0 --- /dev/null +++ b/mesalib/src/mapi/glapi/gen/Makefile @@ -0,0 +1,208 @@ +# This file isn't used during a normal compilation since we don't want to +# require Python in order to compile Mesa. +# Instead, when the Mesa developers update/change the API interface it's +# up to him/her to re-run this makefile and check in the newly generated files. + + +TOP = ../../../.. +include $(TOP)/configs/current + +MESA_DIR = $(TOP)/src/mesa +MESA_GLAPI_DIR = $(TOP)/src/mapi/glapi +MESA_GLX_DIR = $(TOP)/src/glx + +MESA_GLAPI_OUTPUTS = \ + $(MESA_GLAPI_DIR)/glprocs.h \ + $(MESA_GLAPI_DIR)/glapitemp.h \ + $(MESA_GLAPI_DIR)/glapioffsets.h \ + $(MESA_GLAPI_DIR)/glapitable.h \ + $(MESA_GLAPI_DIR)/glapidispatch.h + +MESA_GLAPI_ASM_OUTPUTS = \ + $(MESA_GLAPI_DIR)/glapi_x86.S \ + $(MESA_GLAPI_DIR)/glapi_x86-64.S \ + $(MESA_GLAPI_DIR)/glapi_sparc.S + +MESA_OUTPUTS = \ + $(MESA_GLAPI_OUTPUTS) \ + $(MESA_GLAPI_ASM_OUTPUTS) \ + $(MESA_DIR)/main/enums.c \ + $(MESA_DIR)/main/remap_helper.h \ + $(MESA_GLX_DIR)/indirect.c \ + $(MESA_GLX_DIR)/indirect.h \ + $(MESA_GLX_DIR)/indirect_init.c \ + $(MESA_GLX_DIR)/indirect_size.h \ + $(MESA_GLX_DIR)/indirect_size.c + +###################################################################### + +XORG_GLX_DIR = $(XORG_BASE)/glx +XORG_GLAPI_DIR = $(XORG_BASE)/glx + +XORG_GLAPI_FILES = \ + $(XORG_GLAPI_DIR)/glapi.h \ + $(XORG_GLAPI_DIR)/glapi.c \ + $(XORG_GLAPI_DIR)/glapi_getproc.c \ + $(XORG_GLAPI_DIR)/glapi_nop.c \ + $(XORG_GLAPI_DIR)/glthread.c \ + $(XORG_GLAPI_DIR)/glthread.h + +XORG_GLAPI_OUTPUTS = \ + $(XORG_GLAPI_DIR)/glprocs.h \ + $(XORG_GLAPI_DIR)/glapitemp.h \ + $(XORG_GLAPI_DIR)/glapioffsets.h \ + $(XORG_GLAPI_DIR)/glapitable.h \ + $(XORG_GLAPI_DIR)/glapidispatch.h + +XORG_OUTPUTS = \ + $(XORG_GLAPI_FILES) \ + $(XORG_GLAPI_OUTPUTS) \ + $(XORG_GLX_DIR)/indirect_dispatch.c \ + $(XORG_GLX_DIR)/indirect_dispatch_swap.c \ + $(XORG_GLX_DIR)/indirect_dispatch.h \ + $(XORG_GLX_DIR)/indirect_reqsize.c \ + $(XORG_GLX_DIR)/indirect_reqsize.h \ + $(XORG_GLX_DIR)/indirect_size.h \ + $(XORG_GLX_DIR)/indirect_size_get.c \ + $(XORG_GLX_DIR)/indirect_size_get.h \ + $(XORG_GLX_DIR)/indirect_table.c + +###################################################################### + +API_XML = \ + gl_API.xml \ + ARB_copy_buffer.xml \ + ARB_depth_clamp.xml \ + ARB_draw_elements_base_vertex.xml \ + ARB_draw_instanced.xml \ + ARB_framebuffer_object.xml \ + ARB_geometry_shader4.xml \ + ARB_map_buffer_range.xml \ + ARB_seamless_cube_map.xml \ + ARB_sync.xml \ + ARB_vertex_array_object.xml \ + APPLE_object_purgeable.xml \ + APPLE_vertex_array_object.xml \ + EXT_draw_buffers2.xml \ + EXT_framebuffer_object.xml \ + EXT_packed_depth_stencil.xml \ + EXT_provoking_vertex.xml \ + EXT_texture_array.xml \ + EXT_transform_feedback.xml \ + NV_conditional_render.xml \ + OES_EGL_image.xml + +COMMON = $(API_XML) gl_XML.py glX_XML.py license.py typeexpr.py + +COMMON_GLX = $(COMMON) glX_API.xml glX_XML.py glX_proto_common.py + +###################################################################### + +all: mesa xorg + +mesa: $(MESA_OUTPUTS) + +xorg: check-xorg-source $(XORG_OUTPUTS) + +check-xorg-source: + @if ! test -d $(XORG_GLX_DIR); then \ + echo "ERROR: Must specify path to xserver/GL/ checkout; set XORG_BASE env var."; \ + exit 1; \ + fi + +clean: + -rm -f *~ *.pyo + -rm -f $(MESA_OUTPUTS) + +###################################################################### + +$(XORG_GLAPI_DIR)/%.c: $(MESA_GLAPI_DIR)/%.c + cp $< $@ + +$(XORG_GLAPI_DIR)/%.h: $(MESA_GLAPI_DIR)/%.h + cp $< $@ + +###################################################################### + +$(MESA_GLAPI_DIR)/glprocs.h: gl_procs.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_GLAPI_DIR)/glapitemp.h: gl_apitemp.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_GLAPI_DIR)/glapioffsets.h: gl_offsets.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_GLAPI_DIR)/glapitable.h: gl_table.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_GLAPI_DIR)/glapidispatch.h: gl_table.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< -m remap_table > $@ + +###################################################################### + +$(MESA_GLAPI_DIR)/glapi_x86.S: gl_x86_asm.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_GLAPI_DIR)/glapi_x86-64.S: gl_x86-64_asm.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_GLAPI_DIR)/glapi_sparc.S: gl_SPARC_asm.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +###################################################################### + +$(MESA_DIR)/main/enums.c: gl_enums.py $(COMMON) $(ES_API) + $(PYTHON2) $(PYTHON_FLAGS) $< -f gl_API.xml \ + -f $(MESA_GLAPI_DIR)/gen-es/es1_API.xml \ + -f $(MESA_GLAPI_DIR)/gen-es/es2_API.xml > $@ + +$(MESA_DIR)/main/remap_helper.h: remap_helper.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +###################################################################### + +$(MESA_GLX_DIR)/indirect.c: glX_proto_send.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m proto | $(INDENT) $(INDENT_FLAGS) > $@ + +$(MESA_GLX_DIR)/indirect.h: glX_proto_send.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m init_h > $@ + +$(MESA_GLX_DIR)/indirect_init.c: glX_proto_send.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m init_c > $@ + +$(MESA_GLX_DIR)/indirect_size.h $(XORG_GLX_DIR)/indirect_size.h: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m size_h --only-set -h _INDIRECT_SIZE_H_ \ + | $(INDENT) $(INDENT_FLAGS) > $@ + +$(MESA_GLX_DIR)/indirect_size.c: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m size_c --only-set \ + | $(INDENT) $(INDENT_FLAGS) > $@ + +###################################################################### + +$(XORG_GLX_DIR)/indirect_dispatch.c: glX_proto_recv.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m dispatch_c > $@ + +$(XORG_GLX_DIR)/indirect_dispatch_swap.c: glX_proto_recv.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m dispatch_c -s > $@ + +$(XORG_GLX_DIR)/indirect_dispatch.h: glX_proto_recv.py gl_and_glX_API.xml $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m dispatch_h -f gl_and_glX_API.xml -s > $@ + +$(XORG_GLX_DIR)/indirect_size_get.h: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m size_h --only-get -h '_INDIRECT_SIZE_GET_H_' \ + | $(INDENT) $(INDENT_FLAGS) > $@ + +$(XORG_GLX_DIR)/indirect_size_get.c: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m size_c | $(INDENT) $(INDENT_FLAGS) > $@ + +$(XORG_GLX_DIR)/indirect_reqsize.h: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m reqsize_h --only-get -h '_INDIRECT_SIZE_GET_H_' \ + | $(INDENT) $(INDENT_FLAGS) -l200 > $@ + +$(XORG_GLX_DIR)/indirect_reqsize.c: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m reqsize_c | $(INDENT) $(INDENT_FLAGS) > $@ + +$(XORG_GLX_DIR)/indirect_table.c: glX_server_table.py gl_and_glX_API.xml $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -f gl_and_glX_API.xml > $@ diff --git a/mesalib/src/mapi/glapi/gen/glX_proto_recv.py b/mesalib/src/mapi/glapi/gen/glX_proto_recv.py index 31745fcef..887f63191 100644 --- a/mesalib/src/mapi/glapi/gen/glX_proto_recv.py +++ b/mesalib/src/mapi/glapi/gen/glX_proto_recv.py @@ -384,9 +384,9 @@ class PrintGlxDispatchFunctions(glX_proto_common.glx_print_proto): print ' int error;' if self.do_swap: - print ' __GLXcontext * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error);' + print ' struct glx_context * const cx = __glXForceCurrent(cl, bswap_CARD32( &req->contextTag ), &error);' else: - print ' __GLXcontext * const cx = __glXForceCurrent(cl, req->contextTag, &error);' + print ' struct glx_context * const cx = __glXForceCurrent(cl, req->contextTag, &error);' print '' if name not in f.glx_vendorpriv_names: diff --git a/mesalib/src/mapi/glapi/gen/glX_proto_send.py b/mesalib/src/mapi/glapi/gen/glX_proto_send.py index c52b85bfb..bd41c9e66 100644 --- a/mesalib/src/mapi/glapi/gen/glX_proto_send.py +++ b/mesalib/src/mapi/glapi/gen/glX_proto_send.py @@ -220,7 +220,7 @@ __glXReadReply( Display *dpy, size_t size, void * dest, GLboolean reply_is_alway } NOINLINE void -__glXReadPixelReply( Display *dpy, __GLXcontext * gc, unsigned max_dim, +__glXReadPixelReply( Display *dpy, struct glx_context * gc, unsigned max_dim, GLint width, GLint height, GLint depth, GLenum format, GLenum type, void * dest, GLboolean dimensions_in_reply ) { @@ -264,7 +264,7 @@ __glXReadPixelReply( Display *dpy, __GLXcontext * gc, unsigned max_dim, #define X_GLXSingle 0 NOINLINE FASTCALL GLubyte * -__glXSetupSingleRequest( __GLXcontext * gc, GLint sop, GLint cmdlen ) +__glXSetupSingleRequest( struct glx_context * gc, GLint sop, GLint cmdlen ) { xGLXSingleReq * req; Display * const dpy = gc->currentDpy; @@ -279,7 +279,7 @@ __glXSetupSingleRequest( __GLXcontext * gc, GLint sop, GLint cmdlen ) } NOINLINE FASTCALL GLubyte * -__glXSetupVendorRequest( __GLXcontext * gc, GLint code, GLint vop, GLint cmdlen ) +__glXSetupVendorRequest( struct glx_context * gc, GLint code, GLint vop, GLint cmdlen ) { xGLXVendorPrivateReq * req; Display * const dpy = gc->currentDpy; @@ -371,10 +371,10 @@ const GLuint __glXDefaultPixelStore[9] = { 0, 0, 0, 0, 0, 0, 0, 0, 1 }; print '#define %s %d' % (func.opcode_vendor_name(name), func.glx_vendorpriv) print '%s gl%s(%s)' % (func.return_type, func_name, func.get_parameter_string()) print '{' - print ' __GLXcontext * const gc = __glXGetCurrentContext();' + print ' struct glx_context * const gc = __glXGetCurrentContext();' print '' - print '#ifdef GLX_DIRECT_RENDERING' - print ' if (gc->driContext) {' + print '#if defined(GLX_DIRECT_RENDERING) && !defined(GLX_USE_APPLEGL)' + print ' if (gc->isDirect) {' print ' %sCALL_%s(GET_DISPATCH(), (%s));' % (ret_string, func.name, func.get_called_parameter_string()) print ' } else' print '#endif' @@ -408,7 +408,7 @@ const GLuint __glXDefaultPixelStore[9] = { 0, 0, 0, 0, 0, 0, 0, 0, 1 }; print """static FASTCALL NOINLINE void generic_%u_byte( GLint rop, const void * ptr ) { - __GLXcontext * const gc = __glXGetCurrentContext(); + struct glx_context * const gc = __glXGetCurrentContext(); const GLuint cmdlen = %u; emit_header(gc->pc, rop, cmdlen); @@ -523,7 +523,7 @@ generic_%u_byte( GLint rop, const void * ptr ) def common_func_print_just_start(self, f, name): - print ' __GLXcontext * const gc = __glXGetCurrentContext();' + print ' struct glx_context * const gc = __glXGetCurrentContext();' # The only reason that single and vendor private commands need # a variable called 'dpy' is becuase they use the SyncHandle @@ -895,13 +895,13 @@ static int NoOp(void) * Create and initialize a new GL dispatch table. The table is initialized * with GLX indirect rendering protocol functions. */ -__GLapi * __glXNewIndirectAPI( void ) +struct _glapi_table * __glXNewIndirectAPI( void ) { - __GLapi *glAPI; + struct _glapi_table *glAPI; GLuint entries; entries = _glapi_get_dispatch_table_size(); - glAPI = (__GLapi *) Xmalloc(entries * sizeof(void *)); + glAPI = (struct _glapi_table *) Xmalloc(entries * sizeof(void *)); /* first, set all entries to point to no-op functions */ { @@ -971,15 +971,15 @@ extern HIDDEN NOINLINE CARD32 __glXReadReply( Display *dpy, size_t size, void * dest, GLboolean reply_is_always_array ); extern HIDDEN NOINLINE void __glXReadPixelReply( Display *dpy, - __GLXcontext * gc, unsigned max_dim, GLint width, GLint height, + struct glx_context * gc, unsigned max_dim, GLint width, GLint height, GLint depth, GLenum format, GLenum type, void * dest, GLboolean dimensions_in_reply ); extern HIDDEN NOINLINE FASTCALL GLubyte * __glXSetupSingleRequest( - __GLXcontext * gc, GLint sop, GLint cmdlen ); + struct glx_context * gc, GLint sop, GLint cmdlen ); extern HIDDEN NOINLINE FASTCALL GLubyte * __glXSetupVendorRequest( - __GLXcontext * gc, GLint code, GLint vop, GLint cmdlen ); + struct glx_context * gc, GLint code, GLint vop, GLint cmdlen ); """ diff --git a/mesalib/src/mapi/glapi/gen/glX_proto_size.py b/mesalib/src/mapi/glapi/gen/glX_proto_size.py index 95cb5110c..f16ea4c3b 100644 --- a/mesalib/src/mapi/glapi/gen/glX_proto_size.py +++ b/mesalib/src/mapi/glapi/gen/glX_proto_size.py @@ -329,7 +329,7 @@ class PrintGlxSizeStubs_c(PrintGlxSizeStubs_common): self.printVisibility( "INTERNAL", "internal" ) print '' print '' - print '#if defined(__CYGWIN__) || defined(__MINGW32__) || defined(__APPLE__)' + print '#if defined(__CYGWIN__) || defined(__MINGW32__) || defined(GLX_USE_APPLEGL)' print '# undef HAVE_ALIAS' print '#endif' print '#ifdef HAVE_ALIAS' diff --git a/mesalib/src/mapi/glapi/gen/gl_API.xml b/mesalib/src/mapi/glapi/gen/gl_API.xml index 3e2981b91..123565458 100644 --- a/mesalib/src/mapi/glapi/gen/gl_API.xml +++ b/mesalib/src/mapi/glapi/gen/gl_API.xml @@ -4666,8 +4666,8 @@ <function name="MultiDrawArrays" alias="MultiDrawArraysEXT"> <param name="mode" type="GLenum"/> - <param name="first" type="GLint *"/> <!-- Spec bug. Should be const. --> - <param name="count" type="GLsizei *"/> <!-- Spec bug. Should be const. --> + <param name="first" type="const GLint *"/> + <param name="count" type="const GLsizei *"/> <param name="primcount" type="GLsizei"/> </function> @@ -7967,6 +7967,12 @@ <xi:include href="NV_conditional_render.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> +<xi:include href="EXT_transform_feedback.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> + +<xi:include href="ARB_draw_instanced.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> + +<xi:include href="ARB_geometry_shader4.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> + <!-- Non-ARB extensions sorted by extension number. --> @@ -9788,8 +9794,8 @@ <category name="GL_EXT_multi_draw_arrays" number="148"> <function name="MultiDrawArraysEXT" offset="assign"> <param name="mode" type="GLenum"/> - <param name="first" type="GLint *"/> <!-- Spec bug. Should be const. --> - <param name="count" type="GLsizei *"/> <!-- Spec bug. Should be const. --> + <param name="first" type="const GLint *"/> + <param name="count" type="const GLsizei *"/> <param name="primcount" type="GLsizei"/> <glx handcode="true"/> </function> diff --git a/mesalib/src/mapi/glapi/gen/gl_enums.py b/mesalib/src/mapi/glapi/gen/gl_enums.py index 3a9ea3c86..0caa01030 100644 --- a/mesalib/src/mapi/glapi/gen/gl_enums.py +++ b/mesalib/src/mapi/glapi/gen/gl_enums.py @@ -105,7 +105,8 @@ const char *_mesa_lookup_enum_by_nr( int nr ) } else { /* this is not re-entrant safe, no big deal here */ - sprintf(token_tmp, "0x%x", nr); + _mesa_snprintf(token_tmp, sizeof(token_tmp) - 1, "0x%x", nr); + token_tmp[sizeof(token_tmp) - 1] = '\\0'; return token_tmp; } } @@ -151,8 +152,10 @@ int _mesa_lookup_enum_by_name( const char *symbol ) return - def printBody(self, api): - self.process_enums( api ) + def printBody(self, api_list): + self.enum_table = {} + for api in api_list: + self.process_enums( api ) keys = self.enum_table.keys() keys.sort() @@ -209,16 +212,20 @@ int _mesa_lookup_enum_by_name( const char *symbol ) def process_enums(self, api): - self.enum_table = {} - for obj in api.enumIterateByName(): if obj.value not in self.enum_table: self.enum_table[ obj.value ] = [] + enum = self.enum_table[ obj.value ] name = "GL_" + obj.name priority = obj.priority() - self.enum_table[ obj.value ].append( [name, priority] ) + already_in = False; + for n, p in enum: + if n == name: + already_in = True + if not already_in: + enum.append( [name, priority] ) def show_usage(): @@ -226,18 +233,16 @@ def show_usage(): sys.exit(1) if __name__ == '__main__': - file_name = "gl_API.xml" - try: (args, trail) = getopt.getopt(sys.argv[1:], "f:") except Exception,e: show_usage() + api_list = [] for (arg,val) in args: if arg == "-f": - file_name = val - - api = gl_XML.parse_GL_API( file_name ) + api = gl_XML.parse_GL_API( val ) + api_list.append(api); printer = PrintGlEnums() - printer.Print( api ) + printer.Print( api_list ) diff --git a/mesalib/src/mapi/glapi/gen/remap_helper.py b/mesalib/src/mapi/glapi/gen/remap_helper.py index 8b50526d2..69b8e5e9d 100644 --- a/mesalib/src/mapi/glapi/gen/remap_helper.py +++ b/mesalib/src/mapi/glapi/gen/remap_helper.py @@ -65,17 +65,12 @@ class PrintGlRemap(gl_XML.gl_print_base): def printRealHeader(self): print '#include "main/dispatch.h"' + print '#include "main/remap.h"' print '' return def printBody(self, api): - print 'struct gl_function_remap {' - print ' GLint func_index;' - print ' GLint dispatch_offset; /* for sanity check */' - print '};' - print '' - pool_indices = {} print '/* this is internal to remap.c */' @@ -108,10 +103,7 @@ class PrintGlRemap(gl_XML.gl_print_base): print '' print '/* these functions need to be remapped */' - print 'static const struct {' - print ' GLint pool_index;' - print ' GLint remap_index;' - print '} MESA_remap_table_functions[] = {' + print 'static const struct gl_function_pool_remap MESA_remap_table_functions[] = {' # output all functions that need to be remapped # iterate by offsets so that they are sorted by remap indices for f in api.functionIterateByOffset(): |