[Piglit] [PATCH 07/10] shader_runner: enable scissor command
Jordan Justen
jordan.l.justen at intel.com
Wed Oct 16 01:33:11 CEST 2013
Signed-off-by: Jordan Justen <jordan.l.justen at intel.com>
---
tests/shaders/shader_runner.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/tests/shaders/shader_runner.c b/tests/shaders/shader_runner.c
index 6841cd3..b3f17e3 100644
--- a/tests/shaders/shader_runner.c
+++ b/tests/shaders/shader_runner.c
@@ -1927,6 +1927,13 @@ piglit_display(void)
} else if (string_match("time show", line)) {
uint64_t delta = piglit_get_microseconds() - microseconds;
printf("microseconds: %lu\n", delta);
+ } else if (string_match("scissor off", line)) {
+ glDisable(GL_SCISSOR_TEST);
+ } else if (sscanf(line,
+ "scissor %d %d %d %d",
+ &x, &y, &w, &h) == 4) {
+ glEnable(GL_SCISSOR_TEST);
+ glScissor(x, y, w, h);
} else if ((line[0] != '\n') && (line[0] != '\0')
&& (line[0] != '#')) {
printf("unknown command \"%s\"\n", line);
--
1.7.10.4
More information about the Piglit
mailing list