summaryrefslogtreecommitdiff
path: root/tests/spec/ext_texture_array
diff options
context:
space:
mode:
authorIan Romanick <ian.d.romanick@intel.com>2015-11-04 12:04:58 -0800
committerIan Romanick <ian.d.romanick@intel.com>2015-12-04 08:10:20 -0800
commitb97b64ca071b93d8e390c395edcf5f061556212a (patch)
tree4ecf5a9bb9353898ec782ffd4bfb42db4ff0960b /tests/spec/ext_texture_array
parenta82e683b82530747fe5ed8f59ecb8f90ecf66337 (diff)
ext_texture_array: Use piglit_build_simple_program
I don't think piglit_build_simple_program supported piglit_vertex and piglit_texcoord when this test was written, but it does now. Use it! Signed-off-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Matt Turner <mattst88@gmail.com>
Diffstat (limited to 'tests/spec/ext_texture_array')
-rw-r--r--tests/spec/ext_texture_array/compressed.c17
1 files changed, 5 insertions, 12 deletions
diff --git a/tests/spec/ext_texture_array/compressed.c b/tests/spec/ext_texture_array/compressed.c
index cc45cc9cf..f8acc1d16 100644
--- a/tests/spec/ext_texture_array/compressed.c
+++ b/tests/spec/ext_texture_array/compressed.c
@@ -86,24 +86,22 @@ PIGLIT_GL_TEST_CONFIG_END
static const char vs_text[] =
#ifdef PIGLIT_USE_OPENGL
"#version 120\n"
- "#define piglit_Vertex gl_Vertex\n"
- "#define piglit_MultiTexCoord0 gl_MultiTexCoord0\n"
"#define piglit_in attribute\n"
"#define piglit_out varying\n"
#else // PIGLIT_USE_OPENGL_ES3
"#version 300 es\n"
"#define piglit_in in\n"
"#define piglit_out out\n"
- "piglit_in vec4 piglit_Vertex;\n"
- "piglit_in vec4 piglit_MultiTexCoord0;\n"
#endif
+ "piglit_in vec4 piglit_vertex;\n"
+ "piglit_in vec4 piglit_texcoord;\n"
"piglit_out vec3 texcoord;\n"
"uniform mat4 proj;\n"
"uniform int layer;\n"
"void main()\n"
"{\n"
- " gl_Position = proj * piglit_Vertex;\n"
- " texcoord = vec3(piglit_MultiTexCoord0.xy, float(layer));\n"
+ " gl_Position = proj * piglit_vertex;\n"
+ " texcoord = vec3(piglit_texcoord.xy, float(layer));\n"
"}\n";
static const char fs_text[] =
@@ -251,12 +249,7 @@ piglit_init(int argc, char **argv)
}
/* Create the shaders */
- prog = piglit_build_simple_program_unlinked(vs_text, fs_text);
- glBindAttribLocation(prog, PIGLIT_ATTRIB_POS, "piglit_Vertex");
- glBindAttribLocation(prog, PIGLIT_ATTRIB_TEX, "piglit_MultiTexCoord0");
- glLinkProgram(prog);
- if (!piglit_link_check_status(prog))
- piglit_report_result(PIGLIT_FAIL);
+ prog = piglit_build_simple_program(vs_text, fs_text);
proj_loc = glGetUniformLocation(prog, "proj");
layer_loc = glGetUniformLocation(prog, "layer");
if (!piglit_check_gl_error(GL_NO_ERROR))