[Piglit] [PATCH] arb_viewport_array: Only specify 150 for shader version
Jordan Justen
jordan.l.justen at intel.com
Tue Nov 26 08:57:26 PST 2013
These tests are expected to run with OpenGL 3.2, so
we should only use #version 150. We also need to
enable the GL_ARB_viewport_array extension in the
geometry shader.
Signed-off-by: Jordan Justen <jordan.l.justen at intel.com>
Cc: Jon Ashburn <jon at lunarg.com>
---
Jon, my slightly older nVidia card failed render_depthrange
before and after this change. Would you be able to test this
change on your setup?
tests/spec/arb_viewport_array/render_depthrange.c | 8 +++++---
tests/spec/arb_viewport_array/render_scissor.c | 7 ++++---
tests/spec/arb_viewport_array/render_viewport.c | 7 ++++---
3 files changed, 13 insertions(+), 9 deletions(-)
diff --git a/tests/spec/arb_viewport_array/render_depthrange.c b/tests/spec/arb_viewport_array/render_depthrange.c
index a74b7c2..f274e3e 100644
--- a/tests/spec/arb_viewport_array/render_depthrange.c
+++ b/tests/spec/arb_viewport_array/render_depthrange.c
@@ -51,7 +51,7 @@ PIGLIT_GL_TEST_CONFIG_BEGIN
PIGLIT_GL_TEST_CONFIG_END
const char *vsSource = {
- "#version 430\n"
+ "#version 150\n"
"in vec4 piglit_vertex;\n"
"void main() {\n"
" gl_Position = piglit_vertex;\n"
@@ -59,7 +59,8 @@ const char *vsSource = {
};
const char *gsSource = {
- "#version 430\n"
+ "#version 150\n"
+ "#extension GL_ARB_viewport_array : enable\n"
"layout(triangles) in;\n"
"layout(triangle_strip, max_vertices = 3) out;\n"
"uniform int idx;\n"
@@ -76,7 +77,8 @@ const char *gsSource = {
};
const char *fsSource = {
- "#version 430\n"
+ "#version 150\n"
+ "#extension GL_ARB_viewport_array : enable\n"
"uniform vec3 color;\n"
"in int gl_ViewportIndex;\n"
"void main() {\n"
diff --git a/tests/spec/arb_viewport_array/render_scissor.c b/tests/spec/arb_viewport_array/render_scissor.c
index a0d5d94..15d9583 100644
--- a/tests/spec/arb_viewport_array/render_scissor.c
+++ b/tests/spec/arb_viewport_array/render_scissor.c
@@ -207,14 +207,15 @@ piglit_init(int argc, char **argv)
piglit_require_extension("GL_ARB_viewport_array");
asprintf(&vsSource,
- "#version 410\n"
+ "#version 150\n"
"in vec4 piglit_vertex;\n"
"void main() {\n"
" gl_Position = piglit_vertex;\n"
"}\n");
asprintf(&gsSource,
- "#version 410\n"
+ "#version 150\n"
+ "#extension GL_ARB_viewport_array : enable\n"
"layout(triangles) in;\n"
"layout(triangle_strip, max_vertices = 18) out;\n"
"out vec3 color;\n"
@@ -233,7 +234,7 @@ piglit_init(int argc, char **argv)
"}\n", divX * divY);
asprintf(&fsSource,
- "#version 410\n"
+ "#version 150\n"
"in vec3 color;\n"
"void main() {\n"
" gl_FragColor = vec4(color.xyz, 1.0);\n"
diff --git a/tests/spec/arb_viewport_array/render_viewport.c b/tests/spec/arb_viewport_array/render_viewport.c
index 3274fb1..4b69945 100644
--- a/tests/spec/arb_viewport_array/render_viewport.c
+++ b/tests/spec/arb_viewport_array/render_viewport.c
@@ -48,7 +48,7 @@ PIGLIT_GL_TEST_CONFIG_BEGIN
PIGLIT_GL_TEST_CONFIG_END
const char *vsSource = {
- "#version 410\n"
+ "#version 150\n"
"in vec4 piglit_vertex;\n"
"void main() {\n"
" gl_Position = piglit_vertex;\n"
@@ -56,7 +56,8 @@ const char *vsSource = {
};
const char *gsSource = {
- "#version 410\n"
+ "#version 150\n"
+ "#extension GL_ARB_viewport_array : enable\n"
"layout(triangles) in;\n"
"layout(triangle_strip, max_vertices = 3) out;\n"
"uniform int idx;\n"
@@ -73,7 +74,7 @@ const char *gsSource = {
};
const char *fsSource = {
- "#version 410\n"
+ "#version 150\n"
"uniform vec3 color;\n"
"void main() {\n"
" gl_FragColor = vec4(color.xyz, 1.0);\n"
--
1.8.4.3
More information about the Piglit
mailing list