These XMLs define OpenGL ES 1.x and 2.x APIs. Signed-off-by: Chia-I Wu <olvaffe@gmail.com>tags/7.8-rc1
| @@ -0,0 +1,90 @@ | |||
| TOP = ../../../.. | |||
| GLAPI = ../../glapi | |||
| include $(TOP)/configs/current | |||
| OUTPUTS := \ | |||
| glapi/glapidispatch.h \ | |||
| glapi/glapioffsets.h \ | |||
| glapi/glapitable.h \ | |||
| glapi/glapitemp.h \ | |||
| glapi/glprocs.h \ | |||
| sparc/glapi_sparc.S \ | |||
| x86-64/glapi_x86-64.S \ | |||
| x86/glapi_x86.S \ | |||
| main/enums.c \ | |||
| main/remap_helper.h | |||
| COMMON = gl_XML.py glX_XML.py license.py typeexpr.py | |||
| COMMON := $(addprefix $(GLAPI)/, $(COMMON)) | |||
| ES1_APIXML := es1_API.xml | |||
| ES2_APIXML := es2_API.xml | |||
| ES1_OUTPUT_DIR := glapi-es1 | |||
| ES2_OUTPUT_DIR := glapi-es2 | |||
| ES1_DEPS = $(ES1_APIXML) base1_API.xml es1_EXT.xml es_EXT.xml \ | |||
| es1_COMPAT.xml es_COMPAT.xml | |||
| ES2_DEPS = $(ES2_APIXML) base2_API.xml es2_EXT.xml es_EXT.xml \ | |||
| es2_COMPAT.xml es_COMPAT.xml | |||
| ES1_OUTPUTS := $(addprefix $(ES1_OUTPUT_DIR)/, $(OUTPUTS)) | |||
| ES2_OUTPUTS := $(addprefix $(ES2_OUTPUT_DIR)/, $(OUTPUTS)) | |||
| all: $(ES1_OUTPUTS) $(ES2_OUTPUTS) | |||
| $(ES1_OUTPUTS): APIXML := $(ES1_APIXML) | |||
| $(ES2_OUTPUTS): APIXML := $(ES2_APIXML) | |||
| $(ES1_OUTPUTS): $(ES1_DEPS) | |||
| $(ES2_OUTPUTS): $(ES2_DEPS) | |||
| define gen-glapi | |||
| @mkdir -p $(dir $@) | |||
| $(PYTHON2) $(PYTHON_FLAGS) $< -f $(APIXML) $(1) > $@ | |||
| endef | |||
| %/glapidispatch.h: $(GLAPI)/gl_table.py $(COMMON) | |||
| $(call gen-glapi,-c -m remap_table) | |||
| %/glapioffsets.h: $(GLAPI)/gl_offsets.py $(COMMON) | |||
| $(call gen-glapi,-c) | |||
| %/glapitable.h: $(GLAPI)/gl_table.py $(COMMON) | |||
| $(call gen-glapi,-c) | |||
| %/glapitemp.h: $(GLAPI)/gl_apitemp.py $(COMMON) | |||
| $(call gen-glapi) | |||
| %/glprocs.h: $(GLAPI)/gl_procs.py $(COMMON) | |||
| $(call gen-glapi,-c) | |||
| %/sparc/glapi_sparc.S: $(GLAPI)/gl_SPARC_asm.py $(COMMON) | |||
| $(call gen-glapi) | |||
| %/x86-64/glapi_x86-64.S: $(GLAPI)/gl_x86-64_asm.py $(COMMON) | |||
| $(call gen-glapi) | |||
| %/x86/glapi_x86.S: $(GLAPI)/gl_x86_asm.py $(COMMON) | |||
| $(call gen-glapi) | |||
| %/main/enums.c: $(GLAPI)/gl_enums.py $(COMMON) | |||
| $(call gen-glapi) | |||
| %/main/remap_helper.h: $(GLAPI)/remap_helper.py $(COMMON) | |||
| $(call gen-glapi) | |||
| verify_xml: | |||
| @if [ ! -f gl.h ]; then \ | |||
| echo "Please copy gl.h and gl2.h to this directory"; \ | |||
| exit 1; \ | |||
| fi | |||
| @echo "Verifying that es1_API.xml covers OpenGL ES 1.1..." | |||
| @$(PYTHON2) $(PYTHON_FLAGS) gl_parse_header.py gl.h > tmp.xml | |||
| @$(PYTHON2) $(PYTHON_FLAGS) gl_compare.py difference tmp.xml es1_API.xml | |||
| @echo "Verifying that es2_API.xml covers OpenGL ES 2.0..." | |||
| @$(PYTHON2) $(PYTHON_FLAGS) gl_parse_header.py gl2.h > tmp.xml | |||
| @$(PYTHON2) $(PYTHON_FLAGS) gl_compare.py difference tmp.xml es2_API.xml | |||
| @rm -f tmp.xml | |||
| clean: | |||
| -rm -rf $(ES1_OUTPUT_DIR) $(ES2_OUTPUT_DIR) | |||
| -rm -f *~ *.pyc *.pyo | |||
| @@ -0,0 +1,744 @@ | |||
| <?xml version="1.0"?> | |||
| <!DOCTYPE OpenGLAPI SYSTEM "../../glapi/gl_API.dtd"> | |||
| <!-- OpenGL and OpenGL ES 1.x APIs | |||
| This file defines the base categories that can be shared by all APIs. | |||
| They are defined in an incremental fashion. | |||
| --> | |||
| <OpenGLAPI> | |||
| <!-- base subset of OpenGL 1.0 --> | |||
| <category name="base1.0"> | |||
| <enum name="FALSE" value="0x0"/> | |||
| <enum name="TRUE" value="0x1"/> | |||
| <enum name="ZERO" value="0x0"/> | |||
| <enum name="ONE" value="0x1"/> | |||
| <enum name="NO_ERROR" value="0x0"/> | |||
| <enum name="POINTS" value="0x0000"/> | |||
| <enum name="LINES" value="0x0001"/> | |||
| <enum name="LINE_LOOP" value="0x0002"/> | |||
| <enum name="LINE_STRIP" value="0x0003"/> | |||
| <enum name="TRIANGLES" value="0x0004"/> | |||
| <enum name="TRIANGLE_STRIP" value="0x0005"/> | |||
| <enum name="TRIANGLE_FAN" value="0x0006"/> | |||
| <enum name="NEVER" value="0x0200"/> | |||
| <enum name="LESS" value="0x0201"/> | |||
| <enum name="EQUAL" value="0x0202"/> | |||
| <enum name="LEQUAL" value="0x0203"/> | |||
| <enum name="GREATER" value="0x0204"/> | |||
| <enum name="NOTEQUAL" value="0x0205"/> | |||
| <enum name="GEQUAL" value="0x0206"/> | |||
| <enum name="ALWAYS" value="0x0207"/> | |||
| <enum name="SRC_COLOR" value="0x0300"/> | |||
| <enum name="ONE_MINUS_SRC_COLOR" value="0x0301"/> | |||
| <enum name="SRC_ALPHA" value="0x0302"/> | |||
| <enum name="ONE_MINUS_SRC_ALPHA" value="0x0303"/> | |||
| <enum name="DST_ALPHA" value="0x0304"/> | |||
| <enum name="ONE_MINUS_DST_ALPHA" value="0x0305"/> | |||
| <enum name="DST_COLOR" value="0x0306"/> | |||
| <enum name="ONE_MINUS_DST_COLOR" value="0x0307"/> | |||
| <enum name="SRC_ALPHA_SATURATE" value="0x0308"/> | |||
| <enum name="FRONT" value="0x0404"/> | |||
| <enum name="BACK" value="0x0405"/> | |||
| <enum name="FRONT_AND_BACK" value="0x0408"/> | |||
| <enum name="INVALID_ENUM" value="0x0500"/> | |||
| <enum name="INVALID_VALUE" value="0x0501"/> | |||
| <enum name="INVALID_OPERATION" value="0x0502"/> | |||
| <enum name="OUT_OF_MEMORY" value="0x0505"/> | |||
| <enum name="CW" value="0x0900"/> | |||
| <enum name="CCW" value="0x0901"/> | |||
| <enum name="CULL_FACE" count="1" value="0x0B44"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="DEPTH_TEST" count="1" value="0x0B71"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_TEST" count="1" value="0x0B90"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="DITHER" count="1" value="0x0BD0"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="BLEND" count="1" value="0x0BE2"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="SCISSOR_TEST" count="1" value="0x0C11"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="UNPACK_ALIGNMENT" count="1" value="0x0CF5"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="PACK_ALIGNMENT" count="1" value="0x0D05"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="MAX_TEXTURE_SIZE" count="1" value="0x0D33"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="MAX_VIEWPORT_DIMS" count="2" value="0x0D3A"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="SUBPIXEL_BITS" count="1" value="0x0D50"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="RED_BITS" count="1" value="0x0D52"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="GREEN_BITS" count="1" value="0x0D53"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="BLUE_BITS" count="1" value="0x0D54"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="ALPHA_BITS" count="1" value="0x0D55"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="DEPTH_BITS" count="1" value="0x0D56"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_BITS" count="1" value="0x0D57"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="TEXTURE_2D" count="1" value="0x0DE1"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="DONT_CARE" value="0x1100"/> | |||
| <enum name="FASTEST" value="0x1101"/> | |||
| <enum name="NICEST" value="0x1102"/> | |||
| <enum name="BYTE" count="1" value="0x1400"> | |||
| <size name="CallLists"/> | |||
| </enum> | |||
| <enum name="UNSIGNED_BYTE" count="1" value="0x1401"> | |||
| <size name="CallLists"/> | |||
| </enum> | |||
| <enum name="SHORT" count="2" value="0x1402"> | |||
| <size name="CallLists"/> | |||
| </enum> | |||
| <enum name="UNSIGNED_SHORT" count="2" value="0x1403"> | |||
| <size name="CallLists"/> | |||
| </enum> | |||
| <enum name="FLOAT" count="4" value="0x1406"> | |||
| <size name="CallLists"/> | |||
| </enum> | |||
| <enum name="INVERT" value="0x150A"/> | |||
| <enum name="TEXTURE" value="0x1702"/> | |||
| <enum name="ALPHA" value="0x1906"/> | |||
| <enum name="RGB" value="0x1907"/> | |||
| <enum name="RGBA" value="0x1908"/> | |||
| <enum name="LUMINANCE" value="0x1909"/> | |||
| <enum name="LUMINANCE_ALPHA" value="0x190A"/> | |||
| <enum name="KEEP" value="0x1E00"/> | |||
| <enum name="REPLACE" value="0x1E01"/> | |||
| <enum name="INCR" value="0x1E02"/> | |||
| <enum name="DECR" value="0x1E03"/> | |||
| <enum name="VENDOR" value="0x1F00"/> | |||
| <enum name="RENDERER" value="0x1F01"/> | |||
| <enum name="VERSION" value="0x1F02"/> | |||
| <enum name="EXTENSIONS" value="0x1F03"/> | |||
| <enum name="NEAREST" value="0x2600"/> | |||
| <enum name="LINEAR" value="0x2601"/> | |||
| <enum name="NEAREST_MIPMAP_NEAREST" value="0x2700"/> | |||
| <enum name="LINEAR_MIPMAP_NEAREST" value="0x2701"/> | |||
| <enum name="NEAREST_MIPMAP_LINEAR" value="0x2702"/> | |||
| <enum name="LINEAR_MIPMAP_LINEAR" value="0x2703"/> | |||
| <enum name="TEXTURE_MAG_FILTER" count="1" value="0x2800"> | |||
| <size name="TexParameterfv"/> | |||
| <size name="TexParameteriv"/> | |||
| <size name="GetTexParameterfv" mode="get"/> | |||
| <size name="GetTexParameteriv" mode="get"/> | |||
| </enum> | |||
| <enum name="TEXTURE_MIN_FILTER" count="1" value="0x2801"> | |||
| <size name="TexParameterfv"/> | |||
| <size name="TexParameteriv"/> | |||
| <size name="GetTexParameterfv" mode="get"/> | |||
| <size name="GetTexParameteriv" mode="get"/> | |||
| </enum> | |||
| <enum name="TEXTURE_WRAP_S" count="1" value="0x2802"> | |||
| <size name="TexParameterfv"/> | |||
| <size name="TexParameteriv"/> | |||
| <size name="GetTexParameterfv" mode="get"/> | |||
| <size name="GetTexParameteriv" mode="get"/> | |||
| </enum> | |||
| <enum name="TEXTURE_WRAP_T" count="1" value="0x2803"> | |||
| <size name="TexParameterfv"/> | |||
| <size name="TexParameteriv"/> | |||
| <size name="GetTexParameterfv" mode="get"/> | |||
| <size name="GetTexParameteriv" mode="get"/> | |||
| </enum> | |||
| <enum name="REPEAT" value="0x2901"/> | |||
| <enum name="DEPTH_BUFFER_BIT" value="0x00000100"/> | |||
| <enum name="STENCIL_BUFFER_BIT" value="0x00000400"/> | |||
| <enum name="COLOR_BUFFER_BIT" value="0x00004000"/> | |||
| <type name="float" size="4" float="true" glx_name="FLOAT32"/> | |||
| <type name="clampf" size="4" float="true" glx_name="FLOAT32"/> | |||
| <type name="int" size="4" glx_name="CARD32"/> | |||
| <type name="uint" size="4" unsigned="true" glx_name="CARD32"/> | |||
| <type name="sizei" size="4" glx_name="CARD32"/> | |||
| <type name="enum" size="4" unsigned="true" glx_name="ENUM"/> | |||
| <type name="bitfield" size="4" unsigned="true" glx_name="CARD32"/> | |||
| <type name="short" size="2" glx_name="CARD16"/> | |||
| <type name="ushort" size="2" unsigned="true" glx_name="CARD16"/> | |||
| <type name="byte" size="1" glx_name="CARD8"/> | |||
| <type name="ubyte" size="1" unsigned="true" glx_name="CARD8"/> | |||
| <type name="boolean" size="1" unsigned="true" glx_name="CARD8"/> | |||
| <type name="void" size="1"/> | |||
| <function name="BlendFunc" offset="241"> | |||
| <param name="sfactor" type="GLenum"/> | |||
| <param name="dfactor" type="GLenum"/> | |||
| <glx rop="160"/> | |||
| </function> | |||
| <function name="Clear" offset="203"> | |||
| <param name="mask" type="GLbitfield"/> | |||
| <glx rop="127"/> | |||
| </function> | |||
| <function name="ClearColor" offset="206"> | |||
| <param name="red" type="GLclampf"/> | |||
| <param name="green" type="GLclampf"/> | |||
| <param name="blue" type="GLclampf"/> | |||
| <param name="alpha" type="GLclampf"/> | |||
| <glx rop="130"/> | |||
| </function> | |||
| <function name="ClearStencil" offset="207"> | |||
| <param name="s" type="GLint"/> | |||
| <glx rop="131"/> | |||
| </function> | |||
| <function name="ColorMask" offset="210"> | |||
| <param name="red" type="GLboolean"/> | |||
| <param name="green" type="GLboolean"/> | |||
| <param name="blue" type="GLboolean"/> | |||
| <param name="alpha" type="GLboolean"/> | |||
| <glx rop="134"/> | |||
| </function> | |||
| <function name="CullFace" offset="152"> | |||
| <param name="mode" type="GLenum"/> | |||
| <glx rop="79"/> | |||
| </function> | |||
| <function name="DepthFunc" offset="245"> | |||
| <param name="func" type="GLenum"/> | |||
| <glx rop="164"/> | |||
| </function> | |||
| <function name="DepthMask" offset="211"> | |||
| <param name="flag" type="GLboolean"/> | |||
| <glx rop="135"/> | |||
| </function> | |||
| <function name="Disable" offset="214"> | |||
| <param name="cap" type="GLenum"/> | |||
| <glx rop="138" handcode="client"/> | |||
| </function> | |||
| <function name="Enable" offset="215"> | |||
| <param name="cap" type="GLenum"/> | |||
| <glx rop="139" handcode="client"/> | |||
| </function> | |||
| <function name="Finish" offset="216"> | |||
| <glx sop="108" handcode="true"/> | |||
| </function> | |||
| <function name="Flush" offset="217"> | |||
| <glx sop="142" handcode="true"/> | |||
| </function> | |||
| <function name="FrontFace" offset="157"> | |||
| <param name="mode" type="GLenum"/> | |||
| <glx rop="84"/> | |||
| </function> | |||
| <function name="GetError" offset="261"> | |||
| <return type="GLenum"/> | |||
| <glx sop="115" handcode="client"/> | |||
| </function> | |||
| <function name="GetIntegerv" offset="263"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true" variable_param="pname"/> | |||
| <glx sop="117" handcode="client"/> | |||
| </function> | |||
| <function name="GetString" offset="275"> | |||
| <param name="name" type="GLenum"/> | |||
| <return type="const GLubyte *"/> | |||
| <glx sop="129" handcode="true"/> | |||
| </function> | |||
| <function name="Hint" offset="158"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="mode" type="GLenum"/> | |||
| <glx rop="85"/> | |||
| </function> | |||
| <function name="LineWidth" offset="168"> | |||
| <param name="width" type="GLfloat"/> | |||
| <glx rop="95"/> | |||
| </function> | |||
| <function name="PixelStorei" offset="250"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLint"/> | |||
| <glx sop="110" handcode="client"/> | |||
| </function> | |||
| <function name="ReadPixels" offset="256"> | |||
| <param name="x" type="GLint"/> | |||
| <param name="y" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="pixels" type="GLvoid *" output="true" img_width="width" img_height="height" img_format="format" img_type="type" img_target="0"/> | |||
| <glx sop="111"/> | |||
| </function> | |||
| <function name="Scissor" offset="176"> | |||
| <param name="x" type="GLint"/> | |||
| <param name="y" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <glx rop="103"/> | |||
| </function> | |||
| <function name="StencilFunc" offset="243"> | |||
| <param name="func" type="GLenum"/> | |||
| <param name="ref" type="GLint"/> | |||
| <param name="mask" type="GLuint"/> | |||
| <glx rop="162"/> | |||
| </function> | |||
| <function name="StencilMask" offset="209"> | |||
| <param name="mask" type="GLuint"/> | |||
| <glx rop="133"/> | |||
| </function> | |||
| <function name="StencilOp" offset="244"> | |||
| <param name="fail" type="GLenum"/> | |||
| <param name="zfail" type="GLenum"/> | |||
| <param name="zpass" type="GLenum"/> | |||
| <glx rop="163"/> | |||
| </function> | |||
| <function name="TexParameterf" offset="178"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfloat"/> | |||
| <glx rop="105"/> | |||
| </function> | |||
| <function name="Viewport" offset="305"> | |||
| <param name="x" type="GLint"/> | |||
| <param name="y" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <glx rop="191"/> | |||
| </function> | |||
| <!-- these are not in OpenGL ES 1.0 --> | |||
| <enum name="LINE_WIDTH" count="1" value="0x0B21"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="CULL_FACE_MODE" count="1" value="0x0B45"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="FRONT_FACE" count="1" value="0x0B46"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="DEPTH_RANGE" count="2" value="0x0B70"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="DEPTH_WRITEMASK" count="1" value="0x0B72"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="DEPTH_CLEAR_VALUE" count="1" value="0x0B73"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="DEPTH_FUNC" count="1" value="0x0B74"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_CLEAR_VALUE" count="1" value="0x0B91"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_FUNC" count="1" value="0x0B92"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_VALUE_MASK" count="1" value="0x0B93"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_FAIL" count="1" value="0x0B94"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_PASS_DEPTH_FAIL" count="1" value="0x0B95"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_PASS_DEPTH_PASS" count="1" value="0x0B96"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_REF" count="1" value="0x0B97"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_WRITEMASK" count="1" value="0x0B98"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="VIEWPORT" count="4" value="0x0BA2"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="SCISSOR_BOX" count="4" value="0x0C10"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="COLOR_CLEAR_VALUE" count="4" value="0x0C22"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="COLOR_WRITEMASK" count="4" value="0x0C23"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <function name="TexParameterfv" offset="179"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfloat *" variable_param="pname"/> | |||
| <glx rop="106"/> | |||
| </function> | |||
| <function name="TexParameteri" offset="180"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLint"/> | |||
| <glx rop="107"/> | |||
| </function> | |||
| <function name="TexParameteriv" offset="181"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLint *" variable_param="pname"/> | |||
| <glx rop="108"/> | |||
| </function> | |||
| <function name="GetBooleanv" offset="258"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLboolean *" output="true" variable_param="pname"/> | |||
| <glx sop="112" handcode="client"/> | |||
| </function> | |||
| <function name="GetFloatv" offset="262"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfloat *" output="true" variable_param="pname"/> | |||
| <glx sop="116" handcode="client"/> | |||
| </function> | |||
| <function name="GetTexParameterfv" offset="282"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfloat *" output="true" variable_param="pname"/> | |||
| <glx sop="136"/> | |||
| </function> | |||
| <function name="GetTexParameteriv" offset="283"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true" variable_param="pname"/> | |||
| <glx sop="137"/> | |||
| </function> | |||
| <function name="IsEnabled" offset="286"> | |||
| <param name="cap" type="GLenum"/> | |||
| <return type="GLboolean"/> | |||
| <glx sop="140" handcode="client"/> | |||
| </function> | |||
| </category> | |||
| <!-- base subset of OpenGL 1.1 --> | |||
| <category name="base1.1"> | |||
| <enum name="POLYGON_OFFSET_FILL" value="0x8037"/> | |||
| <function name="BindTexture" offset="307"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="texture" type="GLuint"/> | |||
| <glx rop="4117"/> | |||
| </function> | |||
| <function name="CopyTexImage2D" offset="324"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="internalformat" type="GLenum"/> | |||
| <param name="x" type="GLint"/> | |||
| <param name="y" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="border" type="GLint"/> | |||
| <glx rop="4120"/> | |||
| </function> | |||
| <function name="CopyTexSubImage2D" offset="326"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="xoffset" type="GLint"/> | |||
| <param name="yoffset" type="GLint"/> | |||
| <param name="x" type="GLint"/> | |||
| <param name="y" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <glx rop="4122"/> | |||
| </function> | |||
| <function name="DeleteTextures" offset="327"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="textures" type="const GLuint *" count="n"/> | |||
| <glx sop="144"/> | |||
| </function> | |||
| <function name="DrawArrays" offset="310"> | |||
| <param name="mode" type="GLenum"/> | |||
| <param name="first" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <glx rop="193" handcode="true"/> | |||
| </function> | |||
| <function name="DrawElements" offset="311"> | |||
| <param name="mode" type="GLenum"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="indices" type="const GLvoid *"/> | |||
| <glx handcode="true"/> | |||
| </function> | |||
| <function name="GenTextures" offset="328"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="textures" type="GLuint *" output="true" count="n"/> | |||
| <glx sop="145" always_array="true"/> | |||
| </function> | |||
| <function name="PolygonOffset" offset="319"> | |||
| <param name="factor" type="GLfloat"/> | |||
| <param name="units" type="GLfloat"/> | |||
| <glx rop="192"/> | |||
| </function> | |||
| <function name="TexSubImage2D" offset="333"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="xoffset" type="GLint"/> | |||
| <param name="yoffset" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="UNUSED" type="GLuint" padding="true"/> | |||
| <param name="pixels" type="const GLvoid *" img_width="width" img_height="height" img_xoff="xoffset" img_yoff="yoffset" img_format="format" img_type="type" img_target="target" img_pad_dimensions="true"/> | |||
| <glx rop="4100" large="true"/> | |||
| </function> | |||
| <!-- these are not in OpenGL ES 1.0 --> | |||
| <enum name="POLYGON_OFFSET_UNITS" count="1" value="0x2A00"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="POLYGON_OFFSET_FACTOR" count="1" value="0x8038"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="TEXTURE_BINDING_2D" count="1" value="0x8069"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <function name="IsTexture" offset="330"> | |||
| <param name="texture" type="GLuint"/> | |||
| <return type="GLboolean"/> | |||
| <glx sop="146"/> | |||
| </function> | |||
| </category> | |||
| <!-- base subset of OpenGL 1.2 --> | |||
| <category name="base1.2"> | |||
| <enum name="UNSIGNED_SHORT_4_4_4_4" value="0x8033"/> | |||
| <enum name="UNSIGNED_SHORT_5_5_5_1" value="0x8034"/> | |||
| <enum name="CLAMP_TO_EDGE" value="0x812F"/> | |||
| <enum name="UNSIGNED_SHORT_5_6_5" value="0x8363"/> | |||
| <enum name="ALIASED_POINT_SIZE_RANGE" count="2" value="0x846D"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="ALIASED_LINE_WIDTH_RANGE" count="2" value="0x846E"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| </category> | |||
| <!-- base subset of OpenGL 1.3 --> | |||
| <category name="base1.3"> | |||
| <enum name="SAMPLE_ALPHA_TO_COVERAGE" count="1" value="0x809E"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="SAMPLE_COVERAGE" count="1" value="0x80A0"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="TEXTURE0" value="0x84C0"/> | |||
| <enum name="TEXTURE1" value="0x84C1"/> | |||
| <enum name="TEXTURE2" value="0x84C2"/> | |||
| <enum name="TEXTURE3" value="0x84C3"/> | |||
| <enum name="TEXTURE4" value="0x84C4"/> | |||
| <enum name="TEXTURE5" value="0x84C5"/> | |||
| <enum name="TEXTURE6" value="0x84C6"/> | |||
| <enum name="TEXTURE7" value="0x84C7"/> | |||
| <enum name="TEXTURE8" value="0x84C8"/> | |||
| <enum name="TEXTURE9" value="0x84C9"/> | |||
| <enum name="TEXTURE10" value="0x84CA"/> | |||
| <enum name="TEXTURE11" value="0x84CB"/> | |||
| <enum name="TEXTURE12" value="0x84CC"/> | |||
| <enum name="TEXTURE13" value="0x84CD"/> | |||
| <enum name="TEXTURE14" value="0x84CE"/> | |||
| <enum name="TEXTURE15" value="0x84CF"/> | |||
| <enum name="TEXTURE16" value="0x84D0"/> | |||
| <enum name="TEXTURE17" value="0x84D1"/> | |||
| <enum name="TEXTURE18" value="0x84D2"/> | |||
| <enum name="TEXTURE19" value="0x84D3"/> | |||
| <enum name="TEXTURE20" value="0x84D4"/> | |||
| <enum name="TEXTURE21" value="0x84D5"/> | |||
| <enum name="TEXTURE22" value="0x84D6"/> | |||
| <enum name="TEXTURE23" value="0x84D7"/> | |||
| <enum name="TEXTURE24" value="0x84D8"/> | |||
| <enum name="TEXTURE25" value="0x84D9"/> | |||
| <enum name="TEXTURE26" value="0x84DA"/> | |||
| <enum name="TEXTURE27" value="0x84DB"/> | |||
| <enum name="TEXTURE28" value="0x84DC"/> | |||
| <enum name="TEXTURE29" value="0x84DD"/> | |||
| <enum name="TEXTURE30" value="0x84DE"/> | |||
| <enum name="TEXTURE31" value="0x84DF"/> | |||
| <enum name="NUM_COMPRESSED_TEXTURE_FORMATS" count="1" value="0x86A2"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="COMPRESSED_TEXTURE_FORMATS" count="-1" value="0x86A3"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <function name="ActiveTexture" offset="374"> | |||
| <param name="texture" type="GLenum"/> | |||
| <glx rop="197"/> | |||
| </function> | |||
| <function name="CompressedTexImage2D" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="internalformat" type="GLenum"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="border" type="GLint"/> | |||
| <param name="imageSize" type="GLsizei" counter="true"/> | |||
| <param name="data" type="const GLvoid *" count="imageSize"/> | |||
| <glx rop="215" handcode="client"/> | |||
| </function> | |||
| <function name="CompressedTexSubImage2D" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="xoffset" type="GLint"/> | |||
| <param name="yoffset" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="imageSize" type="GLsizei" counter="true"/> | |||
| <param name="data" type="const GLvoid *" count="imageSize"/> | |||
| <glx rop="218" handcode="client"/> | |||
| </function> | |||
| <function name="SampleCoverage" offset="assign"> | |||
| <param name="value" type="GLclampf"/> | |||
| <param name="invert" type="GLboolean"/> | |||
| <glx rop="229"/> | |||
| </function> | |||
| <!-- these are not in OpenGL ES 1.0 --> | |||
| <enum name="SAMPLE_BUFFERS" count="1" value="0x80A8"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="SAMPLES" count="1" value="0x80A9"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="SAMPLE_COVERAGE_VALUE" count="1" value="0x80AA"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="SAMPLE_COVERAGE_INVERT" count="1" value="0x80AB"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="ACTIVE_TEXTURE" count="1" value="0x84E0"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| </category> | |||
| <!-- base subset of OpenGL 1.4 --> | |||
| <category name="base1.4"> | |||
| <enum name="GENERATE_MIPMAP_HINT" value="0x8192"/> | |||
| </category> | |||
| <!-- base subset of OpenGL 1.5 --> | |||
| <category name="base1.5"> | |||
| <enum name="BUFFER_SIZE" value="0x8764"/> | |||
| <enum name="BUFFER_USAGE" value="0x8765"/> | |||
| <enum name="ARRAY_BUFFER" value="0x8892"/> | |||
| <enum name="ELEMENT_ARRAY_BUFFER" value="0x8893"/> | |||
| <enum name="ARRAY_BUFFER_BINDING" value="0x8894"/> | |||
| <enum name="ELEMENT_ARRAY_BUFFER_BINDING" value="0x8895"/> | |||
| <enum name="STATIC_DRAW" value="0x88E4"/> | |||
| <enum name="DYNAMIC_DRAW" value="0x88E8"/> | |||
| <type name="intptr" size="4" glx_name="CARD32"/> | |||
| <type name="sizeiptr" size="4" glx_name="CARD32"/> | |||
| <function name="BindBuffer" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="buffer" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="BufferData" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="size" type="GLsizeiptr" counter="true"/> | |||
| <param name="data" type="const GLvoid *" count="size" img_null_flag="true"/> | |||
| <param name="usage" type="GLenum"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="BufferSubData" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="offset" type="GLintptr"/> | |||
| <param name="size" type="GLsizeiptr" counter="true"/> | |||
| <param name="data" type="const GLvoid *" count="size"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="DeleteBuffers" offset="assign"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="buffer" type="const GLuint *" count="n"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GenBuffers" offset="assign"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="buffer" type="GLuint *" output="true" count="n"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetBufferParameteriv" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true" variable_param="pname"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="IsBuffer" offset="assign"> | |||
| <param name="buffer" type="GLuint"/> | |||
| <return type="GLboolean"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| </category> | |||
| </OpenGLAPI> | |||
| @@ -0,0 +1,533 @@ | |||
| <?xml version="1.0"?> | |||
| <!DOCTYPE OpenGLAPI SYSTEM "../../glapi/gl_API.dtd"> | |||
| <!-- OpenGL and OpenGL ES 2.x APIs --> | |||
| <OpenGLAPI> | |||
| <xi:include href="base1_API.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> | |||
| <!-- base subset of OpenGL 2.0 --> | |||
| <category name="base2.0"> | |||
| <enum name="BLEND_EQUATION_RGB" count="1" value="0x8009"> <!-- same as BLEND_EQUATION --> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="VERTEX_ATTRIB_ARRAY_ENABLED" count="1" value="0x8622"> | |||
| <size name="GetVertexAttribdv" mode="get"/> | |||
| <size name="GetVertexAttribfv" mode="get"/> | |||
| <size name="GetVertexAttribiv" mode="get"/> | |||
| </enum> | |||
| <enum name="VERTEX_ATTRIB_ARRAY_SIZE" count="1" value="0x8623"> | |||
| <size name="GetVertexAttribdv" mode="get"/> | |||
| <size name="GetVertexAttribfv" mode="get"/> | |||
| <size name="GetVertexAttribiv" mode="get"/> | |||
| </enum> | |||
| <enum name="VERTEX_ATTRIB_ARRAY_STRIDE" count="1" value="0x8624"> | |||
| <size name="GetVertexAttribdv" mode="get"/> | |||
| <size name="GetVertexAttribfv" mode="get"/> | |||
| <size name="GetVertexAttribiv" mode="get"/> | |||
| </enum> | |||
| <enum name="VERTEX_ATTRIB_ARRAY_TYPE" count="1" value="0x8625"> | |||
| <size name="GetVertexAttribdv" mode="get"/> | |||
| <size name="GetVertexAttribfv" mode="get"/> | |||
| <size name="GetVertexAttribiv" mode="get"/> | |||
| </enum> | |||
| <enum name="CURRENT_VERTEX_ATTRIB" count="1" value="0x8626"> | |||
| <size name="GetVertexAttribdv" mode="get"/> | |||
| <size name="GetVertexAttribfv" mode="get"/> | |||
| <size name="GetVertexAttribiv" mode="get"/> | |||
| </enum> | |||
| <enum name="VERTEX_ATTRIB_ARRAY_POINTER" value="0x8645"/> | |||
| <enum name="STENCIL_BACK_FUNC" count="1" value="0x8800"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_BACK_FAIL" count="1" value="0x8801"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_BACK_PASS_DEPTH_FAIL" count="1" value="0x8802"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="STENCIL_BACK_PASS_DEPTH_PASS" count="1" value="0x8803"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="BLEND_EQUATION_ALPHA" count="1" value="0x883D"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="MAX_VERTEX_ATTRIBS" count="1" value="0x8869"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="VERTEX_ATTRIB_ARRAY_NORMALIZED" value="0x886A"/> | |||
| <enum name="MAX_TEXTURE_IMAGE_UNITS" count="1" value="0x8872"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="FRAGMENT_SHADER" value="0x8B30"/> | |||
| <enum name="VERTEX_SHADER" value="0x8B31"/> | |||
| <enum name="MAX_VERTEX_TEXTURE_IMAGE_UNITS" value="0x8B4C"/> | |||
| <enum name="MAX_COMBINED_TEXTURE_IMAGE_UNITS" value="0x8B4D"/> | |||
| <enum name="SHADER_TYPE" value="0x8B4F"/> | |||
| <enum name="FLOAT_VEC2" value="0x8B50"/> | |||
| <enum name="FLOAT_VEC3" value="0x8B51"/> | |||
| <enum name="FLOAT_VEC4" value="0x8B52"/> | |||
| <enum name="INT_VEC2" value="0x8B53"/> | |||
| <enum name="INT_VEC3" value="0x8B54"/> | |||
| <enum name="INT_VEC4" value="0x8B55"/> | |||
| <enum name="BOOL" value="0x8B56"/> | |||
| <enum name="BOOL_VEC2" value="0x8B57"/> | |||
| <enum name="BOOL_VEC3" value="0x8B58"/> | |||
| <enum name="BOOL_VEC4" value="0x8B59"/> | |||
| <enum name="FLOAT_MAT2" value="0x8B5A"/> | |||
| <enum name="FLOAT_MAT3" value="0x8B5B"/> | |||
| <enum name="FLOAT_MAT4" value="0x8B5C"/> | |||
| <enum name="SAMPLER_2D" value="0x8B5E"/> | |||
| <enum name="SAMPLER_CUBE" value="0x8B60"/> | |||
| <enum name="DELETE_STATUS" value="0x8B80"/> | |||
| <enum name="COMPILE_STATUS" value="0x8B81"/> | |||
| <enum name="LINK_STATUS" value="0x8B82"/> | |||
| <enum name="VALIDATE_STATUS" value="0x8B83"/> | |||
| <enum name="INFO_LOG_LENGTH" value="0x8B84"/> | |||
| <enum name="ATTACHED_SHADERS" value="0x8B85"/> | |||
| <enum name="ACTIVE_UNIFORMS" value="0x8B86"/> | |||
| <enum name="ACTIVE_UNIFORM_MAX_LENGTH" value="0x8B87"/> | |||
| <enum name="SHADER_SOURCE_LENGTH" value="0x8B88"/> | |||
| <enum name="ACTIVE_ATTRIBUTES" value="0x8B89"/> | |||
| <enum name="ACTIVE_ATTRIBUTE_MAX_LENGTH" value="0x8B8A"/> | |||
| <enum name="SHADING_LANGUAGE_VERSION" value="0x8B8C"/> | |||
| <enum name="CURRENT_PROGRAM" value="0x8B8D"/> | |||
| <enum name="STENCIL_BACK_REF" value="0x8CA3"/> | |||
| <enum name="STENCIL_BACK_VALUE_MASK" value="0x8CA4"/> | |||
| <enum name="STENCIL_BACK_WRITEMASK" value="0x8CA5"/> | |||
| <type name="char" size="1" glx_name="CARD8"/> | |||
| <function name="AttachShader" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="shader" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="BindAttribLocation" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="name" type="const GLchar *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="BlendEquationSeparate" offset="assign"> | |||
| <param name="modeRGB" type="GLenum"/> | |||
| <param name="modeA" type="GLenum"/> | |||
| <glx rop="4228"/> | |||
| </function> | |||
| <function name="CompileShader" offset="assign"> | |||
| <param name="shader" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="CreateProgram" offset="assign"> | |||
| <return type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="CreateShader" offset="assign"> | |||
| <param name="type" type="GLenum"/> | |||
| <return type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="DeleteProgram" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="DeleteShader" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="DetachShader" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="shader" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="DisableVertexAttribArray" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="EnableVertexAttribArray" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetActiveAttrib" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="bufSize" type="GLsizei "/> | |||
| <param name="length" type="GLsizei *" output="true"/> | |||
| <param name="size" type="GLint *" output="true"/> | |||
| <param name="type" type="GLenum *" output="true"/> | |||
| <param name="name" type="GLchar *" output="true"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetActiveUniform" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="bufSize" type="GLsizei"/> | |||
| <param name="length" type="GLsizei *" output="true"/> | |||
| <param name="size" type="GLint *" output="true"/> | |||
| <param name="type" type="GLenum *" output="true"/> | |||
| <param name="name" type="GLchar *" output="true"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetAttachedShaders" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="maxCount" type="GLsizei"/> | |||
| <param name="count" type="GLsizei *" output="true"/> | |||
| <param name="obj" type="GLuint *" output="true"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetAttribLocation" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="name" type="const GLchar *"/> | |||
| <return type="GLint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetProgramiv" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetProgramInfoLog" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="bufSize" type="GLsizei"/> | |||
| <param name="length" type="GLsizei *"/> | |||
| <param name="infoLog" type="GLchar *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetShaderiv" offset="assign"> | |||
| <param name="shader" type="GLuint"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetShaderInfoLog" offset="assign"> | |||
| <param name="shader" type="GLuint"/> | |||
| <param name="bufSize" type="GLsizei"/> | |||
| <param name="length" type="GLsizei *"/> | |||
| <param name="infoLog" type="GLchar *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetShaderSource" offset="assign"> | |||
| <param name="shader" type="GLuint"/> | |||
| <param name="bufSize" type="GLsizei"/> | |||
| <param name="length" type="GLsizei *" output="true"/> | |||
| <param name="source" type="GLchar *" output="true"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetUniformfv" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="location" type="GLint"/> | |||
| <param name="params" type="GLfloat *" output="true"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetUniformiv" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="location" type="GLint"/> | |||
| <param name="params" type="GLint *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetUniformLocation" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <param name="name" type="const GLchar *"/> | |||
| <return type="GLint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetVertexAttribfv" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfloat *" output="true" variable_param="pname"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetVertexAttribiv" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true" variable_param="pname"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="GetVertexAttribPointerv" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="pointer" type="GLvoid **" output="true"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="IsProgram" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <return type="GLboolean"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="IsShader" offset="assign"> | |||
| <param name="shader" type="GLuint"/> | |||
| <return type="GLboolean"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="LinkProgram" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="ShaderSource" offset="assign"> | |||
| <param name="shader" type="GLuint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="string" type="const GLchar **"/> | |||
| <param name="length" type="const GLint *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="StencilFuncSeparate" offset="assign"> | |||
| <param name="face" type="GLenum"/> | |||
| <param name="func" type="GLenum"/> | |||
| <param name="ref" type="GLint"/> | |||
| <param name="mask" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="StencilOpSeparate" offset="assign"> | |||
| <param name="face" type="GLenum"/> | |||
| <param name="sfail" type="GLenum"/> | |||
| <param name="zfail" type="GLenum"/> | |||
| <param name="zpass" type="GLenum"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="StencilMaskSeparate" offset="assign"> | |||
| <param name="face" type="GLenum"/> | |||
| <param name="mask" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform1f" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="v0" type="GLfloat"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform1fv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="value" type="const GLfloat *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform1i" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="v0" type="GLint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform1iv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="value" type="const GLint *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform2f" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="v0" type="GLfloat"/> | |||
| <param name="v1" type="GLfloat"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform2fv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="value" type="const GLfloat *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform2i" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="v0" type="GLint"/> | |||
| <param name="v1" type="GLint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform2iv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="value" type="const GLint *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform3f" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="v0" type="GLfloat"/> | |||
| <param name="v1" type="GLfloat"/> | |||
| <param name="v2" type="GLfloat"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform3fv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="value" type="const GLfloat *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform3i" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="v0" type="GLint"/> | |||
| <param name="v1" type="GLint"/> | |||
| <param name="v2" type="GLint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform3iv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="value" type="const GLint *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform4f" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="v0" type="GLfloat"/> | |||
| <param name="v1" type="GLfloat"/> | |||
| <param name="v2" type="GLfloat"/> | |||
| <param name="v3" type="GLfloat"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform4fv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="value" type="const GLfloat *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform4i" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="v0" type="GLint"/> | |||
| <param name="v1" type="GLint"/> | |||
| <param name="v2" type="GLint"/> | |||
| <param name="v3" type="GLint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="Uniform4iv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="value" type="const GLint *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="UniformMatrix2fv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="transpose" type="GLboolean"/> | |||
| <param name="value" type="const GLfloat *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="UniformMatrix3fv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="transpose" type="GLboolean"/> | |||
| <param name="value" type="const GLfloat *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="UniformMatrix4fv" offset="assign"> | |||
| <param name="location" type="GLint"/> | |||
| <param name="count" type="GLsizei"/> | |||
| <param name="transpose" type="GLboolean"/> | |||
| <param name="value" type="const GLfloat *"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="UseProgram" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="ValidateProgram" offset="assign"> | |||
| <param name="program" type="GLuint"/> | |||
| <glx ignore="true"/> | |||
| </function> | |||
| <function name="VertexAttrib1f" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="x" type="GLfloat"/> | |||
| </function> | |||
| <function name="VertexAttrib1fv" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="v" type="const GLfloat *"/> | |||
| </function> | |||
| <function name="VertexAttrib2f" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="x" type="GLfloat"/> | |||
| <param name="y" type="GLfloat"/> | |||
| </function> | |||
| <function name="VertexAttrib2fv" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="v" type="const GLfloat *"/> | |||
| </function> | |||
| <function name="VertexAttrib3f" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="x" type="GLfloat"/> | |||
| <param name="y" type="GLfloat"/> | |||
| <param name="z" type="GLfloat"/> | |||
| </function> | |||
| <function name="VertexAttrib3fv" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="v" type="const GLfloat *"/> | |||
| </function> | |||
| <function name="VertexAttrib4f" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="x" type="GLfloat"/> | |||
| <param name="y" type="GLfloat"/> | |||
| <param name="z" type="GLfloat"/> | |||
| <param name="w" type="GLfloat"/> | |||
| </function> | |||
| <function name="VertexAttrib4fv" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="v" type="const GLfloat *"/> | |||
| </function> | |||
| <function name="VertexAttribPointer" offset="assign"> | |||
| <param name="index" type="GLuint"/> | |||
| <param name="size" type="GLint"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="normalized" type="GLboolean"/> | |||
| <param name="stride" type="GLsizei"/> | |||
| <param name="pointer" type="const GLvoid *"/> | |||
| </function> | |||
| </category> | |||
| </OpenGLAPI> | |||
| @@ -0,0 +1,135 @@ | |||
| <?xml version="1.0"?> | |||
| <!DOCTYPE OpenGLAPI SYSTEM "../../glapi/gl_API.dtd"> | |||
| <OpenGLAPI> | |||
| <!-- This file defines the functions that are needed by Mesa. It | |||
| makes sure the generated glapi headers are compatible with Mesa. | |||
| It mainly consists of missing functions and aliases in OpenGL ES. | |||
| --> | |||
| <xi:include href="es_COMPAT.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> | |||
| <!-- except for those defined by es_COMPAT.xml, these are also needed --> | |||
| <category name="compat"> | |||
| <!-- OpenGL 1.0 --> | |||
| <function name="TexGenf" alias="TexGenfOES" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfloat"/> | |||
| <glx rop="117"/> | |||
| </function> | |||
| <function name="TexGenfv" alias="TexGenfvOES" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfloat *" variable_param="pname"/> | |||
| <glx rop="118"/> | |||
| </function> | |||
| <function name="TexGeni" alias="TexGeniOES" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLint"/> | |||
| <glx rop="119"/> | |||
| </function> | |||
| <function name="TexGeniv" alias="TexGenivOES" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLint *" variable_param="pname"/> | |||
| <glx rop="120"/> | |||
| </function> | |||
| <function name="GetTexGenfv" alias="GetTexGenfvOES" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfloat *" output="true" variable_param="pname"/> | |||
| <glx sop="133"/> | |||
| </function> | |||
| <function name="GetTexGeniv" alias="GetTexGenivOES" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true" variable_param="pname"/> | |||
| <glx sop="134"/> | |||
| </function> | |||
| <!-- OpenGL 1.2 --> | |||
| <function name="BlendColor" offset="336" static_dispatch="false"> | |||
| <param name="red" type="GLclampf"/> | |||
| <param name="green" type="GLclampf"/> | |||
| <param name="blue" type="GLclampf"/> | |||
| <param name="alpha" type="GLclampf"/> | |||
| <glx rop="4096"/> | |||
| </function> | |||
| <function name="BlendEquation" alias="BlendEquationOES" static_dispatch="false"> | |||
| <param name="mode" type="GLenum"/> | |||
| <glx rop="4097"/> | |||
| </function> | |||
| <function name="TexImage3D" offset="371" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="internalformat" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="depth" type="GLsizei"/> | |||
| <param name="border" type="GLint"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="pixels" type="const GLvoid *" img_width="width" img_height="height" img_depth="depth" img_format="format" img_type="type" img_target="target" img_null_flag="true" img_pad_dimensions="true"/> | |||
| <glx rop="4114" large="true"/> | |||
| </function> | |||
| <function name="TexSubImage3D" offset="372" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="xoffset" type="GLint"/> | |||
| <param name="yoffset" type="GLint"/> | |||
| <param name="zoffset" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="depth" type="GLsizei"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="UNUSED" type="GLuint" padding="true"/> | |||
| <param name="pixels" type="const GLvoid *" img_width="width" img_height="height" img_depth="depth" img_xoff="xoffset" img_yoff="yoffset" img_zoff="zoffset" img_format="format" img_type="type" img_target="target" img_pad_dimensions="true"/> | |||
| <glx rop="4115" large="true"/> | |||
| </function> | |||
| <function name="CopyTexSubImage3D" offset="373" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="xoffset" type="GLint"/> | |||
| <param name="yoffset" type="GLint"/> | |||
| <param name="zoffset" type="GLint"/> | |||
| <param name="x" type="GLint"/> | |||
| <param name="y" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <glx rop="4123"/> | |||
| </function> | |||
| <!-- GL_ARB_multitexture --> | |||
| <function name="ActiveTextureARB" alias="ActiveTexture" static_dispatch="false"> | |||
| <param name="texture" type="GLenum"/> | |||
| <glx rop="197"/> | |||
| </function> | |||
| <function name="ClientActiveTextureARB" alias="ClientActiveTexture" static_dispatch="false"> | |||
| <param name="texture" type="GLenum"/> | |||
| <glx handcode="true"/> | |||
| </function> | |||
| <function name="MultiTexCoord4fARB" alias="MultiTexCoord4f" vectorequiv="MultiTexCoord4fvARB" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="s" type="GLfloat"/> | |||
| <param name="t" type="GLfloat"/> | |||
| <param name="r" type="GLfloat"/> | |||
| <param name="q" type="GLfloat"/> | |||
| </function> | |||
| </category> | |||
| </OpenGLAPI> | |||
| @@ -0,0 +1,693 @@ | |||
| <?xml version="1.0"?> | |||
| <!DOCTYPE OpenGLAPI SYSTEM "../../glapi/gl_API.dtd"> | |||
| <!-- OpenGL ES 1.x extensions --> | |||
| <OpenGLAPI> | |||
| <xi:include href="es_EXT.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> | |||
| <!-- part of es1.1 extension pack --> | |||
| <category name="GL_OES_blend_equation_separate" number="1"> | |||
| <enum name="BLEND_EQUATION_RGB_OES" count="1" value="0x8009"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="BLEND_EQUATION_ALPHA_OES" count="1" value="0x883D"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <function name="BlendEquationSeparateOES" offset="assign"> | |||
| <param name="modeRGB" type="GLenum"/> | |||
| <param name="modeA" type="GLenum"/> | |||
| <glx rop="4228"/> | |||
| </function> | |||
| </category> | |||
| <!-- part of es1.1 extension pack --> | |||
| <category name="GL_OES_blend_func_separate" number="2"> | |||
| <enum name="BLEND_DST_RGB_OES" count="1" value="0x80C8"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="BLEND_SRC_RGB_OES" count="1" value="0x80C9"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="BLEND_DST_ALPHA_OES" count="1" value="0x80CA"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="BLEND_SRC_ALPHA_OES" count="1" value="0x80CB"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <function name="BlendFuncSeparateOES" offset="assign"> | |||
| <param name="sfactorRGB" type="GLenum"/> | |||
| <param name="dfactorRGB" type="GLenum"/> | |||
| <param name="sfactorAlpha" type="GLenum"/> | |||
| <param name="dfactorAlpha" type="GLenum"/> | |||
| <glx rop="4134"/> | |||
| </function> | |||
| </category> | |||
| <!-- part of es1.1 extension pack --> | |||
| <category name="GL_OES_blend_subtract" number="3"> | |||
| <enum name="FUNC_ADD_OES" value="0x8006"/> | |||
| <enum name="BLEND_EQUATION_OES" count="1" value="0x8009"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="FUNC_SUBTRACT_OES" value="0x800A"/> | |||
| <enum name="FUNC_REVERSE_SUBTRACT_OES" value="0x800B"/> | |||
| <function name="BlendEquationOES" offset="337"> | |||
| <param name="mode" type="GLenum"/> | |||
| <glx rop="4097"/> | |||
| </function> | |||
| </category> | |||
| <!-- core addition to es1.0 and later --> | |||
| <category name="GL_OES_byte_coordinates" number="4"> | |||
| <enum name="BYTE" value="0x1400"/> | |||
| </category> | |||
| <!-- optional for es1.1 --> | |||
| <category name="GL_OES_draw_texture" number="7"> | |||
| <enum name="TEXTURE_CROP_RECT_OES" value="0x8B9D"/> | |||
| <function name="DrawTexiOES" offset="assign"> | |||
| <param name="x" type="GLint"/> | |||
| <param name="y" type="GLint"/> | |||
| <param name="z" type="GLint"/> | |||
| <param name="width" type="GLint"/> | |||
| <param name="height" type="GLint"/> | |||
| </function> | |||
| <function name="DrawTexivOES" offset="assign"> | |||
| <param name="coords" type="const GLint *" count="5"/> | |||
| </function> | |||
| <function name="DrawTexfOES" offset="assign"> | |||
| <param name="x" type="GLfloat"/> | |||
| <param name="y" type="GLfloat"/> | |||
| <param name="z" type="GLfloat"/> | |||
| <param name="width" type="GLfloat"/> | |||
| <param name="height" type="GLfloat"/> | |||
| </function> | |||
| <function name="DrawTexfvOES" offset="assign"> | |||
| <param name="coords" type="const GLfloat *" count="5"/> | |||
| </function> | |||
| <function name="DrawTexsOES" offset="assign"> | |||
| <param name="x" type="GLshort"/> | |||
| <param name="y" type="GLshort"/> | |||
| <param name="z" type="GLshort"/> | |||
| <param name="width" type="GLshort"/> | |||
| <param name="height" type="GLshort"/> | |||
| </function> | |||
| <function name="DrawTexsvOES" offset="assign"> | |||
| <param name="coords" type="const GLshort *" count="5"/> | |||
| </function> | |||
| <function name="DrawTexxOES" offset="assign"> | |||
| <param name="x" type="GLfixed"/> | |||
| <param name="y" type="GLfixed"/> | |||
| <param name="z" type="GLfixed"/> | |||
| <param name="width" type="GLfixed"/> | |||
| <param name="height" type="GLfixed"/> | |||
| </function> | |||
| <function name="DrawTexxvOES" offset="assign"> | |||
| <param name="coords" type="const GLfixed *" count="5"/> | |||
| </function> | |||
| <!-- TexParameter{ifx}v is skipped here --> | |||
| </category> | |||
| <!-- core addition to es1.0 and later --> | |||
| <category name="GL_OES_fixed_point" number="9"> | |||
| <enum name="FIXED_OES" value="0x140C"/> | |||
| <!-- additon to es1.0 --> | |||
| <function name="AlphaFuncxOES" alias="AlphaFuncx"> | |||
| <param name="func" type="GLenum"/> | |||
| <param name="ref" type="GLclampx"/> | |||
| </function> | |||
| <function name="ClearColorxOES" alias="ClearColorx"> | |||
| <param name="red" type="GLclampx"/> | |||
| <param name="green" type="GLclampx"/> | |||
| <param name="blue" type="GLclampx"/> | |||
| <param name="alpha" type="GLclampx"/> | |||
| </function> | |||
| <function name="ClearDepthxOES" alias="ClearDepthx"> | |||
| <param name="depth" type="GLclampx"/> | |||
| </function> | |||
| <function name="Color4xOES" alias="Color4x"> | |||
| <param name="red" type="GLfixed"/> | |||
| <param name="green" type="GLfixed"/> | |||
| <param name="blue" type="GLfixed"/> | |||
| <param name="alpha" type="GLfixed"/> | |||
| </function> | |||
| <function name="DepthRangexOES" alias="DepthRangex"> | |||
| <param name="zNear" type="GLclampx"/> | |||
| <param name="zFar" type="GLclampx"/> | |||
| </function> | |||
| <function name="FogxOES" alias="Fogx"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfixed"/> | |||
| </function> | |||
| <function name="FogxvOES" alias="Fogxv"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfixed *" variable_param="pname"/> | |||
| </function> | |||
| <function name="FrustumxOES" alias="Frustumx"> | |||
| <param name="left" type="GLfixed"/> | |||
| <param name="right" type="GLfixed"/> | |||
| <param name="bottom" type="GLfixed"/> | |||
| <param name="top" type="GLfixed"/> | |||
| <param name="zNear" type="GLfixed"/> | |||
| <param name="zFar" type="GLfixed"/> | |||
| </function> | |||
| <function name="LightModelxOES" alias="LightModelx"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfixed"/> | |||
| </function> | |||
| <function name="LightModelxvOES" alias="LightModelxv"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfixed *" variable_param="pname"/> | |||
| </function> | |||
| <function name="LightxOES" alias="Lightx"> | |||
| <param name="light" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfixed"/> | |||
| </function> | |||
| <function name="LightxvOES" alias="Lightxv"> | |||
| <param name="light" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfixed *" variable_param="pname"/> | |||
| </function> | |||
| <function name="LineWidthxOES" alias="LineWidthx"> | |||
| <param name="width" type="GLfixed"/> | |||
| </function> | |||
| <function name="LoadMatrixxOES" alias="LoadMatrixx"> | |||
| <param name="m" type="const GLfixed *" count="16"/> | |||
| </function> | |||
| <function name="MaterialxOES" alias="Materialx"> | |||
| <param name="face" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfixed"/> | |||
| </function> | |||
| <function name="MaterialxvOES" alias="Materialxv"> | |||
| <param name="face" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfixed *" variable_param="pname"/> | |||
| </function> | |||
| <function name="MultiTexCoord4xOES" alias="MultiTexCoord4x"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="s" type="GLfixed"/> | |||
| <param name="t" type="GLfixed"/> | |||
| <param name="r" type="GLfixed"/> | |||
| <param name="q" type="GLfixed"/> | |||
| </function> | |||
| <function name="MultMatrixxOES" alias="MultMatrixx"> | |||
| <param name="m" type="const GLfixed *" count="16"/> | |||
| </function> | |||
| <function name="Normal3xOES" alias="Normal3x"> | |||
| <param name="nx" type="GLfixed"/> | |||
| <param name="ny" type="GLfixed"/> | |||
| <param name="nz" type="GLfixed"/> | |||
| </function> | |||
| <function name="OrthoxOES" alias="Orthox"> | |||
| <param name="left" type="GLfixed"/> | |||
| <param name="right" type="GLfixed"/> | |||
| <param name="bottom" type="GLfixed"/> | |||
| <param name="top" type="GLfixed"/> | |||
| <param name="zNear" type="GLfixed"/> | |||
| <param name="zFar" type="GLfixed"/> | |||
| </function> | |||
| <function name="PointSizexOES" alias="PointSizex"> | |||
| <param name="size" type="GLfixed"/> | |||
| </function> | |||
| <function name="PolygonOffsetxOES" alias="PolygonOffsetx"> | |||
| <param name="factor" type="GLfixed"/> | |||
| <param name="units" type="GLfixed"/> | |||
| </function> | |||
| <function name="RotatexOES" alias="Rotatex"> | |||
| <param name="angle" type="GLfixed"/> | |||
| <param name="x" type="GLfixed"/> | |||
| <param name="y" type="GLfixed"/> | |||
| <param name="z" type="GLfixed"/> | |||
| </function> | |||
| <function name="SampleCoveragexOES" alias="SampleCoveragex"> | |||
| <param name="value" type="GLclampx"/> | |||
| <param name="invert" type="GLboolean"/> | |||
| </function> | |||
| <function name="ScalexOES" alias="Scalex"> | |||
| <param name="x" type="GLfixed"/> | |||
| <param name="y" type="GLfixed"/> | |||
| <param name="z" type="GLfixed"/> | |||
| </function> | |||
| <function name="TexEnvxOES" alias="TexEnvx"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfixed"/> | |||
| </function> | |||
| <function name="TexEnvxvOES" alias="TexEnvxv"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfixed *" variable_param="pname"/> | |||
| </function> | |||
| <function name="TexParameterxOES" alias="TexParameterx"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfixed"/> | |||
| </function> | |||
| <function name="TranslatexOES" alias="Translatex"> | |||
| <param name="x" type="GLfixed"/> | |||
| <param name="y" type="GLfixed"/> | |||
| <param name="z" type="GLfixed"/> | |||
| </function> | |||
| <!-- additon to es1.1 --> | |||
| <function name="ClipPlanexOES" alias="ClipPlanex"> | |||
| <param name="plane" type="GLenum"/> | |||
| <param name="equation" type="const GLfixed *" count="4"/> | |||
| </function> | |||
| <function name="GetClipPlanexOES" alias="GetClipPlanex"> | |||
| <param name="plane" type="GLenum"/> | |||
| <param name="equation" type="GLfixed *" output="true" count="4"/> | |||
| </function> | |||
| <function name="GetFixedvOES" alias="GetFixedv"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfixed *" output="true" variable_param="pname"/> | |||
| </function> | |||
| <function name="GetLightxvOES" alias="GetLightxv"> | |||
| <param name="light" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfixed *" output="true" variable_param="pname"/> | |||
| </function> | |||
| <function name="GetMaterialxvOES" alias="GetMaterialxv"> | |||
| <param name="face" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfixed *" output="true" variable_param="pname"/> | |||
| </function> | |||
| <function name="GetTexEnvxvOES" alias="GetTexEnvxv"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfixed *" output="true" variable_param="pname"/> | |||
| </function> | |||
| <function name="GetTexParameterxvOES" alias="GetTexParameterxv"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfixed *" output="true" variable_param="pname"/> | |||
| </function> | |||
| <function name="PointParameterxOES" alias="PointParameterx"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfixed"/> | |||
| </function> | |||
| <function name="PointParameterxvOES" alias="PointParameterxv"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfixed *"/> | |||
| </function> | |||
| <function name="TexParameterxvOES" alias="TexParameterxv"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfixed *" variable_param="pname"/> | |||
| </function> | |||
| </category> | |||
| <!-- part of es1.1 extension pack --> | |||
| <category name="GL_OES_framebuffer_object" number="10"> | |||
| <enum name="NONE_OES" value="0"/> | |||
| <enum name="INVALID_FRAMEBUFFER_OPERATION_OES" value="0x0506"/> | |||
| <enum name="RGBA4_OES" value="0x8056"/> | |||
| <enum name="RGB5_A1_OES" value="0x8057"/> | |||
| <enum name="DEPTH_COMPONENT16_OES" value="0x81A5"/> | |||
| <enum name="MAX_RENDERBUFFER_SIZE_OES" value="0x84E8"/> | |||
| <enum name="FRAMEBUFFER_BINDING_OES" value="0x8CA6"/> | |||
| <enum name="RENDERBUFFER_BINDING_OES" value="0x8CA7"/> | |||
| <enum name="FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_OES" value="0x8CD0"/> | |||
| <enum name="FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_OES" value="0x8CD1"/> | |||
| <enum name="FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_OES" value="0x8CD2"/> | |||
| <enum name="FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_OES" value="0x8CD3"/> | |||
| <enum name="FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_OES" value="0x8CD4"/> | |||
| <enum name="FRAMEBUFFER_COMPLETE_OES" value="0x8CD5"/> | |||
| <enum name="FRAMEBUFFER_INCOMPLETE_ATTACHMENT_OES" value="0x8CD6"/> | |||
| <enum name="FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_OES" value="0x8CD7"/> | |||
| <enum name="FRAMEBUFFER_INCOMPLETE_DIMENSIONS_OES" value="0x8CD9"/> | |||
| <enum name="FRAMEBUFFER_INCOMPLETE_FORMATS_OES" value="0x8CDA"/> | |||
| <enum name="FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_OES" value="0x8CDB"/> | |||
| <enum name="FRAMEBUFFER_INCOMPLETE_READ_BUFFER_OES" value="0x8CDC"/> | |||
| <enum name="FRAMEBUFFER_UNSUPPORTED_OES" value="0x8CDD"/> | |||
| <enum name="COLOR_ATTACHMENT0_OES" value="0x8CE0"/> | |||
| <enum name="DEPTH_ATTACHMENT_OES" value="0x8D00"/> | |||
| <enum name="STENCIL_ATTACHMENT_OES" value="0x8D20"/> | |||
| <enum name="FRAMEBUFFER_OES" value="0x8D40"/> | |||
| <enum name="RENDERBUFFER_OES" value="0x8D41"/> | |||
| <enum name="RENDERBUFFER_WIDTH_OES" value="0x8D42"/> | |||
| <enum name="RENDERBUFFER_HEIGHT_OES" value="0x8D43"/> | |||
| <enum name="RENDERBUFFER_INTERNAL_FORMAT_OES" value="0x8D44"/> | |||
| <enum name="STENCIL_INDEX1_OES" value="0x8D46"/> | |||
| <enum name="STENCIL_INDEX4_OES" value="0x8D47"/> | |||
| <enum name="STENCIL_INDEX8_OES" value="0x8D48"/> | |||
| <enum name="RENDERBUFFER_RED_SIZE_OES" value="0x8D50"/> | |||
| <enum name="RENDERBUFFER_GREEN_SIZE_OES" value="0x8D51"/> | |||
| <enum name="RENDERBUFFER_BLUE_SIZE_OES" value="0x8D52"/> | |||
| <enum name="RENDERBUFFER_ALPHA_SIZE_OES" value="0x8D53"/> | |||
| <enum name="RENDERBUFFER_DEPTH_SIZE_OES" value="0x8D54"/> | |||
| <enum name="RENDERBUFFER_STENCIL_SIZE_OES" value="0x8D55"/> | |||
| <enum name="RGB565_OES" value="0x8D62"/> | |||
| <function name="BindFramebufferOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="framebuffer" type="GLuint"/> | |||
| </function> | |||
| <function name="BindRenderbufferOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="renderbuffer" type="GLuint"/> | |||
| </function> | |||
| <function name="CheckFramebufferStatusOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <return type="GLenum"/> | |||
| </function> | |||
| <function name="DeleteFramebuffersOES" offset="assign"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="framebuffers" type="const GLuint *" count="n"/> | |||
| </function> | |||
| <function name="DeleteRenderbuffersOES" offset="assign"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="renderbuffers" type="const GLuint *" count="n"/> | |||
| </function> | |||
| <function name="FramebufferRenderbufferOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="attachment" type="GLenum"/> | |||
| <param name="renderbuffertarget" type="GLenum"/> | |||
| <param name="renderbuffer" type="GLuint"/> | |||
| </function> | |||
| <function name="FramebufferTexture2DOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="attachment" type="GLenum"/> | |||
| <param name="textarget" type="GLenum"/> | |||
| <param name="texture" type="GLuint"/> | |||
| <param name="level" type="GLint"/> | |||
| </function> | |||
| <function name="GenerateMipmapOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| </function> | |||
| <function name="GenFramebuffersOES" offset="assign"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="framebuffers" type="GLuint *" count="n" output="true"/> | |||
| </function> | |||
| <function name="GenRenderbuffersOES" offset="assign"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="renderbuffers" type="GLuint *" count="n" output="true"/> | |||
| </function> | |||
| <function name="GetFramebufferAttachmentParameterivOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="attachment" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true"/> | |||
| </function> | |||
| <function name="GetRenderbufferParameterivOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true"/> | |||
| </function> | |||
| <function name="IsFramebufferOES" offset="assign"> | |||
| <param name="framebuffer" type="GLuint"/> | |||
| <return type="GLboolean"/> | |||
| </function> | |||
| <function name="IsRenderbufferOES" offset="assign"> | |||
| <param name="renderbuffer" type="GLuint"/> | |||
| <return type="GLboolean"/> | |||
| </function> | |||
| <function name="RenderbufferStorageOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="internalformat" type="GLenum"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| </function> | |||
| </category> | |||
| <!-- core addition to es1.1 --> | |||
| <category name="GL_OES_matrix_get" number="11"> | |||
| <enum name="MODELVIEW_MATRIX_FLOAT_AS_INT_BITS_OES" value="0x898D"/> | |||
| <enum name="PROJECTION_MATRIX_FLOAT_AS_INT_BITS_OES" value="0x898E"/> | |||
| <enum name="TEXTURE_MATRIX_FLOAT_AS_INT_BITS_OES" value="0x898F"/> | |||
| </category> | |||
| <!-- optional for es1.1 --> | |||
| <category name="GL_OES_matrix_palette" number="12"> | |||
| <enum name="MAX_VERTEX_UNITS_OES" value="0x86A4"/> | |||
| <enum name="WEIGHT_ARRAY_TYPE_OES" value="0x86A9"/> | |||
| <enum name="WEIGHT_ARRAY_STRIDE_OES" value="0x86AA"/> | |||
| <enum name="WEIGHT_ARRAY_SIZE_OES" value="0x86AB"/> | |||
| <enum name="WEIGHT_ARRAY_POINTER_OES" value="0x86AC"/> | |||
| <enum name="WEIGHT_ARRAY_OES" value="0x86AD"/> | |||
| <enum name="MATRIX_PALETTE_OES" value="0x8840"/> | |||
| <enum name="MAX_PALETTE_MATRICES_OES" value="0x8842"/> | |||
| <enum name="CURRENT_PALETTE_MATRIX_OES" value="0x8843"/> | |||
| <enum name="MATRIX_INDEX_ARRAY_OES" value="0x8844"/> | |||
| <enum name="MATRIX_INDEX_ARRAY_SIZE_OES" value="0x8846"/> | |||
| <enum name="MATRIX_INDEX_ARRAY_TYPE_OES" value="0x8847"/> | |||
| <enum name="MATRIX_INDEX_ARRAY_STRIDE_OES" value="0x8848"/> | |||
| <enum name="MATRIX_INDEX_ARRAY_POINTER_OES" value="0x8849"/> | |||
| <enum name="WEIGHT_ARRAY_BUFFER_BINDING_OES" value="0x889E"/> | |||
| <enum name="MATRIX_INDEX_ARRAY_BUFFER_BINDING_OES" value="0x8B9E"/> | |||
| <function name="CurrentPaletteMatrixOES"> | |||
| <param name="matrixpaletteindex" type="GLuint"/> | |||
| </function> | |||
| <function name="LoadPaletteFromModelViewMatrixOES"> | |||
| </function> | |||
| <function name="MatrixIndexPointerOES"> | |||
| <param name="size" type="GLint"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="stride" type="GLsizei"/> | |||
| <param name="pointer" type="const GLvoid *"/> | |||
| </function> | |||
| <function name="WeightPointerOES"> | |||
| <param name="size" type="GLint"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="stride" type="GLsizei"/> | |||
| <param name="pointer" type="const GLvoid *"/> | |||
| </function> | |||
| </category> | |||
| <!-- required for es1.1 --> | |||
| <category name="GL_OES_point_size_array" number="14"> | |||
| <enum name="POINT_SIZE_ARRAY_TYPE_OES" value="0x898A"/> | |||
| <enum name="POINT_SIZE_ARRAY_STRIDE_OES" value="0x898B"/> | |||
| <enum name="POINT_SIZE_ARRAY_POINTER_OES" value="0x898C"/> | |||
| <enum name="POINT_SIZE_ARRAY_OES" value="0x8B9C"/> | |||
| <enum name="POINT_SIZE_ARRAY_BUFFER_BINDING_OES" value="0x8B9F"/> | |||
| <function name="PointSizePointerOES" offset="assign"> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="stride" type="GLsizei"/> | |||
| <param name="pointer" type="const GLvoid *"/> | |||
| </function> | |||
| </category> | |||
| <!-- required for es1.1 --> | |||
| <category name="GL_OES_point_sprite" number="15"> | |||
| <enum name="POINT_SPRITE_OES" value="0x8861"/> | |||
| <enum name="COORD_REPLACE_OES" value="0x8862"/> | |||
| </category> | |||
| <!-- optional for es1.0 --> | |||
| <category name="GL_OES_query_matrix" number="16"> | |||
| <function name="QueryMatrixxOES" offset="assign"> | |||
| <param name="mantissa" type="GLfixed *" count="16" /> | |||
| <param name="exponent" type="GLint *" count="16" /> | |||
| <return type="GLbitfield"/> | |||
| </function> | |||
| </category> | |||
| <!-- required for es1.0 and later --> | |||
| <category name="GL_OES_read_format" number="17"> | |||
| <enum name="IMPLEMENTATION_COLOR_READ_TYPE_OES" value="0x8B9A"/> | |||
| <enum name="IMPLEMENTATION_COLOR_READ_FORMAT_OES" value="0x8B9B"/> | |||
| </category> | |||
| <!-- core addition to es1.0 and later --> | |||
| <category name="GL_OES_single_precision" number="18"> | |||
| <!-- additon to es1.0 --> | |||
| <function name="ClearDepthfOES" alias="ClearDepthf"> | |||
| <param name="depth" type="GLclampf"/> | |||
| </function> | |||
| <function name="DepthRangefOES" alias="DepthRangef"> | |||
| <param name="zNear" type="GLclampf"/> | |||
| <param name="zFar" type="GLclampf"/> | |||
| </function> | |||
| <function name="FrustumfOES" alias="Frustumf"> | |||
| <param name="left" type="GLfloat"/> | |||
| <param name="right" type="GLfloat"/> | |||
| <param name="bottom" type="GLfloat"/> | |||
| <param name="top" type="GLfloat"/> | |||
| <param name="zNear" type="GLfloat"/> | |||
| <param name="zFar" type="GLfloat"/> | |||
| </function> | |||
| <function name="OrthofOES" alias="Orthof"> | |||
| <param name="left" type="GLfloat"/> | |||
| <param name="right" type="GLfloat"/> | |||
| <param name="bottom" type="GLfloat"/> | |||
| <param name="top" type="GLfloat"/> | |||
| <param name="zNear" type="GLfloat"/> | |||
| <param name="zFar" type="GLfloat"/> | |||
| </function> | |||
| <!-- additon to es1.1 --> | |||
| <function name="ClipPlanefOES" alias="ClipPlanef"> | |||
| <param name="plane" type="GLenum"/> | |||
| <param name="equation" type="const GLfloat *" count="4"/> | |||
| </function> | |||
| <function name="GetClipPlanefOES" alias="GetClipPlanef"> | |||
| <param name="plane" type="GLenum"/> | |||
| <param name="equation" type="GLfloat *" output="true" count="4"/> | |||
| </function> | |||
| </category> | |||
| <!-- part of es1.1 extension pack --> | |||
| <category name="GL_OES_texture_cube_map" number="20"> | |||
| <enum name="GL_TEXTURE_GEN_MODE_OES" value="0x2500"/> | |||
| <enum name="GL_NORMAL_MAP_OES" value="0x8511"/> | |||
| <enum name="GL_REFLECTION_MAP_OES" value="0x8512"/> | |||
| <enum name="GL_TEXTURE_CUBE_MAP_OES" value="0x8513"/> | |||
| <enum name="GL_TEXTURE_BINDING_CUBE_MAP_OES" value="0x8514"/> | |||
| <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_X_OES" value="0x8515"/> | |||
| <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_X_OES" value="0x8516"/> | |||
| <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Y_OES" value="0x8517"/> | |||
| <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_OES" value="0x8518"/> | |||
| <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Z_OES" value="0x8519"/> | |||
| <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_OES" value="0x851A"/> | |||
| <enum name="GL_MAX_CUBE_MAP_TEXTURE_SIZE_OES" value="0x851C"/> | |||
| <enum name="GL_TEXTURE_GEN_STR_OES" value="0x8D60"/> | |||
| <function name="GetTexGenfvOES" offset="279"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfloat *" output="true" variable_param="pname"/> | |||
| <glx sop="133"/> | |||
| </function> | |||
| <function name="GetTexGenivOES" offset="280"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true" variable_param="pname"/> | |||
| <glx sop="134"/> | |||
| </function> | |||
| <function name="GetTexGenxvOES" offset="assign"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfixed *" output="true" variable_param="pname"/> | |||
| </function> | |||
| <function name="TexGenfOES" offset="190"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfloat"/> | |||
| <glx rop="117"/> | |||
| </function> | |||
| <function name="TexGenfvOES" offset="191"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfloat *" variable_param="pname"/> | |||
| <glx rop="118"/> | |||
| </function> | |||
| <function name="TexGeniOES" offset="192"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLint"/> | |||
| <glx rop="119"/> | |||
| </function> | |||
| <function name="TexGenivOES" offset="193"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLint *" variable_param="pname"/> | |||
| <glx rop="120"/> | |||
| </function> | |||
| <function name="TexGenxOES" offset="assign"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLint"/> | |||
| </function> | |||
| <function name="TexGenxvOES" offset="assign"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfixed *" variable_param="pname"/> | |||
| </function> | |||
| </category> | |||
| <category name="GL_OES_texture_env_crossbar" number="21"> | |||
| <!-- No new functions, types, enums. --> | |||
| </category> | |||
| <category name="GL_OES_texture_mirrored_repeat" number="22"> | |||
| <!-- No new functions, types, enums. --> | |||
| </category> | |||
| </OpenGLAPI> | |||
| @@ -0,0 +1,294 @@ | |||
| <?xml version="1.0"?> | |||
| <!DOCTYPE OpenGLAPI SYSTEM "../../glapi/gl_API.dtd"> | |||
| <!-- OpenGL ES 2.x API --> | |||
| <OpenGLAPI> | |||
| <xi:include href="base2_API.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> | |||
| <!-- core subset of OpenGL 2.0 defined in OpenGL ES 2.0 --> | |||
| <category name="core2.0"> | |||
| <!-- addition to base1.0 --> | |||
| <enum name="NONE" value="0x0"/> | |||
| <enum name="INT" count="4" value="0x1404"> | |||
| <size name="CallLists"/> | |||
| </enum> | |||
| <enum name="UNSIGNED_INT" count="4" value="0x1405"> | |||
| <size name="CallLists"/> | |||
| </enum> | |||
| <enum name="STENCIL_INDEX" value="0x1901"/> | |||
| <enum name="DEPTH_COMPONENT" value="0x1902"/> | |||
| <function name="TexImage2D" offset="183"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="internalformat" type="GLint"/> <!-- XXX the actual type is GLenum... --> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="border" type="GLint"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="pixels" type="const GLvoid *" img_width="width" img_height="height" img_format="format" img_type="type" img_target="target" img_send_null="true" img_pad_dimensions="true"/> | |||
| <glx rop="110" large="true"/> | |||
| </function> | |||
| <!-- addition to base1.1 --> | |||
| <enum name="RGBA4" value="0x8056"/> | |||
| <enum name="RGB5_A1" value="0x8057"/> | |||
| <!-- addition to base1.2 --> | |||
| <enum name="CONSTANT_COLOR" value="0x8001"/> | |||
| <enum name="ONE_MINUS_CONSTANT_COLOR" value="0x8002"/> | |||
| <enum name="CONSTANT_ALPHA" value="0x8003"/> | |||
| <enum name="ONE_MINUS_CONSTANT_ALPHA" value="0x8004"/> | |||
| <enum name="BLEND_COLOR" count="4" value="0x8005"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="FUNC_ADD" value="0x8006"/> | |||
| <enum name="BLEND_EQUATION" count="1" value="0x8009"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="FUNC_SUBTRACT" value="0x800A"/> | |||
| <enum name="FUNC_REVERSE_SUBTRACT" value="0x800B"/> | |||
| <function name="BlendColor" offset="336"> | |||
| <param name="red" type="GLclampf"/> | |||
| <param name="green" type="GLclampf"/> | |||
| <param name="blue" type="GLclampf"/> | |||
| <param name="alpha" type="GLclampf"/> | |||
| <glx rop="4096"/> | |||
| </function> | |||
| <function name="BlendEquation" offset="337"> | |||
| <param name="mode" type="GLenum"/> | |||
| <glx rop="4097"/> | |||
| </function> | |||
| <!-- addition to base1.3 --> | |||
| <enum name="TEXTURE_CUBE_MAP" count="1" value="0x8513"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="TEXTURE_BINDING_CUBE_MAP" count="1" value="0x8514"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="TEXTURE_CUBE_MAP_POSITIVE_X" value="0x8515"/> | |||
| <enum name="TEXTURE_CUBE_MAP_NEGATIVE_X" value="0x8516"/> | |||
| <enum name="TEXTURE_CUBE_MAP_POSITIVE_Y" value="0x8517"/> | |||
| <enum name="TEXTURE_CUBE_MAP_NEGATIVE_Y" value="0x8518"/> | |||
| <enum name="TEXTURE_CUBE_MAP_POSITIVE_Z" value="0x8519"/> | |||
| <enum name="TEXTURE_CUBE_MAP_NEGATIVE_Z" value="0x851A"/> | |||
| <enum name="MAX_CUBE_MAP_TEXTURE_SIZE" count="1" value="0x851C"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <!-- addition to base1.4 --> | |||
| <enum name="BLEND_DST_RGB" count="1" value="0x80C8"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="BLEND_SRC_RGB" count="1" value="0x80C9"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="BLEND_DST_ALPHA" count="1" value="0x80CA"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="BLEND_SRC_ALPHA" count="1" value="0x80CB"> | |||
| <size name="Get" mode="get"/> | |||
| </enum> | |||
| <enum name="DEPTH_COMPONENT16" value="0x81A5"/> | |||
| <enum name="MIRRORED_REPEAT" value="0x8370"/> | |||
| <enum name="INCR_WRAP" value="0x8507"/> | |||
| <enum name="DECR_WRAP" value="0x8508"/> | |||
| <function name="BlendFuncSeparate" offset="assign"> | |||
| <param name="sfactorRGB" type="GLenum"/> | |||
| <param name="dfactorRGB" type="GLenum"/> | |||
| <param name="sfactorAlpha" type="GLenum"/> | |||
| <param name="dfactorAlpha" type="GLenum"/> | |||
| <glx rop="4134"/> | |||
| </function> | |||
| <!-- addition to base1.5 --> | |||
| <enum name="VERTEX_ATTRIB_ARRAY_BUFFER_BINDING" count="1" value="0x889F"> | |||
| <size name="GetVertexAttribdv" mode="get"/> | |||
| <size name="GetVertexAttribfv" mode="get"/> | |||
| <size name="GetVertexAttribiv" mode="get"/> | |||
| </enum> | |||
| <enum name="STREAM_DRAW" value="0x88E0"/> | |||
| <!-- addition to base2.0 --> | |||
| <!-- base2.0 should have everything defined --> | |||
| </category> | |||
| <!-- OpenGL ES 2.0 --> | |||
| <category name="es2.0"> | |||
| <!-- addition to core2.0 --> | |||
| <enum name="LOW_FLOAT" value="0x8DF0"/> | |||
| <enum name="MEDIUM_FLOAT" value="0x8DF1"/> | |||
| <enum name="HIGH_FLOAT" value="0x8DF2"/> | |||
| <enum name="LOW_INT" value="0x8DF3"/> | |||
| <enum name="MEDIUM_INT" value="0x8DF4"/> | |||
| <enum name="HIGH_INT" value="0x8DF5"/> | |||
| <enum name="SHADER_BINARY_FORMATS" value="0x8DF8"/> | |||
| <enum name="NUM_SHADER_BINARY_FORMATS" value="0x8DF9"/> | |||
| <enum name="SHADER_COMPILER" value="0x8DFA"/> | |||
| <enum name="MAX_VERTEX_UNIFORM_VECTORS" value="0x8DFB"/> | |||
| <enum name="MAX_VARYING_VECTORS" value="0x8DFC"/> | |||
| <enum name="MAX_FRAGMENT_UNIFORM_VECTORS" value="0x8DFD"/> | |||
| <function name="GetShaderPrecisionFormat" offset="assign"> | |||
| <param name="shadertype" type="GLenum"/> | |||
| <param name="precisiontype" type="GLenum"/> | |||
| <param name="range" type="GLint *"/> | |||
| <param name="precision" type="GLint *"/> | |||
| </function> | |||
| <function name="ReleaseShaderCompiler" offset="assign"> | |||
| </function> | |||
| <function name="ShaderBinary" offset="assign"> | |||
| <param name="n" type="GLsizei"/> | |||
| <param name="shaders" type="const GLuint *"/> | |||
| <param name="binaryformat" type="GLenum"/> | |||
| <param name="binary" type="const GLvoid *"/> | |||
| <param name="length" type="GLsizei"/> | |||
| </function> | |||
| <!-- from GL_OES_fixed_point --> | |||
| <enum name="FIXED" value="0x140C"/> | |||
| <type name="fixed" size="4" /> | |||
| <!-- from GL_OES_framebuffer_object --> | |||
| <enum name="INVALID_FRAMEBUFFER_OPERATION" value="0x0506"/> | |||
| <enum name="MAX_RENDERBUFFER_SIZE" value="0x84E8"/> | |||
| <enum name="FRAMEBUFFER_BINDING" value="0x8CA6"/> | |||
| <enum name="RENDERBUFFER_BINDING" value="0x8CA7"/> | |||
| <enum name="FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE" value="0x8CD0"/> | |||
| <enum name="FRAMEBUFFER_ATTACHMENT_OBJECT_NAME" value="0x8CD1"/> | |||
| <enum name="FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL" value="0x8CD2"/> | |||
| <enum name="FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE" value="0x8CD3"/> | |||
| <enum name="FRAMEBUFFER_COMPLETE" value="0x8CD5"/> | |||
| <enum name="FRAMEBUFFER_INCOMPLETE_ATTACHMENT" value="0x8CD6"/> | |||
| <enum name="FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT" value="0x8CD7"/> | |||
| <enum name="FRAMEBUFFER_INCOMPLETE_DIMENSIONS" value="0x8CD9"/> | |||
| <enum name="FRAMEBUFFER_UNSUPPORTED" value="0x8CDD"/> | |||
| <enum name="COLOR_ATTACHMENT0" value="0x8CE0"/> | |||
| <enum name="DEPTH_ATTACHMENT" value="0x8D00"/> | |||
| <enum name="STENCIL_ATTACHMENT" value="0x8D20"/> | |||
| <enum name="FRAMEBUFFER" value="0x8D40"/> | |||
| <enum name="RENDERBUFFER" value="0x8D41"/> | |||
| <enum name="RENDERBUFFER_WIDTH" value="0x8D42"/> | |||
| <enum name="RENDERBUFFER_HEIGHT" value="0x8D43"/> | |||
| <enum name="RENDERBUFFER_INTERNAL_FORMAT" value="0x8D44"/> | |||
| <enum name="STENCIL_INDEX8" value="0x8D48"/> | |||
| <enum name="RENDERBUFFER_RED_SIZE" value="0x8D50"/> | |||
| <enum name="RENDERBUFFER_GREEN_SIZE" value="0x8D51"/> | |||
| <enum name="RENDERBUFFER_BLUE_SIZE" value="0x8D52"/> | |||
| <enum name="RENDERBUFFER_ALPHA_SIZE" value="0x8D53"/> | |||
| <enum name="RENDERBUFFER_DEPTH_SIZE" value="0x8D54"/> | |||
| <enum name="RENDERBUFFER_STENCIL_SIZE" value="0x8D55"/> | |||
| <enum name="RGB565" value="0x8D62"/> | |||
| <function name="BindFramebuffer" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="framebuffer" type="GLuint"/> | |||
| </function> | |||
| <function name="BindRenderbuffer" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="renderbuffer" type="GLuint"/> | |||
| </function> | |||
| <function name="CheckFramebufferStatus" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <return type="GLenum"/> | |||
| </function> | |||
| <function name="DeleteFramebuffers" offset="assign"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="framebuffers" type="const GLuint *" count="n"/> | |||
| </function> | |||
| <function name="DeleteRenderbuffers" offset="assign"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="renderbuffers" type="const GLuint *" count="n"/> | |||
| </function> | |||
| <function name="FramebufferRenderbuffer" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="attachment" type="GLenum"/> | |||
| <param name="renderbuffertarget" type="GLenum"/> | |||
| <param name="renderbuffer" type="GLuint"/> | |||
| </function> | |||
| <function name="FramebufferTexture2D" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="attachment" type="GLenum"/> | |||
| <param name="textarget" type="GLenum"/> | |||
| <param name="texture" type="GLuint"/> | |||
| <param name="level" type="GLint"/> | |||
| </function> | |||
| <function name="GenerateMipmap" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| </function> | |||
| <function name="GenFramebuffers" offset="assign"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="framebuffers" type="GLuint *" count="n" output="true"/> | |||
| </function> | |||
| <function name="GenRenderbuffers" offset="assign"> | |||
| <param name="n" type="GLsizei" counter="true"/> | |||
| <param name="renderbuffers" type="GLuint *" count="n" output="true"/> | |||
| </function> | |||
| <function name="GetFramebufferAttachmentParameteriv" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="attachment" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true"/> | |||
| </function> | |||
| <function name="GetRenderbufferParameteriv" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true"/> | |||
| </function> | |||
| <function name="IsFramebuffer" offset="assign"> | |||
| <param name="framebuffer" type="GLuint"/> | |||
| <return type="GLboolean"/> | |||
| </function> | |||
| <function name="IsRenderbuffer" offset="assign"> | |||
| <param name="renderbuffer" type="GLuint"/> | |||
| <return type="GLboolean"/> | |||
| </function> | |||
| <function name="RenderbufferStorage" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="internalformat" type="GLenum"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| </function> | |||
| <!-- from GL_OES_read_format --> | |||
| <enum name="IMPLEMENTATION_COLOR_READ_TYPE" value="0x8B9A"/> | |||
| <enum name="IMPLEMENTATION_COLOR_READ_FORMAT" value="0x8B9B"/> | |||
| <!-- from GL_OES_single_precision --> | |||
| <function name="ClearDepthf" offset="assign"> | |||
| <param name="depth" type="GLclampf"/> | |||
| </function> | |||
| <function name="DepthRangef" offset="assign"> | |||
| <param name="zNear" type="GLclampf"/> | |||
| <param name="zFar" type="GLclampf"/> | |||
| </function> | |||
| </category> | |||
| <xi:include href="es2_EXT.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> | |||
| <xi:include href="es2_COMPAT.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> | |||
| </OpenGLAPI> | |||
| @@ -0,0 +1,368 @@ | |||
| <?xml version="1.0"?> | |||
| <!DOCTYPE OpenGLAPI SYSTEM "../../glapi/gl_API.dtd"> | |||
| <OpenGLAPI> | |||
| <!-- This file defines the functions that are needed by Mesa. It | |||
| makes sure the generated glapi headers are compatible with Mesa. | |||
| It mainly consists of missing functions and aliases in OpenGL ES. | |||
| --> | |||
| <xi:include href="es_COMPAT.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> | |||
| <!-- except for those defined by es_COMPAT.xml, these are also needed --> | |||
| <category name="compat"> | |||
| <!-- OpenGL 1.0 --> | |||
| <function name="Color4f" offset="29" vectorequiv="Color4fv" static_dispatch="false"> | |||
| <param name="red" type="GLfloat"/> | |||
| <param name="green" type="GLfloat"/> | |||
| <param name="blue" type="GLfloat"/> | |||
| <param name="alpha" type="GLfloat"/> | |||
| </function> | |||
| <function name="Color4ub" offset="35" vectorequiv="Color4ubv" static_dispatch="false"> | |||
| <param name="red" type="GLubyte"/> | |||
| <param name="green" type="GLubyte"/> | |||
| <param name="blue" type="GLubyte"/> | |||
| <param name="alpha" type="GLubyte"/> | |||
| </function> | |||
| <function name="Normal3f" offset="56" vectorequiv="Normal3fv" static_dispatch="false"> | |||
| <param name="nx" type="GLfloat"/> | |||
| <param name="ny" type="GLfloat"/> | |||
| <param name="nz" type="GLfloat"/> | |||
| </function> | |||
| <function name="Fogf" offset="153" static_dispatch="false"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfloat"/> | |||
| <glx rop="80"/> | |||
| </function> | |||
| <function name="Fogfv" offset="154" static_dispatch="false"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfloat *" variable_param="pname"/> | |||
| <glx rop="81"/> | |||
| </function> | |||
| <function name="Lightf" offset="159" static_dispatch="false"> | |||
| <param name="light" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfloat"/> | |||
| <glx rop="86"/> | |||
| </function> | |||
| <function name="Lightfv" offset="160" static_dispatch="false"> | |||
| <param name="light" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfloat *" variable_param="pname"/> | |||
| <glx rop="87"/> | |||
| </function> | |||
| <function name="LightModelf" offset="163" static_dispatch="false"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfloat"/> | |||
| <glx rop="90"/> | |||
| </function> | |||
| <function name="LightModelfv" offset="164" static_dispatch="false"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfloat *" variable_param="pname"/> | |||
| <glx rop="91"/> | |||
| </function> | |||
| <function name="Materialf" offset="169" static_dispatch="false"> | |||
| <param name="face" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfloat"/> | |||
| <glx rop="96"/> | |||
| </function> | |||
| <function name="Materialfv" offset="170" static_dispatch="false"> | |||
| <param name="face" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfloat *" variable_param="pname"/> | |||
| <glx rop="97"/> | |||
| </function> | |||
| <function name="PointSize" offset="173" static_dispatch="false"> | |||
| <param name="size" type="GLfloat"/> | |||
| <glx rop="100"/> | |||
| </function> | |||
| <function name="ShadeModel" offset="177" static_dispatch="false"> | |||
| <param name="mode" type="GLenum"/> | |||
| <glx rop="104"/> | |||
| </function> | |||
| <function name="TexEnvf" offset="184" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfloat"/> | |||
| <glx rop="111"/> | |||
| </function> | |||
| <function name="TexEnvfv" offset="185" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfloat *" variable_param="pname"/> | |||
| <glx rop="112"/> | |||
| </function> | |||
| <function name="TexEnvi" offset="186" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLint"/> | |||
| <glx rop="113"/> | |||
| </function> | |||
| <function name="TexEnviv" offset="187" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLint *" variable_param="pname"/> | |||
| <glx rop="114"/> | |||
| </function> | |||
| <function name="TexGenf" offset="190" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLfloat"/> | |||
| <glx rop="117"/> | |||
| </function> | |||
| <function name="TexGenfv" offset="191" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLfloat *" variable_param="pname"/> | |||
| <glx rop="118"/> | |||
| </function> | |||
| <function name="TexGeni" offset="192" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="param" type="GLint"/> | |||
| <glx rop="119"/> | |||
| </function> | |||
| <function name="TexGeniv" offset="193" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="const GLint *" variable_param="pname"/> | |||
| <glx rop="120"/> | |||
| </function> | |||
| <function name="AlphaFunc" offset="240" static_dispatch="false"> | |||
| <param name="func" type="GLenum"/> | |||
| <param name="ref" type="GLclampf"/> | |||
| <glx rop="159"/> | |||
| </function> | |||
| <function name="LogicOp" offset="242" static_dispatch="false"> | |||
| <param name="opcode" type="GLenum"/> | |||
| <glx rop="161"/> | |||
| </function> | |||
| <function name="GetLightfv" offset="264" static_dispatch="false"> | |||
| <param name="light" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfloat *" output="true" variable_param="pname"/> | |||
| <glx sop="118"/> | |||
| </function> | |||
| <function name="GetMaterialfv" offset="269" static_dispatch="false"> | |||
| <param name="face" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfloat *" output="true" variable_param="pname"/> | |||
| <glx sop="123"/> | |||
| </function> | |||
| <function name="GetTexEnvfv" offset="276" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfloat *" output="true" variable_param="pname"/> | |||
| <glx sop="130"/> | |||
| </function> | |||
| <function name="GetTexEnviv" offset="277" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true" variable_param="pname"/> | |||
| <glx sop="131"/> | |||
| </function> | |||
| <function name="GetTexGenfv" offset="279" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLfloat *" output="true" variable_param="pname"/> | |||
| <glx sop="133"/> | |||
| </function> | |||
| <function name="GetTexGeniv" offset="280" static_dispatch="false"> | |||
| <param name="coord" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLint *" output="true" variable_param="pname"/> | |||
| <glx sop="134"/> | |||
| </function> | |||
| <function name="LoadIdentity" offset="290" static_dispatch="false"> | |||
| <glx rop="176"/> | |||
| </function> | |||
| <function name="LoadMatrixf" offset="291" static_dispatch="false"> | |||
| <param name="m" type="const GLfloat *" count="16"/> | |||
| <glx rop="177"/> | |||
| </function> | |||
| <function name="MatrixMode" offset="293" static_dispatch="false"> | |||
| <param name="mode" type="GLenum"/> | |||
| <glx rop="179"/> | |||
| </function> | |||
| <function name="MultMatrixf" offset="294" static_dispatch="false"> | |||
| <param name="m" type="const GLfloat *" count="16"/> | |||
| <glx rop="180"/> | |||
| </function> | |||
| <function name="PopMatrix" offset="297" static_dispatch="false"> | |||
| <glx rop="183"/> | |||
| </function> | |||
| <function name="PushMatrix" offset="298" static_dispatch="false"> | |||
| <glx rop="184"/> | |||
| </function> | |||
| <function name="Rotatef" offset="300" static_dispatch="false"> | |||
| <param name="angle" type="GLfloat"/> | |||
| <param name="x" type="GLfloat"/> | |||
| <param name="y" type="GLfloat"/> | |||
| <param name="z" type="GLfloat"/> | |||
| <glx rop="186"/> | |||
| </function> | |||
| <function name="Scalef" offset="302" static_dispatch="false"> | |||
| <param name="x" type="GLfloat"/> | |||
| <param name="y" type="GLfloat"/> | |||
| <param name="z" type="GLfloat"/> | |||
| <glx rop="188"/> | |||
| </function> | |||
| <function name="Translatef" offset="304" static_dispatch="false"> | |||
| <param name="x" type="GLfloat"/> | |||
| <param name="y" type="GLfloat"/> | |||
| <param name="z" type="GLfloat"/> | |||
| <glx rop="190"/> | |||
| </function> | |||
| <!-- OpenGL 1.1 --> | |||
| <function name="ColorPointer" offset="308" static_dispatch="false"> | |||
| <param name="size" type="GLint"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="stride" type="GLsizei"/> | |||
| <param name="pointer" type="const GLvoid *"/> | |||
| <glx handcode="true"/> | |||
| </function> | |||
| <function name="DisableClientState" offset="309" static_dispatch="false"> | |||
| <param name="array" type="GLenum"/> | |||
| <glx handcode="true"/> | |||
| </function> | |||
| <function name="EnableClientState" offset="313" static_dispatch="false"> | |||
| <param name="array" type="GLenum"/> | |||
| <glx handcode="true"/> | |||
| </function> | |||
| <function name="NormalPointer" offset="318" static_dispatch="false"> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="stride" type="GLsizei"/> | |||
| <param name="pointer" type="const GLvoid *"/> | |||
| <glx handcode="true"/> | |||
| </function> | |||
| <function name="TexCoordPointer" offset="320" static_dispatch="false"> | |||
| <param name="size" type="GLint"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="stride" type="GLsizei"/> | |||
| <param name="pointer" type="const GLvoid *"/> | |||
| <glx handcode="true"/> | |||
| </function> | |||
| <function name="VertexPointer" offset="321" static_dispatch="false"> | |||
| <param name="size" type="GLint"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="stride" type="GLsizei"/> | |||
| <param name="pointer" type="const GLvoid *"/> | |||
| <glx handcode="true"/> | |||
| </function> | |||
| <function name="GetPointerv" offset="329" static_dispatch="false"> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLvoid **" output="true"/> | |||
| <glx handcode="true"/> | |||
| </function> | |||
| <!-- OpenGL 1.2 --> | |||
| <function name="TexImage3D" alias="TexImage3DOES" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="internalformat" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="depth" type="GLsizei"/> | |||
| <param name="border" type="GLint"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="pixels" type="const GLvoid *" img_width="width" img_height="height" img_depth="depth" img_format="format" img_type="type" img_target="target" img_null_flag="true" img_pad_dimensions="true"/> | |||
| <glx rop="4114" large="true"/> | |||
| </function> | |||
| <function name="TexSubImage3D" alias="TexSubImage3DOES" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="xoffset" type="GLint"/> | |||
| <param name="yoffset" type="GLint"/> | |||
| <param name="zoffset" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="depth" type="GLsizei"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="UNUSED" type="GLuint" padding="true"/> | |||
| <param name="pixels" type="const GLvoid *" img_width="width" img_height="height" img_depth="depth" img_xoff="xoffset" img_yoff="yoffset" img_zoff="zoffset" img_format="format" img_type="type" img_target="target" img_pad_dimensions="true"/> | |||
| <glx rop="4115" large="true"/> | |||
| </function> | |||
| <function name="CopyTexSubImage3D" alias="CopyTexSubImage3DOES" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="xoffset" type="GLint"/> | |||
| <param name="yoffset" type="GLint"/> | |||
| <param name="zoffset" type="GLint"/> | |||
| <param name="x" type="GLint"/> | |||
| <param name="y" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <glx rop="4123"/> | |||
| </function> | |||
| <!-- GL_ARB_multitexture --> | |||
| <function name="ActiveTextureARB" alias="ActiveTexture" static_dispatch="false"> | |||
| <param name="texture" type="GLenum"/> | |||
| <glx rop="197"/> | |||
| </function> | |||
| <function name="ClientActiveTextureARB" offset="375" static_dispatch="false"> | |||
| <param name="texture" type="GLenum"/> | |||
| <glx handcode="true"/> | |||
| </function> | |||
| <function name="MultiTexCoord4fARB" offset="402" vectorequiv="MultiTexCoord4fvARB" static_dispatch="false"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="s" type="GLfloat"/> | |||
| <param name="t" type="GLfloat"/> | |||
| <param name="r" type="GLfloat"/> | |||
| <param name="q" type="GLfloat"/> | |||
| </function> | |||
| </category> | |||
| </OpenGLAPI> | |||
| @@ -0,0 +1,122 @@ | |||
| <?xml version="1.0"?> | |||
| <!DOCTYPE OpenGLAPI SYSTEM "../../glapi/gl_API.dtd"> | |||
| <!-- OpenGL ES 2.x extensions --> | |||
| <OpenGLAPI> | |||
| <xi:include href="es_EXT.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> | |||
| <category name="GL_OES_texture_3D" number="34"> | |||
| <enum name="TEXTURE_BINDING_3D_OES" value="0x806A"/> | |||
| <enum name="TEXTURE_3D_OES" value="0x806F"/> | |||
| <enum name="TEXTURE_WRAP_R_OES" value="0x8072"/> | |||
| <enum name="MAX_3D_TEXTURE_SIZE_OES" value="0x8073"/> | |||
| <enum name="SAMPLER_3D_OES" value="0x8B5F"/> | |||
| <enum name="FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_OES" value="0x8CD4"/> | |||
| <function name="CompressedTexImage3DOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="internalformat" type="GLenum"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="depth" type="GLsizei"/> | |||
| <param name="border" type="GLint"/> | |||
| <param name="imageSize" type="GLsizei" counter="true"/> | |||
| <param name="data" type="const GLvoid *" count="imageSize"/> | |||
| <glx rop="216" handcode="client"/> | |||
| </function> | |||
| <function name="CompressedTexSubImage3DOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="xoffset" type="GLint"/> | |||
| <param name="yoffset" type="GLint"/> | |||
| <param name="zoffset" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="depth" type="GLsizei"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="imageSize" type="GLsizei" counter="true"/> | |||
| <param name="data" type="const GLvoid *" count="imageSize"/> | |||
| <glx rop="219" handcode="client"/> | |||
| </function> | |||
| <function name="CopyTexSubImage3DOES" offset="373"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="xoffset" type="GLint"/> | |||
| <param name="yoffset" type="GLint"/> | |||
| <param name="zoffset" type="GLint"/> | |||
| <param name="x" type="GLint"/> | |||
| <param name="y" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <glx rop="4123"/> | |||
| </function> | |||
| <function name="FramebufferTexture3DOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="attachment" type="GLenum"/> | |||
| <param name="textarget" type="GLenum"/> | |||
| <param name="texture" type="GLuint"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="zoffset" type="GLint"/> | |||
| <glx rop="4323"/> | |||
| </function> | |||
| <function name="TexImage3DOES" offset="371"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="internalformat" type="GLenum"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="depth" type="GLsizei"/> | |||
| <param name="border" type="GLint"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="pixels" type="const GLvoid *" img_width="width" img_height="height" img_depth="depth" img_format="format" img_type="type" img_target="target" img_null_flag="true" img_pad_dimensions="true"/> | |||
| <glx rop="4114" large="true"/> | |||
| </function> | |||
| <function name="TexSubImage3DOES" offset="372"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="level" type="GLint"/> | |||
| <param name="xoffset" type="GLint"/> | |||
| <param name="yoffset" type="GLint"/> | |||
| <param name="zoffset" type="GLint"/> | |||
| <param name="width" type="GLsizei"/> | |||
| <param name="height" type="GLsizei"/> | |||
| <param name="depth" type="GLsizei"/> | |||
| <param name="format" type="GLenum"/> | |||
| <param name="type" type="GLenum"/> | |||
| <param name="UNUSED" type="GLuint" padding="true"/> | |||
| <param name="pixels" type="const GLvoid *" img_width="width" img_height="height" img_depth="depth" img_xoff="xoffset" img_yoff="yoffset" img_zoff="zoffset" img_format="format" img_type="type" img_target="target" img_pad_dimensions="true"/> | |||
| <glx rop="4115" large="true"/> | |||
| </function> | |||
| </category> | |||
| <category name="GL_OES_texture_npot" number="37"> | |||
| <!-- No new functions, types, enums. --> | |||
| </category> | |||
| <category name="GL_EXT_texture_type_2_10_10_10_REV" number="42"> | |||
| <enum name="UNSIGNED_INT_2_10_10_10_REV_EXT" value="0x8368"/> | |||
| </category> | |||
| <category name="GL_OES_packed_depth_stencil" number="43"> | |||
| <enum name="DEPTH_STENCIL_OES" value="0x84F9"/> | |||
| <enum name="UNSIGNED_INT_24_8_OES" value="0x84FA"/> | |||
| <enum name="DEPTH24_STENCIL8_OES" value="0x88F0"/> | |||
| </category> | |||
| <category name="GL_OES_depth_texture" number="44"> | |||
| <!-- No new functions, types, enums. --> | |||
| </category> | |||
| <category name="GL_OES_standard_derivatives" number="45"> | |||
| <enum name="FRAGMENT_SHADER_DERIVATIVE_HINT_OES" value="0x8B8B"/> | |||
| </category> | |||
| </OpenGLAPI> | |||
| @@ -0,0 +1,83 @@ | |||
| <?xml version="1.0"?> | |||
| <!DOCTYPE OpenGLAPI SYSTEM "../../glapi/gl_API.dtd"> | |||
| <!-- OpenGL ES extensions --> | |||
| <OpenGLAPI> | |||
| <category name="GL_OES_compressed_paletted_texture" number="6"> | |||
| <enum name="PALETTE4_RGB8_OES" value="0x8B90"/> | |||
| <enum name="PALETTE4_RGBA8_OES" value="0x8B91"/> | |||
| <enum name="PALETTE4_R5_G6_B5_OES" value="0x8B92"/> | |||
| <enum name="PALETTE4_RGBA4_OES" value="0x8B93"/> | |||
| <enum name="PALETTE4_RGB5_A1_OES" value="0x8B94"/> | |||
| <enum name="PALETTE8_RGB8_OES" value="0x8B95"/> | |||
| <enum name="PALETTE8_RGBA8_OES" value="0x8B96"/> | |||
| <enum name="PALETTE8_R5_G6_B5_OES" value="0x8B97"/> | |||
| <enum name="PALETTE8_RGBA4_OES" value="0x8B98"/> | |||
| <enum name="PALETTE8_RGB5_A1_OES" value="0x8B99"/> | |||
| </category> | |||
| <category name="GL_OES_depth24" number="24"> | |||
| <enum name="DEPTH_COMPONENT24_OES" value="0x81A6"/> | |||
| </category> | |||
| <category name="GL_OES_depth32" number="25"> | |||
| <enum name="DEPTH_COMPONENT32_OES" value="0x81A7"/> | |||
| </category> | |||
| <category name="GL_OES_element_index_uint" number="26"> | |||
| <!-- No new functions, types, enums. --> | |||
| </category> | |||
| <category name="GL_OES_fbo_render_mipmap" number="27"> | |||
| <!-- No new functions, types, enums. --> | |||
| </category> | |||
| <category name="GL_OES_mapbuffer" number="29"> | |||
| <enum name="WRITE_ONLY_OES" value="0x88B9"/> | |||
| <enum name="BUFFER_ACCESS_OES" value="0x88BB"/> | |||
| <enum name="BUFFER_MAPPED_OES" value="0x88BC"/> | |||
| <enum name="BUFFER_MAP_POINTER_OES" value="0x88BD"/> | |||
| <function name="GetBufferPointervOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="pname" type="GLenum"/> | |||
| <param name="params" type="GLvoid **"/> | |||
| </function> | |||
| <function name="MapBufferOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <param name="access" type="GLenum"/> | |||
| <return type="GLvoid *"/> | |||
| </function> | |||
| <function name="UnmapBufferOES" offset="assign"> | |||
| <param name="target" type="GLenum"/> | |||
| <return type="GLboolean"/> | |||
| </function> | |||
| </category> | |||
| <category name="GL_OES_rgb8_rgba8" number="30"> | |||
| <enum name="RGB8_OES" value="0x8051"/> | |||
| <enum name="RGBA8_OES" value="0x8058"/> | |||
| </category> | |||
| <category name="GL_OES_stencil1" number="31"> | |||
| <enum name="STENCIL_INDEX1_OES" value="0x8D46"/> | |||
| </category> | |||
| <category name="GL_OES_stencil4" number="32"> | |||
| <enum name="STENCIL_INDEX4_OES" value="0x8D47"/> | |||
| </category> | |||
| <category name="GL_OES_stencil8" number="33"> | |||
| <enum name="STENCIL_INDEX8_OES" value="0x8D48"/> | |||
| </category> | |||
| <category name="GL_EXT_texture_filter_anisotropic" number="41"> | |||
| <enum name="TEXTURE_MAX_ANISOTROPY_EXT" value="0x84FE"/> | |||
| <enum name="MAX_TEXTURE_MAX_ANISOTROPY_EXT" value="0x84FF"/> | |||
| </category> | |||
| </OpenGLAPI> | |||
| @@ -0,0 +1,354 @@ | |||
| #!/usr/bin/python | |||
| # | |||
| # Copyright (C) 2009 Chia-I Wu <olv@0xlab.org> | |||
| # | |||
| # 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 | |||
| # on the rights to use, copy, modify, merge, publish, distribute, sub | |||
| # license, 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 NON-INFRINGEMENT. IN NO EVENT SHALL | |||
| # IBM AND/OR ITS SUPPLIERS 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. | |||
| import sys | |||
| import os.path | |||
| import getopt | |||
| GLAPI = "../../glapi" | |||
| sys.path.append(GLAPI) | |||
| import gl_XML | |||
| import glX_XML | |||
| class ApiSet(object): | |||
| def __init__(self, api, elts=["enum", "type", "function"]): | |||
| self.api = api | |||
| self.elts = elts | |||
| def _check_enum(self, e1, e2, strict=True): | |||
| if e1.name != e2.name: | |||
| raise ValueError("%s: name mismatch" % e1.name) | |||
| if e1.value != e2.value: | |||
| raise ValueError("%s: value 0x%04x != 0x%04x" | |||
| % (e1.name, e1.value, e2.value)) | |||
| def _check_type(self, t1, t2, strict=True): | |||
| if t1.name != t2.name: | |||
| raise ValueError("%s: name mismatch" % t1.name) | |||
| if t1.type_expr.string() != t2.type_expr.string(): | |||
| raise ValueError("%s: type %s != %s" | |||
| % (t1.name, t1.type_expr.string(), t2.type_expr.string())) | |||
| def _check_function(self, f1, f2, strict=True): | |||
| if f1.name != f2.name: | |||
| raise ValueError("%s: name mismatch" % f1.name) | |||
| if f1.return_type != f2.return_type: | |||
| raise ValueError("%s: return type %s != %s" | |||
| % (f1.name, f1.return_type, f2.return_type)) | |||
| # there might be padded parameters | |||
| if strict and len(f1.parameters) != len(f2.parameters): | |||
| raise ValueError("%s: parameter length %d != %d" | |||
| % (f1.name, len(f1.parameters), len(f2.parameters))) | |||
| if f1.assign_offset != f2.assign_offset: | |||
| if ((f1.assign_offset and f2.offset < 0) or | |||
| (f2.assign_offset and f1.offset < 0)): | |||
| raise ValueError("%s: assign offset %d != %d" | |||
| % (f1.name, f1.assign_offset, f2.assign_offset)) | |||
| elif not f1.assign_offset: | |||
| if f1.offset != f2.offset: | |||
| raise ValueError("%s: offset %d != %d" | |||
| % (f1.name, f1.offset, f2.offset)) | |||
| if strict: | |||
| l1 = f1.entry_points | |||
| l2 = f2.entry_points | |||
| l1.sort() | |||
| l2.sort() | |||
| if l1 != l2: | |||
| raise ValueError("%s: entry points %s != %s" | |||
| % (f1.name, l1, l2)) | |||
| l1 = f1.static_entry_points | |||
| l2 = f2.static_entry_points | |||
| l1.sort() | |||
| l2.sort() | |||
| if l1 != l2: | |||
| raise ValueError("%s: static entry points %s != %s" | |||
| % (f1.name, l1, l2)) | |||
| pad = 0 | |||
| for i in xrange(len(f1.parameters)): | |||
| p1 = f1.parameters[i] | |||
| p2 = f2.parameters[i + pad] | |||
| if not strict and p1.is_padding != p2.is_padding: | |||
| if p1.is_padding: | |||
| pad -= 1 | |||
| continue | |||
| else: | |||
| pad += 1 | |||
| p2 = f2.parameters[i + pad] | |||
| if strict and p1.name != p2.name: | |||
| raise ValueError("%s: parameter %d name %s != %s" | |||
| % (f1.name, i, p1.name, p2.name)) | |||
| if p1.type_expr.string() != p2.type_expr.string(): | |||
| if (strict or | |||
| # special case | |||
| f1.name == "TexImage2D" and p1.name != "internalformat"): | |||
| raise ValueError("%s: parameter %s type %s != %s" | |||
| % (f1.name, p1.name, p1.type_expr.string(), | |||
| p2.type_expr.string())) | |||
| def union(self, other): | |||
| union = gl_XML.gl_api(None) | |||
| if "enum" in self.elts: | |||
| union.enums_by_name = other.enums_by_name.copy() | |||
| for key, val in self.api.enums_by_name.iteritems(): | |||
| if key not in union.enums_by_name: | |||
| union.enums_by_name[key] = val | |||
| else: | |||
| self._check_enum(val, other.enums_by_name[key]) | |||
| if "type" in self.elts: | |||
| union.types_by_name = other.types_by_name.copy() | |||
| for key, val in self.api.types_by_name.iteritems(): | |||
| if key not in union.types_by_name: | |||
| union.types_by_name[key] = val | |||
| else: | |||
| self._check_type(val, other.types_by_name[key]) | |||
| if "function" in self.elts: | |||
| union.functions_by_name = other.functions_by_name.copy() | |||
| for key, val in self.api.functions_by_name.iteritems(): | |||
| if key not in union.functions_by_name: | |||
| union.functions_by_name[key] = val | |||
| else: | |||
| self._check_function(val, other.functions_by_name[key]) | |||
| return union | |||
| def intersection(self, other): | |||
| intersection = gl_XML.gl_api(None) | |||
| if "enum" in self.elts: | |||
| for key, val in self.api.enums_by_name.iteritems(): | |||
| if key in other.enums_by_name: | |||
| self._check_enum(val, other.enums_by_name[key]) | |||
| intersection.enums_by_name[key] = val | |||
| if "type" in self.elts: | |||
| for key, val in self.api.types_by_name.iteritems(): | |||
| if key in other.types_by_name: | |||
| self._check_type(val, other.types_by_name[key]) | |||
| intersection.types_by_name[key] = val | |||
| if "function" in self.elts: | |||
| for key, val in self.api.functions_by_name.iteritems(): | |||
| if key in other.functions_by_name: | |||
| self._check_function(val, other.functions_by_name[key]) | |||
| intersection.functions_by_name[key] = val | |||
| return intersection | |||
| def difference(self, other): | |||
| difference = gl_XML.gl_api(None) | |||
| if "enum" in self.elts: | |||
| for key, val in self.api.enums_by_name.iteritems(): | |||
| if key not in other.enums_by_name: | |||
| difference.enums_by_name[key] = val | |||
| else: | |||
| self._check_enum(val, other.enums_by_name[key]) | |||
| if "type" in self.elts: | |||
| for key, val in self.api.types_by_name.iteritems(): | |||
| if key not in other.types_by_name: | |||
| difference.types_by_name[key] = val | |||
| else: | |||
| self._check_type(val, other.types_by_name[key]) | |||
| if "function" in self.elts: | |||
| for key, val in self.api.functions_by_name.iteritems(): | |||
| if key not in other.functions_by_name: | |||
| difference.functions_by_name[key] = val | |||
| else: | |||
| self._check_function(val, other.functions_by_name[key], False) | |||
| return difference | |||
| def cmp_enum(e1, e2): | |||
| if e1.value < e2.value: | |||
| return -1 | |||
| elif e1.value > e2.value: | |||
| return 1 | |||
| else: | |||
| return 0 | |||
| def cmp_type(t1, t2): | |||
| return t1.size - t2.size | |||
| def cmp_function(f1, f2): | |||
| if f1.name > f2.name: | |||
| return 1 | |||
| elif f1.name < f2.name: | |||
| return -1 | |||
| else: | |||
| return 0 | |||
| def spaces(n, str=""): | |||
| spaces = n - len(str) | |||
| if spaces < 1: | |||
| spaces = 1 | |||
| return " " * spaces | |||
| def output_enum(e, indent=0): | |||
| attrs = 'name="%s"' % e.name | |||
| if e.default_count > 0: | |||
| tab = spaces(37, attrs) | |||
| attrs += '%scount="%d"' % (tab, e.default_count) | |||
| tab = spaces(48, attrs) | |||
| val = "%04x" % e.value | |||
| val = "0x" + val.upper() | |||
| attrs += '%svalue="%s"' % (tab, val) | |||
| # no child | |||
| if not e.functions: | |||
| print '%s<enum %s/>' % (spaces(indent), attrs) | |||
| return | |||
| print '%s<enum %s>' % (spaces(indent), attrs) | |||
| for key, val in e.functions.iteritems(): | |||
| attrs = 'name="%s"' % key | |||
| if val[0] != e.default_count: | |||
| attrs += ' count="%d"' % val[0] | |||
| if not val[1]: | |||
| attrs += ' mode="get"' | |||
| print '%s<size %s/>' % (spaces(indent * 2), attrs) | |||
| print '%s</enum>' % spaces(indent) | |||
| def output_type(t, indent=0): | |||
| tab = spaces(16, t.name) | |||
| attrs = 'name="%s"%ssize="%d"' % (t.name, tab, t.size) | |||
| ctype = t.type_expr.string() | |||
| if ctype.find("unsigned") != -1: | |||
| attrs += ' unsigned="true"' | |||
| elif ctype.find("signed") == -1: | |||
| attrs += ' float="true"' | |||
| print '%s<type %s/>' % (spaces(indent), attrs) | |||
| def output_function(f, indent=0): | |||
| attrs = 'name="%s"' % f.name | |||
| if f.offset > 0: | |||
| if f.assign_offset: | |||
| attrs += ' offset="assign"' | |||
| else: | |||
| attrs += ' offset="%d"' % f.offset | |||
| print '%s<function %s>' % (spaces(indent), attrs) | |||
| for p in f.parameters: | |||
| attrs = 'name="%s" type="%s"' \ | |||
| % (p.name, p.type_expr.original_string) | |||
| print '%s<param %s/>' % (spaces(indent * 2), attrs) | |||
| if f.return_type != "void": | |||
| attrs = 'type="%s"' % f.return_type | |||
| print '%s<return %s/>' % (spaces(indent * 2), attrs) | |||
| print '%s</function>' % spaces(indent) | |||
| def output_category(api, indent=0): | |||
| enums = api.enums_by_name.values() | |||
| enums.sort(cmp_enum) | |||
| types = api.types_by_name.values() | |||
| types.sort(cmp_type) | |||
| functions = api.functions_by_name.values() | |||
| functions.sort(cmp_function) | |||
| for e in enums: | |||
| output_enum(e, indent) | |||
| if enums and types: | |||
| for t in types: | |||
| output_type(t, indent) | |||
| if enums or types: | |||
| for f in functions: | |||
| output_function(f, indent) | |||
| if f != functions[-1]: | |||
| def is_api_empty(api): | |||
| return bool(not api.enums_by_name and | |||
| not api.types_by_name and | |||
| not api.functions_by_name) | |||
| def show_usage(ops): | |||
| print "Usage: %s [-k elts] <%s> <file1> <file2>" % (sys.argv[0], "|".join(ops)) | |||
| print " -k elts A comma separated string of types of elements to" | |||
| print " skip. Possible types are enum, type, and function." | |||
| sys.exit(1) | |||
| def main(): | |||
| ops = ["union", "intersection", "difference"] | |||
| elts = ["enum", "type", "function"] | |||
| try: | |||
| options, args = getopt.getopt(sys.argv[1:], "k:") | |||
| except Exception, e: | |||
| show_usage(ops) | |||
| if len(args) != 3: | |||
| show_usage(ops) | |||
| op, file1, file2 = args | |||
| if op not in ops: | |||
| show_usage(ops) | |||
| skips = [] | |||
| for opt, val in options: | |||
| if opt == "-k": | |||
| skips = val.split(",") | |||
| for elt in skips: | |||
| try: | |||
| elts.remove(elt) | |||
| except ValueError: | |||
| show_usage(ops) | |||
| api1 = gl_XML.parse_GL_API(file1, glX_XML.glx_item_factory()) | |||
| api2 = gl_XML.parse_GL_API(file2, glX_XML.glx_item_factory()) | |||
| set = ApiSet(api1, elts) | |||
| func = getattr(set, op) | |||
| result = func(api2) | |||
| if not is_api_empty(result): | |||
| cat_name = "%s_of_%s_and_%s" \ | |||
| % (op, os.path.basename(file1), os.path.basename(file2)) | |||
| print '<?xml version="1.0"?>' | |||
| print '<!DOCTYPE OpenGLAPI SYSTEM "%s/gl_API.dtd">' % GLAPI | |||
| print '<OpenGLAPI>' | |||
| print '<category name="%s">' % (cat_name) | |||
| output_category(result, 4) | |||
| print '</category>' | |||
| print '</OpenGLAPI>' | |||
| if __name__ == "__main__": | |||
| main() | |||
| @@ -0,0 +1,450 @@ | |||
| #!/usr/bin/python | |||
| # | |||
| # Copyright (C) 2009 Chia-I Wu <olv@0xlab.org> | |||
| # | |||
| # 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 | |||
| # on the rights to use, copy, modify, merge, publish, distribute, sub | |||
| # license, 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 NON-INFRINGEMENT. IN NO EVENT SHALL | |||
| # IBM AND/OR ITS SUPPLIERS 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. | |||
| import sys | |||
| import os.path | |||
| import getopt | |||
| import re | |||
| GLAPI = "../../glapi" | |||
| sys.path.append(GLAPI) | |||
| class HeaderParser(object): | |||
| """Parser for GL header files.""" | |||
| def __init__(self, verbose=0): | |||
| # match #if and #ifdef | |||
| self.IFDEF = re.compile('#\s*if(n?def\s+(?P<ifdef>\w+)|\s+(?P<if>.+))') | |||
| # match #endif | |||
| self.ENDIF = re.compile('#\s*endif') | |||
| # match typedef abc def; | |||
| self.TYPEDEF = re.compile('typedef\s+(?P<from>[\w ]+)\s+(?P<to>\w+);') | |||
| # match #define XYZ VAL | |||
| self.DEFINE = re.compile('#\s*define\s+(?P<key>\w+)(?P<value>\s+[\w"]*)?') | |||
| # match GLAPI | |||
| self.GLAPI = re.compile('^GL_?API(CALL)?\s+(?P<return>[\w\s*]+[\w*])\s+(GL)?_?APIENTRY\s+(?P<name>\w+)\s*\((?P<params>[\w\s(,*\[\])]+)\)\s*;') | |||
| self.split_params = re.compile('\s*,\s*') | |||
| self.split_ctype = re.compile('(\W)') | |||
| # ignore GL_VERSION_X_Y | |||
| self.ignore_enum = re.compile('GL(_ES)?_VERSION(_ES_C[ML])?_\d_\d') | |||
| self.verbose = verbose | |||
| self._reset() | |||
| def _reset(self): | |||
| """Reset to initial state.""" | |||
| self.ifdef_levels = [] | |||
| self.need_char = False | |||
| # use typeexpr? | |||
| def _format_ctype(self, ctype, fix=True): | |||
| """Format a ctype string, optionally fix it.""" | |||
| # split the type string | |||
| tmp = self.split_ctype.split(ctype) | |||
| tmp = [s for s in tmp if s and s != " "] | |||
| pretty = "" | |||
| for i in xrange(len(tmp)): | |||
| # add missing GL prefix | |||
| if (fix and tmp[i] != "const" and tmp[i] != "*" and | |||
| not tmp[i].startswith("GL")): | |||
| tmp[i] = "GL" + tmp[i] | |||
| if i == 0: | |||
| pretty = tmp[i] | |||
| else: | |||
| sep = " " | |||
| if tmp[i - 1] == "*": | |||
| sep = "" | |||
| pretty += sep + tmp[i] | |||
| return pretty | |||
| # use typeexpr? | |||
| def _get_ctype_attrs(self, ctype): | |||
| """Get the attributes of a ctype.""" | |||
| is_float = (ctype.find("float") != -1 or ctype.find("double") != -1) | |||
| is_signed = not (ctype.find("unsigned") != -1) | |||
| size = 0 | |||
| if ctype.find("char") != -1: | |||
| size = 1 | |||
| elif ctype.find("short") != -1: | |||
| size = 2 | |||
| elif ctype.find("int") != -1: | |||
| size = 4 | |||
| elif is_float: | |||
| if ctype.find("float") != -1: | |||
| size = 4 | |||
| else: | |||
| size = 8 | |||
| return (size, is_float, is_signed) | |||
| def _parse_define(self, line): | |||
| """Parse a #define line for an <enum>.""" | |||
| m = self.DEFINE.search(line) | |||
| if not m: | |||
| if self.verbose and line.find("#define") >= 0: | |||
| print "ignore %s" % (line) | |||
| return None | |||
| key = m.group("key").strip() | |||
| val = m.group("value").strip() | |||
| # enum must begin with GL_ and be all uppercase | |||
| if ((not (key.startswith("GL_") and key.isupper())) or | |||
| (self.ignore_enum.match(key) and val == "1")): | |||
| if self.verbose: | |||
| print "ignore enum %s" % (key) | |||
| return None | |||
| return (key, val) | |||
| def _parse_typedef(self, line): | |||
| """Parse a typedef line for a <type>.""" | |||
| m = self.TYPEDEF.search(line) | |||
| if not m: | |||
| if self.verbose and line.find("typedef") >= 0: | |||
| print "ignore %s" % (line) | |||
| return None | |||
| f = m.group("from").strip() | |||
| t = m.group("to").strip() | |||
| if not t.startswith("GL"): | |||
| if self.verbose: | |||
| print "ignore type %s" % (t) | |||
| return None | |||
| attrs = self._get_ctype_attrs(f) | |||
| return (f, t, attrs) | |||
| def _parse_gl_api(self, line): | |||
| """Parse a GLAPI line for a <function>.""" | |||
| m = self.GLAPI.search(line) | |||
| if not m: | |||
| if self.verbose and line.find("APIENTRY") >= 0: | |||
| print "ignore %s" % (line) | |||
| return None | |||
| rettype = m.group("return") | |||
| rettype = self._format_ctype(rettype) | |||
| if rettype == "GLvoid": | |||
| rettype = "" | |||
| name = m.group("name") | |||
| param_str = m.group("params") | |||
| chunks = self.split_params.split(param_str) | |||
| chunks = [s.strip() for s in chunks] | |||
| if len(chunks) == 1 and (chunks[0] == "void" or chunks[0] == "GLvoid"): | |||
| chunks = [] | |||
| params = [] | |||
| for c in chunks: | |||
| # split type and variable name | |||
| idx = c.rfind("*") | |||
| if idx < 0: | |||
| idx = c.rfind(" ") | |||
| if idx >= 0: | |||
| idx += 1 | |||
| ctype = c[:idx] | |||
| var = c[idx:] | |||
| else: | |||
| ctype = c | |||
| var = "unnamed" | |||
| # convert array to pointer | |||
| idx = var.find("[") | |||
| if idx >= 0: | |||
| var = var[:idx] | |||
| ctype += "*" | |||
| ctype = self._format_ctype(ctype) | |||
| var = var.strip() | |||
| if not self.need_char and ctype.find("GLchar") >= 0: | |||
| self.need_char = True | |||
| params.append((ctype, var)) | |||
| return (rettype, name, params) | |||
| def _change_level(self, line): | |||
| """Parse a #ifdef line and change level.""" | |||
| m = self.IFDEF.search(line) | |||
| if m: | |||
| ifdef = m.group("ifdef") | |||
| if not ifdef: | |||
| ifdef = m.group("if") | |||
| self.ifdef_levels.append(ifdef) | |||
| return True | |||
| m = self.ENDIF.search(line) | |||
| if m: | |||
| self.ifdef_levels.pop() | |||
| return True | |||
| return False | |||
| def _read_header(self, header): | |||
| """Open a header file and read its contents.""" | |||
| lines = [] | |||
| try: | |||
| fp = open(header, "rb") | |||
| lines = fp.readlines() | |||
| fp.close() | |||
| except IOError, e: | |||
| print "failed to read %s: %s" % (header, e) | |||
| return lines | |||
| def _cmp_enum(self, enum1, enum2): | |||
| """Compare two enums.""" | |||
| # sort by length of the values as strings | |||
| val1 = enum1[1] | |||
| val2 = enum2[1] | |||
| ret = len(val1) - len(val2) | |||
| # sort by the values | |||
| if not ret: | |||
| val1 = int(val1, 16) | |||
| val2 = int(val2, 16) | |||
| ret = val1 - val2 | |||
| # in case int cannot hold the result | |||
| if ret > 0: | |||
| ret = 1 | |||
| elif ret < 0: | |||
| ret = -1 | |||
| # sort by the names | |||
| if not ret: | |||
| if enum1[0] < enum2[0]: | |||
| ret = -1 | |||
| elif enum1[0] > enum2[0]: | |||
| ret = 1 | |||
| return ret | |||
| def _cmp_type(self, type1, type2): | |||
| """Compare two types.""" | |||
| attrs1 = type1[2] | |||
| attrs2 = type2[2] | |||
| # sort by type size | |||
| ret = attrs1[0] - attrs2[0] | |||
| # float is larger | |||
| if not ret: | |||
| ret = attrs1[1] - attrs2[1] | |||
| # signed is larger | |||
| if not ret: | |||
| ret = attrs1[2] - attrs2[2] | |||
| # reverse | |||
| ret = -ret | |||
| return ret | |||
| def _cmp_function(self, func1, func2): | |||
| """Compare two functions.""" | |||
| name1 = func1[1] | |||
| name2 = func2[1] | |||
| ret = 0 | |||
| # sort by the names | |||
| if name1 < name2: | |||
| ret = -1 | |||
| elif name1 > name2: | |||
| ret = 1 | |||
| return ret | |||
| def _postprocess_dict(self, hdict): | |||
| """Post-process a header dict and return an ordered list.""" | |||
| hlist = [] | |||
| largest = 0 | |||
| for key, cat in hdict.iteritems(): | |||
| size = len(cat["enums"]) + len(cat["types"]) + len(cat["functions"]) | |||
| # ignore empty category | |||
| if not size: | |||
| continue | |||
| cat["enums"].sort(self._cmp_enum) | |||
| # remove duplicates | |||
| dup = [] | |||
| for i in xrange(1, len(cat["enums"])): | |||
| if cat["enums"][i] == cat["enums"][i - 1]: | |||
| dup.insert(0, i) | |||
| for i in dup: | |||
| e = cat["enums"].pop(i) | |||
| if self.verbose: | |||
| print "remove duplicate enum %s" % e[0] | |||
| cat["types"].sort(self._cmp_type) | |||
| cat["functions"].sort(self._cmp_function) | |||
| # largest category comes first | |||
| if size > largest: | |||
| hlist.insert(0, (key, cat)) | |||
| largest = size | |||
| else: | |||
| hlist.append((key, cat)) | |||
| return hlist | |||
| def parse(self, header): | |||
| """Parse a header file.""" | |||
| self._reset() | |||
| if self.verbose: | |||
| print "Parsing %s" % (header) | |||
| hdict = {} | |||
| lines = self._read_header(header) | |||
| for line in lines: | |||
| if self._change_level(line): | |||
| continue | |||
| # skip until the first ifdef (i.e. __gl_h_) | |||
| if not self.ifdef_levels: | |||
| continue | |||
| cat_name = os.path.basename(header) | |||
| # check if we are in an extension | |||
| if (len(self.ifdef_levels) > 1 and | |||
| self.ifdef_levels[-1].startswith("GL_")): | |||
| cat_name = self.ifdef_levels[-1] | |||
| try: | |||
| cat = hdict[cat_name] | |||
| except KeyError: | |||
| cat = { | |||
| "enums": [], | |||
| "types": [], | |||
| "functions": [] | |||
| } | |||
| hdict[cat_name] = cat | |||
| key = "enums" | |||
| elem = self._parse_define(line) | |||
| if not elem: | |||
| key = "types" | |||
| elem = self._parse_typedef(line) | |||
| if not elem: | |||
| key = "functions" | |||
| elem = self._parse_gl_api(line) | |||
| if elem: | |||
| cat[key].append(elem) | |||
| if self.need_char: | |||
| if self.verbose: | |||
| print "define GLchar" | |||
| elem = self._parse_typedef("typedef char GLchar;") | |||
| cat["types"].append(elem) | |||
| return self._postprocess_dict(hdict) | |||
| def spaces(n, str=""): | |||
| spaces = n - len(str) | |||
| if spaces < 1: | |||
| spaces = 1 | |||
| return " " * spaces | |||
| def output_xml(name, hlist): | |||
| """Output a parsed header in OpenGLAPI XML.""" | |||
| for i in xrange(len(hlist)): | |||
| cat_name, cat = hlist[i] | |||
| print '<category name="%s">' % (cat_name) | |||
| indent = 4 | |||
| for enum in cat["enums"]: | |||
| name = enum[0][3:] | |||
| value = enum[1] | |||
| tab = spaces(41, name) | |||
| attrs = 'name="%s"%svalue="%s"' % (name, tab, value) | |||
| print '%s<enum %s/>' % (spaces(indent), attrs) | |||
| if cat["enums"] and cat["types"]: | |||
| for type in cat["types"]: | |||
| ctype = type[0] | |||
| size, is_float, is_signed = type[2] | |||
| attrs = 'name="%s"' % (type[1][2:]) | |||
| attrs += spaces(16, attrs) + 'size="%d"' % (size) | |||
| if is_float: | |||
| attrs += ' float="true"' | |||
| elif not is_signed: | |||
| attrs += ' unsigned="true"' | |||
| print '%s<type %s/>' % (spaces(indent), attrs) | |||
| for func in cat["functions"]: | |||
| ret = func[0] | |||
| name = func[1][2:] | |||
| params = func[2] | |||
| attrs = 'name="%s" offset="assign"' % name | |||
| print '%s<function %s>' % (spaces(indent), attrs) | |||
| for param in params: | |||
| attrs = 'name="%s" type="%s"' % (param[1], param[0]) | |||
| print '%s<param %s/>' % (spaces(indent * 2), attrs) | |||
| if ret: | |||
| attrs = 'type="%s"' % ret | |||
| print '%s<return %s/>' % (spaces(indent * 2), attrs) | |||
| print '%s</function>' % spaces(indent) | |||
| print '</category>' | |||
| def show_usage(): | |||
| print "Usage: %s [-v] <header> ..." % sys.argv[0] | |||
| sys.exit(1) | |||
| def main(): | |||
| try: | |||
| args, headers = getopt.getopt(sys.argv[1:], "v") | |||
| except Exception, e: | |||
| show_usage() | |||
| if not headers: | |||
| show_usage() | |||
| verbose = 0 | |||
| for arg in args: | |||
| if arg[0] == "-v": | |||
| verbose += 1 | |||
| need_xml_header = True | |||
| parser = HeaderParser(verbose) | |||
| for h in headers: | |||
| h = os.path.abspath(h) | |||
| hlist = parser.parse(h) | |||
| if need_xml_header: | |||
| print '<?xml version="1.0"?>' | |||
| print '<!DOCTYPE OpenGLAPI SYSTEM "%s/gl_API.dtd">' % GLAPI | |||
| need_xml_header = False | |||
| print '<!-- %s -->' % (h) | |||
| print '<OpenGLAPI>' | |||
| output_xml(h, hlist) | |||
| print '</OpenGLAPI>' | |||
| if __name__ == '__main__': | |||
| main() | |||