Commit fd424ad3 authored by Ian Romanick's avatar Ian Romanick

Add vertex attribute pointer related functions to piglit wrapper

These functions were also not part of core (for GLSL) until OpenGL 2.0.
parent 2fdf2d69
......@@ -49,6 +49,9 @@ PFNGLUNIFORM4FVPROC piglit_Uniform4fv = NULL;
PFNGLUNIFORM1IPROC piglit_Uniform1i = NULL;
PFNGLUNIFORMMATRIX4FVPROC piglit_UniformMatrix4fv = NULL;
PFNGLGETUNIFORMFVPROC piglit_GetUniformfv = NULL;
PFNGLVERTEXATTRIBPOINTERPROC piglit_VertexAttribPointer = NULL;
PFNGLENABLEVERTEXATTRIBARRAYPROC piglit_EnableVertexAttribArray = NULL;
PFNGLDISABLEVERTEXATTRIBARRAYPROC piglit_DisableVertexAttribArray = NULL;
static void
init_functions_from_core(void)
......@@ -75,6 +78,9 @@ init_functions_from_core(void)
piglit_Uniform1i = glUniform1i;
piglit_UniformMatrix4fv = glUniformMatrix4fv;
piglit_GetUniformfv = glGetUniformfv;
piglit_VertexAttribPointer = glVertexAttribPointer;
piglit_EnableVertexAttribArray = glEnableVertexAttribArray;
piglit_DisableVertexAttribArray = glDisableVertexAttribArray;
}
static void
......@@ -102,6 +108,9 @@ init_functions_from_extension(void)
piglit_Uniform1i = glUniform1iARB;
piglit_UniformMatrix4fv = glUniformMatrix4fvARB;
piglit_GetUniformfv = glGetUniformfvARB;
piglit_VertexAttribPointer = glVertexAttribPointerARB;
piglit_EnableVertexAttribArray = glEnableVertexAttribArrayARB;
piglit_DisableVertexAttribArray = glDisableVertexAttribArrayARB;
}
void
......
......@@ -183,6 +183,9 @@ extern GLint piglit_ARBfp_pass_through;
#define piglit_Uniform1i glUniform1i
#define piglit_UniformMatrix4fv glUniformMatrix4fv
#define piglit_GetUniformfv glGetUniformfv
#define piglit_VertexAttribPointer glVertexAttribPointer
#define piglit_EnableVertexAttribArray glEnableVertexAttribArray
#define piglit_DisableVertexAttribArray glDisableVertexAttribArray
#else
extern PFNGLATTACHSHADERPROC piglit_AttachShader;
extern PFNGLBINDATTRIBLOCATIONPROC piglit_BindAttribLocation;
......@@ -206,6 +209,9 @@ extern PFNGLUNIFORM4FVPROC piglit_Uniform4fv;
extern PFNGLUNIFORM1IPROC piglit_Uniform1i;
extern PFNGLUNIFORMMATRIX4FVPROC piglit_UniformMatrix4fv;
extern PFNGLGETUNIFORMFVPROC piglit_GetUniformfv;
extern PFNGLVERTEXATTRIBPOINTERPROC piglit_VertexAttribPointer;
extern PFNGLENABLEVERTEXATTRIBARRAYPROC piglit_EnableVertexAttribArray;
extern PFNGLDISABLEVERTEXATTRIBARRAYPROC piglit_DisableVertexAttribArray;
#endif
/*@}*/
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment