[Piglit] [PATCH 08/10] textureGather: add some more sanity checks

Chris Forbes chrisf at ijw.co.nz
Tue Oct 15 10:47:10 CEST 2013


Signed-off-by: Chris Forbes <chrisf at ijw.co.nz>
---
 tests/texturing/shaders/textureGather.c | 15 +++++++++++++--
 1 file changed, 13 insertions(+), 2 deletions(-)

diff --git a/tests/texturing/shaders/textureGather.c b/tests/texturing/shaders/textureGather.c
index 4aea294..a2de215 100644
--- a/tests/texturing/shaders/textureGather.c
+++ b/tests/texturing/shaders/textureGather.c
@@ -213,10 +213,21 @@ do_requires(void)
 		piglit_report_result(PIGLIT_SKIP);
 	}
 
+	if (comptype == SHADOW && components > 1) {
+		printf("Shadow supported with single-component textures only");
+		piglit_report_result(PIGLIT_SKIP);
+	}
+
+	if (comptype == SHADOW && comp_select != -1) {
+		printf("Shadow not supported with component select parameter");
+		piglit_report_result(PIGLIT_SKIP);
+	}
+
 	/* if we are trying to specify the component from the shader,
-	 * or use non-constant offsets, check that we have ARB_gpu_shader5
+	 * or use non-constant offsets, or use shadow comparitor,
+	 * check that we have ARB_gpu_shader5
 	 */
-	if (comp_select != -1 || use_nonconst)
+	if (comp_select != -1 || use_nonconst || comptype == SHADOW)
 		piglit_require_extension("GL_ARB_gpu_shader5");
 }
 
-- 
1.8.4



More information about the Piglit mailing list