X-Git-Url: https://git.cworth.org/git?a=blobdiff_plain;f=glapi.py;h=22db8f271bb5bbfd9e4abe5363d039000557946a;hb=f12c6bcea97c445ef3805e40d06fd81672900895;hp=2309ea9db885bd16fdb8390c4ebcac8871f868d4;hpb=e6a50bd11a981afdb13501cb739b1666bbf444eb;p=apitrace diff --git a/glapi.py b/glapi.py index 2309ea9..22db8f2 100644 --- a/glapi.py +++ b/glapi.py @@ -54,8 +54,8 @@ GLhalfNV = Alias("GLhalfNV", UShort) GLint64EXT = Alias("GLint64EXT", LongLong) GLuint64EXT = Alias("GLuint64EXT", ULongLong) -GLstring = String("const GLchar *") -GLstringARB = String("const GLcharARB *") +GLstring = String("GLchar *") +GLstringARB = String("GLcharARB *") GLenum = Enum("GLenum", [ #"GL_NO_ERROR", # 0x0 @@ -2963,9 +2963,9 @@ def extended_functions(Function): F(Void, "glDeleteShader", [(GLuint, "program")]), F(Void, "glDetachShader", [(GLuint, "program"), (GLuint, "shader")]), F(Void, "glGetAttachedShaders", [(GLuint, "program"), (GLsizei, "maxCount"), Out(Pointer(GLsizei), "count"), Out(Array(GLuint, "maxCount"), "obj")], sideeffects=False), - F(Void, "glGetProgramInfoLog", [(GLuint, "program"), (GLsizei, "bufSize"), (OpaquePointer(GLsizei), "length"), (OpaquePointer(GLchar), "infoLog")], sideeffects=False), + F(Void, "glGetProgramInfoLog", [(GLuint, "program"), (GLsizei, "bufSize"), Out(Pointer(GLsizei), "length"), Out(GLstring, "infoLog")], sideeffects=False), F(Void, "glGetProgramiv", [(GLuint, "program"), (GLenum, "pname"), (OpaquePointer(GLint), "params")], sideeffects=False), - F(Void, "glGetShaderInfoLog", [(GLuint, "shader"), (GLsizei, "bufSize"), (OpaquePointer(GLsizei), "length"), (OpaquePointer(GLchar), "infoLog")], sideeffects=False), + F(Void, "glGetShaderInfoLog", [(GLuint, "shader"), (GLsizei, "bufSize"), Out(Pointer(GLsizei), "length"), Out(GLstring, "infoLog")], sideeffects=False), F(Void, "glGetShaderiv", [(GLuint, "shader"), (GLenum, "pname"), (OpaquePointer(GLint), "params")], sideeffects=False), F(GLboolean, "glIsProgram", [(GLuint, "program")]), F(GLboolean, "glIsShader", [(GLuint, "shader")]), @@ -3002,13 +3002,13 @@ def extended_functions(Function): F(Void, "glGetVertexAttribfvARB", [(GLuint, "index"), (GLenum, "pname"), (OpaquePointer(GLfloat), "params")], sideeffects=False), F(Void, "glGetVertexAttribivARB", [(GLuint, "index"), (GLenum, "pname"), (OpaquePointer(GLint), "params")], sideeffects=False), F(Void, "glProgramEnvParameter4dARB", [(GLenum, "target"), (GLuint, "index"), (GLdouble, "x"), (GLdouble, "y"), (GLdouble, "z"), (GLdouble, "w")]), - F(Void, "glProgramEnvParameter4dvARB", [(GLenum, "target"), (GLuint, "index"), (OpaquePointer(Const(GLdouble)), "params")]), + F(Void, "glProgramEnvParameter4dvARB", [(GLenum, "target"), (GLuint, "index"), (Array(Const(GLdouble), "4"), "params")]), F(Void, "glProgramEnvParameter4fARB", [(GLenum, "target"), (GLuint, "index"), (GLfloat, "x"), (GLfloat, "y"), (GLfloat, "z"), (GLfloat, "w")]), - F(Void, "glProgramEnvParameter4fvARB", [(GLenum, "target"), (GLuint, "index"), (OpaquePointer(Const(GLfloat)), "params")]), + F(Void, "glProgramEnvParameter4fvARB", [(GLenum, "target"), (GLuint, "index"), (Array(Const(GLfloat), "4"), "params")]), F(Void, "glProgramLocalParameter4dARB", [(GLenum, "target"), (GLuint, "index"), (GLdouble, "x"), (GLdouble, "y"), (GLdouble, "z"), (GLdouble, "w")]), - F(Void, "glProgramLocalParameter4dvARB", [(GLenum, "target"), (GLuint, "index"), (OpaquePointer(Const(GLdouble)), "params")]), + F(Void, "glProgramLocalParameter4dvARB", [(GLenum, "target"), (GLuint, "index"), (Array(Const(GLdouble), "4"), "params")]), F(Void, "glProgramLocalParameter4fARB", [(GLenum, "target"), (GLuint, "index"), (GLfloat, "x"), (GLfloat, "y"), (GLfloat, "z"), (GLfloat, "w")]), - F(Void, "glProgramLocalParameter4fvARB", [(GLenum, "target"), (GLuint, "index"), (OpaquePointer(Const(GLfloat)), "params")]), + F(Void, "glProgramLocalParameter4fvARB", [(GLenum, "target"), (GLuint, "index"), (Array(Const(GLfloat), "4"), "params")]), F(Void, "glProgramStringARB", [(GLenum, "target"), (GLenum, "format"), (GLsizei, "len"), (String("const void *", "len"), "string")]), F(Void, "glVertexAttrib1dARB", [(GLuint, "index"), (GLdouble, "x")]), F(Void, "glVertexAttrib1dvARB", [(GLuint, "index"), (Array(Const(GLdouble), "1"), "v")]), @@ -3072,34 +3072,34 @@ def extended_functions(Function): F(GLhandleARB, "glCreateShaderObjectARB", [(GLenum, "shaderType")]), F(Void, "glDeleteObjectARB", [(GLhandleARB, "obj")]), F(Void, "glDetachObjectARB", [(GLhandleARB, "containerObj"), (GLhandleARB, "attachedObj")]), - F(Void, "glGetActiveUniformARB", [(GLhandleARB, "program"), (GLuint, "index"), (GLsizei, "bufSize"), (OpaquePointer(GLsizei), "length"), (OpaquePointer(GLint), "size"), (OpaquePointer(GLenum), "type"), (OpaquePointer(GLcharARB), "name")], sideeffects=False), + F(Void, "glGetActiveUniformARB", [(GLhandleARB, "program"), (GLuint, "index"), (GLsizei, "bufSize"), Out(Pointer(GLsizei), "length"), Out(Pointer(GLint), "size"), Out(Pointer(GLenum), "type"), Out(GLstringARB, "name")], sideeffects=False), F(Void, "glGetAttachedObjectsARB", [(GLhandleARB, "containerObj"), (GLsizei, "maxLength"), (OpaquePointer(GLsizei), "length"), (OpaquePointer(GLhandleARB), "infoLog")], sideeffects=False), F(GLhandleARB, "glGetHandleARB", [(GLenum, "pname")], sideeffects=False), - F(Void, "glGetInfoLogARB", [(GLhandleARB, "obj"), (GLsizei, "maxLength"), (OpaquePointer(GLsizei), "length"), (OpaquePointer(GLcharARB), "infoLog")], sideeffects=False), + F(Void, "glGetInfoLogARB", [(GLhandleARB, "obj"), (GLsizei, "maxLength"), Out(Pointer(GLsizei), "length"), Out(GLstringARB, "infoLog")], sideeffects=False), F(Void, "glGetObjectParameterfvARB", [(GLhandleARB, "obj"), (GLenum, "pname"), (OpaquePointer(GLfloat), "params")], sideeffects=False), F(Void, "glGetObjectParameterivARB", [(GLhandleARB, "obj"), (GLenum, "pname"), (OpaquePointer(GLint), "params")], sideeffects=False), - F(Void, "glGetShaderSourceARB", [(GLhandleARB, "shader"), (GLsizei, "bufSize"), (OpaquePointer(GLsizei), "length"), (OpaquePointer(GLcharARB), "source")], sideeffects=False), + F(Void, "glGetShaderSourceARB", [(GLhandleARB, "shader"), (GLsizei, "bufSize"), Out(Pointer(GLsizei), "length"), Out(GLstringARB, "source")], sideeffects=False), F(GLint, "glGetUniformLocationARB", [(GLhandleARB, "program"), (OpaquePointer(Const(GLcharARB)), "name")], sideeffects=False), F(Void, "glGetUniformfvARB", [(GLhandleARB, "program"), (GLint, "location"), (OpaquePointer(GLfloat), "params")], sideeffects=False), F(Void, "glGetUniformivARB", [(GLhandleARB, "program"), (GLint, "location"), (OpaquePointer(GLint), "params")], sideeffects=False), F(Void, "glLinkProgramARB", [(GLhandleARB, "program")]), - F(Void, "glShaderSourceARB", [(GLhandleARB, "shader"), (GLsizei, "count"), (Array(GLstringARB, "count"), "string"), (Array(Const(GLint), "count"), "length")]), # FIXME + F(Void, "glShaderSourceARB", [(GLhandleARB, "shader"), (GLsizei, "count"), (Const(Array(Const(GLstringARB), "count")), "string"), (Const(Array(GLint, "count")), "length")]), F(Void, "glUniform1fARB", [(GLint, "location"), (GLfloat, "v0")]), - F(Void, "glUniform1fvARB", [(GLint, "location"), (GLsizei, "count"), (OpaquePointer(Const(GLfloat)), "value")]), + F(Void, "glUniform1fvARB", [(GLint, "location"), (GLsizei, "count"), (Const(Array(GLfloat, "count")), "value")]), F(Void, "glUniform1iARB", [(GLint, "location"), (GLint, "v0")]), - F(Void, "glUniform1ivARB", [(GLint, "location"), (GLsizei, "count"), (OpaquePointer(Const(GLint)), "value")]), + F(Void, "glUniform1ivARB", [(GLint, "location"), (GLsizei, "count"), (Const(Array(GLint, "count")), "value")]), F(Void, "glUniform2fARB", [(GLint, "location"), (GLfloat, "v0"), (GLfloat, "v1")]), - F(Void, "glUniform2fvARB", [(GLint, "location"), (GLsizei, "count"), (OpaquePointer(Const(GLfloat)), "value")]), + F(Void, "glUniform2fvARB", [(GLint, "location"), (GLsizei, "count"), (Const(Array(GLfloat, "(2*count)")), "value")]), F(Void, "glUniform2iARB", [(GLint, "location"), (GLint, "v0"), (GLint, "v1")]), - F(Void, "glUniform2ivARB", [(GLint, "location"), (GLsizei, "count"), (OpaquePointer(Const(GLint)), "value")]), + F(Void, "glUniform2ivARB", [(GLint, "location"), (GLsizei, "count"), (Const(Array(GLint, "(2*count)")), "value")]), F(Void, "glUniform3fARB", [(GLint, "location"), (GLfloat, "v0"), (GLfloat, "v1"), (GLfloat, "v2")]), - F(Void, "glUniform3fvARB", [(GLint, "location"), (GLsizei, "count"), (OpaquePointer(Const(GLfloat)), "value")]), + F(Void, "glUniform3fvARB", [(GLint, "location"), (GLsizei, "count"), (Const(Array(GLfloat, "(3*count)")), "value")]), F(Void, "glUniform3iARB", [(GLint, "location"), (GLint, "v0"), (GLint, "v1"), (GLint, "v2")]), - F(Void, "glUniform3ivARB", [(GLint, "location"), (GLsizei, "count"), (OpaquePointer(Const(GLint)), "value")]), + F(Void, "glUniform3ivARB", [(GLint, "location"), (GLsizei, "count"), (Const(Array(GLint, "(3*count)")), "value")]), F(Void, "glUniform4fARB", [(GLint, "location"), (GLfloat, "v0"), (GLfloat, "v1"), (GLfloat, "v2"), (GLfloat, "v3")]), - F(Void, "glUniform4fvARB", [(GLint, "location"), (GLsizei, "count"), (OpaquePointer(Const(GLfloat)), "value")]), + F(Void, "glUniform4fvARB", [(GLint, "location"), (GLsizei, "count"), (Const(Array(GLfloat, "(4*count)")), "value")]), F(Void, "glUniform4iARB", [(GLint, "location"), (GLint, "v0"), (GLint, "v1"), (GLint, "v2"), (GLint, "v3")]), - F(Void, "glUniform4ivARB", [(GLint, "location"), (GLsizei, "count"), (OpaquePointer(Const(GLint)), "value")]), + F(Void, "glUniform4ivARB", [(GLint, "location"), (GLsizei, "count"), (Const(Array(GLint, "(4*count)")), "value")]), F(Void, "glUniformMatrix2fvARB", [(GLint, "location"), (GLsizei, "count"), (GLboolean, "transpose"), (OpaquePointer(Const(GLfloat)), "value")]), F(Void, "glUniformMatrix3fvARB", [(GLint, "location"), (GLsizei, "count"), (GLboolean, "transpose"), (OpaquePointer(Const(GLfloat)), "value")]), F(Void, "glUniformMatrix4fvARB", [(GLint, "location"), (GLsizei, "count"), (GLboolean, "transpose"), (OpaquePointer(Const(GLfloat)), "value")]), @@ -3209,7 +3209,7 @@ def extended_functions(Function): F(GLboolean, "glAreProgramsResidentNV", [(GLsizei, "n"), (Array(Const(GLprogram), "n"), "ids"), Out(Array(GLboolean, "n"), "residences")]), F(Void, "glBindProgramNV", [(GLenum, "target"), (GLprogram, "program")]), F(Void, "glDeleteProgramsNV", [(GLsizei, "n"), (Array(Const(GLprogram), "n"), "programs")]), - F(Void, "glExecuteProgramNV", [(GLenum, "target"), (GLprogram, "id"), (OpaquePointer(Const(GLfloat)), "params")]), + F(Void, "glExecuteProgramNV", [(GLenum, "target"), (GLprogram, "id"), (Const(Array(GLfloat, "4")), "params")]), F(Void, "glGenProgramsNV", [(GLsizei, "n"), Out(Array(GLprogram, "n"), "programs")]), F(Void, "glGetProgramParameterdvNV", [(GLenum, "target"), (GLuint, "index"), (GLenum, "pname"), (OpaquePointer(GLdouble), "params")], sideeffects=False), F(Void, "glGetProgramParameterfvNV", [(GLenum, "target"), (GLuint, "index"), (GLenum, "pname"), (OpaquePointer(GLfloat), "params")], sideeffects=False),