summaryrefslogtreecommitdiff
path: root/tests/shaders/vp-max-array.c
diff options
context:
space:
mode:
authorIan Romanick <ian.d.romanick@intel.com>2011-08-30 11:24:20 -0700
committerIan Romanick <ian.d.romanick@intel.com>2011-09-04 18:14:51 -0700
commit0c66d2bcd8b1227d341d183cca5c3c269017aeb0 (patch)
tree2d74d9adaf84f1cd098bb8fd8161237c2bbd6062 /tests/shaders/vp-max-array.c
parent9c0a5e8f4f1e56ec20b2094f0789949601f33f27 (diff)
vp-max-array: Exercise GL_MAX_PROGRAM_ENV_PARAMETERS_ARB
Tested-by: Brian Paul <brianp@vmware.com>
Diffstat (limited to 'tests/shaders/vp-max-array.c')
-rw-r--r--tests/shaders/vp-max-array.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/shaders/vp-max-array.c b/tests/shaders/vp-max-array.c
index 6b4947308..82bd8af77 100644
--- a/tests/shaders/vp-max-array.c
+++ b/tests/shaders/vp-max-array.c
@@ -206,4 +206,16 @@ piglit_init(int argc, char **argv)
"local", max_local_parameters - 47, max_local_parameters - 1);
(void) piglit_compile_program(GL_VERTEX_PROGRAM_ARB, shader_source);
+
+ /* Generate a program that uses as much of the env parameter space
+ * as possible. This basically tries to hit both ends of the
+ * program.env array without making assumptions about the relative
+ * amount of parameter space. We only assume that the
+ * minimum-maximums of 96 are respected by the GL implementation.
+ */
+ snprintf(shader_source, len, max_local_template,
+ "env",
+ "env", max_env_parameters - 47, max_env_parameters - 1);
+
+ (void) piglit_compile_program(GL_VERTEX_PROGRAM_ARB, shader_source);
}