summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Forbes <chrisf@ijw.co.nz>2014-04-13 00:34:05 +1200
committerChris Forbes <chrisf@ijw.co.nz>2014-04-16 18:39:40 +1200
commit6fcadaefa628ff4e1a390391aec0d65cbae2d75c (patch)
treed6f650987e7ef0d661a71e4be98fc13b02f204e8
parent223b61fc6dcac7011fc36e93c3187908c51a0700 (diff)
depth-tex-compare: Get rid of handrolled enum strings
Signed-off-by: Chris Forbes <chrisf@ijw.co.nz> Reviewed-by: Brian Paul <brianp@vmware.com>
-rw-r--r--tests/texturing/depth-tex-compare.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/tests/texturing/depth-tex-compare.c b/tests/texturing/depth-tex-compare.c
index 9fbd56dab..9afadb112 100644
--- a/tests/texturing/depth-tex-compare.c
+++ b/tests/texturing/depth-tex-compare.c
@@ -47,15 +47,6 @@ PIGLIT_GL_TEST_CONFIG_END
static GLuint tex;
-static const char *const compare_names[8] = {
- "GL_NEVER", "GL_LESS", "GL_EQUAL", "GL_LEQUAL",
- "GL_GREATER", "GL_NOTEQUAL", "GL_GEQUAL", "GL_ALWAYS"
-};
-
-static const char *const mode_names[3] = {
- "GL_ALPHA", "GL_LUMINANCE", "GL_INTENSITY"
-};
-
void
piglit_init(int argc, char **argv)
{
@@ -235,8 +226,8 @@ piglit_display(void)
color)) {
if (!piglit_automatic) {
printf("compare = %s, mode = %s\n",
- compare_names[compare - GL_NEVER],
- mode_names[col]);
+ piglit_get_gl_enum_name(compare),
+ piglit_get_gl_enum_name(modes[col]));
}
pass = GL_FALSE;