[Piglit] [PATCH 7/9] built-in-constants: fix tessellation compile failures

Marek Olšák maraeo at gmail.com
Tue Jun 16 13:57:40 PDT 2015


From: Marek Olšák <marek.olsak at amd.com>

---
 tests/shaders/built-in-constants.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/tests/shaders/built-in-constants.c b/tests/shaders/built-in-constants.c
index dc428db..9eeb0d1 100644
--- a/tests/shaders/built-in-constants.c
+++ b/tests/shaders/built-in-constants.c
@@ -444,6 +444,14 @@ piglit_init(int argc, char **argv)
 	} else if (glsl_version < required_glsl_version)
 		piglit_report_result(PIGLIT_SKIP);
 
+	/* Tessellation shaders must use the #extension directive. */
+	if (piglit_is_extension_supported("GL_ARB_tessellation_shader")) {
+		assert(num_required_extensions < ARRAY_SIZE(required_extensions));
+		required_extensions[num_required_extensions] =
+			strdup("GL_ARB_tessellation_shader");
+		num_required_extensions++;
+	}
+
 	/* Process the list of required extensions.  While doing this,
 	 * generate the GLSL code that will enable those extensions in the
 	 * shaders.
-- 
2.1.0



More information about the Piglit mailing list