diff options
author | Chad Versace <chad.versace@linux.intel.com> | 2012-09-28 06:13:10 -0700 |
---|---|---|
committer | Chad Versace <chad.versace@linux.intel.com> | 2012-10-09 19:08:31 -0700 |
commit | 973db3e1743682c6ac8f58301c5e8f97588f6520 (patch) | |
tree | 1cda2236128063df45f52809b4219e41a1e2d7ae | |
parent | 8ed4af46b76cb7fe74ed6d228302141f66d49dc4 (diff) |
util: Convert GL tests to use PIGLIT_GL_CONFIG_BEGIN/END
This patch has two components.
1. In tests/util/piglit-framework-gl.h, replace the definition of
PIGLIT_GL_TEST_MAIN with the macro block PIGLIT_GL_CONFIG_BEGIN/END.
The macro PIGLIT_GL_TEST_MAIN was very restrictive. It was a fixed-arity
macro function that allowed a test to set only set 3 values: window width,
height, and visual. It would have been difficult to shoehorn optional test
attributes into such a fixed-arity macro function. Allowing optional
attributes is an essential feature because a following commit adds
optional fields to struct piglit_gl_test_config.
The macro block PIGLIT_GL_TEST_CONFIG_BEGIN/END is more flexible. Within
it the test is allowed to arbitrarilty modify the piglit_gl_test_config
structure.
2. In each GL test source, replace PIGLIT_GL_TEST_MAIN with
a PIGLIT_GL_TEST_CONFIG_BEGIN/END block.
Reviewed-and-tested-by: Jordan Justen <jordan.l.justen@intel.com>
Tested-by: Paul Berry <stereotype441@gmail.com>
Acked-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
688 files changed, 4807 insertions, 2715 deletions
diff --git a/tests/asmparsertest/asmparsertest.c b/tests/asmparsertest/asmparsertest.c index e18760377..b916555bd 100644 --- a/tests/asmparsertest/asmparsertest.c +++ b/tests/asmparsertest/asmparsertest.c @@ -30,10 +30,13 @@ #define TRUE (!FALSE) #endif -PIGLIT_GL_TEST_MAIN( - 250 /*window_width*/, - 250 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_SINGLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 250; + config.window_height = 250; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_SINGLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END char * unix_line_endings(const char *input, size_t length) diff --git a/tests/bugs/crash-cubemap-order.c b/tests/bugs/crash-cubemap-order.c index f5c570567..fa72ba431 100644 --- a/tests/bugs/crash-cubemap-order.c +++ b/tests/bugs/crash-cubemap-order.c @@ -8,10 +8,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/bugs/crash-texparameter-before-teximage.c b/tests/bugs/crash-texparameter-before-teximage.c index e1ca76bb2..e01d993df 100644 --- a/tests/bugs/crash-texparameter-before-teximage.c +++ b/tests/bugs/crash-texparameter-before-teximage.c @@ -9,10 +9,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/bugs/drawbuffer-modes.c b/tests/bugs/drawbuffer-modes.c index 44a264819..7b0ce720a 100644 --- a/tests/bugs/drawbuffer-modes.c +++ b/tests/bugs/drawbuffer-modes.c @@ -36,10 +36,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END float color[7][4] = { { 0.1, 0.2, 0.3, 1.0 }, diff --git a/tests/bugs/fdo10370.c b/tests/bugs/fdo10370.c index f050adcd6..fa56e2112 100644 --- a/tests/bugs/fdo10370.c +++ b/tests/bugs/fdo10370.c @@ -5,10 +5,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_SINGLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_SINGLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define BITMAP_WIDTH 1 #define BITMAP_HEIGHT 1 diff --git a/tests/bugs/fdo14575.c b/tests/bugs/fdo14575.c index 2d8865aeb..df7b617f5 100644 --- a/tests/bugs/fdo14575.c +++ b/tests/bugs/fdo14575.c @@ -32,10 +32,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_SINGLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_SINGLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char**argv) diff --git a/tests/bugs/fdo20701.c b/tests/bugs/fdo20701.c index cf7d0bbd2..e2c57ae33 100644 --- a/tests/bugs/fdo20701.c +++ b/tests/bugs/fdo20701.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLuint fb; static GLuint tex; diff --git a/tests/bugs/fdo22540.c b/tests/bugs/fdo22540.c index b28f17f96..0940a6e2b 100644 --- a/tests/bugs/fdo22540.c +++ b/tests/bugs/fdo22540.c @@ -25,10 +25,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLuint vBuffer; diff --git a/tests/bugs/fdo23489.c b/tests/bugs/fdo23489.c index f4e2195c5..f9bcc6af8 100644 --- a/tests/bugs/fdo23489.c +++ b/tests/bugs/fdo23489.c @@ -5,10 +5,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 250 /*window_width*/, - 250 /*window_height*/, - PIGLIT_GL_VISUAL_SINGLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 250; + config.window_height = 250; + config.window_visual = PIGLIT_GL_VISUAL_SINGLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/bugs/fdo23670-depth_test.c b/tests/bugs/fdo23670-depth_test.c index 0b806f656..40a1f95f5 100644 --- a/tests/bugs/fdo23670-depth_test.c +++ b/tests/bugs/fdo23670-depth_test.c @@ -26,10 +26,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/bugs/fdo23670-drawpix_stencil.c b/tests/bugs/fdo23670-drawpix_stencil.c index f254a8d31..f07d74b6b 100644 --- a/tests/bugs/fdo23670-drawpix_stencil.c +++ b/tests/bugs/fdo23670-drawpix_stencil.c @@ -26,10 +26,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/bugs/fdo24066.c b/tests/bugs/fdo24066.c index b32189611..13e668147 100644 --- a/tests/bugs/fdo24066.c +++ b/tests/bugs/fdo24066.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 16 /*window_width*/, - 16 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 16; + config.window_height = 16; + config.window_visual = PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) { diff --git a/tests/bugs/fdo25614-genmipmap.c b/tests/bugs/fdo25614-genmipmap.c index 7c90ec50c..9d7724642 100644 --- a/tests/bugs/fdo25614-genmipmap.c +++ b/tests/bugs/fdo25614-genmipmap.c @@ -40,10 +40,13 @@ #define TEST_COLS 5 #define BOX_SIZE (1 << (TEST_COLS + 1)) -PIGLIT_GL_TEST_MAIN( - (BOX_SIZE + 2) * TEST_COLS + 1 /*window_width*/, - (BOX_SIZE + 1) + 1 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (BOX_SIZE+2)*TEST_COLS+1; + config.window_height = (BOX_SIZE+1)+1; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex[1]; diff --git a/tests/bugs/fdo28551.c b/tests/bugs/fdo28551.c index dc4173f7b..ea4a4a53f 100644 --- a/tests/bugs/fdo28551.c +++ b/tests/bugs/fdo28551.c @@ -26,10 +26,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/bugs/fdo31934.c b/tests/bugs/fdo31934.c index f1c69b53b..cf262c9b4 100644 --- a/tests/bugs/fdo31934.c +++ b/tests/bugs/fdo31934.c @@ -1,9 +1,12 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 512 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 512; + config.window_visual = PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char *argv[]) diff --git a/tests/bugs/fdo9833.c b/tests/bugs/fdo9833.c index 8d8ca39ed..06ac13bf4 100644 --- a/tests/bugs/fdo9833.c +++ b/tests/bugs/fdo9833.c @@ -5,10 +5,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/bugs/point-sprite.c b/tests/bugs/point-sprite.c index 08c356015..d9184486b 100644 --- a/tests/bugs/point-sprite.c +++ b/tests/bugs/point-sprite.c @@ -34,10 +34,13 @@ #define TEST_COLS 6 #define TEST_ROWS 2 -PIGLIT_GL_TEST_MAIN( - 1 + ((BOX_SIZE + 1) * TEST_COLS) /*window_width*/, - 1 + ((BOX_SIZE + 1) * TEST_ROWS) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 1+((BOX_SIZE+1)*TEST_COLS); + config.window_height = 1+((BOX_SIZE+1)*TEST_ROWS); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static float maxSize = 0.0f; static GLuint tex; diff --git a/tests/bugs/r300-readcache.c b/tests/bugs/r300-readcache.c index 3461e4a75..709783a47 100644 --- a/tests/bugs/r300-readcache.c +++ b/tests/bugs/r300-readcache.c @@ -17,10 +17,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END static GLfloat colors[8][3] = { { 1.0, 1.0, 1.0 }, diff --git a/tests/bugs/tex1d-2dborder.c b/tests/bugs/tex1d-2dborder.c index f2bcc1d31..aa7d762a3 100644 --- a/tests/bugs/tex1d-2dborder.c +++ b/tests/bugs/tex1d-2dborder.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLfloat TextureColor[3] = { 1.0, 0.5, 0.0 }; diff --git a/tests/bugs/tri-tex-crash.c b/tests/bugs/tri-tex-crash.c index 6702e60a9..d706453f3 100644 --- a/tests/bugs/tri-tex-crash.c +++ b/tests/bugs/tri-tex-crash.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static void make_texture(void) diff --git a/tests/bugs/vbo-buffer-unmap.c b/tests/bugs/vbo-buffer-unmap.c index 0c13f70b9..affa56d47 100644 --- a/tests/bugs/vbo-buffer-unmap.c +++ b/tests/bugs/vbo-buffer-unmap.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-1d.c b/tests/fbo/fbo-1d.c index c6fa03494..67ea7448e 100644 --- a/tests/fbo/fbo-1d.c +++ b/tests/fbo/fbo-1d.c @@ -35,10 +35,13 @@ #define BUF_WIDTH 32 -PIGLIT_GL_TEST_MAIN( - 50 /*window_width*/, - 20 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 50; + config.window_height = 20; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static int create_1d_fbo(void) diff --git a/tests/fbo/fbo-3d.c b/tests/fbo/fbo-3d.c index 1b7dda058..f3ca36c32 100644 --- a/tests/fbo/fbo-3d.c +++ b/tests/fbo/fbo-3d.c @@ -36,10 +36,13 @@ #define BUF_WIDTH 32 #define BUF_HEIGHT 32 -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define NUM_DEPTHS 6 #define POT_DEPTHS 8 diff --git a/tests/fbo/fbo-alpha.c b/tests/fbo/fbo-alpha.c index 2778a4d49..8bd6be104 100644 --- a/tests/fbo/fbo-alpha.c +++ b/tests/fbo/fbo-alpha.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-alphatest-formats.c b/tests/fbo/fbo-alphatest-formats.c index d8205d0bd..5fad26c9a 100644 --- a/tests/fbo/fbo-alphatest-formats.c +++ b/tests/fbo/fbo-alphatest-formats.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" #include "fbo-formats.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** * Draw a quad with alpha testing diff --git a/tests/fbo/fbo-alphatest-nocolor-ff.c b/tests/fbo/fbo-alphatest-nocolor-ff.c index a82be7678..14314b285 100644 --- a/tests/fbo/fbo-alphatest-nocolor-ff.c +++ b/tests/fbo/fbo-alphatest-nocolor-ff.c @@ -32,10 +32,13 @@ #define BUF_WIDTH 32 -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static void create_fbo(GLuint *out_tex) { diff --git a/tests/fbo/fbo-alphatest-nocolor.c b/tests/fbo/fbo-alphatest-nocolor.c index 06983d610..bf96aea95 100644 --- a/tests/fbo/fbo-alphatest-nocolor.c +++ b/tests/fbo/fbo-alphatest-nocolor.c @@ -31,10 +31,13 @@ #define BUF_WIDTH 32 -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END GLuint prog; diff --git a/tests/fbo/fbo-array.c b/tests/fbo/fbo-array.c index bc2338a82..7491fd243 100644 --- a/tests/fbo/fbo-array.c +++ b/tests/fbo/fbo-array.c @@ -38,10 +38,13 @@ #define BUF_WIDTH 32 #define BUF_HEIGHT 32 -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define NUM_LAYERS 6 diff --git a/tests/fbo/fbo-bind-renderbuffer.c b/tests/fbo/fbo-bind-renderbuffer.c index 338c50462..df935fca3 100644 --- a/tests/fbo/fbo-bind-renderbuffer.c +++ b/tests/fbo/fbo-bind-renderbuffer.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END /* Test binding and return error code */ static GLenum diff --git a/tests/fbo/fbo-blending-formats.c b/tests/fbo/fbo-blending-formats.c index ac7147b6a..2efd7e1ce 100644 --- a/tests/fbo/fbo-blending-formats.c +++ b/tests/fbo/fbo-blending-formats.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" #include "fbo-formats.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static void blend(const float *rect, const float *src, const float *dst, const float *blendcol, GLenum blendsrc, GLenum blenddst) diff --git a/tests/fbo/fbo-blit-d24s8.c b/tests/fbo/fbo-blit-d24s8.c index 5e34d2ce1..bc7d6c1c0 100644 --- a/tests/fbo/fbo-blit-d24s8.c +++ b/tests/fbo/fbo-blit-d24s8.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 150 /*window_width*/, - 150 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_STENCIL | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 150; + config.window_height = 150; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_STENCIL | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END #define PAD 10 #define SIZE 20 diff --git a/tests/fbo/fbo-blit-stretch.cpp b/tests/fbo/fbo-blit-stretch.cpp index 86a18f6b5..b75941ce5 100644 --- a/tests/fbo/fbo-blit-stretch.cpp +++ b/tests/fbo/fbo-blit-stretch.cpp @@ -51,10 +51,13 @@ #define DSTW 200 #define DSTH 150 -PIGLIT_GL_TEST_MAIN( - DSTW /*window_width*/, - DSTH /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = DSTW; + config.window_height = DSTH; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END struct TestCase { diff --git a/tests/fbo/fbo-blit.c b/tests/fbo/fbo-blit.c index 842f689ac..59bcd4664 100644 --- a/tests/fbo/fbo-blit.c +++ b/tests/fbo/fbo-blit.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 150 /*window_width*/, - 150 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 150; + config.window_height = 150; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define PAD 10 #define SIZE 20 diff --git a/tests/fbo/fbo-clear-formats.c b/tests/fbo/fbo-clear-formats.c index 8062d7dd4..c8a7e6ec2 100644 --- a/tests/fbo/fbo-clear-formats.c +++ b/tests/fbo/fbo-clear-formats.c @@ -37,10 +37,13 @@ #define TEX_WIDTH 256 #define TEX_HEIGHT 256 -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END /* Do piglit_rgbw_texture() image but using glClear */ static bool diff --git a/tests/fbo/fbo-clearmipmap.c b/tests/fbo/fbo-clearmipmap.c index cb8ebcea8..ea459129b 100644 --- a/tests/fbo/fbo-clearmipmap.c +++ b/tests/fbo/fbo-clearmipmap.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define TEX_WIDTH 256 #define TEX_HEIGHT 256 diff --git a/tests/fbo/fbo-colormask-formats.c b/tests/fbo/fbo-colormask-formats.c index 1050ae5f5..4708161d6 100644 --- a/tests/fbo/fbo-colormask-formats.c +++ b/tests/fbo/fbo-colormask-formats.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" #include "fbo-formats.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** * Draw a quad with colormask diff --git a/tests/fbo/fbo-copypix.c b/tests/fbo/fbo-copypix.c index ccac7e393..44f5ad09a 100644 --- a/tests/fbo/fbo-copypix.c +++ b/tests/fbo/fbo-copypix.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 150 /*window_width*/, - 150 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 150; + config.window_height = 150; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define PAD 10 #define SIZE 20 diff --git a/tests/fbo/fbo-copyteximage-simple.c b/tests/fbo/fbo-copyteximage-simple.c index afbe22b27..3db5b2515 100644 --- a/tests/fbo/fbo-copyteximage-simple.c +++ b/tests/fbo/fbo-copyteximage-simple.c @@ -38,10 +38,13 @@ #define TEX_WIDTH 256 #define TEX_HEIGHT 256 -PIGLIT_GL_TEST_MAIN( - TEX_WIDTH /*window_width*/, - TEX_HEIGHT /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = TEX_WIDTH; + config.window_height = TEX_HEIGHT; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const float red[] = {1, 0, 0, 0}; static const float green[] = {0, 1, 0, 0}; diff --git a/tests/fbo/fbo-copyteximage.c b/tests/fbo/fbo-copyteximage.c index db2db5114..d7a8e307f 100644 --- a/tests/fbo/fbo-copyteximage.c +++ b/tests/fbo/fbo-copyteximage.c @@ -36,10 +36,13 @@ #define TEX_WIDTH 254 #define TEX_HEIGHT 254 -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const float red[] = {1, 0, 0, 0}; static const float green[] = {0, 1, 0, 0}; diff --git a/tests/fbo/fbo-cubemap.c b/tests/fbo/fbo-cubemap.c index bb9a33de3..c193a81c9 100644 --- a/tests/fbo/fbo-cubemap.c +++ b/tests/fbo/fbo-cubemap.c @@ -36,10 +36,13 @@ #define BUF_WIDTH 32 #define BUF_HEIGHT 32 -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END float face_color[7][4] = { {1.0, 0.0, 0.0, 0.0}, diff --git a/tests/fbo/fbo-depth-array.c b/tests/fbo/fbo-depth-array.c index 8f669e011..0283ffdbe 100644 --- a/tests/fbo/fbo-depth-array.c +++ b/tests/fbo/fbo-depth-array.c @@ -41,10 +41,13 @@ #define BUF_WIDTH 32 #define BUF_HEIGHT 32 -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define NUM_LAYERS 6 diff --git a/tests/fbo/fbo-depth-sample-compare.c b/tests/fbo/fbo-depth-sample-compare.c index d6c41603e..2562ea7ab 100644 --- a/tests/fbo/fbo-depth-sample-compare.c +++ b/tests/fbo/fbo-depth-sample-compare.c @@ -45,10 +45,13 @@ #define SIZE 256 -PIGLIT_GL_TEST_MAIN( - 3 * SIZE /*window_width*/, - SIZE /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 3*SIZE; + config.window_height = SIZE; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static GLfloat ErrorScale = 0.0; static GLuint ColorTex, DepthTex, FBO; diff --git a/tests/fbo/fbo-depth-tex1d.c b/tests/fbo/fbo-depth-tex1d.c index 44bdf9798..0d3ec1398 100644 --- a/tests/fbo/fbo-depth-tex1d.c +++ b/tests/fbo/fbo-depth-tex1d.c @@ -36,10 +36,13 @@ #define BUF_WIDTH 16 -PIGLIT_GL_TEST_MAIN( - 50 /*window_width*/, - 20 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 50; + config.window_height = 20; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END #define F(name) #name, name diff --git a/tests/fbo/fbo-depth.c b/tests/fbo/fbo-depth.c index b2dd80dd9..36568ea5d 100644 --- a/tests/fbo/fbo-depth.c +++ b/tests/fbo/fbo-depth.c @@ -32,10 +32,13 @@ #define BUF_SIZE 123 -PIGLIT_GL_TEST_MAIN( - BUF_SIZE /*window_width*/, - BUF_SIZE /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = BUF_SIZE; + config.window_height = BUF_SIZE; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum { CLEAR, diff --git a/tests/fbo/fbo-depthstencil.c b/tests/fbo/fbo-depthstencil.c index 1e07b8c00..e10a4cefe 100644 --- a/tests/fbo/fbo-depthstencil.c +++ b/tests/fbo/fbo-depthstencil.c @@ -32,10 +32,13 @@ #define BUF_SIZE 123 -PIGLIT_GL_TEST_MAIN( - BUF_SIZE /*window_width*/, - BUF_SIZE /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = BUF_SIZE; + config.window_height = BUF_SIZE; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END enum { CLEAR, diff --git a/tests/fbo/fbo-depthtex.c b/tests/fbo/fbo-depthtex.c index 467c6a65c..331d2a9b7 100644 --- a/tests/fbo/fbo-depthtex.c +++ b/tests/fbo/fbo-depthtex.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 640 /*window_width*/, - 480 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 640; + config.window_height = 480; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static void check_fbo_status() diff --git a/tests/fbo/fbo-deriv.c b/tests/fbo/fbo-deriv.c index 783b12c60..06f1f00d4 100644 --- a/tests/fbo/fbo-deriv.c +++ b/tests/fbo/fbo-deriv.c @@ -45,10 +45,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END static const int fbo_width = 128, fbo_height = 128; diff --git a/tests/fbo/fbo-draw-buffers-blend.c b/tests/fbo/fbo-draw-buffers-blend.c index 60a54ad3b..3b2fe487d 100644 --- a/tests/fbo/fbo-draw-buffers-blend.c +++ b/tests/fbo/fbo-draw-buffers-blend.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "fbo-draw-buffers-blend"; diff --git a/tests/fbo/fbo-drawbuffers-arbfp.c b/tests/fbo/fbo-drawbuffers-arbfp.c index 9f18f0ea4..e943ae203 100644 --- a/tests/fbo/fbo-drawbuffers-arbfp.c +++ b/tests/fbo/fbo-drawbuffers-arbfp.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static float result0[] = {0.7, 0.6, 0.3, 0.1}; static float result1[] = {0.2, 0.9, 0.5, 0.8}; diff --git a/tests/fbo/fbo-drawbuffers-blend-add.c b/tests/fbo/fbo-drawbuffers-blend-add.c index c1c0a29b8..54491f12e 100644 --- a/tests/fbo/fbo-drawbuffers-blend-add.c +++ b/tests/fbo/fbo-drawbuffers-blend-add.c @@ -34,10 +34,13 @@ #include <string.h> #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint max_targets; diff --git a/tests/fbo/fbo-drawbuffers-fragcolor.c b/tests/fbo/fbo-drawbuffers-fragcolor.c index 81c1f0f08..e52a2342e 100644 --- a/tests/fbo/fbo-drawbuffers-fragcolor.c +++ b/tests/fbo/fbo-drawbuffers-fragcolor.c @@ -34,10 +34,13 @@ #include <string.h> #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint max_targets; diff --git a/tests/fbo/fbo-drawbuffers-maxtargets.c b/tests/fbo/fbo-drawbuffers-maxtargets.c index af953fd50..fe3bb104a 100644 --- a/tests/fbo/fbo-drawbuffers-maxtargets.c +++ b/tests/fbo/fbo-drawbuffers-maxtargets.c @@ -34,10 +34,13 @@ #include <string.h> #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint max_targets; diff --git a/tests/fbo/fbo-drawbuffers.c b/tests/fbo/fbo-drawbuffers.c index d5edec2fc..c20b2f0fd 100644 --- a/tests/fbo/fbo-drawbuffers.c +++ b/tests/fbo/fbo-drawbuffers.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint attach_texture(int i) diff --git a/tests/fbo/fbo-drawbuffers2-blend.c b/tests/fbo/fbo-drawbuffers2-blend.c index 06085196e..38baf97c7 100644 --- a/tests/fbo/fbo-drawbuffers2-blend.c +++ b/tests/fbo/fbo-drawbuffers2-blend.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint attach_texture(int i) diff --git a/tests/fbo/fbo-drawbuffers2-colormask.c b/tests/fbo/fbo-drawbuffers2-colormask.c index 477806b61..783bea4eb 100644 --- a/tests/fbo/fbo-drawbuffers2-colormask.c +++ b/tests/fbo/fbo-drawbuffers2-colormask.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint attach_texture(int i) diff --git a/tests/fbo/fbo-finish-deleted.c b/tests/fbo/fbo-finish-deleted.c index 642204593..33aa53cd8 100644 --- a/tests/fbo/fbo-finish-deleted.c +++ b/tests/fbo/fbo-finish-deleted.c @@ -34,10 +34,13 @@ #define BUF_WIDTH 32 #define BUF_HEIGHT 32 -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-flushing-2.c b/tests/fbo/fbo-flushing-2.c index 412bf1a9d..58595a5b9 100644 --- a/tests/fbo/fbo-flushing-2.c +++ b/tests/fbo/fbo-flushing-2.c @@ -40,10 +40,13 @@ #define TEX_WIDTH 8 #define TEX_HEIGHT 8 -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-flushing.c b/tests/fbo/fbo-flushing.c index 936c7c3df..88f1a6677 100644 --- a/tests/fbo/fbo-flushing.c +++ b/tests/fbo/fbo-flushing.c @@ -40,10 +40,13 @@ #define TEX_WIDTH 128 #define TEX_HEIGHT 128 -PIGLIT_GL_TEST_MAIN( - 300 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 300; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-fragcoord.c b/tests/fbo/fbo-fragcoord.c index 999b27d88..38ce7ae8e 100644 --- a/tests/fbo/fbo-fragcoord.c +++ b/tests/fbo/fbo-fragcoord.c @@ -31,10 +31,13 @@ #define WIDTH 256 #define HEIGHT 256 -PIGLIT_GL_TEST_MAIN( - WIDTH /*window_width*/, - HEIGHT /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = WIDTH; + config.window_height = HEIGHT; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/fbo/fbo-fragcoord2.c b/tests/fbo/fbo-fragcoord2.c index f91fe90fc..b4ff660c8 100644 --- a/tests/fbo/fbo-fragcoord2.c +++ b/tests/fbo/fbo-fragcoord2.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint prog; diff --git a/tests/fbo/fbo-generatemipmap-array.c b/tests/fbo/fbo-generatemipmap-array.c index 2d75d6d66..069b67d5d 100644 --- a/tests/fbo/fbo-generatemipmap-array.c +++ b/tests/fbo/fbo-generatemipmap-array.c @@ -36,10 +36,13 @@ #define TEX_WIDTH 128 #define TEX_HEIGHT 128 -PIGLIT_GL_TEST_MAIN( - 600 /*window_width*/, - 560 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 600; + config.window_height = 560; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const float red[] = {1, 0, 0, 0}; static const float green[] = {0, 1, 0, 0}; diff --git a/tests/fbo/fbo-generatemipmap-filtering.c b/tests/fbo/fbo-generatemipmap-filtering.c index 6d66835fa..48185aa29 100644 --- a/tests/fbo/fbo-generatemipmap-filtering.c +++ b/tests/fbo/fbo-generatemipmap-filtering.c @@ -31,10 +31,13 @@ #define TEX_WIDTH 256 #define TEX_HEIGHT 256 -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static int create_tex(void) diff --git a/tests/fbo/fbo-generatemipmap-formats.c b/tests/fbo/fbo-generatemipmap-formats.c index de528e3f6..2f19ff1d4 100644 --- a/tests/fbo/fbo-generatemipmap-formats.c +++ b/tests/fbo/fbo-generatemipmap-formats.c @@ -37,10 +37,13 @@ static int tex_width = 256; static int tex_height = 256; -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static void set_npot(GLboolean npot) { diff --git a/tests/fbo/fbo-generatemipmap-noimage.c b/tests/fbo/fbo-generatemipmap-noimage.c index 734605a6a..060f244d7 100644 --- a/tests/fbo/fbo-generatemipmap-noimage.c +++ b/tests/fbo/fbo-generatemipmap-noimage.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-generatemipmap-nonsquare.c b/tests/fbo/fbo-generatemipmap-nonsquare.c index bc82734f3..a531fd396 100644 --- a/tests/fbo/fbo-generatemipmap-nonsquare.c +++ b/tests/fbo/fbo-generatemipmap-nonsquare.c @@ -38,10 +38,13 @@ #define TEX_HEIGHT 64 #define TEX_DIFF (TEX_WIDTH/TEX_HEIGHT) -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const float red[] = {1, 0, 0, 0}; static const float green[] = {0, 1, 0, 0}; diff --git a/tests/fbo/fbo-generatemipmap-npot.c b/tests/fbo/fbo-generatemipmap-npot.c index eb3032d19..d32204b2d 100644 --- a/tests/fbo/fbo-generatemipmap-npot.c +++ b/tests/fbo/fbo-generatemipmap-npot.c @@ -35,10 +35,13 @@ #define TEX_WIDTH 254 #define TEX_HEIGHT 254 -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const float red[] = {1, 0, 0, 0}; static const float green[] = {0, 1, 0, 0}; diff --git a/tests/fbo/fbo-generatemipmap-scissor.c b/tests/fbo/fbo-generatemipmap-scissor.c index c04568fee..32eb1e021 100644 --- a/tests/fbo/fbo-generatemipmap-scissor.c +++ b/tests/fbo/fbo-generatemipmap-scissor.c @@ -38,10 +38,13 @@ #define TEX_WIDTH 256 #define TEX_HEIGHT 256 -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const float red[] = {1, 0, 0, 0}; static const float green[] = {0, 1, 0, 0}; diff --git a/tests/fbo/fbo-generatemipmap-viewport.c b/tests/fbo/fbo-generatemipmap-viewport.c index b5369bb36..6f0838b0e 100644 --- a/tests/fbo/fbo-generatemipmap-viewport.c +++ b/tests/fbo/fbo-generatemipmap-viewport.c @@ -39,10 +39,13 @@ #define TEX_WIDTH 256 #define TEX_HEIGHT 256 -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const float red[] = {1, 0, 0, 0}; static const float green[] = {0, 1, 0, 0}; diff --git a/tests/fbo/fbo-generatemipmap.c b/tests/fbo/fbo-generatemipmap.c index 18db7394a..8ca1f4b3f 100644 --- a/tests/fbo/fbo-generatemipmap.c +++ b/tests/fbo/fbo-generatemipmap.c @@ -35,10 +35,13 @@ #define TEX_WIDTH 256 #define TEX_HEIGHT 256 -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const float red[] = {1, 0, 0, 0}; static const float green[] = {0, 1, 0, 0}; diff --git a/tests/fbo/fbo-getframebufferattachmentparameter-01.c b/tests/fbo/fbo-getframebufferattachmentparameter-01.c index f4f756d89..c6ec7a1e4 100644 --- a/tests/fbo/fbo-getframebufferattachmentparameter-01.c +++ b/tests/fbo/fbo-getframebufferattachmentparameter-01.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-gl_pointcoord.c b/tests/fbo/fbo-gl_pointcoord.c index 9ac476818..f9b8bfe2f 100644 --- a/tests/fbo/fbo-gl_pointcoord.c +++ b/tests/fbo/fbo-gl_pointcoord.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_SINGLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_SINGLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "#version 120 \n" diff --git a/tests/fbo/fbo-incomplete-texture-01.c b/tests/fbo/fbo-incomplete-texture-01.c index dddf1707e..224c59eff 100644 --- a/tests/fbo/fbo-incomplete-texture-01.c +++ b/tests/fbo/fbo-incomplete-texture-01.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-incomplete-texture-02.c b/tests/fbo/fbo-incomplete-texture-02.c index 98853c3dc..58c56a0dd 100644 --- a/tests/fbo/fbo-incomplete-texture-02.c +++ b/tests/fbo/fbo-incomplete-texture-02.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-incomplete-texture-03.c b/tests/fbo/fbo-incomplete-texture-03.c index 69a017d70..708a11569 100644 --- a/tests/fbo/fbo-incomplete-texture-03.c +++ b/tests/fbo/fbo-incomplete-texture-03.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-incomplete-texture-04.c b/tests/fbo/fbo-incomplete-texture-04.c index b77d45f3f..2b19e9109 100644 --- a/tests/fbo/fbo-incomplete-texture-04.c +++ b/tests/fbo/fbo-incomplete-texture-04.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-integer.c b/tests/fbo/fbo-integer.c index 965d4078f..d91219abd 100644 --- a/tests/fbo/fbo-integer.c +++ b/tests/fbo/fbo-integer.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "texture-integer"; diff --git a/tests/fbo/fbo-luminance-alpha.c b/tests/fbo/fbo-luminance-alpha.c index d9ca6e1d9..e0c98751c 100644 --- a/tests/fbo/fbo-luminance-alpha.c +++ b/tests/fbo/fbo-luminance-alpha.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-maxsize.c b/tests/fbo/fbo-maxsize.c index a5c46c8cd..aed1b28d2 100644 --- a/tests/fbo/fbo-maxsize.c +++ b/tests/fbo/fbo-maxsize.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static int find_max_texture_size(void) diff --git a/tests/fbo/fbo-mipmap-copypix.c b/tests/fbo/fbo-mipmap-copypix.c index 0fc7127c5..93c072161 100644 --- a/tests/fbo/fbo-mipmap-copypix.c +++ b/tests/fbo/fbo-mipmap-copypix.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 50 /*window_width*/, - 50 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 50; + config.window_height = 50; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const GLuint NumLevels = 10; diff --git a/tests/fbo/fbo-nodepth-test.c b/tests/fbo/fbo-nodepth-test.c index e449b8c5b..3c3d32343 100644 --- a/tests/fbo/fbo-nodepth-test.c +++ b/tests/fbo/fbo-nodepth-test.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-nostencil-test.c b/tests/fbo/fbo-nostencil-test.c index 1613238e6..05a5f56e2 100644 --- a/tests/fbo/fbo-nostencil-test.c +++ b/tests/fbo/fbo-nostencil-test.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/fbo/fbo-pbo-readpixels-small.c b/tests/fbo/fbo-pbo-readpixels-small.c index 88fd28a75..33e2c8d85 100644 --- a/tests/fbo/fbo-pbo-readpixels-small.c +++ b/tests/fbo/fbo-pbo-readpixels-small.c @@ -39,10 +39,13 @@ #define BUF_WIDTH 8 #define BUF_HEIGHT 8 -PIGLIT_GL_TEST_MAIN( - 50 /*window_width*/, - 50 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 50; + config.window_height = 50; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static void make_fbo(GLuint *fbo, GLuint *tex) diff --git a/tests/fbo/fbo-readdrawpix.c b/tests/fbo/fbo-readdrawpix.c index 05243a1ef..24ec57de9 100644 --- a/tests/fbo/fbo-readdrawpix.c +++ b/tests/fbo/fbo-readdrawpix.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 150 /*window_width*/, - 150 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 150; + config.window_height = 150; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define PAD 10 #define SIZE 20 diff --git a/tests/fbo/fbo-readpixels-depth-formats.c b/tests/fbo/fbo-readpixels-depth-formats.c index 6a80e6a11..24941396a 100644 --- a/tests/fbo/fbo-readpixels-depth-formats.c +++ b/tests/fbo/fbo-readpixels-depth-formats.c @@ -33,10 +33,13 @@ #define BUF_WIDTH 15 #define BUF_HEIGHT 15 -PIGLIT_GL_TEST_MAIN( - BUF_WIDTH /*window_width*/, - BUF_WIDTH /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = BUF_WIDTH; + config.window_height = BUF_WIDTH; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END /* Width of our stripes of z = 0.0, 0.5, 1.0 */ static int w = BUF_WIDTH / 3; diff --git a/tests/fbo/fbo-readpixels.c b/tests/fbo/fbo-readpixels.c index cc646d9c3..81eab7f19 100644 --- a/tests/fbo/fbo-readpixels.c +++ b/tests/fbo/fbo-readpixels.c @@ -36,10 +36,13 @@ #define BUF_WIDTH 32 #define BUF_HEIGHT 32 -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLboolean test_with_format(GLenum internal_format, GLenum format, diff --git a/tests/fbo/fbo-rg.c b/tests/fbo/fbo-rg.c index 4aecd05c9..6ea46f8cd 100644 --- a/tests/fbo/fbo-rg.c +++ b/tests/fbo/fbo-rg.c @@ -44,10 +44,13 @@ static GLuint rgba_tex; static GLuint other_tex; static GLboolean pass = GL_TRUE; -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char vert_code[] = "attribute vec2 position;\n" diff --git a/tests/fbo/fbo-scissor-bitmap.c b/tests/fbo/fbo-scissor-bitmap.c index 1f9bba638..a0a96e461 100644 --- a/tests/fbo/fbo-scissor-bitmap.c +++ b/tests/fbo/fbo-scissor-bitmap.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct probes { struct test_position { diff --git a/tests/fbo/fbo-scissor-blit.c b/tests/fbo/fbo-scissor-blit.c index 4b12b0bf2..200d8f9d4 100644 --- a/tests/fbo/fbo-scissor-blit.c +++ b/tests/fbo/fbo-scissor-blit.c @@ -40,8 +40,13 @@ static const int width = 128, height = 128; -PIGLIT_GL_TEST_MAIN(width, height, PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + config.window_width = width; + config.window_height = height; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint src_fbo; static GLuint ref_fbo; static GLuint dst_fbo; diff --git a/tests/fbo/fbo-srgb-blit.c b/tests/fbo/fbo-srgb-blit.c index 1784563a2..4c2f0ecd1 100644 --- a/tests/fbo/fbo-srgb-blit.c +++ b/tests/fbo/fbo-srgb-blit.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLuint src_tex, dst_tex; static GLuint src_fbo, dst_fbo; diff --git a/tests/fbo/fbo-srgb.c b/tests/fbo/fbo-srgb.c index 7f73425c1..6aa73e23a 100644 --- a/tests/fbo/fbo-srgb.c +++ b/tests/fbo/fbo-srgb.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* size of texture/renderbuffer (power of two) */ #define FBO_SIZE 128 diff --git a/tests/fbo/fbo-stencil.c b/tests/fbo/fbo-stencil.c index 283007e36..cedcb5ada 100644 --- a/tests/fbo/fbo-stencil.c +++ b/tests/fbo/fbo-stencil.c @@ -32,10 +32,13 @@ #define BUF_SIZE 123 -PIGLIT_GL_TEST_MAIN( - BUF_SIZE /*window_width*/, - BUF_SIZE /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = BUF_SIZE; + config.window_height = BUF_SIZE; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum { CLEAR, diff --git a/tests/fbo/fbo-storage-completeness.c b/tests/fbo/fbo-storage-completeness.c index b5a87ab74..b4eab4fa8 100644 --- a/tests/fbo/fbo-storage-completeness.c +++ b/tests/fbo/fbo-storage-completeness.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "fbo-storage-formats"; diff --git a/tests/fbo/fbo-storage-formats.c b/tests/fbo/fbo-storage-formats.c index 15132f78f..3e20051d3 100644 --- a/tests/fbo/fbo-storage-formats.c +++ b/tests/fbo/fbo-storage-formats.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "fbo-storage-formats"; diff --git a/tests/fbo/fbo-sys-blit.c b/tests/fbo/fbo-sys-blit.c index 4265ee874..bd682c6f6 100644 --- a/tests/fbo/fbo-sys-blit.c +++ b/tests/fbo/fbo-sys-blit.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) { diff --git a/tests/fbo/fbo-sys-sub-blit.c b/tests/fbo/fbo-sys-sub-blit.c index 3e4703bcb..b27d4edf0 100644 --- a/tests/fbo/fbo-sys-sub-blit.c +++ b/tests/fbo/fbo-sys-sub-blit.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) { diff --git a/tests/fbo/fbo-viewport.c b/tests/fbo/fbo-viewport.c index e1033d51d..cfdb65301 100644 --- a/tests/fbo/fbo-viewport.c +++ b/tests/fbo/fbo-viewport.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 500 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 500; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** * Draw some simple quads in a bunch of viewports which tile the window. diff --git a/tests/general/array-stride.c b/tests/general/array-stride.c index 8c360ce19..9a644c3c1 100644 --- a/tests/general/array-stride.c +++ b/tests/general/array-stride.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "array-stride"; diff --git a/tests/general/bgra-sec-color-pointer.c b/tests/general/bgra-sec-color-pointer.c index 25b125683..b2184a738 100644 --- a/tests/general/bgra-sec-color-pointer.c +++ b/tests/general/bgra-sec-color-pointer.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLfloat verts[12] = {225.0, 175.0, 0.0, 225.0, 225.0, 0.0, diff --git a/tests/general/bgra-vert-attrib-pointer.c b/tests/general/bgra-vert-attrib-pointer.c index b504e6e6c..9b4505628 100644 --- a/tests/general/bgra-vert-attrib-pointer.c +++ b/tests/general/bgra-vert-attrib-pointer.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; static GLint fs; diff --git a/tests/general/blendminmax.c b/tests/general/blendminmax.c index fc703f2cd..5195bd356 100644 --- a/tests/general/blendminmax.c +++ b/tests/general/blendminmax.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLfloat Near = 5.0, Far = 25.0; diff --git a/tests/general/blendsquare.c b/tests/general/blendsquare.c index 5dd324f36..d184ca094 100644 --- a/tests/general/blendsquare.c +++ b/tests/general/blendsquare.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLfloat Near = 5.0, Far = 25.0; diff --git a/tests/general/clear-accum.c b/tests/general/clear-accum.c index 22474b17f..9569c9236 100644 --- a/tests/general/clear-accum.c +++ b/tests/general/clear-accum.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ACCUM) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ACCUM; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/clear-varray-2.0.c b/tests/general/clear-varray-2.0.c index 221e3af7c..8acb5dba3 100644 --- a/tests/general/clear-varray-2.0.c +++ b/tests/general/clear-varray-2.0.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END /* apply MVP and set the color to blue. */ static const GLchar *const vp_code = diff --git a/tests/general/copy-pixels.c b/tests/general/copy-pixels.c index 4c38f2757..460793997 100644 --- a/tests/general/copy-pixels.c +++ b/tests/general/copy-pixels.c @@ -34,10 +34,13 @@ #define IMAGE_WIDTH 16 #define IMAGE_HEIGHT 16 -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_STENCIL | PIGLIT_GL_VISUAL_DEPTH); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_STENCIL | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/copypixels-draw-sync.c b/tests/general/copypixels-draw-sync.c index ca44d1665..f632f4cb4 100644 --- a/tests/general/copypixels-draw-sync.c +++ b/tests/general/copypixels-draw-sync.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/copypixels-sync.c b/tests/general/copypixels-sync.c index 44379c7c2..7a31d415e 100644 --- a/tests/general/copypixels-sync.c +++ b/tests/general/copypixels-sync.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/depth-clamp-range.c b/tests/general/depth-clamp-range.c index 0cf027b4b..26c386836 100644 --- a/tests/general/depth-clamp-range.c +++ b/tests/general/depth-clamp-range.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 150 /*window_width*/, - 150 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 150; + config.window_height = 150; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/general/depth_clamp.c b/tests/general/depth_clamp.c index 662000631..b78389d9e 100644 --- a/tests/general/depth_clamp.c +++ b/tests/general/depth_clamp.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 150 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 150; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/general/depthfunc.c b/tests/general/depthfunc.c index 92d3c9066..f56352156 100644 --- a/tests/general/depthfunc.c +++ b/tests/general/depthfunc.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END /** * Convenience function to draw an axis-aligned rectangle. diff --git a/tests/general/depthrange-clear.c b/tests/general/depthrange-clear.c index 0f4603489..eee62f322 100644 --- a/tests/general/depthrange-clear.c +++ b/tests/general/depthrange-clear.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END /** * Convenience function to draw an axis-aligned rectangle. diff --git a/tests/general/dlist-clear.c b/tests/general/dlist-clear.c index 8f33ee457..a8523c679 100644 --- a/tests/general/dlist-clear.c +++ b/tests/general/dlist-clear.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/dlist-color-material.c b/tests/general/dlist-color-material.c index bcb37e0ff..6db791b4f 100644 --- a/tests/general/dlist-color-material.c +++ b/tests/general/dlist-color-material.c @@ -35,10 +35,13 @@ #include <assert.h> #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** * Test glMaterial handling in a display list for one of GL_AMBIENT, diff --git a/tests/general/dlist-fdo3129-01.c b/tests/general/dlist-fdo3129-01.c index 56446abfb..c53b073b7 100644 --- a/tests/general/dlist-fdo3129-01.c +++ b/tests/general/dlist-fdo3129-01.c @@ -30,10 +30,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint list; diff --git a/tests/general/dlist-fdo3129-02.c b/tests/general/dlist-fdo3129-02.c index 6d4eb991a..27af71961 100644 --- a/tests/general/dlist-fdo3129-02.c +++ b/tests/general/dlist-fdo3129-02.c @@ -30,10 +30,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint list; diff --git a/tests/general/dlist-fdo31590.c b/tests/general/dlist-fdo31590.c index ffdeb473e..519fd8cbd 100644 --- a/tests/general/dlist-fdo31590.c +++ b/tests/general/dlist-fdo31590.c @@ -37,10 +37,13 @@ static const char *TestName = "dlist-fdo31590"; -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 500 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 500; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLfloat ctrlpoints[4][3] = { { -4.0, -4.0, 0.0}, { -2.0, 4.0, 0.0}, diff --git a/tests/general/draw-arrays-colormaterial.c b/tests/general/draw-arrays-colormaterial.c index 2fc9431ef..bb7045ae8 100644 --- a/tests/general/draw-arrays-colormaterial.c +++ b/tests/general/draw-arrays-colormaterial.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define DX0 -0.6 diff --git a/tests/general/draw-batch.c b/tests/general/draw-batch.c index e311f8e31..6aaaecfa3 100644 --- a/tests/general/draw-batch.c +++ b/tests/general/draw-batch.c @@ -24,10 +24,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 130 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 130; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/general/draw-copypixels-sync.c b/tests/general/draw-copypixels-sync.c index 0cb0f6160..2630230e2 100644 --- a/tests/general/draw-copypixels-sync.c +++ b/tests/general/draw-copypixels-sync.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/draw-elements-base-vertex-bounds.c b/tests/general/draw-elements-base-vertex-bounds.c index 03791c34c..63897286f 100644 --- a/tests/general/draw-elements-base-vertex-bounds.c +++ b/tests/general/draw-elements-base-vertex-bounds.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 300 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 300; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLfloat vertices[][4] = { { 1, -1, 0, 1 }, /* bottom right */ diff --git a/tests/general/draw-elements-base-vertex-neg.c b/tests/general/draw-elements-base-vertex-neg.c index ff4c97fc2..1ba70dfa6 100644 --- a/tests/general/draw-elements-base-vertex-neg.c +++ b/tests/general/draw-elements-base-vertex-neg.c @@ -26,10 +26,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 320 /*window_width*/, - 80 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 320; + config.window_height = 80; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END GLboolean user_va = GL_FALSE; diff --git a/tests/general/draw-elements-base-vertex.c b/tests/general/draw-elements-base-vertex.c index 99f8791b0..56adb0260 100644 --- a/tests/general/draw-elements-base-vertex.c +++ b/tests/general/draw-elements-base-vertex.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 300 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 300; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define NUM_QUADS 10 diff --git a/tests/general/draw-elements-vs-inputs.c b/tests/general/draw-elements-vs-inputs.c index acdcd2b81..f186f568a 100644 --- a/tests/general/draw-elements-vs-inputs.c +++ b/tests/general/draw-elements-vs-inputs.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 300 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 300; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/general/draw-elements.c b/tests/general/draw-elements.c index c17f9dea6..8ac433e79 100644 --- a/tests/general/draw-elements.c +++ b/tests/general/draw-elements.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 320 /*window_width*/, - 60 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 320; + config.window_height = 60; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END GLboolean user = GL_FALSE; diff --git a/tests/general/draw-instanced-divisor.c b/tests/general/draw-instanced-divisor.c index 731a24e9b..684fd5495 100644 --- a/tests/general/draw-instanced-divisor.c +++ b/tests/general/draw-instanced-divisor.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 500 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 500; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "draw-instanced"; diff --git a/tests/general/draw-instanced.c b/tests/general/draw-instanced.c index e3906700c..860becdb3 100644 --- a/tests/general/draw-instanced.c +++ b/tests/general/draw-instanced.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 500 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 500; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "draw-instanced"; diff --git a/tests/general/draw-pixel-with-texture.c b/tests/general/draw-pixel-with-texture.c index 7437de79e..debc9377f 100644 --- a/tests/general/draw-pixel-with-texture.c +++ b/tests/general/draw-pixel-with-texture.c @@ -23,10 +23,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define SCREEN_SIZE_IN_PIXELS (piglit_width * piglit_height * 4) diff --git a/tests/general/draw-pixels.c b/tests/general/draw-pixels.c index ffc8813cc..6860cb9ce 100644 --- a/tests/general/draw-pixels.c +++ b/tests/general/draw-pixels.c @@ -51,10 +51,13 @@ /** Convert GLint in [-2147483648,2147483647] to GLfloat in [-1.0,1.0] */ #define INT_TO_FLOAT(I) ((GLfloat) ((2.0F * (I) + 1.0F) * (1.0F/4294967294.0))) -PIGLIT_GL_TEST_MAIN( - 16 /*window_width*/, - 16 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 16; + config.window_height = 16; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END const GLuint idx0 = 0, idx1 = 1, idx2 = 2, idx3 = 3; static GLfloat expected[100][4]; diff --git a/tests/general/draw-sync.c b/tests/general/draw-sync.c index 628e18ebe..9f017d267 100644 --- a/tests/general/draw-sync.c +++ b/tests/general/draw-sync.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/draw-vertices-half-float.c b/tests/general/draw-vertices-half-float.c index 4a4a88316..2ed9eeb7b 100644 --- a/tests/general/draw-vertices-half-float.c +++ b/tests/general/draw-vertices-half-float.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 320 /*window_width*/, - 60 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 320; + config.window_height = 60; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END GLboolean user_va = GL_FALSE; diff --git a/tests/general/draw-vertices.c b/tests/general/draw-vertices.c index 63b4ad89d..7d5e1d2ad 100644 --- a/tests/general/draw-vertices.c +++ b/tests/general/draw-vertices.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 320 /*window_width*/, - 60 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 320; + config.window_height = 60; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END GLboolean user_va = GL_FALSE; diff --git a/tests/general/drawpix-z.c b/tests/general/drawpix-z.c index 646868158..895c90c59 100644 --- a/tests/general/drawpix-z.c +++ b/tests/general/drawpix-z.c @@ -36,9 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN(200 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static void draw_z_gradient(GLfloat zLeft, GLfloat zRight) diff --git a/tests/general/early-z.c b/tests/general/early-z.c index fa269629f..88ad2aae4 100644 --- a/tests/general/early-z.c +++ b/tests/general/early-z.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END GLint u_zval; diff --git a/tests/general/fog-modes.c b/tests/general/fog-modes.c index c4ad5d701..11059ca8c 100644 --- a/tests/general/fog-modes.c +++ b/tests/general/fog-modes.c @@ -33,10 +33,13 @@ #undef far #endif -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/fragment-center.c b/tests/general/fragment-center.c index 14ed623b6..d1b4c5d3b 100644 --- a/tests/general/fragment-center.c +++ b/tests/general/fragment-center.c @@ -23,10 +23,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 96 /*window_width*/, - 96 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 96; + config.window_height = 96; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/framebuffer-srgb.c b/tests/general/framebuffer-srgb.c index a776f7b6d..4120a120a 100644 --- a/tests/general/framebuffer-srgb.c +++ b/tests/general/framebuffer-srgb.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* size of texture/renderbuffer (power of two) */ #define FBO_SIZE 128 diff --git a/tests/general/getactiveattrib.c b/tests/general/getactiveattrib.c index 7a994f559..19e6671ae 100644 --- a/tests/general/getactiveattrib.c +++ b/tests/general/getactiveattrib.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END struct attribute { /** Name of the attribute. */ diff --git a/tests/general/geterror-inside-begin.c b/tests/general/geterror-inside-begin.c index a55cc4c6f..d8c0d6328 100644 --- a/tests/general/geterror-inside-begin.c +++ b/tests/general/geterror-inside-begin.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/geterror-invalid-enum.c b/tests/general/geterror-invalid-enum.c index 76b14ef91..0839beb86 100644 --- a/tests/general/geterror-invalid-enum.c +++ b/tests/general/geterror-invalid-enum.c @@ -22,10 +22,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/gl30basic.c b/tests/general/gl30basic.c index b8fe82972..9a664591e 100644 --- a/tests/general/gl30basic.c +++ b/tests/general/gl30basic.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END static const char *Prog = "gl30basic"; diff --git a/tests/general/hiz.c b/tests/general/hiz.c index ee9f945f4..a43bdcb5f 100644 --- a/tests/general/hiz.c +++ b/tests/general/hiz.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum { INSIDE, diff --git a/tests/general/infinite-spot-light.c b/tests/general/infinite-spot-light.c index f2855d5b1..a7d28c15a 100644 --- a/tests/general/infinite-spot-light.c +++ b/tests/general/infinite-spot-light.c @@ -41,10 +41,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* Already normalized, and 0.5 would be the expected color */ static GLfloat dir[3] = {0.866025404, 0.0, 0.5}; diff --git a/tests/general/isbufferobj.c b/tests/general/isbufferobj.c index b8d2a6cc2..7f53bc4c8 100644 --- a/tests/general/isbufferobj.c +++ b/tests/general/isbufferobj.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "isbufferobj"; diff --git a/tests/general/line-aa-width.c b/tests/general/line-aa-width.c index f1523c4ba..a14846a38 100644 --- a/tests/general/line-aa-width.c +++ b/tests/general/line-aa-width.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 300 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 300; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static float y_from_x(float x) diff --git a/tests/general/linestipple.c b/tests/general/linestipple.c index 08910e32a..4da4da0a9 100644 --- a/tests/general/linestipple.c +++ b/tests/general/linestipple.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static void probe_pixel(int x, int y, const float* expected) { diff --git a/tests/general/longprim.c b/tests/general/longprim.c index 2c3b40308..4822e904c 100644 --- a/tests/general/longprim.c +++ b/tests/general/longprim.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "longprim"; diff --git a/tests/general/object_purgeable-api-pbo.c b/tests/general/object_purgeable-api-pbo.c index 94e101327..80413dede 100644 --- a/tests/general/object_purgeable-api-pbo.c +++ b/tests/general/object_purgeable-api-pbo.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" #include "object_purgeable.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/general/object_purgeable-api-texture.c b/tests/general/object_purgeable-api-texture.c index 0bb3b0a35..1f02da0d2 100644 --- a/tests/general/object_purgeable-api-texture.c +++ b/tests/general/object_purgeable-api-texture.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" #include "object_purgeable.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/general/object_purgeable-api-vbo.c b/tests/general/object_purgeable-api-vbo.c index 18bb5a63c..33a2dd1df 100644 --- a/tests/general/object_purgeable-api-vbo.c +++ b/tests/general/object_purgeable-api-vbo.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" #include "object_purgeable.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/general/occlusion-query-discard.c b/tests/general/occlusion-query-discard.c index d2418ac99..6bfc84420 100644 --- a/tests/general/occlusion-query-discard.c +++ b/tests/general/occlusion-query-discard.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 50 /*window_width*/, - 50 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 50; + config.window_height = 50; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static char vs_code[] = "varying float do_discard;\n" diff --git a/tests/general/occlusion_query.c b/tests/general/occlusion_query.c index 290fd99ab..18a5d80ec 100644 --- a/tests/general/occlusion_query.c +++ b/tests/general/occlusion_query.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 180 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 180; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END #define MAX_QUERIES 5 static GLuint occ_queries[MAX_QUERIES]; diff --git a/tests/general/oes-read-format.c b/tests/general/oes-read-format.c index 4a6306c73..7c9c64aec 100644 --- a/tests/general/oes-read-format.c +++ b/tests/general/oes-read-format.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/pbo-drawpixels.c b/tests/general/pbo-drawpixels.c index f4cee90c7..1a6410b72 100644 --- a/tests/general/pbo-drawpixels.c +++ b/tests/general/pbo-drawpixels.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/pbo-read-argb8888.c b/tests/general/pbo-read-argb8888.c index f4886cfe3..4833f9b96 100644 --- a/tests/general/pbo-read-argb8888.c +++ b/tests/general/pbo-read-argb8888.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLboolean probe(int x, int y, uint32_t expected, uint32_t observed) diff --git a/tests/general/pbo-readpixels-small.c b/tests/general/pbo-readpixels-small.c index ea984d1b8..66d52163f 100644 --- a/tests/general/pbo-readpixels-small.c +++ b/tests/general/pbo-readpixels-small.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 2 /*window_width*/, - 2 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 2; + config.window_height = 2; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLboolean probe(int x, int y, uint32_t expected, uint32_t observed) diff --git a/tests/general/pbo-teximage-tiling-2.c b/tests/general/pbo-teximage-tiling-2.c index 665a74f20..281bc0e72 100644 --- a/tests/general/pbo-teximage-tiling-2.c +++ b/tests/general/pbo-teximage-tiling-2.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/pbo-teximage-tiling.c b/tests/general/pbo-teximage-tiling.c index 8965ff02b..69fc990b9 100644 --- a/tests/general/pbo-teximage-tiling.c +++ b/tests/general/pbo-teximage-tiling.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/pbo-teximage.c b/tests/general/pbo-teximage.c index 3b1444a29..180681a2d 100644 --- a/tests/general/pbo-teximage.c +++ b/tests/general/pbo-teximage.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/point-line-no-cull.c b/tests/general/point-line-no-cull.c index dbe7d6024..34c6080db 100644 --- a/tests/general/point-line-no-cull.c +++ b/tests/general/point-line-no-cull.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 120 /*window_width*/, - 120 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 120; + config.window_height = 120; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** Test if the pixels at (x,y) and (x,y+1) are black. * We test two pixels to be sure we hit the primitive we drew. We could diff --git a/tests/general/polygon-mode.c b/tests/general/polygon-mode.c index 047a2ddb6..425c09b41 100644 --- a/tests/general/polygon-mode.c +++ b/tests/general/polygon-mode.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static float ortho_left = -1, ortho_right = 8, ortho_bottom = -2, ortho_top = 2; diff --git a/tests/general/pos-array.c b/tests/general/pos-array.c index b1a91fb36..c5afb122e 100644 --- a/tests/general/pos-array.c +++ b/tests/general/pos-array.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "pos-array"; diff --git a/tests/general/primitive-restart.c b/tests/general/primitive-restart.c index 5918918c1..d496ee74d 100644 --- a/tests/general/primitive-restart.c +++ b/tests/general/primitive-restart.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "primitive-restart"; diff --git a/tests/general/provoking-vertex.c b/tests/general/provoking-vertex.c index 46d81d1f9..284007ac2 100644 --- a/tests/general/provoking-vertex.c +++ b/tests/general/provoking-vertex.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/general/quad-invariance.c b/tests/general/quad-invariance.c index 5fe12d12a..7015eab9a 100644 --- a/tests/general/quad-invariance.c +++ b/tests/general/quad-invariance.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/read-front.c b/tests/general/read-front.c index 2aceb236d..e0e017c4a 100644 --- a/tests/general/read-front.c +++ b/tests/general/read-front.c @@ -37,10 +37,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/readpix-z.c b/tests/general/readpix-z.c index 42c6b7cc6..fa79a2194 100644 --- a/tests/general/readpix-z.c +++ b/tests/general/readpix-z.c @@ -29,9 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN(200 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static void draw_z_gradient(GLfloat zLeft, GLfloat zRight) diff --git a/tests/general/roundmode-getintegerv.c b/tests/general/roundmode-getintegerv.c index fecb17361..280580b91 100644 --- a/tests/general/roundmode-getintegerv.c +++ b/tests/general/roundmode-getintegerv.c @@ -43,10 +43,13 @@ #include <fenv.h> -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/roundmode-pixelstore.c b/tests/general/roundmode-pixelstore.c index ace5cff8a..433953223 100644 --- a/tests/general/roundmode-pixelstore.c +++ b/tests/general/roundmode-pixelstore.c @@ -40,10 +40,13 @@ #include <fenv.h> -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/scissor-bitmap.c b/tests/general/scissor-bitmap.c index 0631bed14..6af6ba84a 100644 --- a/tests/general/scissor-bitmap.c +++ b/tests/general/scissor-bitmap.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct probes { struct test_position { diff --git a/tests/general/scissor-clear.c b/tests/general/scissor-clear.c index 022df4a0c..5840a94f0 100644 --- a/tests/general/scissor-clear.c +++ b/tests/general/scissor-clear.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/scissor-copypixels.c b/tests/general/scissor-copypixels.c index bf08f2b09..b9b782ae7 100644 --- a/tests/general/scissor-copypixels.c +++ b/tests/general/scissor-copypixels.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLboolean check_red_box_surrounded_by_green(int x, int y, int w, int h) diff --git a/tests/general/scissor-depth-clear.c b/tests/general/scissor-depth-clear.c index e9a760091..77166ad3d 100644 --- a/tests/general/scissor-depth-clear.c +++ b/tests/general/scissor-depth-clear.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/scissor-many.c b/tests/general/scissor-many.c index dcd97e6d9..68bba082f 100644 --- a/tests/general/scissor-many.c +++ b/tests/general/scissor-many.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/scissor-offscreen.c b/tests/general/scissor-offscreen.c index 49d717ffe..f77a11b76 100644 --- a/tests/general/scissor-offscreen.c +++ b/tests/general/scissor-offscreen.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/scissor-stencil-clear.c b/tests/general/scissor-stencil-clear.c index b1e90979b..40de62cbe 100644 --- a/tests/general/scissor-stencil-clear.c +++ b/tests/general/scissor-stencil-clear.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/select.c b/tests/general/select.c index 70df613c4..ede8c0757 100644 --- a/tests/general/select.c +++ b/tests/general/select.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END GLuint ReferenceHitEntries[3][64]; #define NAME_STACK_DEPTH 0 diff --git a/tests/general/stencil-drawpixels.c b/tests/general/stencil-drawpixels.c index eb52a20b1..c390ed450 100644 --- a/tests/general/stencil-drawpixels.c +++ b/tests/general/stencil-drawpixels.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/stencil-twoside.c b/tests/general/stencil-twoside.c index cfce9c3bc..22cf20c72 100644 --- a/tests/general/stencil-twoside.c +++ b/tests/general/stencil-twoside.c @@ -37,10 +37,13 @@ static int use20syntax = 1; -PIGLIT_GL_TEST_MAIN( - 650 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 650; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END static const GLfloat Near = 5.0, Far = 25.0; diff --git a/tests/general/stencil-wrap.c b/tests/general/stencil-wrap.c index 8040008de..9c6eed8d3 100644 --- a/tests/general/stencil-wrap.c +++ b/tests/general/stencil-wrap.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 550 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 550; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/sync_api.c b/tests/general/sync_api.c index 6a8a50345..af5652bf0 100644 --- a/tests/general/sync_api.c +++ b/tests/general/sync_api.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define FAIL_ON_ERROR(string) \ do { \ diff --git a/tests/general/texgen.c b/tests/general/texgen.c index c8bb288c0..7e29ad200 100644 --- a/tests/general/texgen.c +++ b/tests/general/texgen.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int CurrentTest = 0; static int UseFragmentProgram = 0; diff --git a/tests/general/texunits.c b/tests/general/texunits.c index 31db6bb46..a3dde2759 100644 --- a/tests/general/texunits.c +++ b/tests/general/texunits.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** random number for checking state */ static GLfloat Random[128][4]; diff --git a/tests/general/timer_query.c b/tests/general/timer_query.c index 3b6ed5238..9dc69d666 100644 --- a/tests/general/timer_query.c +++ b/tests/general/timer_query.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 180 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 180; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static GLuint timer_query; diff --git a/tests/general/triangle-rasterization-overdraw.cpp b/tests/general/triangle-rasterization-overdraw.cpp index d8e04f560..998523342 100644 --- a/tests/general/triangle-rasterization-overdraw.cpp +++ b/tests/general/triangle-rasterization-overdraw.cpp @@ -71,10 +71,13 @@ int random_test_count = 10; /* Piglit variables */ -PIGLIT_GL_TEST_MAIN( - 1000 /*window_width*/, - 1000 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 1000; + config.window_height = 1000; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* Globals */ int test_id = 0; diff --git a/tests/general/triangle-rasterization.cpp b/tests/general/triangle-rasterization.cpp index 313214c24..0df75c72a 100644 --- a/tests/general/triangle-rasterization.cpp +++ b/tests/general/triangle-rasterization.cpp @@ -99,10 +99,13 @@ int fbo_height = 256; /* Piglit variables */ -PIGLIT_GL_TEST_MAIN( - fbo_width /*window_width*/, - fbo_height /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = fbo_width; + config.window_height = fbo_height; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* Globals */ int test_id = 0; diff --git a/tests/general/two-sided-lighting-separate-specular.c b/tests/general/two-sided-lighting-separate-specular.c index 1359ec7ae..cb567565c 100644 --- a/tests/general/two-sided-lighting-separate-specular.c +++ b/tests/general/two-sided-lighting-separate-specular.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLfloat red[4] = {1, 0, 0, 0}; static const GLfloat green[4] = {0, 1, 0, 1}; diff --git a/tests/general/two-sided-lighting.c b/tests/general/two-sided-lighting.c index e6187a364..4ea139836 100644 --- a/tests/general/two-sided-lighting.c +++ b/tests/general/two-sided-lighting.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLfloat green[4] = {0, 1, 0, 1}; static const GLfloat blue[4] = {0, 0, 1, 1}; diff --git a/tests/general/user-clip.c b/tests/general/user-clip.c index c5984bdc0..db283e2ce 100644 --- a/tests/general/user-clip.c +++ b/tests/general/user-clip.c @@ -31,10 +31,13 @@ #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLfloat clear_color[4] = { 0.5, 0.5, 0.5, 1.0 }; diff --git a/tests/general/vao-01.c b/tests/general/vao-01.c index b4e158cc5..eaa3f468a 100644 --- a/tests/general/vao-01.c +++ b/tests/general/vao-01.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/vao-02.c b/tests/general/vao-02.c index ec6f19595..9b7eca220 100644 --- a/tests/general/vao-02.c +++ b/tests/general/vao-02.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/general/vao-element-array-buffer.c b/tests/general/vao-element-array-buffer.c index b00799797..1e387f657 100644 --- a/tests/general/vao-element-array-buffer.c +++ b/tests/general/vao-element-array-buffer.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint vao; diff --git a/tests/general/varray-disabled.c b/tests/general/varray-disabled.c index 4d2a9b3a0..efca19a08 100644 --- a/tests/general/varray-disabled.c +++ b/tests/general/varray-disabled.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static void set_colors(GLfloat *color_array, GLfloat *color) diff --git a/tests/general/vbo-bufferdata.c b/tests/general/vbo-bufferdata.c index a0171ccfd..e35173941 100644 --- a/tests/general/vbo-bufferdata.c +++ b/tests/general/vbo-bufferdata.c @@ -27,10 +27,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint vbo; diff --git a/tests/general/vbo-map-remap.c b/tests/general/vbo-map-remap.c index 661d0aee6..957d0cc2d 100644 --- a/tests/general/vbo-map-remap.c +++ b/tests/general/vbo-map-remap.c @@ -26,10 +26,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint vbo; diff --git a/tests/general/vbo-subdata-sync.c b/tests/general/vbo-subdata-sync.c index a37982b7b..d065dc24d 100644 --- a/tests/general/vbo-subdata-sync.c +++ b/tests/general/vbo-subdata-sync.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint vbo; diff --git a/tests/general/vbo-subdata-zero.c b/tests/general/vbo-subdata-zero.c index 46f64067c..f9387ac17 100644 --- a/tests/general/vbo-subdata-zero.c +++ b/tests/general/vbo-subdata-zero.c @@ -26,10 +26,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint vbo; diff --git a/tests/general/vs-point_size-zero.c b/tests/general/vs-point_size-zero.c index 2c647ee0c..b30684754 100644 --- a/tests/general/vs-point_size-zero.c +++ b/tests/general/vs-point_size-zero.c @@ -24,10 +24,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 50 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 50; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *vstext = "void main() \n" diff --git a/tests/gles2/gles2_shader_runner.c b/tests/gles2/gles2_shader_runner.c index e1d8297a4..42eb5c8b8 100644 --- a/tests/gles2/gles2_shader_runner.c +++ b/tests/gles2/gles2_shader_runner.c @@ -34,10 +34,13 @@ #include <string.h> #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 250 /*window_width*/, - 250 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 250; + config.window_height = 250; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static float gles_version = 0.0; static float essl_version = 0.0; diff --git a/tests/glslparsertest/glslparsertest.c b/tests/glslparsertest/glslparsertest.c index b45f1ed4f..52ff91692 100644 --- a/tests/glslparsertest/glslparsertest.c +++ b/tests/glslparsertest/glslparsertest.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static char *filename; static int expected_pass; diff --git a/tests/hiz/hiz-depth-read-fbo-d24-s0.c b/tests/hiz/hiz-depth-read-fbo-d24-s0.c index fffd7553f..a35d2d003 100644 --- a/tests/hiz/hiz-depth-read-fbo-d24-s0.c +++ b/tests/hiz/hiz-depth-read-fbo-d24-s0.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-depth-read-fbo-d24-s8.c b/tests/hiz/hiz-depth-read-fbo-d24-s8.c index 8c6a96e64..7e35b384f 100644 --- a/tests/hiz/hiz-depth-read-fbo-d24-s8.c +++ b/tests/hiz/hiz-depth-read-fbo-d24-s8.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-depth-read-fbo-d24s8.c b/tests/hiz/hiz-depth-read-fbo-d24s8.c index b3f985b37..8ab92fbf8 100644 --- a/tests/hiz/hiz-depth-read-fbo-d24s8.c +++ b/tests/hiz/hiz-depth-read-fbo-d24s8.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-depth-read-window-stencil0.c b/tests/hiz/hiz-depth-read-window-stencil0.c index 209f6421d..159cd8f67 100644 --- a/tests/hiz/hiz-depth-read-window-stencil0.c +++ b/tests/hiz/hiz-depth-read-window-stencil0.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/hiz/hiz-depth-read-window-stencil1.c b/tests/hiz/hiz-depth-read-window-stencil1.c index ab8f4bbec..02626774e 100644 --- a/tests/hiz/hiz-depth-read-window-stencil1.c +++ b/tests/hiz/hiz-depth-read-window-stencil1.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/hiz/hiz-depth-stencil-test-fbo-d0-s8.c b/tests/hiz/hiz-depth-stencil-test-fbo-d0-s8.c index c024d6d2f..4f30b3a7d 100644 --- a/tests/hiz/hiz-depth-stencil-test-fbo-d0-s8.c +++ b/tests/hiz/hiz-depth-stencil-test-fbo-d0-s8.c @@ -41,10 +41,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-depth-stencil-test-fbo-d24-s0.c b/tests/hiz/hiz-depth-stencil-test-fbo-d24-s0.c index b3bddb3bf..efe228983 100644 --- a/tests/hiz/hiz-depth-stencil-test-fbo-d24-s0.c +++ b/tests/hiz/hiz-depth-stencil-test-fbo-d24-s0.c @@ -41,10 +41,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-depth-stencil-test-fbo-d24-s8.c b/tests/hiz/hiz-depth-stencil-test-fbo-d24-s8.c index 169ccbf4c..5ff534561 100644 --- a/tests/hiz/hiz-depth-stencil-test-fbo-d24-s8.c +++ b/tests/hiz/hiz-depth-stencil-test-fbo-d24-s8.c @@ -42,10 +42,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-depth-stencil-test-fbo-d24s8.c b/tests/hiz/hiz-depth-stencil-test-fbo-d24s8.c index d4d5e4c7b..302f1a74e 100644 --- a/tests/hiz/hiz-depth-stencil-test-fbo-d24s8.c +++ b/tests/hiz/hiz-depth-stencil-test-fbo-d24s8.c @@ -41,10 +41,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-depth-test-fbo-d24-s0.c b/tests/hiz/hiz-depth-test-fbo-d24-s0.c index c9f2e310f..ff79b78b8 100644 --- a/tests/hiz/hiz-depth-test-fbo-d24-s0.c +++ b/tests/hiz/hiz-depth-test-fbo-d24-s0.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-depth-test-fbo-d24-s8.c b/tests/hiz/hiz-depth-test-fbo-d24-s8.c index b9eac9ec6..298454e68 100644 --- a/tests/hiz/hiz-depth-test-fbo-d24-s8.c +++ b/tests/hiz/hiz-depth-test-fbo-d24-s8.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-depth-test-fbo-d24s8.c b/tests/hiz/hiz-depth-test-fbo-d24s8.c index 2febeb1da..4c66779af 100644 --- a/tests/hiz/hiz-depth-test-fbo-d24s8.c +++ b/tests/hiz/hiz-depth-test-fbo-d24s8.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-depth-test-window-stencil0.c b/tests/hiz/hiz-depth-test-window-stencil0.c index 56fd89ac1..679a23040 100644 --- a/tests/hiz/hiz-depth-test-window-stencil0.c +++ b/tests/hiz/hiz-depth-test-window-stencil0.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/hiz/hiz-depth-test-window-stencil1.c b/tests/hiz/hiz-depth-test-window-stencil1.c index 4df7a8a86..a6ae6ac64 100644 --- a/tests/hiz/hiz-depth-test-window-stencil1.c +++ b/tests/hiz/hiz-depth-test-window-stencil1.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/hiz/hiz-stencil-read-fbo-d0-s8.c b/tests/hiz/hiz-stencil-read-fbo-d0-s8.c index b2c289304..9a3c29105 100644 --- a/tests/hiz/hiz-stencil-read-fbo-d0-s8.c +++ b/tests/hiz/hiz-stencil-read-fbo-d0-s8.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-stencil-read-fbo-d24-s8.c b/tests/hiz/hiz-stencil-read-fbo-d24-s8.c index 231a6d3b2..b281c91f4 100644 --- a/tests/hiz/hiz-stencil-read-fbo-d24-s8.c +++ b/tests/hiz/hiz-stencil-read-fbo-d24-s8.c @@ -40,10 +40,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-stencil-read-fbo-d24s8.c b/tests/hiz/hiz-stencil-read-fbo-d24s8.c index f3b0b5960..87c4d33b6 100644 --- a/tests/hiz/hiz-stencil-read-fbo-d24s8.c +++ b/tests/hiz/hiz-stencil-read-fbo-d24s8.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-stencil-read-window-depth0.c b/tests/hiz/hiz-stencil-read-window-depth0.c index 369b2d011..63e77dff2 100644 --- a/tests/hiz/hiz-stencil-read-window-depth0.c +++ b/tests/hiz/hiz-stencil-read-window-depth0.c @@ -37,10 +37,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/hiz/hiz-stencil-read-window-depth1.c b/tests/hiz/hiz-stencil-read-window-depth1.c index e054deb67..d7ebaa6f0 100644 --- a/tests/hiz/hiz-stencil-read-window-depth1.c +++ b/tests/hiz/hiz-stencil-read-window-depth1.c @@ -37,10 +37,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_STENCIL | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_STENCIL | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/hiz/hiz-stencil-test-fbo-d0-s8.c b/tests/hiz/hiz-stencil-test-fbo-d0-s8.c index 998040b76..1f6aa5346 100644 --- a/tests/hiz/hiz-stencil-test-fbo-d0-s8.c +++ b/tests/hiz/hiz-stencil-test-fbo-d0-s8.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-stencil-test-fbo-d24-s8.c b/tests/hiz/hiz-stencil-test-fbo-d24-s8.c index 04f14e911..685e9ce4e 100644 --- a/tests/hiz/hiz-stencil-test-fbo-d24-s8.c +++ b/tests/hiz/hiz-stencil-test-fbo-d24-s8.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-stencil-test-fbo-d24s8.c b/tests/hiz/hiz-stencil-test-fbo-d24s8.c index 516c54108..86de596aa 100644 --- a/tests/hiz/hiz-stencil-test-fbo-d24s8.c +++ b/tests/hiz/hiz-stencil-test-fbo-d24s8.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END struct hiz_fbo_options fbo_options = { GL_RGBA, diff --git a/tests/hiz/hiz-stencil-test-window-depth0.c b/tests/hiz/hiz-stencil-test-window-depth0.c index 37bcdca9d..d61d5d118 100644 --- a/tests/hiz/hiz-stencil-test-window-depth0.c +++ b/tests/hiz/hiz-stencil-test-window-depth0.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/hiz/hiz-stencil-test-window-depth1.c b/tests/hiz/hiz-stencil-test-window-depth1.c index bf671051e..90ebfaa31 100644 --- a/tests/hiz/hiz-stencil-test-window-depth1.c +++ b/tests/hiz/hiz-stencil-test-window-depth1.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" #include "hiz/hiz-util.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_STENCIL | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_STENCIL | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/security/initialized-fbo.c b/tests/security/initialized-fbo.c index 85acd90f6..c9e8957ce 100644 --- a/tests/security/initialized-fbo.c +++ b/tests/security/initialized-fbo.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 512 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 512; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint fbo, rb; diff --git a/tests/security/initialized-texmemory.c b/tests/security/initialized-texmemory.c index 68d318d01..a626cf1fb 100644 --- a/tests/security/initialized-texmemory.c +++ b/tests/security/initialized-texmemory.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 512 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 512; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result diff --git a/tests/security/initialized-vbo.c b/tests/security/initialized-vbo.c index eb167dcdd..be6e4e588 100644 --- a/tests/security/initialized-vbo.c +++ b/tests/security/initialized-vbo.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result diff --git a/tests/shaders/activeprogram-bad-program.c b/tests/shaders/activeprogram-bad-program.c index f462ada87..405586537 100644 --- a/tests/shaders/activeprogram-bad-program.c +++ b/tests/shaders/activeprogram-bad-program.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char bad_vs_text[] = "vec4 my_ftransform(void);\n" diff --git a/tests/shaders/activeprogram-get.c b/tests/shaders/activeprogram-get.c index 37ba333c8..104ba090e 100644 --- a/tests/shaders/activeprogram-get.c +++ b/tests/shaders/activeprogram-get.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "void main() { gl_Position = gl_Vertex; }"; diff --git a/tests/shaders/ati-fs-bad-delete.c b/tests/shaders/ati-fs-bad-delete.c index 6975e2e0e..1f679b633 100644 --- a/tests/shaders/ati-fs-bad-delete.c +++ b/tests/shaders/ati-fs-bad-delete.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/attribute0.c b/tests/shaders/attribute0.c index 155b668e8..b53eb8984 100644 --- a/tests/shaders/attribute0.c +++ b/tests/shaders/attribute0.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "attribute vec4 vertex;\n" diff --git a/tests/shaders/createshaderprogram-attached-shaders.c b/tests/shaders/createshaderprogram-attached-shaders.c index c44f822d2..92e01fe14 100644 --- a/tests/shaders/createshaderprogram-attached-shaders.c +++ b/tests/shaders/createshaderprogram-attached-shaders.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "void main() { gl_Position = gl_Vertex; }"; diff --git a/tests/shaders/createshaderprogram-bad-type.c b/tests/shaders/createshaderprogram-bad-type.c index 8450415e1..14f107c61 100644 --- a/tests/shaders/createshaderprogram-bad-type.c +++ b/tests/shaders/createshaderprogram-bad-type.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "void main() { gl_Position = gl_Vertex; }"; diff --git a/tests/shaders/fp-abs-01.c b/tests/shaders/fp-abs-01.c index 269136b34..ca9a562fa 100644 --- a/tests/shaders/fp-abs-01.c +++ b/tests/shaders/fp-abs-01.c @@ -34,10 +34,13 @@ #define TEST_COLS 2 #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char cos_shader_source[] = "!!ARBfp1.0\n" diff --git a/tests/shaders/fp-abs-02.c b/tests/shaders/fp-abs-02.c index ba43d1a16..2cdb1c63c 100644 --- a/tests/shaders/fp-abs-02.c +++ b/tests/shaders/fp-abs-02.c @@ -34,10 +34,13 @@ #define TEST_COLS 3 #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char cos_shader_source[] = "!!ARBfp1.0\n" diff --git a/tests/shaders/fp-condition_codes-01.c b/tests/shaders/fp-condition_codes-01.c index 32bd69a48..32e3f4cda 100644 --- a/tests/shaders/fp-condition_codes-01.c +++ b/tests/shaders/fp-condition_codes-01.c @@ -41,10 +41,13 @@ #define BOX_SIZE 16 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define INVERT_MASK(x) (~(x) & 0x0f) diff --git a/tests/shaders/fp-fog.c b/tests/shaders/fp-fog.c index 67b506d9f..29b8630bb 100644 --- a/tests/shaders/fp-fog.c +++ b/tests/shaders/fp-fog.c @@ -38,10 +38,13 @@ static const char* const program_text = "END\n" ; -PIGLIT_GL_TEST_MAIN( - 50 /*window_width*/, - 50 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 50; + config.window_height = 50; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static PFNGLFOGCOORDFPROC pglFogCoordf = NULL; diff --git a/tests/shaders/fp-formats.c b/tests/shaders/fp-formats.c index 32a47f1f2..ad8ecfa15 100644 --- a/tests/shaders/fp-formats.c +++ b/tests/shaders/fp-formats.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** * Modulate the primary color with the alpha channel of the texture diff --git a/tests/shaders/fp-fragment-position.c b/tests/shaders/fp-fragment-position.c index f366ab2d6..d1a7e24f7 100644 --- a/tests/shaders/fp-fragment-position.c +++ b/tests/shaders/fp-fragment-position.c @@ -27,10 +27,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END extern float piglit_tolerance[4]; diff --git a/tests/shaders/fp-incomplete-tex.c b/tests/shaders/fp-incomplete-tex.c index 12ce13008..b15365b2e 100644 --- a/tests/shaders/fp-incomplete-tex.c +++ b/tests/shaders/fp-incomplete-tex.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END #define NUM_PROGRAMS 5 diff --git a/tests/shaders/fp-indirections.c b/tests/shaders/fp-indirections.c index 2dc9b59b5..917d4771d 100644 --- a/tests/shaders/fp-indirections.c +++ b/tests/shaders/fp-indirections.c @@ -27,10 +27,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int get_program_i(GLenum pname) { diff --git a/tests/shaders/fp-indirections2.c b/tests/shaders/fp-indirections2.c index 929809d53..95d9cc5af 100644 --- a/tests/shaders/fp-indirections2.c +++ b/tests/shaders/fp-indirections2.c @@ -36,10 +36,13 @@ #define TEXTURE_SIZE 32 /* Note: Hardcoded dependencies in texture_init and texture_follow */ -PIGLIT_GL_TEST_MAIN( - TEXTURE_SIZE /*window_width*/, - TEXTURE_SIZE /*window_height*/, - PIGLIT_GL_VISUAL_RGBA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = TEXTURE_SIZE; + config.window_height = TEXTURE_SIZE; + config.window_visual = PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END unsigned int max_samples; unsigned char * texture_data; diff --git a/tests/shaders/fp-kil.c b/tests/shaders/fp-kil.c index 87fc8a3b5..2e4cf0292 100644 --- a/tests/shaders/fp-kil.c +++ b/tests/shaders/fp-kil.c @@ -27,10 +27,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END #define NUM_PROGRAMS 2 diff --git a/tests/shaders/fp-lit-mask.c b/tests/shaders/fp-lit-mask.c index dbb0a16eb..428b38f55 100644 --- a/tests/shaders/fp-lit-mask.c +++ b/tests/shaders/fp-lit-mask.c @@ -27,10 +27,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static GLuint FragProg[15]; diff --git a/tests/shaders/fp-lit-src-equals-dst.c b/tests/shaders/fp-lit-src-equals-dst.c index 0a8bece63..e3e22946a 100644 --- a/tests/shaders/fp-lit-src-equals-dst.c +++ b/tests/shaders/fp-lit-src-equals-dst.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static GLuint FragProg[15]; diff --git a/tests/shaders/fp-long-alu.c b/tests/shaders/fp-long-alu.c index 784e2b964..29d1145d2 100644 --- a/tests/shaders/fp-long-alu.c +++ b/tests/shaders/fp-long-alu.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END int max_alu_instructions; diff --git a/tests/shaders/fp-rfl.c b/tests/shaders/fp-rfl.c index 0b0cae8b4..e951e8de8 100644 --- a/tests/shaders/fp-rfl.c +++ b/tests/shaders/fp-rfl.c @@ -42,10 +42,13 @@ */ #define TEST_ROWS ((400 - 1) / (BOX_SIZE + 1)) -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE + 1) * TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE + 1) * TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vert_shader_source[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/fp-set-01.c b/tests/shaders/fp-set-01.c index 288a21381..6bff7c305 100644 --- a/tests/shaders/fp-set-01.c +++ b/tests/shaders/fp-set-01.c @@ -40,10 +40,13 @@ #define BOX_SIZE 16 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** * Source for the fragment program to render the reference box. diff --git a/tests/shaders/fp-set-02.c b/tests/shaders/fp-set-02.c index 57d13a430..1e5cb1d53 100644 --- a/tests/shaders/fp-set-02.c +++ b/tests/shaders/fp-set-02.c @@ -69,10 +69,13 @@ struct { #define BOX_SIZE 8 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** * Source for the fragment program to render the reference box. diff --git a/tests/shaders/fp-unpack-01.c b/tests/shaders/fp-unpack-01.c index e0e1575de..ec4d1b869 100644 --- a/tests/shaders/fp-unpack-01.c +++ b/tests/shaders/fp-unpack-01.c @@ -41,10 +41,13 @@ #define BOX_SIZE 16 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static char shader_source[64 * 1024]; static GLfloat colors[TEST_COLS][4]; diff --git a/tests/shaders/getuniform-01.c b/tests/shaders/getuniform-01.c index 1934f5101..1aa7b4f1b 100644 --- a/tests/shaders/getuniform-01.c +++ b/tests/shaders/getuniform-01.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 20 /*window_width*/, - 20 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 20; + config.window_height = 20; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "uniform float c[4];\n" diff --git a/tests/shaders/getuniform-02.c b/tests/shaders/getuniform-02.c index 7b06fb512..3d9eddef5 100644 --- a/tests/shaders/getuniform-02.c +++ b/tests/shaders/getuniform-02.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 20 /*window_width*/, - 20 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 20; + config.window_height = 20; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static char *TestName = "getuniform-02"; diff --git a/tests/shaders/glsl-arb-fragment-coord-conventions-define.c b/tests/shaders/glsl-arb-fragment-coord-conventions-define.c index 0955adb04..d02a6984d 100644 --- a/tests/shaders/glsl-arb-fragment-coord-conventions-define.c +++ b/tests/shaders/glsl-arb-fragment-coord-conventions-define.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-arb-fragment-coord-conventions.c b/tests/shaders/glsl-arb-fragment-coord-conventions.c index 8309cf3dc..9fb630989 100644 --- a/tests/shaders/glsl-arb-fragment-coord-conventions.c +++ b/tests/shaders/glsl-arb-fragment-coord-conventions.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const float black[4] = {0.0, 0.0, 0.0, 0.0}; static const float red[4] = {1.0, 0.0, 0.0, 0.0}; diff --git a/tests/shaders/glsl-bindattriblocation.c b/tests/shaders/glsl-bindattriblocation.c index 07163dad6..1b32a8ab3 100644 --- a/tests/shaders/glsl-bindattriblocation.c +++ b/tests/shaders/glsl-bindattriblocation.c @@ -41,10 +41,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLchar *vertShaderText = "attribute vec4 attrib;\n" diff --git a/tests/shaders/glsl-bug-22603.c b/tests/shaders/glsl-bug-22603.c index c017f4ff5..8c6bc12e7 100644 --- a/tests/shaders/glsl-bug-22603.c +++ b/tests/shaders/glsl-bug-22603.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 800 /*window_width*/, - 600 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 800; + config.window_height = 600; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* Misbehaviour: first: the quads are not drawn in the correct order * (darker equals closer to the viewer), second: the middle one is strangely diff --git a/tests/shaders/glsl-cos.c b/tests/shaders/glsl-cos.c index fc0acd29d..a69a63fc3 100644 --- a/tests/shaders/glsl-cos.c +++ b/tests/shaders/glsl-cos.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static char vs_code[] = "uniform float a;\n" diff --git a/tests/shaders/glsl-deriv-varyings.c b/tests/shaders/glsl-deriv-varyings.c index e043c8c9a..9c56e049f 100644 --- a/tests/shaders/glsl-deriv-varyings.c +++ b/tests/shaders/glsl-deriv-varyings.c @@ -33,10 +33,13 @@ static void compileLinkProg(void); static void loadTex(void); -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex[1]; static GLint prog1; diff --git a/tests/shaders/glsl-derivs.c b/tests/shaders/glsl-derivs.c index 31160b458..0f38ad41b 100644 --- a/tests/shaders/glsl-derivs.c +++ b/tests/shaders/glsl-derivs.c @@ -33,10 +33,13 @@ static void compileLinkProg(void); static void loadTex(void); -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex[1]; static GLint prog1; diff --git a/tests/shaders/glsl-dlist-getattriblocation.c b/tests/shaders/glsl-dlist-getattriblocation.c index 4be44a011..3d98c673f 100644 --- a/tests/shaders/glsl-dlist-getattriblocation.c +++ b/tests/shaders/glsl-dlist-getattriblocation.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const GLchar *vertShaderText = "attribute vec4 attrib;\n" diff --git a/tests/shaders/glsl-empty-vs-no-fs.c b/tests/shaders/glsl-empty-vs-no-fs.c index 46dc16fc7..0f8240c4d 100644 --- a/tests/shaders/glsl-empty-vs-no-fs.c +++ b/tests/shaders/glsl-empty-vs-no-fs.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 250 /*window_width*/, - 250 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 250; + config.window_height = 250; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_source = "void main() {}"; diff --git a/tests/shaders/glsl-explicit-location-01.c b/tests/shaders/glsl-explicit-location-01.c index 483e73964..ac4e32563 100644 --- a/tests/shaders/glsl-explicit-location-01.c +++ b/tests/shaders/glsl-explicit-location-01.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-explicit-location-02.c b/tests/shaders/glsl-explicit-location-02.c index 9096f1943..8d9fa7fe0 100644 --- a/tests/shaders/glsl-explicit-location-02.c +++ b/tests/shaders/glsl-explicit-location-02.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-explicit-location-03.c b/tests/shaders/glsl-explicit-location-03.c index 103f4e97f..bc04102a2 100644 --- a/tests/shaders/glsl-explicit-location-03.c +++ b/tests/shaders/glsl-explicit-location-03.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-explicit-location-04.c b/tests/shaders/glsl-explicit-location-04.c index b1668474d..d35dc2e9b 100644 --- a/tests/shaders/glsl-explicit-location-04.c +++ b/tests/shaders/glsl-explicit-location-04.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-explicit-location-05.c b/tests/shaders/glsl-explicit-location-05.c index 695878672..b43566276 100644 --- a/tests/shaders/glsl-explicit-location-05.c +++ b/tests/shaders/glsl-explicit-location-05.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-fs-bug25902.c b/tests/shaders/glsl-fs-bug25902.c index 988c0c310..25bf57a63 100644 --- a/tests/shaders/glsl-fs-bug25902.c +++ b/tests/shaders/glsl-fs-bug25902.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int args_location, tex_location; static GLint prog; diff --git a/tests/shaders/glsl-fs-color-matrix.c b/tests/shaders/glsl-fs-color-matrix.c index 5098f24e0..972dd4624 100644 --- a/tests/shaders/glsl-fs-color-matrix.c +++ b/tests/shaders/glsl-fs-color-matrix.c @@ -31,10 +31,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END const char *vs_text = "attribute vec4 vertex;\n" diff --git a/tests/shaders/glsl-fs-discard-02.c b/tests/shaders/glsl-fs-discard-02.c index b08d81b47..9b87976c1 100644 --- a/tests/shaders/glsl-fs-discard-02.c +++ b/tests/shaders/glsl-fs-discard-02.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static char vs_code[] = "varying vec4 color;" diff --git a/tests/shaders/glsl-fs-exp2.c b/tests/shaders/glsl-fs-exp2.c index 696b18463..eedc23d1a 100644 --- a/tests/shaders/glsl-fs-exp2.c +++ b/tests/shaders/glsl-fs-exp2.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int args1_location, args2_location; static GLint prog; diff --git a/tests/shaders/glsl-fs-flat-color.c b/tests/shaders/glsl-fs-flat-color.c index c3b45b60f..12aca37c6 100644 --- a/tests/shaders/glsl-fs-flat-color.c +++ b/tests/shaders/glsl-fs-flat-color.c @@ -27,10 +27,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END GLuint prog; diff --git a/tests/shaders/glsl-fs-fogcolor-statechange.c b/tests/shaders/glsl-fs-fogcolor-statechange.c index d059442fa..caeec7deb 100644 --- a/tests/shaders/glsl-fs-fogcolor-statechange.c +++ b/tests/shaders/glsl-fs-fogcolor-statechange.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-fs-fragcoord-zw-ortho.c b/tests/shaders/glsl-fs-fragcoord-zw-ortho.c index 34f561db6..675be52d0 100644 --- a/tests/shaders/glsl-fs-fragcoord-zw-ortho.c +++ b/tests/shaders/glsl-fs-fragcoord-zw-ortho.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static void draw_quad(float x, float y, float w, float h) diff --git a/tests/shaders/glsl-fs-fragcoord-zw-perspective.c b/tests/shaders/glsl-fs-fragcoord-zw-perspective.c index b997f2005..4ffecadb9 100644 --- a/tests/shaders/glsl-fs-fragcoord-zw-perspective.c +++ b/tests/shaders/glsl-fs-fragcoord-zw-perspective.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static GLfloat Znear = 1.0, Zfar = 10.0; diff --git a/tests/shaders/glsl-fs-fragcoord.c b/tests/shaders/glsl-fs-fragcoord.c index a7309daae..eaf1ad847 100644 --- a/tests/shaders/glsl-fs-fragcoord.c +++ b/tests/shaders/glsl-fs-fragcoord.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-fs-loop-nested.c b/tests/shaders/glsl-fs-loop-nested.c index 9de20f60d..67b568b28 100644 --- a/tests/shaders/glsl-fs-loop-nested.c +++ b/tests/shaders/glsl-fs-loop-nested.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int color_location; static GLint prog; diff --git a/tests/shaders/glsl-fs-loop.c b/tests/shaders/glsl-fs-loop.c index eafc32c4f..53c2501ba 100644 --- a/tests/shaders/glsl-fs-loop.c +++ b/tests/shaders/glsl-fs-loop.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int color_location; static GLint prog; diff --git a/tests/shaders/glsl-fs-mix-constant.c b/tests/shaders/glsl-fs-mix-constant.c index fcbf76f10..f9e70e6e3 100644 --- a/tests/shaders/glsl-fs-mix-constant.c +++ b/tests/shaders/glsl-fs-mix-constant.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-fs-mix.c b/tests/shaders/glsl-fs-mix.c index 90fe8fa50..7b3a4f0d1 100644 --- a/tests/shaders/glsl-fs-mix.c +++ b/tests/shaders/glsl-fs-mix.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static int args1_location, args2_location, args3_location; static GLint prog; diff --git a/tests/shaders/glsl-fs-pointcoord.c b/tests/shaders/glsl-fs-pointcoord.c index 7112deec3..72649f265 100644 --- a/tests/shaders/glsl-fs-pointcoord.c +++ b/tests/shaders/glsl-fs-pointcoord.c @@ -44,10 +44,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; static GLint point_size; diff --git a/tests/shaders/glsl-fs-raytrace-bug27060.c b/tests/shaders/glsl-fs-raytrace-bug27060.c index 12d92783c..f00102d99 100644 --- a/tests/shaders/glsl-fs-raytrace-bug27060.c +++ b/tests/shaders/glsl-fs-raytrace-bug27060.c @@ -25,10 +25,13 @@ #include "piglit-util-gl-common.h" #include "glsl-fs-raytrace-bug27060.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint program = -1; static float rot[9] = {1,0,0, 0,1,0, 0,0,1}; diff --git a/tests/shaders/glsl-fs-sampler-numbering.c b/tests/shaders/glsl-fs-sampler-numbering.c index 0ed8d051a..ceabb1c80 100644 --- a/tests/shaders/glsl-fs-sampler-numbering.c +++ b/tests/shaders/glsl-fs-sampler-numbering.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int sampler_location; static GLint prog; diff --git a/tests/shaders/glsl-fs-shader-stencil-export.c b/tests/shaders/glsl-fs-shader-stencil-export.c index d1dbbcc35..f69814a92 100644 --- a/tests/shaders/glsl-fs-shader-stencil-export.c +++ b/tests/shaders/glsl-fs-shader-stencil-export.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-fs-sqrt-branch.c b/tests/shaders/glsl-fs-sqrt-branch.c index eb90cbb0b..b960fe308 100644 --- a/tests/shaders/glsl-fs-sqrt-branch.c +++ b/tests/shaders/glsl-fs-sqrt-branch.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int args1_location, args2_location; static GLint prog; diff --git a/tests/shaders/glsl-fs-texture2drect.c b/tests/shaders/glsl-fs-texture2drect.c index e05628c27..742104fbf 100644 --- a/tests/shaders/glsl-fs-texture2drect.c +++ b/tests/shaders/glsl-fs-texture2drect.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 50 /*window_width*/, - 50 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 50; + config.window_height = 50; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; float red[4] = {1.0, 0.0, 0.0, 1.0}; diff --git a/tests/shaders/glsl-fs-texturecube-2.c b/tests/shaders/glsl-fs-texturecube-2.c index 9783aa27f..4c3fd30f7 100644 --- a/tests/shaders/glsl-fs-texturecube-2.c +++ b/tests/shaders/glsl-fs-texturecube-2.c @@ -35,10 +35,13 @@ #define SIZE 32 -PIGLIT_GL_TEST_MAIN( - SIZE * 6 /*window_width*/, - SIZE /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = SIZE*6; + config.window_height = SIZE; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-fs-texturecube.c b/tests/shaders/glsl-fs-texturecube.c index db04033c7..d3d01c475 100644 --- a/tests/shaders/glsl-fs-texturecube.c +++ b/tests/shaders/glsl-fs-texturecube.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 120 /*window_width*/, - 20 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 120; + config.window_height = 20; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-fs-textureenvcolor-statechange.c b/tests/shaders/glsl-fs-textureenvcolor-statechange.c index cb7375091..23b90bcf0 100644 --- a/tests/shaders/glsl-fs-textureenvcolor-statechange.c +++ b/tests/shaders/glsl-fs-textureenvcolor-statechange.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-fs-user-varying-ff.c b/tests/shaders/glsl-fs-user-varying-ff.c index 092551fbd..8c894a178 100644 --- a/tests/shaders/glsl-fs-user-varying-ff.c +++ b/tests/shaders/glsl-fs-user-varying-ff.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char fs_text[] = "varying vec4 color;\n" diff --git a/tests/shaders/glsl-fwidth.c b/tests/shaders/glsl-fwidth.c index d839c1a15..9679e1a9b 100644 --- a/tests/shaders/glsl-fwidth.c +++ b/tests/shaders/glsl-fwidth.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static void loadTex(void); static void compileLinkProg(void); diff --git a/tests/shaders/glsl-getactiveuniform-array-size.c b/tests/shaders/glsl-getactiveuniform-array-size.c index 39ffff706..1eb9c743c 100644 --- a/tests/shaders/glsl-getactiveuniform-array-size.c +++ b/tests/shaders/glsl-getactiveuniform-array-size.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-getactiveuniform-count.c b/tests/shaders/glsl-getactiveuniform-count.c index 1317d50b7..19007a481 100644 --- a/tests/shaders/glsl-getactiveuniform-count.c +++ b/tests/shaders/glsl-getactiveuniform-count.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-getactiveuniform-length.c b/tests/shaders/glsl-getactiveuniform-length.c index 65ddaff3a..b46df782e 100644 --- a/tests/shaders/glsl-getactiveuniform-length.c +++ b/tests/shaders/glsl-getactiveuniform-length.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-getattriblocation.c b/tests/shaders/glsl-getattriblocation.c index 1357e1331..a35b8d0aa 100644 --- a/tests/shaders/glsl-getattriblocation.c +++ b/tests/shaders/glsl-getattriblocation.c @@ -42,10 +42,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLchar *vertShaderText = "attribute vec4 attrib;\n" diff --git a/tests/shaders/glsl-invalid-asm-01.c b/tests/shaders/glsl-invalid-asm-01.c index 4e5d623f8..0d35dd648 100644 --- a/tests/shaders/glsl-invalid-asm-01.c +++ b/tests/shaders/glsl-invalid-asm-01.c @@ -39,10 +39,13 @@ static const char vs_text[] = static const char fp_text[] = "this won't compile"; -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-invalid-asm-02.c b/tests/shaders/glsl-invalid-asm-02.c index 6cbbe0c6f..0a964af39 100644 --- a/tests/shaders/glsl-invalid-asm-02.c +++ b/tests/shaders/glsl-invalid-asm-02.c @@ -38,10 +38,13 @@ static const char fs_text[] = static const char vp_text[] = "this won't compile"; -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-kwin-blur-1.c b/tests/shaders/glsl-kwin-blur-1.c index 88d6af211..70f900cfc 100644 --- a/tests/shaders/glsl-kwin-blur-1.c +++ b/tests/shaders/glsl-kwin-blur-1.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* Note: In KWin, the code for these shaders is generated at runtime, diff --git a/tests/shaders/glsl-kwin-blur-2.c b/tests/shaders/glsl-kwin-blur-2.c index 23acda622..be40abe2c 100644 --- a/tests/shaders/glsl-kwin-blur-2.c +++ b/tests/shaders/glsl-kwin-blur-2.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* Note: In KWin, the code for these shaders is generated at runtime, diff --git a/tests/shaders/glsl-light-model.c b/tests/shaders/glsl-light-model.c index 744320b86..693ea9b02 100644 --- a/tests/shaders/glsl-light-model.c +++ b/tests/shaders/glsl-light-model.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLfloat verts[12] = { 10.0, 10.0, diff --git a/tests/shaders/glsl-link-bug30552.c b/tests/shaders/glsl-link-bug30552.c index 9615215b8..d5e014793 100644 --- a/tests/shaders/glsl-link-bug30552.c +++ b/tests/shaders/glsl-link-bug30552.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-link-bug38015.c b/tests/shaders/glsl-link-bug38015.c index 7699ca52e..ebb82724c 100644 --- a/tests/shaders/glsl-link-bug38015.c +++ b/tests/shaders/glsl-link-bug38015.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char fs_text[] = "#extension GL_ARB_shader_texture_lod : enable\n" diff --git a/tests/shaders/glsl-link-empty-prog-01.c b/tests/shaders/glsl-link-empty-prog-01.c index e3ba105f3..465e0fdc4 100644 --- a/tests/shaders/glsl-link-empty-prog-01.c +++ b/tests/shaders/glsl-link-empty-prog-01.c @@ -23,10 +23,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) { diff --git a/tests/shaders/glsl-link-empty-prog-02.c b/tests/shaders/glsl-link-empty-prog-02.c index 74b059729..b146ba791 100644 --- a/tests/shaders/glsl-link-empty-prog-02.c +++ b/tests/shaders/glsl-link-empty-prog-02.c @@ -55,10 +55,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint prog = 0; static GLuint tex = 0; diff --git a/tests/shaders/glsl-link-initializer-03.c b/tests/shaders/glsl-link-initializer-03.c index 2bba219ca..0d299621f 100644 --- a/tests/shaders/glsl-link-initializer-03.c +++ b/tests/shaders/glsl-link-initializer-03.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-link-test.c b/tests/shaders/glsl-link-test.c index 2fca629c6..0d46468de 100644 --- a/tests/shaders/glsl-link-test.c +++ b/tests/shaders/glsl-link-test.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-lod-bias.c b/tests/shaders/glsl-lod-bias.c index a34d6de63..524494051 100644 --- a/tests/shaders/glsl-lod-bias.c +++ b/tests/shaders/glsl-lod-bias.c @@ -39,10 +39,13 @@ #define TEST_COLS 5 #define BOX_SIZE (1 << (TEST_COLS + 1)) -PIGLIT_GL_TEST_MAIN( - (BOX_SIZE + 2) * TEST_COLS + 1 /*window_width*/, - (BOX_SIZE + 1) + 1 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (BOX_SIZE+2)*TEST_COLS+1; + config.window_height = (BOX_SIZE+1)+1; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex[1]; static GLint prog; diff --git a/tests/shaders/glsl-mat-attribute.c b/tests/shaders/glsl-mat-attribute.c index 1de3e4f93..c93666940 100644 --- a/tests/shaders/glsl-mat-attribute.c +++ b/tests/shaders/glsl-mat-attribute.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog[4]; diff --git a/tests/shaders/glsl-max-varyings.c b/tests/shaders/glsl-max-varyings.c index 934c66c8c..2ef19f6b9 100644 --- a/tests/shaders/glsl-max-varyings.c +++ b/tests/shaders/glsl-max-varyings.c @@ -37,10 +37,13 @@ /* 10x10 rectangles with 2 pixels of pad. Deal with up to 32 varyings. */ -PIGLIT_GL_TEST_MAIN( - (2 + MAX_VARYING * 12) /*window_width*/, - (2 + MAX_VARYING * 12) /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (2+MAX_VARYING*12); + config.window_height = (2+MAX_VARYING*12); + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* Generate a VS that writes to num_varyings vec4s, and put * interesting data in data_varying with 0.0 everywhere else. diff --git a/tests/shaders/glsl-max-vertex-attrib.c b/tests/shaders/glsl-max-vertex-attrib.c index f7082da9d..4386e62bb 100644 --- a/tests/shaders/glsl-max-vertex-attrib.c +++ b/tests/shaders/glsl-max-vertex-attrib.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 250 /*window_width*/, - 250 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 250; + config.window_height = 250; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static int test = 0; diff --git a/tests/shaders/glsl-novertexdata.c b/tests/shaders/glsl-novertexdata.c index e13bb0330..061a77e0a 100644 --- a/tests/shaders/glsl-novertexdata.c +++ b/tests/shaders/glsl-novertexdata.c @@ -42,10 +42,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLchar *vertShaderText = "attribute vec4 attrib;\n" diff --git a/tests/shaders/glsl-orangebook-ch06-bump.c b/tests/shaders/glsl-orangebook-ch06-bump.c index 260a480d9..2d201b938 100644 --- a/tests/shaders/glsl-orangebook-ch06-bump.c +++ b/tests/shaders/glsl-orangebook-ch06-bump.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int bump_density_location, bump_size_location; static int specular_factor_location, surface_color_location; diff --git a/tests/shaders/glsl-preprocessor-comments.c b/tests/shaders/glsl-preprocessor-comments.c index e2d90efce..202728836 100644 --- a/tests/shaders/glsl-preprocessor-comments.c +++ b/tests/shaders/glsl-preprocessor-comments.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int args1_location; static GLint prog; diff --git a/tests/shaders/glsl-reload-source.c b/tests/shaders/glsl-reload-source.c index 38a3a22aa..d794b3059 100644 --- a/tests/shaders/glsl-reload-source.c +++ b/tests/shaders/glsl-reload-source.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_one[] = "varying vec4 color;\n" diff --git a/tests/shaders/glsl-routing.c b/tests/shaders/glsl-routing.c index c6ed396f3..50c94b93c 100644 --- a/tests/shaders/glsl-routing.c +++ b/tests/shaders/glsl-routing.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 260 /*window_width*/, - 365 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 260; + config.window_height = 365; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define COLORS 2 #define TEXCOORDS 6 diff --git a/tests/shaders/glsl-sin.c b/tests/shaders/glsl-sin.c index 9b76701d9..18b15efe8 100644 --- a/tests/shaders/glsl-sin.c +++ b/tests/shaders/glsl-sin.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static char vs_code[] = "uniform float a;\n" diff --git a/tests/shaders/glsl-uniform-out-of-bounds.c b/tests/shaders/glsl-uniform-out-of-bounds.c index 2af5fe3ca..979d270e6 100644 --- a/tests/shaders/glsl-uniform-out-of-bounds.c +++ b/tests/shaders/glsl-uniform-out-of-bounds.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static void expect_error(GLenum expect, const char * where, ...) { diff --git a/tests/shaders/glsl-uniform-update.c b/tests/shaders/glsl-uniform-update.c index 303c77511..4d614280a 100644 --- a/tests/shaders/glsl-uniform-update.c +++ b/tests/shaders/glsl-uniform-update.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int color_location; static GLint prog; diff --git a/tests/shaders/glsl-unused-varying.c b/tests/shaders/glsl-unused-varying.c index dad744b7c..0b8bc8157 100644 --- a/tests/shaders/glsl-unused-varying.c +++ b/tests/shaders/glsl-unused-varying.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int do_red_location; static int red_location; diff --git a/tests/shaders/glsl-useprogram-displaylist.c b/tests/shaders/glsl-useprogram-displaylist.c index 514b24949..962f704a3 100644 --- a/tests/shaders/glsl-useprogram-displaylist.c +++ b/tests/shaders/glsl-useprogram-displaylist.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint progr; static GLint progg; diff --git a/tests/shaders/glsl-vs-arrays.c b/tests/shaders/glsl-vs-arrays.c index 73a7601e5..6acb1ef24 100644 --- a/tests/shaders/glsl-vs-arrays.c +++ b/tests/shaders/glsl-vs-arrays.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; static int index1_location, index2_location; diff --git a/tests/shaders/glsl-vs-functions.c b/tests/shaders/glsl-vs-functions.c index 9677d90af..191491a6c 100644 --- a/tests/shaders/glsl-vs-functions.c +++ b/tests/shaders/glsl-vs-functions.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; static int args1_location; diff --git a/tests/shaders/glsl-vs-if-bool.c b/tests/shaders/glsl-vs-if-bool.c index 7bb856c1f..3ef13988d 100644 --- a/tests/shaders/glsl-vs-if-bool.c +++ b/tests/shaders/glsl-vs-if-bool.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; static int red_location; diff --git a/tests/shaders/glsl-vs-loop-nested.c b/tests/shaders/glsl-vs-loop-nested.c index e0757d260..34e8394db 100644 --- a/tests/shaders/glsl-vs-loop-nested.c +++ b/tests/shaders/glsl-vs-loop-nested.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-vs-loop.c b/tests/shaders/glsl-vs-loop.c index be0541969..a4b2780d3 100644 --- a/tests/shaders/glsl-vs-loop.c +++ b/tests/shaders/glsl-vs-loop.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int color_location; static GLint prog; diff --git a/tests/shaders/glsl-vs-mov-after-deref.c b/tests/shaders/glsl-vs-mov-after-deref.c index f766b81e2..ab1affb6b 100644 --- a/tests/shaders/glsl-vs-mov-after-deref.c +++ b/tests/shaders/glsl-vs-mov-after-deref.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; static int index_location; diff --git a/tests/shaders/glsl-vs-mvp-statechange.c b/tests/shaders/glsl-vs-mvp-statechange.c index cae1e8439..5e489ffbe 100644 --- a/tests/shaders/glsl-vs-mvp-statechange.c +++ b/tests/shaders/glsl-vs-mvp-statechange.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/glsl-vs-normalscale.c b/tests/shaders/glsl-vs-normalscale.c index db1254224..c6595836d 100644 --- a/tests/shaders/glsl-vs-normalscale.c +++ b/tests/shaders/glsl-vs-normalscale.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-vs-point-size.c b/tests/shaders/glsl-vs-point-size.c index 1c9cae485..5ecf3b884 100644 --- a/tests/shaders/glsl-vs-point-size.c +++ b/tests/shaders/glsl-vs-point-size.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-vs-raytrace-bug26691.c b/tests/shaders/glsl-vs-raytrace-bug26691.c index cdb0b09e7..99820bbb6 100644 --- a/tests/shaders/glsl-vs-raytrace-bug26691.c +++ b/tests/shaders/glsl-vs-raytrace-bug26691.c @@ -25,10 +25,13 @@ #include "piglit-util-gl-common.h" #include "glsl-vs-raytrace-bug26691.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const float failing_pixel_percentage = 0.15F; diff --git a/tests/shaders/glsl-vs-statechange-1.c b/tests/shaders/glsl-vs-statechange-1.c index d102dd7d4..afc4e9e1a 100644 --- a/tests/shaders/glsl-vs-statechange-1.c +++ b/tests/shaders/glsl-vs-statechange-1.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 50 /*window_width*/, - 50 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 50; + config.window_height = 50; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END const char *vs_source = "void main()\n" diff --git a/tests/shaders/glsl-vs-texturematrix-1.c b/tests/shaders/glsl-vs-texturematrix-1.c index ec7edbaa8..2ab7e6e4e 100644 --- a/tests/shaders/glsl-vs-texturematrix-1.c +++ b/tests/shaders/glsl-vs-texturematrix-1.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-vs-texturematrix-2.c b/tests/shaders/glsl-vs-texturematrix-2.c index d8cf2e43a..7f00fe6fa 100644 --- a/tests/shaders/glsl-vs-texturematrix-2.c +++ b/tests/shaders/glsl-vs-texturematrix-2.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/glsl-vs-user-varying-ff.c b/tests/shaders/glsl-vs-user-varying-ff.c index 04dffa223..673aad330 100644 --- a/tests/shaders/glsl-vs-user-varying-ff.c +++ b/tests/shaders/glsl-vs-user-varying-ff.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "varying vec4 color;\n" diff --git a/tests/shaders/gpu_shader4_attribs.c b/tests/shaders/gpu_shader4_attribs.c index 43397777e..e31bd20a6 100644 --- a/tests/shaders/gpu_shader4_attribs.c +++ b/tests/shaders/gpu_shader4_attribs.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "texture-integer"; static const GLuint Index = 3; diff --git a/tests/shaders/link-mismatch-layout-01.c b/tests/shaders/link-mismatch-layout-01.c index 448314d5f..11b4f0df1 100644 --- a/tests/shaders/link-mismatch-layout-01.c +++ b/tests/shaders/link-mismatch-layout-01.c @@ -33,10 +33,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char layout_center[] = "#extension GL_ARB_fragment_coord_conventions: enable\n" diff --git a/tests/shaders/link-mismatch-layout-02.c b/tests/shaders/link-mismatch-layout-02.c index 907ccb4ca..1b8988be2 100644 --- a/tests/shaders/link-mismatch-layout-02.c +++ b/tests/shaders/link-mismatch-layout-02.c @@ -33,10 +33,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char layout_greater[] = "#extension GL_AMD_conservative_depth: require\n" diff --git a/tests/shaders/link-mismatch-layout-03.c b/tests/shaders/link-mismatch-layout-03.c index baca2351e..3829714b7 100644 --- a/tests/shaders/link-mismatch-layout-03.c +++ b/tests/shaders/link-mismatch-layout-03.c @@ -33,10 +33,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char layout_center[] = "#extension GL_ARB_fragment_coord_conventions: enable\n" diff --git a/tests/shaders/link-unresolved-function.c b/tests/shaders/link-unresolved-function.c index 7be7b7bc1..a89c50c14 100644 --- a/tests/shaders/link-unresolved-function.c +++ b/tests/shaders/link-unresolved-function.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char bad_vs_text[] = "vec4 my_ftransform(void);\n" diff --git a/tests/shaders/shader_runner.c b/tests/shaders/shader_runner.c index 13e2f94a4..e9a5cb313 100644 --- a/tests/shaders/shader_runner.c +++ b/tests/shaders/shader_runner.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" #include "piglit-vbo.h" -PIGLIT_GL_TEST_MAIN( - 250 /*window_width*/, - 250 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 250; + config.window_height = 250; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END extern float piglit_tolerance[4]; diff --git a/tests/shaders/sso-simple.c b/tests/shaders/sso-simple.c index 26aeb654c..d24228e44 100644 --- a/tests/shaders/sso-simple.c +++ b/tests/shaders/sso-simple.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 70 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 70; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "void main() { gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex; " diff --git a/tests/shaders/sso-uniforms-01.c b/tests/shaders/sso-uniforms-01.c index c9917670d..a2a535e24 100644 --- a/tests/shaders/sso-uniforms-01.c +++ b/tests/shaders/sso-uniforms-01.c @@ -34,10 +34,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "uniform vec4 color;\n" diff --git a/tests/shaders/sso-uniforms-02.c b/tests/shaders/sso-uniforms-02.c index 9febc2d02..a8fb69f90 100644 --- a/tests/shaders/sso-uniforms-02.c +++ b/tests/shaders/sso-uniforms-02.c @@ -33,10 +33,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "uniform vec4 color;\n" diff --git a/tests/shaders/sso-user-varying-01.c b/tests/shaders/sso-user-varying-01.c index 99aa628c8..f1b8c3492 100644 --- a/tests/shaders/sso-user-varying-01.c +++ b/tests/shaders/sso-user-varying-01.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "varying vec4 color;\n" diff --git a/tests/shaders/sso-user-varying-02.c b/tests/shaders/sso-user-varying-02.c index 6b9615604..af91275c1 100644 --- a/tests/shaders/sso-user-varying-02.c +++ b/tests/shaders/sso-user-varying-02.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 30 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 30; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "varying vec4 color;\n" diff --git a/tests/shaders/trinity-fp1.c b/tests/shaders/trinity-fp1.c index 17adb8063..50a0229cf 100644 --- a/tests/shaders/trinity-fp1.c +++ b/tests/shaders/trinity-fp1.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static GLuint TexDiffuse = 1; static GLuint TexNormal = 2; diff --git a/tests/shaders/useprogram-flushverts-1.c b/tests/shaders/useprogram-flushverts-1.c index e3d67c857..1ce67e0d3 100644 --- a/tests/shaders/useprogram-flushverts-1.c +++ b/tests/shaders/useprogram-flushverts-1.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog1, prog2; diff --git a/tests/shaders/useprogram-flushverts-2.c b/tests/shaders/useprogram-flushverts-2.c index c8a2250b4..7da710966 100644 --- a/tests/shaders/useprogram-flushverts-2.c +++ b/tests/shaders/useprogram-flushverts-2.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog1, prog2; diff --git a/tests/shaders/useprogram-inside-begin.c b/tests/shaders/useprogram-inside-begin.c index a18ce2b70..7fcdd39e7 100644 --- a/tests/shaders/useprogram-inside-begin.c +++ b/tests/shaders/useprogram-inside-begin.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "void main() { gl_Position = gl_Vertex; }"; diff --git a/tests/shaders/useprogram-refcount-1.c b/tests/shaders/useprogram-refcount-1.c index 62c5ca4ee..3b182f2bf 100644 --- a/tests/shaders/useprogram-refcount-1.c +++ b/tests/shaders/useprogram-refcount-1.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/shaders/useshaderprogram-bad-program.c b/tests/shaders/useshaderprogram-bad-program.c index cfd88a5e1..18fa4a943 100644 --- a/tests/shaders/useshaderprogram-bad-program.c +++ b/tests/shaders/useshaderprogram-bad-program.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char bad_vs_text[] = "vec4 my_ftransform(void);\n" diff --git a/tests/shaders/useshaderprogram-bad-type.c b/tests/shaders/useshaderprogram-bad-type.c index c1c087f28..6bba1ad97 100644 --- a/tests/shaders/useshaderprogram-bad-type.c +++ b/tests/shaders/useshaderprogram-bad-type.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/useshaderprogram-flushverts-1.c b/tests/shaders/useshaderprogram-flushverts-1.c index 51428db6c..fc5ba322f 100644 --- a/tests/shaders/useshaderprogram-flushverts-1.c +++ b/tests/shaders/useshaderprogram-flushverts-1.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint vs_prog, fs_prog_1, fs_prog_2; diff --git a/tests/shaders/vp-address-01.c b/tests/shaders/vp-address-01.c index 117dabf9f..279e6fbeb 100644 --- a/tests/shaders/vp-address-01.c +++ b/tests/shaders/vp-address-01.c @@ -42,10 +42,13 @@ static const GLfloat attrib[] = { #define TEST_COLS ARRAY_SIZE(attrib) #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vertex_source_template[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vp-address-02.c b/tests/shaders/vp-address-02.c index 81a78a779..a6cfaa206 100644 --- a/tests/shaders/vp-address-02.c +++ b/tests/shaders/vp-address-02.c @@ -52,10 +52,13 @@ static const GLfloat attrib[] = { #define TEST_COLS (ARRAY_SIZE(attrib) / 2) #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vertex_source_template[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vp-address-03.c b/tests/shaders/vp-address-03.c index 72fb6529e..11b8410d4 100644 --- a/tests/shaders/vp-address-03.c +++ b/tests/shaders/vp-address-03.c @@ -34,10 +34,13 @@ #define TEST_COLS 4 #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vertex_source_template[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vp-address-04.c b/tests/shaders/vp-address-04.c index 9bd4321fd..e24295595 100644 --- a/tests/shaders/vp-address-04.c +++ b/tests/shaders/vp-address-04.c @@ -71,10 +71,13 @@ static const GLfloat attrib[] = { #define TEST_COLS (ARRAY_SIZE(attrib) / 2) #define BOX_SIZE 16 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vertex_source_template[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vp-address-05.c b/tests/shaders/vp-address-05.c index 596ec83ba..513665d55 100644 --- a/tests/shaders/vp-address-05.c +++ b/tests/shaders/vp-address-05.c @@ -34,10 +34,13 @@ #define TEST_COLS 4 #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vertex_source_template[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vp-address-06.c b/tests/shaders/vp-address-06.c index 605f4b612..acc7332b3 100644 --- a/tests/shaders/vp-address-06.c +++ b/tests/shaders/vp-address-06.c @@ -34,10 +34,13 @@ #define TEST_COLS 2 #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vertex_source_template[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vp-bad-program.c b/tests/shaders/vp-bad-program.c index f6ec9a9f8..16f2b86b4 100644 --- a/tests/shaders/vp-bad-program.c +++ b/tests/shaders/vp-bad-program.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/vp-clipdistance-01.c b/tests/shaders/vp-clipdistance-01.c index add72305c..dbee3bef8 100644 --- a/tests/shaders/vp-clipdistance-01.c +++ b/tests/shaders/vp-clipdistance-01.c @@ -34,10 +34,13 @@ #define TEST_COLS 6 #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vertex_source_template[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vp-clipdistance-02.c b/tests/shaders/vp-clipdistance-02.c index 6538685e3..1c6dc8434 100644 --- a/tests/shaders/vp-clipdistance-02.c +++ b/tests/shaders/vp-clipdistance-02.c @@ -38,10 +38,13 @@ #define TEST_COLS 6 #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vertex_source_template[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vp-clipdistance-03.c b/tests/shaders/vp-clipdistance-03.c index 880cd1474..86486c9d3 100644 --- a/tests/shaders/vp-clipdistance-03.c +++ b/tests/shaders/vp-clipdistance-03.c @@ -34,10 +34,13 @@ #define TEST_COLS 1 #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vertex_source_template[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vp-clipdistance-04.c b/tests/shaders/vp-clipdistance-04.c index 04409cf8f..f5c45c50e 100644 --- a/tests/shaders/vp-clipdistance-04.c +++ b/tests/shaders/vp-clipdistance-04.c @@ -38,10 +38,13 @@ #define TEST_COLS 6 #define BOX_SIZE 32 -PIGLIT_GL_TEST_MAIN( - (((BOX_SIZE+1)*TEST_COLS)+1) /*window_width*/, - (((BOX_SIZE+1)*TEST_ROWS)+1) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (((BOX_SIZE+1)*TEST_COLS)+1); + config.window_height = (((BOX_SIZE+1)*TEST_ROWS)+1); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vertex_source_template[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vp-combined-image-units.c b/tests/shaders/vp-combined-image-units.c index 9cb0c484b..b7aa8221f 100644 --- a/tests/shaders/vp-combined-image-units.c +++ b/tests/shaders/vp-combined-image-units.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/shaders/vp-ignore-input.c b/tests/shaders/vp-ignore-input.c index 62589facd..bcc3c4b01 100644 --- a/tests/shaders/vp-ignore-input.c +++ b/tests/shaders/vp-ignore-input.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; static GLint fs; diff --git a/tests/shaders/vp-max-array.c b/tests/shaders/vp-max-array.c index 568a8c9e5..fcccd9dfa 100644 --- a/tests/shaders/vp-max-array.c +++ b/tests/shaders/vp-max-array.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char template_header[] = "!!ARBvp1.0\n" diff --git a/tests/shaders/vpfp-generic.cpp b/tests/shaders/vpfp-generic.cpp index 0184b605a..01891b6ec 100644 --- a/tests/shaders/vpfp-generic.cpp +++ b/tests/shaders/vpfp-generic.cpp @@ -167,9 +167,13 @@ private: }; -PIGLIT_GL_TEST_MAIN(100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char* Filename = 0; static TestGroup tests; diff --git a/tests/spec/amd_seamless_cubemap_per_texture/amd_seamless_cubemap_per_texture.c b/tests/spec/amd_seamless_cubemap_per_texture/amd_seamless_cubemap_per_texture.c index 506d83c18..79f8e9ff8 100644 --- a/tests/spec/amd_seamless_cubemap_per_texture/amd_seamless_cubemap_per_texture.c +++ b/tests/spec/amd_seamless_cubemap_per_texture/amd_seamless_cubemap_per_texture.c @@ -21,10 +21,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 250 /*window_width*/, - 70 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 250; + config.window_height = 70; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const float colors[6][3] = { {1, 0, 0}, diff --git a/tests/spec/arb_blend_func_extended/api/bindfragdataindexed-invalid-parameters.c b/tests/spec/arb_blend_func_extended/api/bindfragdataindexed-invalid-parameters.c index 01ebf36a8..fedd0b14f 100644 --- a/tests/spec/arb_blend_func_extended/api/bindfragdataindexed-invalid-parameters.c +++ b/tests/spec/arb_blend_func_extended/api/bindfragdataindexed-invalid-parameters.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_blend_func_extended/api/blend-api.c b/tests/spec/arb_blend_func_extended/api/blend-api.c index 276ce70a2..07b126b72 100644 --- a/tests/spec/arb_blend_func_extended/api/blend-api.c +++ b/tests/spec/arb_blend_func_extended/api/blend-api.c @@ -28,10 +28,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_blend_func_extended/api/error-at-begin.c b/tests/spec/arb_blend_func_extended/api/error-at-begin.c index a73fe6048..b3dd1ed0b 100644 --- a/tests/spec/arb_blend_func_extended/api/error-at-begin.c +++ b/tests/spec/arb_blend_func_extended/api/error-at-begin.c @@ -34,10 +34,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_blend_func_extended/api/getfragdataindex.c b/tests/spec/arb_blend_func_extended/api/getfragdataindex.c index 7fedf9dec..4faa93ab5 100644 --- a/tests/spec/arb_blend_func_extended/api/getfragdataindex.c +++ b/tests/spec/arb_blend_func_extended/api/getfragdataindex.c @@ -28,10 +28,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_text = "#version 130\n" diff --git a/tests/spec/arb_blend_func_extended/execution/fbo-extended-blend-explicit.c b/tests/spec/arb_blend_func_extended/execution/fbo-extended-blend-explicit.c index 7336e2c4d..9dedef947 100644 --- a/tests/spec/arb_blend_func_extended/execution/fbo-extended-blend-explicit.c +++ b/tests/spec/arb_blend_func_extended/execution/fbo-extended-blend-explicit.c @@ -37,10 +37,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "fbo-extended-blend-explicit"; diff --git a/tests/spec/arb_blend_func_extended/execution/fbo-extended-blend.c b/tests/spec/arb_blend_func_extended/execution/fbo-extended-blend.c index b859196b2..a1851aa58 100644 --- a/tests/spec/arb_blend_func_extended/execution/fbo-extended-blend.c +++ b/tests/spec/arb_blend_func_extended/execution/fbo-extended-blend.c @@ -37,10 +37,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "fbo-extended-blend"; diff --git a/tests/spec/arb_color_buffer_float/common.h b/tests/spec/arb_color_buffer_float/common.h index 6d3386a0f..3a3dfbd2e 100644 --- a/tests/spec/arb_color_buffer_float/common.h +++ b/tests/spec/arb_color_buffer_float/common.h @@ -32,9 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN(128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* use small values for pixels[0..3], so that the 0.01 tolerance is met for fp16 */ static float pixels[] = { diff --git a/tests/spec/arb_copy_buffer/copy_buffer_coherency.c b/tests/spec/arb_copy_buffer/copy_buffer_coherency.c index e219e29ec..75b943d1e 100644 --- a/tests/spec/arb_copy_buffer/copy_buffer_coherency.c +++ b/tests/spec/arb_copy_buffer/copy_buffer_coherency.c @@ -31,10 +31,13 @@ uint8_t src_data[COPY_BUFFER_SIZE]; uint8_t dest_data[COPY_BUFFER_SIZE]; -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_copy_buffer/copybuffersubdata.c b/tests/spec/arb_copy_buffer/copybuffersubdata.c index e4e17dc70..b429a5aa8 100644 --- a/tests/spec/arb_copy_buffer/copybuffersubdata.c +++ b/tests/spec/arb_copy_buffer/copybuffersubdata.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static bool test_copy(void) diff --git a/tests/spec/arb_copy_buffer/dlist.c b/tests/spec/arb_copy_buffer/dlist.c index 3f6b5a557..f6ba09cde 100644 --- a/tests/spec/arb_copy_buffer/dlist.c +++ b/tests/spec/arb_copy_buffer/dlist.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_copy_buffer/get.c b/tests/spec/arb_copy_buffer/get.c index 938aa3338..fdb9fa97e 100644 --- a/tests/spec/arb_copy_buffer/get.c +++ b/tests/spec/arb_copy_buffer/get.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_copy_buffer/negative-bound-zero.c b/tests/spec/arb_copy_buffer/negative-bound-zero.c index a8b82b184..f8db59ffe 100644 --- a/tests/spec/arb_copy_buffer/negative-bound-zero.c +++ b/tests/spec/arb_copy_buffer/negative-bound-zero.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_copy_buffer/negative-bounds.c b/tests/spec/arb_copy_buffer/negative-bounds.c index 3f2c4f378..eeaa70d68 100644 --- a/tests/spec/arb_copy_buffer/negative-bounds.c +++ b/tests/spec/arb_copy_buffer/negative-bounds.c @@ -37,10 +37,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_copy_buffer/negative-mapped.c b/tests/spec/arb_copy_buffer/negative-mapped.c index acfdf3c45..fcc952ee6 100644 --- a/tests/spec/arb_copy_buffer/negative-mapped.c +++ b/tests/spec/arb_copy_buffer/negative-mapped.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_copy_buffer/overlap.c b/tests/spec/arb_copy_buffer/overlap.c index 7ddf70b72..703a71f98 100644 --- a/tests/spec/arb_copy_buffer/overlap.c +++ b/tests/spec/arb_copy_buffer/overlap.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static void test_copy(GLenum usage, int data_size, int src, int dst, int size) diff --git a/tests/spec/arb_copy_buffer/targets.c b/tests/spec/arb_copy_buffer/targets.c index 30cba2cfc..e2fce3c50 100644 --- a/tests/spec/arb_copy_buffer/targets.c +++ b/tests/spec/arb_copy_buffer/targets.c @@ -47,10 +47,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_debug_output/api_error.c b/tests/spec/arb_debug_output/api_error.c index a9500c0ef..c76eaeb78 100644 --- a/tests/spec/arb_debug_output/api_error.c +++ b/tests/spec/arb_debug_output/api_error.c @@ -24,10 +24,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 50 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 50; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define USER_PARAM ((void*)(intptr_t)12345678) diff --git a/tests/spec/arb_draw_buffers/state_change.c b/tests/spec/arb_draw_buffers/state_change.c index a52da0bd3..9655943f7 100644 --- a/tests/spec/arb_draw_buffers/state_change.c +++ b/tests/spec/arb_draw_buffers/state_change.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static void check_fbo_status(void) diff --git a/tests/spec/arb_draw_elements_base_vertex/dlist-arb_draw_instanced.c b/tests/spec/arb_draw_elements_base_vertex/dlist-arb_draw_instanced.c index 4eb6d180d..ada0b2d8b 100644 --- a/tests/spec/arb_draw_elements_base_vertex/dlist-arb_draw_instanced.c +++ b/tests/spec/arb_draw_elements_base_vertex/dlist-arb_draw_instanced.c @@ -53,10 +53,13 @@ * during display list compilation." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_draw_elements_base_vertex/draw-elements-instanced-base-vertex.c b/tests/spec/arb_draw_elements_base_vertex/draw-elements-instanced-base-vertex.c index 8ac37b58c..4cbd9254e 100644 --- a/tests/spec/arb_draw_elements_base_vertex/draw-elements-instanced-base-vertex.c +++ b/tests/spec/arb_draw_elements_base_vertex/draw-elements-instanced-base-vertex.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 300 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 300; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define NUM_QUADS 10 diff --git a/tests/spec/arb_draw_instanced/execution/dlist.c b/tests/spec/arb_draw_instanced/execution/dlist.c index 7718c983a..6a1be07dc 100644 --- a/tests/spec/arb_draw_instanced/execution/dlist.c +++ b/tests/spec/arb_draw_instanced/execution/dlist.c @@ -35,10 +35,13 @@ * during display list compilation." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_draw_instanced/execution/elements.c b/tests/spec/arb_draw_instanced/execution/elements.c index a939bd5c6..fc1ee9d2a 100644 --- a/tests/spec/arb_draw_instanced/execution/elements.c +++ b/tests/spec/arb_draw_instanced/execution/elements.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 70 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 70; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_source = "#version 120\n" diff --git a/tests/spec/arb_draw_instanced/execution/negative-arrays-first-negative.c b/tests/spec/arb_draw_instanced/execution/negative-arrays-first-negative.c index 547b75dbd..08c71eff2 100644 --- a/tests/spec/arb_draw_instanced/execution/negative-arrays-first-negative.c +++ b/tests/spec/arb_draw_instanced/execution/negative-arrays-first-negative.c @@ -34,10 +34,13 @@ * <first> is less than zero" */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_draw_instanced/execution/negative-elements-type.c b/tests/spec/arb_draw_instanced/execution/negative-elements-type.c index ed2f1af70..a2e41a043 100644 --- a/tests/spec/arb_draw_instanced/execution/negative-elements-type.c +++ b/tests/spec/arb_draw_instanced/execution/negative-elements-type.c @@ -35,10 +35,13 @@ * UNSIGNED_INT." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-depthrangef.c b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-depthrangef.c index b6347c63d..71a2ad62d 100644 --- a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-depthrangef.c +++ b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-depthrangef.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 150 /*window_width*/, - 150 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 150; + config.window_height = 150; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-drawbuffers.c b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-drawbuffers.c index 7209c5890..50bd7a943 100644 --- a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-drawbuffers.c +++ b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-drawbuffers.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint attach_texture(int i) diff --git a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-fixed-type.c b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-fixed-type.c index 92c6da75f..2389ea950 100644 --- a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-fixed-type.c +++ b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-fixed-type.c @@ -25,10 +25,13 @@ #include "piglit-util-gl-common.h" #include <stdarg.h> -PIGLIT_GL_TEST_MAIN( - 250 /*window_width*/, - 250 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 250; + config.window_height = 250; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static unsigned verts[4*4*4]; diff --git a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-getshaderprecisionformat.c b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-getshaderprecisionformat.c index 3764f601d..c81510942 100644 --- a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-getshaderprecisionformat.c +++ b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-getshaderprecisionformat.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-maxvectors.c b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-maxvectors.c index b2e63638a..3a9ce9089 100644 --- a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-maxvectors.c +++ b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-maxvectors.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-releaseshadercompiler.c b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-releaseshadercompiler.c index 509dbab9f..7d3a178b3 100644 --- a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-releaseshadercompiler.c +++ b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-releaseshadercompiler.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #ifdef GL_ARB_ES2_compatibility static const char vs_text[] = diff --git a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-shadercompiler.c b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-shadercompiler.c index 1aa4cd555..6f659e2de 100644 --- a/tests/spec/arb_es2_compatibility/arb_es2_compatibility-shadercompiler.c +++ b/tests/spec/arb_es2_compatibility/arb_es2_compatibility-shadercompiler.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_es2_compatibility/fbo-missing-attachment-blit.c b/tests/spec/arb_es2_compatibility/fbo-missing-attachment-blit.c index 572efe224..803c74358 100644 --- a/tests/spec/arb_es2_compatibility/fbo-missing-attachment-blit.c +++ b/tests/spec/arb_es2_compatibility/fbo-missing-attachment-blit.c @@ -56,10 +56,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_es2_compatibility/fbo-missing-attachment-clear.c b/tests/spec/arb_es2_compatibility/fbo-missing-attachment-clear.c index 9232b8cbd..bf51a6fc5 100644 --- a/tests/spec/arb_es2_compatibility/fbo-missing-attachment-clear.c +++ b/tests/spec/arb_es2_compatibility/fbo-missing-attachment-clear.c @@ -43,10 +43,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_fragment_program/minmax.c b/tests/spec/arb_fragment_program/minmax.c index 3b6572e44..70c9e37c7 100644 --- a/tests/spec/arb_fragment_program/minmax.c +++ b/tests/spec/arb_fragment_program/minmax.c @@ -27,10 +27,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_framebuffer_object/framebuffer-blit-levels.c b/tests/spec/arb_framebuffer_object/framebuffer-blit-levels.c index e79a18457..ac6ad3ae9 100644 --- a/tests/spec/arb_framebuffer_object/framebuffer-blit-levels.c +++ b/tests/spec/arb_framebuffer_object/framebuffer-blit-levels.c @@ -54,10 +54,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32, - 32, - PIGLIT_GL_VISUAL_RGBA); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END enum { TEST_MODE_DRAW, diff --git a/tests/spec/arb_framebuffer_object/get-renderbuffer-internalformat.c b/tests/spec/arb_framebuffer_object/get-renderbuffer-internalformat.c index c48a6c902..f20b7a788 100644 --- a/tests/spec/arb_framebuffer_object/get-renderbuffer-internalformat.c +++ b/tests/spec/arb_framebuffer_object/get-renderbuffer-internalformat.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" #include "../../fbo/fbo-formats.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display() diff --git a/tests/spec/arb_framebuffer_object/same-attachment-glFramebufferRenderbuffer-GL_DEPTH_STENCIL_ATTACHMENT.c b/tests/spec/arb_framebuffer_object/same-attachment-glFramebufferRenderbuffer-GL_DEPTH_STENCIL_ATTACHMENT.c index 79a9ae8b4..0e988c90f 100644 --- a/tests/spec/arb_framebuffer_object/same-attachment-glFramebufferRenderbuffer-GL_DEPTH_STENCIL_ATTACHMENT.c +++ b/tests/spec/arb_framebuffer_object/same-attachment-glFramebufferRenderbuffer-GL_DEPTH_STENCIL_ATTACHMENT.c @@ -31,10 +31,13 @@ #include <stdio.h> #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END const char* get_attachment_string(GLint attach) diff --git a/tests/spec/arb_framebuffer_object/same-attachment-glFramebufferTexture2D-GL_DEPTH_STENCIL_ATTACHMENT.c b/tests/spec/arb_framebuffer_object/same-attachment-glFramebufferTexture2D-GL_DEPTH_STENCIL_ATTACHMENT.c index c92c4b55a..e478336d9 100644 --- a/tests/spec/arb_framebuffer_object/same-attachment-glFramebufferTexture2D-GL_DEPTH_STENCIL_ATTACHMENT.c +++ b/tests/spec/arb_framebuffer_object/same-attachment-glFramebufferTexture2D-GL_DEPTH_STENCIL_ATTACHMENT.c @@ -32,10 +32,13 @@ #include <stdio.h> #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END const char* get_attachment_string(GLint attach) diff --git a/tests/spec/arb_framebuffer_srgb/pushpop.c b/tests/spec/arb_framebuffer_srgb/pushpop.c index dc73d4db1..7717f253c 100644 --- a/tests/spec/arb_framebuffer_srgb/pushpop.c +++ b/tests/spec/arb_framebuffer_srgb/pushpop.c @@ -30,10 +30,13 @@ * push/pop bits. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_instanced_arrays/instanced_arrays.c b/tests/spec/arb_instanced_arrays/instanced_arrays.c index f19193813..e7de3c251 100644 --- a/tests/spec/arb_instanced_arrays/instanced_arrays.c +++ b/tests/spec/arb_instanced_arrays/instanced_arrays.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 500 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 500; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "draw-instanced-arrays"; diff --git a/tests/spec/arb_map_buffer_range/map_buffer_range_error_check.c b/tests/spec/arb_map_buffer_range/map_buffer_range_error_check.c index 0cbacf380..00fce2263 100644 --- a/tests/spec/arb_map_buffer_range/map_buffer_range_error_check.c +++ b/tests/spec/arb_map_buffer_range/map_buffer_range_error_check.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_map_buffer_range/map_buffer_range_test.c b/tests/spec/arb_map_buffer_range/map_buffer_range_test.c index 0716edd67..095602676 100644 --- a/tests/spec/arb_map_buffer_range/map_buffer_range_test.c +++ b/tests/spec/arb_map_buffer_range/map_buffer_range_test.c @@ -27,10 +27,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END uint8_t data[1 << 20]; diff --git a/tests/spec/arb_multisample/beginend.c b/tests/spec/arb_multisample/beginend.c index b66f71155..d538bb6bf 100644 --- a/tests/spec/arb_multisample/beginend.c +++ b/tests/spec/arb_multisample/beginend.c @@ -33,10 +33,13 @@ * corresponding End." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_multisample/pushpop.c b/tests/spec/arb_multisample/pushpop.c index aa412de1f..1b1504bba 100644 --- a/tests/spec/arb_multisample/pushpop.c +++ b/tests/spec/arb_multisample/pushpop.c @@ -51,10 +51,13 @@ * */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_robustness/client-mem-bounds.c b/tests/spec/arb_robustness/client-mem-bounds.c index 042cb3a0a..dea97614d 100644 --- a/tests/spec/arb_robustness/client-mem-bounds.c +++ b/tests/spec/arb_robustness/client-mem-bounds.c @@ -23,10 +23,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 320 /*window_width*/, - 320 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 320; + config.window_height = 320; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define width (10) #define height (12) diff --git a/tests/spec/arb_robustness/draw-vbo-bounds.c b/tests/spec/arb_robustness/draw-vbo-bounds.c index 22b045cb9..221e5045f 100644 --- a/tests/spec/arb_robustness/draw-vbo-bounds.c +++ b/tests/spec/arb_robustness/draw-vbo-bounds.c @@ -47,10 +47,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 320 /*window_width*/, - 320 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 320; + config.window_height = 320; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) { diff --git a/tests/spec/arb_sampler_objects/framebufferblit.c b/tests/spec/arb_sampler_objects/framebufferblit.c index 82bb40f2d..6bfa667af 100644 --- a/tests/spec/arb_sampler_objects/framebufferblit.c +++ b/tests/spec/arb_sampler_objects/framebufferblit.c @@ -36,11 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 16 /*window_width*/, - 16 /*window_height*/, +PIGLIT_GL_TEST_CONFIG_BEGIN - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) + config.window_width = 16; + config.window_height = 16; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_sampler_objects/sampler-incomplete.c b/tests/spec/arb_sampler_objects/sampler-incomplete.c index 147bdc47a..d0b63699b 100644 --- a/tests/spec/arb_sampler_objects/sampler-incomplete.c +++ b/tests/spec/arb_sampler_objects/sampler-incomplete.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static void setup(void) diff --git a/tests/spec/arb_sampler_objects/sampler-objects.c b/tests/spec/arb_sampler_objects/sampler-objects.c index c62618aaa..9066dbb4e 100644 --- a/tests/spec/arb_sampler_objects/sampler-objects.c +++ b/tests/spec/arb_sampler_objects/sampler-objects.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char *Prog = "sampler-objects"; diff --git a/tests/spec/arb_sampler_objects/srgb-decode.c b/tests/spec/arb_sampler_objects/srgb-decode.c index 55cf520c6..57e0c48e4 100644 --- a/tests/spec/arb_sampler_objects/srgb-decode.c +++ b/tests/spec/arb_sampler_objects/srgb-decode.c @@ -41,11 +41,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 16 /*window_width*/, - 16 /*window_height*/, +PIGLIT_GL_TEST_CONFIG_BEGIN - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) + config.window_width = 16; + config.window_height = 16; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static bool test_getter(GLuint sampler) diff --git a/tests/spec/arb_seamless_cube_map/arb_seamless_cubemap.c b/tests/spec/arb_seamless_cube_map/arb_seamless_cubemap.c index 053d4fa36..d3e71a32c 100644 --- a/tests/spec/arb_seamless_cube_map/arb_seamless_cubemap.c +++ b/tests/spec/arb_seamless_cube_map/arb_seamless_cubemap.c @@ -21,10 +21,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 40 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 40; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const float colors[6][3] = { {1, 0, 0}, diff --git a/tests/spec/arb_shader_objects/bindattriblocation-scratch-name.c b/tests/spec/arb_shader_objects/bindattriblocation-scratch-name.c index da9af2761..f8e695759 100644 --- a/tests/spec/arb_shader_objects/bindattriblocation-scratch-name.c +++ b/tests/spec/arb_shader_objects/bindattriblocation-scratch-name.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLchar *vertShaderText = "attribute vec4 attrib;\n" diff --git a/tests/spec/arb_shader_objects/clear-with-deleted.c b/tests/spec/arb_shader_objects/clear-with-deleted.c index d234191de..13993c36f 100644 --- a/tests/spec/arb_shader_objects/clear-with-deleted.c +++ b/tests/spec/arb_shader_objects/clear-with-deleted.c @@ -32,10 +32,13 @@ * early). */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_source = "void main()\n" diff --git a/tests/spec/arb_shader_objects/delete-repeat.c b/tests/spec/arb_shader_objects/delete-repeat.c index b87718c44..5a485f347 100644 --- a/tests/spec/arb_shader_objects/delete-repeat.c +++ b/tests/spec/arb_shader_objects/delete-repeat.c @@ -29,10 +29,13 @@ * glDeleteProgram() is called multiple times. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_source = "void main()\n" diff --git a/tests/spec/arb_shader_objects/getactiveuniform-beginend.c b/tests/spec/arb_shader_objects/getactiveuniform-beginend.c index 9bfacef9c..468060fff 100644 --- a/tests/spec/arb_shader_objects/getactiveuniform-beginend.c +++ b/tests/spec/arb_shader_objects/getactiveuniform-beginend.c @@ -32,10 +32,13 @@ * INVALID OPERATION." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_shader_objects/getuniform.c b/tests/spec/arb_shader_objects/getuniform.c index e81a4e2f4..e8c7d2d76 100644 --- a/tests/spec/arb_shader_objects/getuniform.c +++ b/tests/spec/arb_shader_objects/getuniform.c @@ -28,10 +28,13 @@ * Tests that glGetUniform* work on various scalar/vector types. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_shader_objects/getuniformlocation-array-of-struct-of-array.c b/tests/spec/arb_shader_objects/getuniformlocation-array-of-struct-of-array.c index 0c684c0ef..d2fb7c700 100644 --- a/tests/spec/arb_shader_objects/getuniformlocation-array-of-struct-of-array.c +++ b/tests/spec/arb_shader_objects/getuniformlocation-array-of-struct-of-array.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_code = "struct S { mat4 m; vec4 v[10]; };\n" diff --git a/tests/spec/arb_shader_texture_lod/execution/texgrad.c b/tests/spec/arb_shader_texture_lod/execution/texgrad.c index d8dd4554f..319e06c58 100644 --- a/tests/spec/arb_shader_texture_lod/execution/texgrad.c +++ b/tests/spec/arb_shader_texture_lod/execution/texgrad.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define TEX_WIDTH 256 #define TEX_HEIGHT 256 diff --git a/tests/spec/arb_sync/repeat-wait.c b/tests/spec/arb_sync/repeat-wait.c index a0f3d782b..d0dc38b2b 100644 --- a/tests/spec/arb_sync/repeat-wait.c +++ b/tests/spec/arb_sync/repeat-wait.c @@ -43,10 +43,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END #define ONE_SECOND 1000000 diff --git a/tests/spec/arb_sync/timeout-zero.c b/tests/spec/arb_sync/timeout-zero.c index b3fefba6e..c06d257b3 100644 --- a/tests/spec/arb_sync/timeout-zero.c +++ b/tests/spec/arb_sync/timeout-zero.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END #define ONE_SECOND 1000000 diff --git a/tests/spec/arb_texture_buffer_object/dlist.c b/tests/spec/arb_texture_buffer_object/dlist.c index 4faffda6c..55450450f 100644 --- a/tests/spec/arb_texture_buffer_object/dlist.c +++ b/tests/spec/arb_texture_buffer_object/dlist.c @@ -33,10 +33,13 @@ * list. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_texture_buffer_object/formats.c b/tests/spec/arb_texture_buffer_object/formats.c index 3e85dad84..35b577bf9 100644 --- a/tests/spec/arb_texture_buffer_object/formats.c +++ b/tests/spec/arb_texture_buffer_object/formats.c @@ -28,10 +28,13 @@ #define _GNU_SOURCE #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 500 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 500; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum channels { A, diff --git a/tests/spec/arb_texture_buffer_object/get.c b/tests/spec/arb_texture_buffer_object/get.c index e2f876646..d232303e8 100644 --- a/tests/spec/arb_texture_buffer_object/get.c +++ b/tests/spec/arb_texture_buffer_object/get.c @@ -29,10 +29,13 @@ * Tests glGetIntegerv queries not covered by other tests. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_texture_buffer_object/minmax.c b/tests/spec/arb_texture_buffer_object/minmax.c index ba3047595..d6bbe1c99 100644 --- a/tests/spec/arb_texture_buffer_object/minmax.c +++ b/tests/spec/arb_texture_buffer_object/minmax.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" #include "minmax-test.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_texture_buffer_object/negative-bad-bo.c b/tests/spec/arb_texture_buffer_object/negative-bad-bo.c index 9abc00d84..c7ebe8e7b 100644 --- a/tests/spec/arb_texture_buffer_object/negative-bad-bo.c +++ b/tests/spec/arb_texture_buffer_object/negative-bad-bo.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_texture_buffer_object/negative-bad-format.c b/tests/spec/arb_texture_buffer_object/negative-bad-format.c index c959183fe..21698a3d8 100644 --- a/tests/spec/arb_texture_buffer_object/negative-bad-format.c +++ b/tests/spec/arb_texture_buffer_object/negative-bad-format.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_texture_buffer_object/negative-bad-target.c b/tests/spec/arb_texture_buffer_object/negative-bad-target.c index c6391dd7c..5a2d75b03 100644 --- a/tests/spec/arb_texture_buffer_object/negative-bad-target.c +++ b/tests/spec/arb_texture_buffer_object/negative-bad-target.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_texture_buffer_object/unused-name.c b/tests/spec/arb_texture_buffer_object/unused-name.c index 93825119a..273735de3 100644 --- a/tests/spec/arb_texture_buffer_object/unused-name.c +++ b/tests/spec/arb_texture_buffer_object/unused-name.c @@ -35,10 +35,13 @@ * TEXTURE_BUFFER_ARB." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_texture_compression/internal-format-query.c b/tests/spec/arb_texture_compression/internal-format-query.c index fa5d7ee33..0eb77ffb7 100644 --- a/tests/spec/arb_texture_compression/internal-format-query.c +++ b/tests/spec/arb_texture_compression/internal-format-query.c @@ -70,10 +70,13 @@ #include <stdarg.h> #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define ENUM_AND_STRING(e) \ # e, e diff --git a/tests/spec/arb_texture_compression/invalid-formats.c b/tests/spec/arb_texture_compression/invalid-formats.c index f7b3ee6e1..f4b147fd4 100644 --- a/tests/spec/arb_texture_compression/invalid-formats.c +++ b/tests/spec/arb_texture_compression/invalid-formats.c @@ -39,10 +39,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define ENUM_AND_STRING(e) \ # e, e diff --git a/tests/spec/arb_texture_cube_map_array/cubemap.c b/tests/spec/arb_texture_cube_map_array/cubemap.c index 55c44b0cc..2c16387b8 100644 --- a/tests/spec/arb_texture_cube_map_array/cubemap.c +++ b/tests/spec/arb_texture_cube_map_array/cubemap.c @@ -39,10 +39,13 @@ #define NUM_LAYERS 2 -PIGLIT_GL_TEST_MAIN( - (64 * 6 + PAD * 9) * 2 /*window_width*/, - 400*NUM_LAYERS /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (64 * 6 + PAD * 9) * 2; + config.window_height = 400*NUM_LAYERS; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END int max_size; diff --git a/tests/spec/arb_texture_cube_map_array/fbo-cubemap-array.c b/tests/spec/arb_texture_cube_map_array/fbo-cubemap-array.c index 6d0bce977..f0d796ed3 100644 --- a/tests/spec/arb_texture_cube_map_array/fbo-cubemap-array.c +++ b/tests/spec/arb_texture_cube_map_array/fbo-cubemap-array.c @@ -39,10 +39,13 @@ #define BUF_WIDTH 32 #define BUF_HEIGHT 32 -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define NUM_FACES 6 #define NUM_LAYERS 3 diff --git a/tests/spec/arb_texture_cube_map_array/get.c b/tests/spec/arb_texture_cube_map_array/get.c index a55dd5e82..b1b584061 100644 --- a/tests/spec/arb_texture_cube_map_array/get.c +++ b/tests/spec/arb_texture_cube_map_array/get.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_texture_cube_map_array/sampler-cube-array-shadow.c b/tests/spec/arb_texture_cube_map_array/sampler-cube-array-shadow.c index 5fbef71e5..823dcfe2f 100644 --- a/tests/spec/arb_texture_cube_map_array/sampler-cube-array-shadow.c +++ b/tests/spec/arb_texture_cube_map_array/sampler-cube-array-shadow.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex; static GLint prog; diff --git a/tests/spec/arb_texture_cube_map_array/teximage3d-invalid-values.c b/tests/spec/arb_texture_cube_map_array/teximage3d-invalid-values.c index 98202b29f..2adfe1569 100644 --- a/tests/spec/arb_texture_cube_map_array/teximage3d-invalid-values.c +++ b/tests/spec/arb_texture_cube_map_array/teximage3d-invalid-values.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width= 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_texture_float/texture-float-formats.c b/tests/spec/arb_texture_float/texture-float-formats.c index 1ec7f571d..e971e74df 100644 --- a/tests/spec/arb_texture_float/texture-float-formats.c +++ b/tests/spec/arb_texture_float/texture-float-formats.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "texture-float-formats"; static GLint TexWidth = 16, TexHeight = 16; diff --git a/tests/spec/arb_texture_storage/texture-storage.c b/tests/spec/arb_texture_storage/texture-storage.c index 00a7769df..d2d059a7d 100644 --- a/tests/spec/arb_texture_storage/texture-storage.c +++ b/tests/spec/arb_texture_storage/texture-storage.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "texture-storage"; diff --git a/tests/spec/arb_timer_query/timestamp-get.c b/tests/spec/arb_timer_query/timestamp-get.c index 14b526db6..ea2f4be93 100644 --- a/tests/spec/arb_timer_query/timestamp-get.c +++ b/tests/spec/arb_timer_query/timestamp-get.c @@ -32,10 +32,13 @@ * the same value. */ -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLint64 get_gpu_time_via_query(GLuint q) diff --git a/tests/spec/arb_transform_feedback2/draw-auto.c b/tests/spec/arb_transform_feedback2/draw-auto.c index d056474d4..11212ec30 100644 --- a/tests/spec/arb_transform_feedback2/draw-auto.c +++ b/tests/spec/arb_transform_feedback2/draw-auto.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char *vstext = { "void main() {" diff --git a/tests/spec/arb_uniform_buffer_object/bindbuffer-general-point.c b/tests/spec/arb_uniform_buffer_object/bindbuffer-general-point.c index 03ca9c6a1..12255f7c3 100644 --- a/tests/spec/arb_uniform_buffer_object/bindbuffer-general-point.c +++ b/tests/spec/arb_uniform_buffer_object/bindbuffer-general-point.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/buffer-targets.c b/tests/spec/arb_uniform_buffer_object/buffer-targets.c index cd4a7e78a..6b4f69629 100644 --- a/tests/spec/arb_uniform_buffer_object/buffer-targets.c +++ b/tests/spec/arb_uniform_buffer_object/buffer-targets.c @@ -37,10 +37,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/deletebuffers.c b/tests/spec/arb_uniform_buffer_object/deletebuffers.c index 94a874d60..5736c4d8e 100644 --- a/tests/spec/arb_uniform_buffer_object/deletebuffers.c +++ b/tests/spec/arb_uniform_buffer_object/deletebuffers.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/dlist.c b/tests/spec/arb_uniform_buffer_object/dlist.c index ef8163155..329d12280 100644 --- a/tests/spec/arb_uniform_buffer_object/dlist.c +++ b/tests/spec/arb_uniform_buffer_object/dlist.c @@ -54,10 +54,13 @@ * list needed." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END const char *source = "#extension GL_ARB_uniform_buffer_object : enable\n" diff --git a/tests/spec/arb_uniform_buffer_object/getactiveuniformblockiv-uniform-block-data-size.c b/tests/spec/arb_uniform_buffer_object/getactiveuniformblockiv-uniform-block-data-size.c index 40dbfdeec..31dd0fd33 100644 --- a/tests/spec/arb_uniform_buffer_object/getactiveuniformblockiv-uniform-block-data-size.c +++ b/tests/spec/arb_uniform_buffer_object/getactiveuniformblockiv-uniform-block-data-size.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" #include "uniform-types.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static int align(int v, int a) diff --git a/tests/spec/arb_uniform_buffer_object/getactiveuniformblockname.c b/tests/spec/arb_uniform_buffer_object/getactiveuniformblockname.c index 28a179d6b..6541a1156 100644 --- a/tests/spec/arb_uniform_buffer_object/getactiveuniformblockname.c +++ b/tests/spec/arb_uniform_buffer_object/getactiveuniformblockname.c @@ -66,10 +66,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/getactiveuniformname.c b/tests/spec/arb_uniform_buffer_object/getactiveuniformname.c index 1327991ef..010d719df 100644 --- a/tests/spec/arb_uniform_buffer_object/getactiveuniformname.c +++ b/tests/spec/arb_uniform_buffer_object/getactiveuniformname.c @@ -66,10 +66,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-array-stride.c b/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-array-stride.c index 6b0583a22..b632612d5 100644 --- a/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-array-stride.c +++ b/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-array-stride.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char fs_source[] = "#extension GL_ARB_uniform_buffer_object : require\n" diff --git a/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-block-index.c b/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-block-index.c index 884d6bada..8dba64a6f 100644 --- a/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-block-index.c +++ b/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-block-index.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_source[] = "#extension GL_ARB_uniform_buffer_object : require\n" diff --git a/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-matrix-stride.c b/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-matrix-stride.c index eeef2c20b..c924b7d84 100644 --- a/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-matrix-stride.c +++ b/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-matrix-stride.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char fs_source[] = "#extension GL_ARB_uniform_buffer_object : require\n" diff --git a/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-type.c b/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-type.c index 68069e5df..d7ff6fc94 100644 --- a/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-type.c +++ b/tests/spec/arb_uniform_buffer_object/getactiveuniformsiv-uniform-type.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" #include "uniform-types.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static bool test_format(const struct uniform_type *type) diff --git a/tests/spec/arb_uniform_buffer_object/getintegeri_v.c b/tests/spec/arb_uniform_buffer_object/getintegeri_v.c index 9d3d7ab95..d21e055e3 100644 --- a/tests/spec/arb_uniform_buffer_object/getintegeri_v.c +++ b/tests/spec/arb_uniform_buffer_object/getintegeri_v.c @@ -37,10 +37,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static bool pass = true; diff --git a/tests/spec/arb_uniform_buffer_object/getprogramiv.c b/tests/spec/arb_uniform_buffer_object/getprogramiv.c index 4befc37f9..89d434bfc 100644 --- a/tests/spec/arb_uniform_buffer_object/getprogramiv.c +++ b/tests/spec/arb_uniform_buffer_object/getprogramiv.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END struct { const char *source; diff --git a/tests/spec/arb_uniform_buffer_object/getuniformblockindex.c b/tests/spec/arb_uniform_buffer_object/getuniformblockindex.c index 732b2a122..caa6e896a 100644 --- a/tests/spec/arb_uniform_buffer_object/getuniformblockindex.c +++ b/tests/spec/arb_uniform_buffer_object/getuniformblockindex.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint prog; diff --git a/tests/spec/arb_uniform_buffer_object/getuniformindices.c b/tests/spec/arb_uniform_buffer_object/getuniformindices.c index e3c89e8d0..6722e6b83 100644 --- a/tests/spec/arb_uniform_buffer_object/getuniformindices.c +++ b/tests/spec/arb_uniform_buffer_object/getuniformindices.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint prog; diff --git a/tests/spec/arb_uniform_buffer_object/getuniformlocation.c b/tests/spec/arb_uniform_buffer_object/getuniformlocation.c index 13b86b61d..121dd2356 100644 --- a/tests/spec/arb_uniform_buffer_object/getuniformlocation.c +++ b/tests/spec/arb_uniform_buffer_object/getuniformlocation.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint prog; diff --git a/tests/spec/arb_uniform_buffer_object/layout-std140-base-size-and-alignment.c b/tests/spec/arb_uniform_buffer_object/layout-std140-base-size-and-alignment.c index c6a918dfc..f0351d035 100644 --- a/tests/spec/arb_uniform_buffer_object/layout-std140-base-size-and-alignment.c +++ b/tests/spec/arb_uniform_buffer_object/layout-std140-base-size-and-alignment.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" #include "uniform-types.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static int align(int v, int a) diff --git a/tests/spec/arb_uniform_buffer_object/layout-std140.c b/tests/spec/arb_uniform_buffer_object/layout-std140.c index eeb208354..1b562269e 100644 --- a/tests/spec/arb_uniform_buffer_object/layout-std140.c +++ b/tests/spec/arb_uniform_buffer_object/layout-std140.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint prog; diff --git a/tests/spec/arb_uniform_buffer_object/link-mismatch-blocks.c b/tests/spec/arb_uniform_buffer_object/link-mismatch-blocks.c index c7a413c54..12b8c171b 100644 --- a/tests/spec/arb_uniform_buffer_object/link-mismatch-blocks.c +++ b/tests/spec/arb_uniform_buffer_object/link-mismatch-blocks.c @@ -37,10 +37,13 @@ #define _GNU_SOURCE #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END struct test { const char *a_header; diff --git a/tests/spec/arb_uniform_buffer_object/maxblocks.c b/tests/spec/arb_uniform_buffer_object/maxblocks.c index 832e71ccd..636218a85 100644 --- a/tests/spec/arb_uniform_buffer_object/maxblocks.c +++ b/tests/spec/arb_uniform_buffer_object/maxblocks.c @@ -47,10 +47,13 @@ #define _GNU_SOURCE #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static char * get_shader(GLenum target, const char *block_prefix, int blocks) diff --git a/tests/spec/arb_uniform_buffer_object/minmax.c b/tests/spec/arb_uniform_buffer_object/minmax.c index e864ba7a9..4c78a753c 100644 --- a/tests/spec/arb_uniform_buffer_object/minmax.c +++ b/tests/spec/arb_uniform_buffer_object/minmax.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" #include "minmax-test.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-buffer.c b/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-buffer.c index 246645c71..75b40370d 100644 --- a/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-buffer.c +++ b/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-buffer.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-index.c b/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-index.c index dc6f87d01..ff4beda41 100644 --- a/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-index.c +++ b/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-index.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-target.c b/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-target.c index 347a46603..c8e14c556 100644 --- a/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-target.c +++ b/tests/spec/arb_uniform_buffer_object/negative-bindbuffer-target.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/negative-bindbufferrange-range.c b/tests/spec/arb_uniform_buffer_object/negative-bindbufferrange-range.c index c814fd3fa..285d5c55c 100644 --- a/tests/spec/arb_uniform_buffer_object/negative-bindbufferrange-range.c +++ b/tests/spec/arb_uniform_buffer_object/negative-bindbufferrange-range.c @@ -41,10 +41,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/negative-getactiveuniformblockiv.c b/tests/spec/arb_uniform_buffer_object/negative-getactiveuniformblockiv.c index 0a811a79c..9fae38c28 100644 --- a/tests/spec/arb_uniform_buffer_object/negative-getactiveuniformblockiv.c +++ b/tests/spec/arb_uniform_buffer_object/negative-getactiveuniformblockiv.c @@ -50,10 +50,13 @@ #include "piglit-util-gl-common.h" #include "uniform-types.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/negative-getactiveuniformsiv.c b/tests/spec/arb_uniform_buffer_object/negative-getactiveuniformsiv.c index 947813989..6f6d349f4 100644 --- a/tests/spec/arb_uniform_buffer_object/negative-getactiveuniformsiv.c +++ b/tests/spec/arb_uniform_buffer_object/negative-getactiveuniformsiv.c @@ -51,10 +51,13 @@ #include "piglit-util-gl-common.h" #include "uniform-types.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/referenced-by-shader.c b/tests/spec/arb_uniform_buffer_object/referenced-by-shader.c index a80c434b5..e7e274935 100644 --- a/tests/spec/arb_uniform_buffer_object/referenced-by-shader.c +++ b/tests/spec/arb_uniform_buffer_object/referenced-by-shader.c @@ -36,10 +36,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_uniform_buffer_object/row-major.c b/tests/spec/arb_uniform_buffer_object/row-major.c index 591055ac6..cd1dfd27a 100644 --- a/tests/spec/arb_uniform_buffer_object/row-major.c +++ b/tests/spec/arb_uniform_buffer_object/row-major.c @@ -50,10 +50,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char *source = "#extension GL_ARB_uniform_buffer_object : enable\n" diff --git a/tests/spec/arb_uniform_buffer_object/uniformblockbinding.c b/tests/spec/arb_uniform_buffer_object/uniformblockbinding.c index ce6e56827..4dd9a26dd 100644 --- a/tests/spec/arb_uniform_buffer_object/uniformblockbinding.c +++ b/tests/spec/arb_uniform_buffer_object/uniformblockbinding.c @@ -58,10 +58,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_vertex_buffer_object/elements-negative-offset.c b/tests/spec/arb_vertex_buffer_object/elements-negative-offset.c index 7b24e952e..f49845b9f 100644 --- a/tests/spec/arb_vertex_buffer_object/elements-negative-offset.c +++ b/tests/spec/arb_vertex_buffer_object/elements-negative-offset.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint vbo; diff --git a/tests/spec/arb_vertex_buffer_object/mixed-immediate-and-vbo.c b/tests/spec/arb_vertex_buffer_object/mixed-immediate-and-vbo.c index 2fe93d490..7b8c8701b 100644 --- a/tests/spec/arb_vertex_buffer_object/mixed-immediate-and-vbo.c +++ b/tests/spec/arb_vertex_buffer_object/mixed-immediate-and-vbo.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint vbo; diff --git a/tests/spec/arb_vertex_program/getenv4d-with-error.c b/tests/spec/arb_vertex_program/getenv4d-with-error.c index baa976f13..75ac71097 100644 --- a/tests/spec/arb_vertex_program/getenv4d-with-error.c +++ b/tests/spec/arb_vertex_program/getenv4d-with-error.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_vertex_program/getlocal4d-with-error.c b/tests/spec/arb_vertex_program/getlocal4d-with-error.c index b1fef8392..6f15bd9b0 100644 --- a/tests/spec/arb_vertex_program/getlocal4d-with-error.c +++ b/tests/spec/arb_vertex_program/getlocal4d-with-error.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/arb_vertex_program/minmax.c b/tests/spec/arb_vertex_program/minmax.c index 3a7bc2f68..c31523c95 100644 --- a/tests/spec/arb_vertex_program/minmax.c +++ b/tests/spec/arb_vertex_program/minmax.c @@ -27,10 +27,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/arb_vertex_type_2_10_10_10_rev/draw-vertices-2101010.c b/tests/spec/arb_vertex_type_2_10_10_10_rev/draw-vertices-2101010.c index 3e2e70f5d..4e982aa9c 100644 --- a/tests/spec/arb_vertex_type_2_10_10_10_rev/draw-vertices-2101010.c +++ b/tests/spec/arb_vertex_type_2_10_10_10_rev/draw-vertices-2101010.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 320 /*window_width*/, - 60 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 320; + config.window_height = 60; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define i32to10(x) ((x) >= 0 ? (x & 0x1ff) : 1024-(abs((x))& 0x1ff)) #define i32to2(x) ((x) >= 0 ? (x & 0x1) : 1-abs((x))) diff --git a/tests/spec/ati_draw_buffers/arbfp-no-index.c b/tests/spec/ati_draw_buffers/arbfp-no-index.c index ce197120f..0b4147541 100644 --- a/tests/spec/ati_draw_buffers/arbfp-no-index.c +++ b/tests/spec/ati_draw_buffers/arbfp-no-index.c @@ -41,10 +41,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static float result0[] = {0.7, 0.6, 0.3, 0.1}; static float result1[] = {0.2, 0.9, 0.5, 0.8}; diff --git a/tests/spec/ati_draw_buffers/arbfp-no-option.c b/tests/spec/ati_draw_buffers/arbfp-no-option.c index 4e44bebf7..6a1862970 100644 --- a/tests/spec/ati_draw_buffers/arbfp-no-option.c +++ b/tests/spec/ati_draw_buffers/arbfp-no-option.c @@ -40,10 +40,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *mrt_fp_string = "!!ARBfp1.0\n" diff --git a/tests/spec/ati_draw_buffers/arbfp.c b/tests/spec/ati_draw_buffers/arbfp.c index 1df1bc1b8..3509c87fd 100644 --- a/tests/spec/ati_draw_buffers/arbfp.c +++ b/tests/spec/ati_draw_buffers/arbfp.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static float result0[] = {0.7, 0.6, 0.3, 0.1}; static float result1[] = {0.2, 0.9, 0.5, 0.8}; diff --git a/tests/spec/ati_envmap_bumpmap/bump.c b/tests/spec/ati_envmap_bumpmap/bump.c index 5aef76af6..2a646bcc5 100644 --- a/tests/spec/ati_envmap_bumpmap/bump.c +++ b/tests/spec/ati_envmap_bumpmap/bump.c @@ -30,10 +30,13 @@ #define TEXSIZE 32 -PIGLIT_GL_TEST_MAIN( - TEXSIZE * 2 /*window_width*/, - TEXSIZE * 2 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = TEXSIZE*2; + config.window_height = TEXSIZE*2; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLenum tex_unit, bump_unit; diff --git a/tests/spec/ext_fog_coord/modes.c b/tests/spec/ext_fog_coord/modes.c index 72cc22e9d..a0693d411 100644 --- a/tests/spec/ext_fog_coord/modes.c +++ b/tests/spec/ext_fog_coord/modes.c @@ -33,10 +33,13 @@ #undef far #endif -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/accuracy.cpp b/tests/spec/ext_framebuffer_multisample/accuracy.cpp index 5ded01970..a750bbcea 100644 --- a/tests/spec/ext_framebuffer_multisample/accuracy.cpp +++ b/tests/spec/ext_framebuffer_multisample/accuracy.cpp @@ -44,10 +44,13 @@ * On others (e.g. i965), this is an important corner case to test. */ -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; const int supersample_factor = 16; diff --git a/tests/spec/ext_framebuffer_multisample/alpha-blending.c b/tests/spec/ext_framebuffer_multisample/alpha-blending.c index 66b5c3986..a4449e475 100644 --- a/tests/spec/ext_framebuffer_multisample/alpha-blending.c +++ b/tests/spec/ext_framebuffer_multisample/alpha-blending.c @@ -41,10 +41,13 @@ GLuint framebuffer, renderbuffer; #define HEIGHT 350 int numSamples; -PIGLIT_GL_TEST_MAIN( - WIDTH, - HEIGHT, - PIGLIT_GL_VISUAL_DOUBLE| PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = WIDTH; + config.window_height = HEIGHT; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/ext_framebuffer_multisample/alpha-to-coverage-dual-src-blend.cpp b/tests/spec/ext_framebuffer_multisample/alpha-to-coverage-dual-src-blend.cpp index 07d49f125..5841ec823 100644 --- a/tests/spec/ext_framebuffer_multisample/alpha-to-coverage-dual-src-blend.cpp +++ b/tests/spec/ext_framebuffer_multisample/alpha-to-coverage-dual-src-blend.cpp @@ -38,9 +38,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void print_usage_and_exit(char *prog_name) { diff --git a/tests/spec/ext_framebuffer_multisample/alpha-to-coverage-no-draw-buffer-zero.cpp b/tests/spec/ext_framebuffer_multisample/alpha-to-coverage-no-draw-buffer-zero.cpp index a6ac00374..be08a42f0 100644 --- a/tests/spec/ext_framebuffer_multisample/alpha-to-coverage-no-draw-buffer-zero.cpp +++ b/tests/spec/ext_framebuffer_multisample/alpha-to-coverage-no-draw-buffer-zero.cpp @@ -46,9 +46,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 768 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 768; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void print_usage_and_exit(char *prog_name) diff --git a/tests/spec/ext_framebuffer_multisample/alpha-to-one-dual-src-blend.cpp b/tests/spec/ext_framebuffer_multisample/alpha-to-one-dual-src-blend.cpp index 3f1602102..e76cb079e 100644 --- a/tests/spec/ext_framebuffer_multisample/alpha-to-one-dual-src-blend.cpp +++ b/tests/spec/ext_framebuffer_multisample/alpha-to-one-dual-src-blend.cpp @@ -38,9 +38,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void print_usage_and_exit(char *prog_name) { diff --git a/tests/spec/ext_framebuffer_multisample/alpha-to-one-msaa-disabled.cpp b/tests/spec/ext_framebuffer_multisample/alpha-to-one-msaa-disabled.cpp index a5a95e093..e2c7eca48 100644 --- a/tests/spec/ext_framebuffer_multisample/alpha-to-one-msaa-disabled.cpp +++ b/tests/spec/ext_framebuffer_multisample/alpha-to-one-msaa-disabled.cpp @@ -39,9 +39,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void print_usage_and_exit(char *prog_name) diff --git a/tests/spec/ext_framebuffer_multisample/alpha-to-one-single-sample-buffer.cpp b/tests/spec/ext_framebuffer_multisample/alpha-to-one-single-sample-buffer.cpp index b72f633a1..b74096e1e 100644 --- a/tests/spec/ext_framebuffer_multisample/alpha-to-one-single-sample-buffer.cpp +++ b/tests/spec/ext_framebuffer_multisample/alpha-to-one-single-sample-buffer.cpp @@ -39,9 +39,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/spec/ext_framebuffer_multisample/bitmap.cpp b/tests/spec/ext_framebuffer_multisample/bitmap.cpp index 5e3b050f7..c4ee240dd 100644 --- a/tests/spec/ext_framebuffer_multisample/bitmap.cpp +++ b/tests/spec/ext_framebuffer_multisample/bitmap.cpp @@ -41,9 +41,13 @@ * Compare the two halves of default framebuffer. */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; diff --git a/tests/spec/ext_framebuffer_multisample/blit-flipped.cpp b/tests/spec/ext_framebuffer_multisample/blit-flipped.cpp index 5ce02af8f..d8ab26225 100644 --- a/tests/spec/ext_framebuffer_multisample/blit-flipped.cpp +++ b/tests/spec/ext_framebuffer_multisample/blit-flipped.cpp @@ -52,9 +52,13 @@ const int pattern_width = 256; const int pattern_height = 256; -PIGLIT_GL_TEST_MAIN(pattern_width * 2, - pattern_height, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = pattern_width*2; + config.window_height = pattern_height; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static Fbo multisampled_fbo, singlesampled_fbo; static TestPattern *test_pattern; diff --git a/tests/spec/ext_framebuffer_multisample/blit-mismatched-formats.cpp b/tests/spec/ext_framebuffer_multisample/blit-mismatched-formats.cpp index dc410d469..da3b139d7 100644 --- a/tests/spec/ext_framebuffer_multisample/blit-mismatched-formats.cpp +++ b/tests/spec/ext_framebuffer_multisample/blit-mismatched-formats.cpp @@ -36,9 +36,13 @@ #include "common.h" -PIGLIT_GL_TEST_MAIN(256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; Fbo src_fbo, dst_fbo; diff --git a/tests/spec/ext_framebuffer_multisample/blit-mismatched-samples.cpp b/tests/spec/ext_framebuffer_multisample/blit-mismatched-samples.cpp index fa8f3f089..e35841079 100644 --- a/tests/spec/ext_framebuffer_multisample/blit-mismatched-samples.cpp +++ b/tests/spec/ext_framebuffer_multisample/blit-mismatched-samples.cpp @@ -35,9 +35,13 @@ #include "common.h" -PIGLIT_GL_TEST_MAIN(256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; Fbo src_fbo, dst_fbo; diff --git a/tests/spec/ext_framebuffer_multisample/blit-mismatched-sizes.cpp b/tests/spec/ext_framebuffer_multisample/blit-mismatched-sizes.cpp index 6c78423ba..2e6d56265 100644 --- a/tests/spec/ext_framebuffer_multisample/blit-mismatched-sizes.cpp +++ b/tests/spec/ext_framebuffer_multisample/blit-mismatched-sizes.cpp @@ -35,9 +35,13 @@ #include "common.h" -PIGLIT_GL_TEST_MAIN(256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; Fbo src_fbo, dst_fbo; diff --git a/tests/spec/ext_framebuffer_multisample/clear.cpp b/tests/spec/ext_framebuffer_multisample/clear.cpp index e03f2cbbc..c7cf6c67a 100644 --- a/tests/spec/ext_framebuffer_multisample/clear.cpp +++ b/tests/spec/ext_framebuffer_multisample/clear.cpp @@ -60,10 +60,13 @@ #include "common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END namespace { diff --git a/tests/spec/ext_framebuffer_multisample/clip-and-scissor-blit.cpp b/tests/spec/ext_framebuffer_multisample/clip-and-scissor-blit.cpp index d7c733ab8..589ce8556 100644 --- a/tests/spec/ext_framebuffer_multisample/clip-and-scissor-blit.cpp +++ b/tests/spec/ext_framebuffer_multisample/clip-and-scissor-blit.cpp @@ -56,10 +56,13 @@ */ #include "common.h" -PIGLIT_GL_TEST_MAIN( - 600 /*window_width*/, - 320 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 600; + config.window_height = 320; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END namespace { diff --git a/tests/spec/ext_framebuffer_multisample/dlist.c b/tests/spec/ext_framebuffer_multisample/dlist.c index 9041ed0f4..5b0f3ec11 100644 --- a/tests/spec/ext_framebuffer_multisample/dlist.c +++ b/tests/spec/ext_framebuffer_multisample/dlist.c @@ -37,10 +37,13 @@ immediately instead of being compiled into display lists. * RenderbufferStorageMultisampleEXT..." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/draw-buffers-alpha-to-coverage.cpp b/tests/spec/ext_framebuffer_multisample/draw-buffers-alpha-to-coverage.cpp index 857a0568e..f4e47dfee 100644 --- a/tests/spec/ext_framebuffer_multisample/draw-buffers-alpha-to-coverage.cpp +++ b/tests/spec/ext_framebuffer_multisample/draw-buffers-alpha-to-coverage.cpp @@ -44,9 +44,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 768 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 768; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void print_usage_and_exit(char *prog_name) diff --git a/tests/spec/ext_framebuffer_multisample/draw-buffers-alpha-to-one.cpp b/tests/spec/ext_framebuffer_multisample/draw-buffers-alpha-to-one.cpp index c49434a0b..3e17acce8 100644 --- a/tests/spec/ext_framebuffer_multisample/draw-buffers-alpha-to-one.cpp +++ b/tests/spec/ext_framebuffer_multisample/draw-buffers-alpha-to-one.cpp @@ -64,9 +64,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 768 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 768; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static int samples; diff --git a/tests/spec/ext_framebuffer_multisample/enable-flag.cpp b/tests/spec/ext_framebuffer_multisample/enable-flag.cpp index 85eeb4515..b619a812c 100644 --- a/tests/spec/ext_framebuffer_multisample/enable-flag.cpp +++ b/tests/spec/ext_framebuffer_multisample/enable-flag.cpp @@ -63,9 +63,13 @@ #include "common.h" -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END namespace { diff --git a/tests/spec/ext_framebuffer_multisample/formats.cpp b/tests/spec/ext_framebuffer_multisample/formats.cpp index 36d9f0ac5..6e81558ad 100644 --- a/tests/spec/ext_framebuffer_multisample/formats.cpp +++ b/tests/spec/ext_framebuffer_multisample/formats.cpp @@ -46,10 +46,13 @@ #include "common.h" #include "../../fbo/fbo-formats.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END namespace { diff --git a/tests/spec/ext_framebuffer_multisample/int-draw-buffers-alpha-to-coverage.cpp b/tests/spec/ext_framebuffer_multisample/int-draw-buffers-alpha-to-coverage.cpp index b92c98385..1b982f79b 100644 --- a/tests/spec/ext_framebuffer_multisample/int-draw-buffers-alpha-to-coverage.cpp +++ b/tests/spec/ext_framebuffer_multisample/int-draw-buffers-alpha-to-coverage.cpp @@ -43,9 +43,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 768 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 768; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END /* At present fragment shader in draw-buffers-common.cpp supports only * fixed number of attachments = 3. diff --git a/tests/spec/ext_framebuffer_multisample/int-draw-buffers-alpha-to-one.cpp b/tests/spec/ext_framebuffer_multisample/int-draw-buffers-alpha-to-one.cpp index 6bb5d91a5..a5f37d001 100644 --- a/tests/spec/ext_framebuffer_multisample/int-draw-buffers-alpha-to-one.cpp +++ b/tests/spec/ext_framebuffer_multisample/int-draw-buffers-alpha-to-one.cpp @@ -42,9 +42,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 768 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 768; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END /* At present fragment shader supports only fixed number of attachments (3) */ static int num_attachments = 3; diff --git a/tests/spec/ext_framebuffer_multisample/interpolation.cpp b/tests/spec/ext_framebuffer_multisample/interpolation.cpp index bccb1f5f5..107145373 100644 --- a/tests/spec/ext_framebuffer_multisample/interpolation.cpp +++ b/tests/spec/ext_framebuffer_multisample/interpolation.cpp @@ -123,10 +123,13 @@ #include "common.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END namespace { diff --git a/tests/spec/ext_framebuffer_multisample/line-smooth.cpp b/tests/spec/ext_framebuffer_multisample/line-smooth.cpp index f2ce36a1d..90aec86ec 100644 --- a/tests/spec/ext_framebuffer_multisample/line-smooth.cpp +++ b/tests/spec/ext_framebuffer_multisample/line-smooth.cpp @@ -44,9 +44,13 @@ * */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; diff --git a/tests/spec/ext_framebuffer_multisample/minmax.c b/tests/spec/ext_framebuffer_multisample/minmax.c index 66807c810..e259f3ded 100644 --- a/tests/spec/ext_framebuffer_multisample/minmax.c +++ b/tests/spec/ext_framebuffer_multisample/minmax.c @@ -29,10 +29,13 @@ * Test for the MAX_SAMPLES_EXT minimum value. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/multisample-blit.cpp b/tests/spec/ext_framebuffer_multisample/multisample-blit.cpp index 4bb3cfdfe..0fcd1feb2 100644 --- a/tests/spec/ext_framebuffer_multisample/multisample-blit.cpp +++ b/tests/spec/ext_framebuffer_multisample/multisample-blit.cpp @@ -36,9 +36,13 @@ * blit straight from the MSAA buffer to the window system * framebuffer--this should produce the same image. */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; diff --git a/tests/spec/ext_framebuffer_multisample/negative-copypixels.c b/tests/spec/ext_framebuffer_multisample/negative-copypixels.c index 60bb78650..e3d2dfdc0 100644 --- a/tests/spec/ext_framebuffer_multisample/negative-copypixels.c +++ b/tests/spec/ext_framebuffer_multisample/negative-copypixels.c @@ -44,10 +44,13 @@ * "INVALID_OPERATION_EXT", but that appears to be a typo. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/negative-copyteximage.c b/tests/spec/ext_framebuffer_multisample/negative-copyteximage.c index 8029abb42..742d6e0ce 100644 --- a/tests/spec/ext_framebuffer_multisample/negative-copyteximage.c +++ b/tests/spec/ext_framebuffer_multisample/negative-copyteximage.c @@ -44,10 +44,13 @@ * "INVALID_OPERATION_EXT", but that appears to be a typo. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/negative-max-samples.c b/tests/spec/ext_framebuffer_multisample/negative-max-samples.c index a24ca3e27..4bf471cf4 100644 --- a/tests/spec/ext_framebuffer_multisample/negative-max-samples.c +++ b/tests/spec/ext_framebuffer_multisample/negative-max-samples.c @@ -35,10 +35,13 @@ * MAX_SAMPLES_EXT, then the error INVALID_VALUE is generated." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/negative-mismatched-samples.c b/tests/spec/ext_framebuffer_multisample/negative-mismatched-samples.c index 787c0e464..766cdcee1 100644 --- a/tests/spec/ext_framebuffer_multisample/negative-mismatched-samples.c +++ b/tests/spec/ext_framebuffer_multisample/negative-mismatched-samples.c @@ -37,10 +37,13 @@ * { FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT }" */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/negative-readpixels.c b/tests/spec/ext_framebuffer_multisample/negative-readpixels.c index a6333c4fa..2735ce703 100644 --- a/tests/spec/ext_framebuffer_multisample/negative-readpixels.c +++ b/tests/spec/ext_framebuffer_multisample/negative-readpixels.c @@ -36,10 +36,13 @@ * the read framebuffer is greater than zero." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/no-color.cpp b/tests/spec/ext_framebuffer_multisample/no-color.cpp index 995c5044a..9acc854b3 100644 --- a/tests/spec/ext_framebuffer_multisample/no-color.cpp +++ b/tests/spec/ext_framebuffer_multisample/no-color.cpp @@ -73,10 +73,13 @@ #include "common.h" -PIGLIT_GL_TEST_MAIN( - 512 /* window_width */, - 256 /* window_height */, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END namespace { diff --git a/tests/spec/ext_framebuffer_multisample/point-smooth.cpp b/tests/spec/ext_framebuffer_multisample/point-smooth.cpp index ee9368345..2d82fb65e 100644 --- a/tests/spec/ext_framebuffer_multisample/point-smooth.cpp +++ b/tests/spec/ext_framebuffer_multisample/point-smooth.cpp @@ -44,9 +44,13 @@ * */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; diff --git a/tests/spec/ext_framebuffer_multisample/polygon-smooth.cpp b/tests/spec/ext_framebuffer_multisample/polygon-smooth.cpp index 5ef872a99..c164569c1 100644 --- a/tests/spec/ext_framebuffer_multisample/polygon-smooth.cpp +++ b/tests/spec/ext_framebuffer_multisample/polygon-smooth.cpp @@ -43,9 +43,13 @@ * halves of default framebuffer. They are expected to match. */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; diff --git a/tests/spec/ext_framebuffer_multisample/polygon-stipple.cpp b/tests/spec/ext_framebuffer_multisample/polygon-stipple.cpp index 543d63496..6b4169529 100644 --- a/tests/spec/ext_framebuffer_multisample/polygon-stipple.cpp +++ b/tests/spec/ext_framebuffer_multisample/polygon-stipple.cpp @@ -43,9 +43,13 @@ * comparing the two halves of default framebuffer. */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; diff --git a/tests/spec/ext_framebuffer_multisample/renderbuffer-samples.c b/tests/spec/ext_framebuffer_multisample/renderbuffer-samples.c index 12acbb3e7..2d71646b3 100644 --- a/tests/spec/ext_framebuffer_multisample/renderbuffer-samples.c +++ b/tests/spec/ext_framebuffer_multisample/renderbuffer-samples.c @@ -66,10 +66,13 @@ * by a "multisample location" extension." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/renderbufferstorage-samples.c b/tests/spec/ext_framebuffer_multisample/renderbufferstorage-samples.c index c6cf68b40..12e8b24e5 100644 --- a/tests/spec/ext_framebuffer_multisample/renderbufferstorage-samples.c +++ b/tests/spec/ext_framebuffer_multisample/renderbufferstorage-samples.c @@ -37,10 +37,13 @@ * with <samples> equal to zero." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/sample-alpha-to-coverage.cpp b/tests/spec/ext_framebuffer_multisample/sample-alpha-to-coverage.cpp index d3823e0d3..c39b24963 100644 --- a/tests/spec/ext_framebuffer_multisample/sample-alpha-to-coverage.cpp +++ b/tests/spec/ext_framebuffer_multisample/sample-alpha-to-coverage.cpp @@ -43,9 +43,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLenum buffer_to_test; diff --git a/tests/spec/ext_framebuffer_multisample/sample-alpha-to-one.cpp b/tests/spec/ext_framebuffer_multisample/sample-alpha-to-one.cpp index e3e8d9987..84b14c100 100644 --- a/tests/spec/ext_framebuffer_multisample/sample-alpha-to-one.cpp +++ b/tests/spec/ext_framebuffer_multisample/sample-alpha-to-one.cpp @@ -39,9 +39,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END void print_usage_and_exit(char *prog_name) diff --git a/tests/spec/ext_framebuffer_multisample/sample-coverage.cpp b/tests/spec/ext_framebuffer_multisample/sample-coverage.cpp index 83c8daac7..6d3e23de3 100644 --- a/tests/spec/ext_framebuffer_multisample/sample-coverage.cpp +++ b/tests/spec/ext_framebuffer_multisample/sample-coverage.cpp @@ -63,9 +63,13 @@ * Author: Anuj Phogat <anuj.phogat@gmail.com> */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 512; const int pattern_height = 128; static Fbo ms_fbo, resolve_fbo; diff --git a/tests/spec/ext_framebuffer_multisample/samples.c b/tests/spec/ext_framebuffer_multisample/samples.c index 3903f3d2c..847e6f4a9 100644 --- a/tests/spec/ext_framebuffer_multisample/samples.c +++ b/tests/spec/ext_framebuffer_multisample/samples.c @@ -41,10 +41,13 @@ * See also negative-mismatched-samples.c. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_framebuffer_multisample/turn-on-off.cpp b/tests/spec/ext_framebuffer_multisample/turn-on-off.cpp index 656714e4f..334d7a568 100644 --- a/tests/spec/ext_framebuffer_multisample/turn-on-off.cpp +++ b/tests/spec/ext_framebuffer_multisample/turn-on-off.cpp @@ -45,10 +45,13 @@ * TODO: Add testing for depth and stencil buffers. */ -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static int num_samples = 0; const int pattern_width = 256; diff --git a/tests/spec/ext_framebuffer_multisample/unaligned-blit.cpp b/tests/spec/ext_framebuffer_multisample/unaligned-blit.cpp index bfe2ff6fb..062155809 100644 --- a/tests/spec/ext_framebuffer_multisample/unaligned-blit.cpp +++ b/tests/spec/ext_framebuffer_multisample/unaligned-blit.cpp @@ -53,9 +53,13 @@ const int tile_size = 49; const int tiles_across = 5; const int num_tiles = tiles_across * tiles_across; -PIGLIT_GL_TEST_MAIN(2 * pattern_size /*window_width*/, - pattern_size /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 2*pattern_size; + config.window_height = pattern_size; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END const int permutation[num_tiles] = { 10, 5, 6, 17, 3, 11, 16, 21, 14, 24, 23, 8, 15, 18, 0, 12, 9, diff --git a/tests/spec/ext_framebuffer_multisample/upsample.cpp b/tests/spec/ext_framebuffer_multisample/upsample.cpp index 4bef055e1..7278e3bd0 100644 --- a/tests/spec/ext_framebuffer_multisample/upsample.cpp +++ b/tests/spec/ext_framebuffer_multisample/upsample.cpp @@ -52,9 +52,13 @@ * accuracy.cpp. */ -PIGLIT_GL_TEST_MAIN(512 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_STENCIL; + +PIGLIT_GL_TEST_CONFIG_END const int pattern_width = 256; const int pattern_height = 256; diff --git a/tests/spec/ext_packed_depth_stencil/readpixels-24_8.c b/tests/spec/ext_packed_depth_stencil/readpixels-24_8.c index ae0063b1b..e7c90be71 100644 --- a/tests/spec/ext_packed_depth_stencil/readpixels-24_8.c +++ b/tests/spec/ext_packed_depth_stencil/readpixels-24_8.c @@ -33,10 +33,13 @@ #define BUF_WIDTH 15 #define BUF_HEIGHT 15 -PIGLIT_GL_TEST_MAIN( - BUF_WIDTH /*window_width*/, - BUF_WIDTH /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = BUF_WIDTH; + config.window_height = BUF_WIDTH; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END /* Width of our stripes of z = 0.0, 0.5, 1.0 */ static int w = BUF_WIDTH / 3; diff --git a/tests/spec/ext_packed_float/getteximage-invalid-format-for-packed-type.c b/tests/spec/ext_packed_float/getteximage-invalid-format-for-packed-type.c index 975a73173..0216a09ea 100644 --- a/tests/spec/ext_packed_float/getteximage-invalid-format-for-packed-type.c +++ b/tests/spec/ext_packed_float/getteximage-invalid-format-for-packed-type.c @@ -69,10 +69,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLenum formatTypes[] = { GL_RGBA, diff --git a/tests/spec/ext_packed_float/pack.c b/tests/spec/ext_packed_float/pack.c index 60a7385fd..1126c1f31 100755 --- a/tests/spec/ext_packed_float/pack.c +++ b/tests/spec/ext_packed_float/pack.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* Any maximum e with m != 0 is NAN */ diff --git a/tests/spec/ext_texture_array/maxlayers.c b/tests/spec/ext_texture_array/maxlayers.c index 19b12d118..5d7fb0708 100644 --- a/tests/spec/ext_texture_array/maxlayers.c +++ b/tests/spec/ext_texture_array/maxlayers.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END int height = 100, ybase = 0; diff --git a/tests/spec/ext_texture_integer/api-drawpixels.c b/tests/spec/ext_texture_integer/api-drawpixels.c index c26753554..9c5913377 100644 --- a/tests/spec/ext_texture_integer/api-drawpixels.c +++ b/tests/spec/ext_texture_integer/api-drawpixels.c @@ -58,10 +58,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_texture_integer/api-readpixels.c b/tests/spec/ext_texture_integer/api-readpixels.c index 7541267a4..044bc2df9 100644 --- a/tests/spec/ext_texture_integer/api-readpixels.c +++ b/tests/spec/ext_texture_integer/api-readpixels.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_texture_integer/api-teximage.c b/tests/spec/ext_texture_integer/api-teximage.c index 767061e21..44fdd3f66 100644 --- a/tests/spec/ext_texture_integer/api-teximage.c +++ b/tests/spec/ext_texture_integer/api-teximage.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_texture_integer/fbo-blending.c b/tests/spec/ext_texture_integer/fbo-blending.c index 4ce29db78..d0235e20a 100644 --- a/tests/spec/ext_texture_integer/fbo-blending.c +++ b/tests/spec/ext_texture_integer/fbo-blending.c @@ -42,10 +42,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex; static int color_loc; diff --git a/tests/spec/ext_texture_integer/fbo-integer-precision-clear.c b/tests/spec/ext_texture_integer/fbo-integer-precision-clear.c index e41168830..a24e489be 100644 --- a/tests/spec/ext_texture_integer/fbo-integer-precision-clear.c +++ b/tests/spec/ext_texture_integer/fbo-integer-precision-clear.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "fbo-integer-precision-clear"; diff --git a/tests/spec/ext_texture_integer/fbo-integer-readpixels-sint-uint.c b/tests/spec/ext_texture_integer/fbo-integer-readpixels-sint-uint.c index 7a360db11..10df12596 100644 --- a/tests/spec/ext_texture_integer/fbo-integer-readpixels-sint-uint.c +++ b/tests/spec/ext_texture_integer/fbo-integer-readpixels-sint-uint.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "fbo-integer-readpixels-sint-uint"; diff --git a/tests/spec/ext_texture_integer/getteximage-clamping.c b/tests/spec/ext_texture_integer/getteximage-clamping.c index e320d7216..feb4074fb 100644 --- a/tests/spec/ext_texture_integer/getteximage-clamping.c +++ b/tests/spec/ext_texture_integer/getteximage-clamping.c @@ -46,10 +46,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END struct format_info { const char *name; diff --git a/tests/spec/ext_texture_integer/texture-integer-glsl130.c b/tests/spec/ext_texture_integer/texture-integer-glsl130.c index c2f3200b0..745c78b74 100644 --- a/tests/spec/ext_texture_integer/texture-integer-glsl130.c +++ b/tests/spec/ext_texture_integer/texture-integer-glsl130.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "texture-integer"; diff --git a/tests/spec/ext_texture_swizzle/depth_texture_mode_and_swizzle.c b/tests/spec/ext_texture_swizzle/depth_texture_mode_and_swizzle.c index 074ca6402..e0c449185 100644 --- a/tests/spec/ext_texture_swizzle/depth_texture_mode_and_swizzle.c +++ b/tests/spec/ext_texture_swizzle/depth_texture_mode_and_swizzle.c @@ -39,7 +39,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN(170, 30, PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 170; + config.window_height= 30; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display() diff --git a/tests/spec/ext_timer_query/time-elapsed.c b/tests/spec/ext_timer_query/time-elapsed.c index 4e55cbd09..2bfce3d14 100644 --- a/tests/spec/ext_timer_query/time-elapsed.c +++ b/tests/spec/ext_timer_query/time-elapsed.c @@ -31,10 +31,13 @@ #include <sys/time.h> -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum { TIME_ELAPSED, diff --git a/tests/spec/ext_transform_feedback/alignment.c b/tests/spec/ext_transform_feedback/alignment.c index 339544d72..caf2df386 100644 --- a/tests/spec/ext_transform_feedback/alignment.c +++ b/tests/spec/ext_transform_feedback/alignment.c @@ -36,10 +36,13 @@ #define BUFFER_SIZE 0x40 -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END /* Test parameters */ static unsigned long additional_offset; diff --git a/tests/spec/ext_transform_feedback/api-errors.c b/tests/spec/ext_transform_feedback/api-errors.c index 3541fc4ed..3503cbea9 100644 --- a/tests/spec/ext_transform_feedback/api-errors.c +++ b/tests/spec/ext_transform_feedback/api-errors.c @@ -50,10 +50,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 16 /*window_width*/, - 16 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 16; + config.window_height = 16; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define XFB_BUFFER_SIZE 12 #define NUM_BUFFERS 2 diff --git a/tests/spec/ext_transform_feedback/buffer-usage.c b/tests/spec/ext_transform_feedback/buffer-usage.c index cb85acd27..900543c4c 100644 --- a/tests/spec/ext_transform_feedback/buffer-usage.c +++ b/tests/spec/ext_transform_feedback/buffer-usage.c @@ -33,10 +33,13 @@ #define NUM_POINTS 10002 #define SHIFT_COUNT 64 -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char *vstext = "#version 130\n" diff --git a/tests/spec/ext_transform_feedback/builtin-varyings.c b/tests/spec/ext_transform_feedback/builtin-varyings.c index 08bcbd82c..0aaaa3e8c 100644 --- a/tests/spec/ext_transform_feedback/builtin-varyings.c +++ b/tests/spec/ext_transform_feedback/builtin-varyings.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define MAX_EXPECTED_OUTPUT_COMPONENTS 8 diff --git a/tests/spec/ext_transform_feedback/discard-api.c b/tests/spec/ext_transform_feedback/discard-api.c index 765c84d23..2e58bbe69 100644 --- a/tests/spec/ext_transform_feedback/discard-api.c +++ b/tests/spec/ext_transform_feedback/discard-api.c @@ -37,10 +37,13 @@ * RASTERIZER_DISCARD_EXT 0x8C89" */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_transform_feedback/discard-bitmap.c b/tests/spec/ext_transform_feedback/discard-bitmap.c index d7817d4db..677092bfe 100644 --- a/tests/spec/ext_transform_feedback/discard-bitmap.c +++ b/tests/spec/ext_transform_feedback/discard-bitmap.c @@ -40,10 +40,13 @@ * CopyPixels, Bitmap, Clear and Accum commands as well." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_transform_feedback/discard-clear.c b/tests/spec/ext_transform_feedback/discard-clear.c index c0a634bcb..cfbf4fa34 100644 --- a/tests/spec/ext_transform_feedback/discard-clear.c +++ b/tests/spec/ext_transform_feedback/discard-clear.c @@ -40,10 +40,13 @@ * CopyPixels, Bitmap, Clear and Accum commands as well." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_transform_feedback/discard-copypixels.c b/tests/spec/ext_transform_feedback/discard-copypixels.c index f05657e44..ff3d2fa9e 100644 --- a/tests/spec/ext_transform_feedback/discard-copypixels.c +++ b/tests/spec/ext_transform_feedback/discard-copypixels.c @@ -40,10 +40,13 @@ * CopyPixels, Bitmap, Clear and Accum commands as well." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_transform_feedback/discard-drawarrays.c b/tests/spec/ext_transform_feedback/discard-drawarrays.c index 1a2f68e43..e35f062e8 100644 --- a/tests/spec/ext_transform_feedback/discard-drawarrays.c +++ b/tests/spec/ext_transform_feedback/discard-drawarrays.c @@ -41,10 +41,13 @@ * CopyPixels, Bitmap, Clear and Accum commands as well." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_transform_feedback/discard-drawpixels.c b/tests/spec/ext_transform_feedback/discard-drawpixels.c index 12c225a6e..6d77548c0 100644 --- a/tests/spec/ext_transform_feedback/discard-drawpixels.c +++ b/tests/spec/ext_transform_feedback/discard-drawpixels.c @@ -40,10 +40,13 @@ * CopyPixels, Bitmap, Clear and Accum commands as well." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/ext_transform_feedback/generatemipmap.c b/tests/spec/ext_transform_feedback/generatemipmap.c index 92da0b091..aae2b830a 100644 --- a/tests/spec/ext_transform_feedback/generatemipmap.c +++ b/tests/spec/ext_transform_feedback/generatemipmap.c @@ -67,10 +67,13 @@ #define TEX_WIDTH 256 #define TEX_HEIGHT 256 -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const float red[] = {1, 0, 0, 0}; static const float green[] = {0, 1, 0, 0.25}; diff --git a/tests/spec/ext_transform_feedback/get-buffer-state.c b/tests/spec/ext_transform_feedback/get-buffer-state.c index 40d73251a..acd7cf127 100644 --- a/tests/spec/ext_transform_feedback/get-buffer-state.c +++ b/tests/spec/ext_transform_feedback/get-buffer-state.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 16 /*window_width*/, - 16 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 16; + config.window_height = 16; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define XFB_BUFFER_SIZE 12 diff --git a/tests/spec/ext_transform_feedback/immediate-reuse.c b/tests/spec/ext_transform_feedback/immediate-reuse.c index 0d857ce6f..97a52faf2 100644 --- a/tests/spec/ext_transform_feedback/immediate-reuse.c +++ b/tests/spec/ext_transform_feedback/immediate-reuse.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 16 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 16; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static const char *vstext = "attribute vec4 in_position;\n" diff --git a/tests/spec/ext_transform_feedback/interleaved.c b/tests/spec/ext_transform_feedback/interleaved.c index f8053a446..c2212f23b 100644 --- a/tests/spec/ext_transform_feedback/interleaved.c +++ b/tests/spec/ext_transform_feedback/interleaved.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char *vstext = { "varying vec3 v3;" diff --git a/tests/spec/ext_transform_feedback/intervening-read.c b/tests/spec/ext_transform_feedback/intervening-read.c index 744b3bd95..6af048834 100644 --- a/tests/spec/ext_transform_feedback/intervening-read.c +++ b/tests/spec/ext_transform_feedback/intervening-read.c @@ -48,10 +48,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static enum test_mode { TEST_MODE_OUTPUT, diff --git a/tests/spec/ext_transform_feedback/max-varyings.c b/tests/spec/ext_transform_feedback/max-varyings.c index 1506d1d44..69d9f5174 100644 --- a/tests/spec/ext_transform_feedback/max-varyings.c +++ b/tests/spec/ext_transform_feedback/max-varyings.c @@ -43,10 +43,13 @@ /* 10x10 rectangles with 2 pixels of pad. Deal with up to 32 varyings. */ -PIGLIT_GL_TEST_MAIN( - (2 + MAX_VARYING * 12) /*window_width*/, - (2 + MAX_VARYING * 12) /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (2+MAX_VARYING*12); + config.window_height = (2+MAX_VARYING*12); + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *xfb_varying_array[MAX_VARYING]; static GLuint xfb_buf; diff --git a/tests/spec/ext_transform_feedback/negative-prims.c b/tests/spec/ext_transform_feedback/negative-prims.c index 6228cb1ce..94c7a1874 100644 --- a/tests/spec/ext_transform_feedback/negative-prims.c +++ b/tests/spec/ext_transform_feedback/negative-prims.c @@ -43,10 +43,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END struct { GLenum tf_prim; diff --git a/tests/spec/ext_transform_feedback/order.c b/tests/spec/ext_transform_feedback/order.c index b2767c1fa..c2798a6f1 100644 --- a/tests/spec/ext_transform_feedback/order.c +++ b/tests/spec/ext_transform_feedback/order.c @@ -57,10 +57,13 @@ #define NUM_POINTS 10002 #define SHIFT_COUNT 64 -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLenum draw_mode; static GLboolean use_draw_elements; diff --git a/tests/spec/ext_transform_feedback/output-type.c b/tests/spec/ext_transform_feedback/output-type.c index a6dae9c3c..ef5755996 100644 --- a/tests/spec/ext_transform_feedback/output-type.c +++ b/tests/spec/ext_transform_feedback/output-type.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END #define DEFAULT_VALUE 0.123456 diff --git a/tests/spec/ext_transform_feedback/overflow-edge-cases.c b/tests/spec/ext_transform_feedback/overflow-edge-cases.c index bebf21198..dd1a2ddf3 100644 --- a/tests/spec/ext_transform_feedback/overflow-edge-cases.c +++ b/tests/spec/ext_transform_feedback/overflow-edge-cases.c @@ -43,10 +43,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 16 /*window_width*/, - 16 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 16; + config.window_height = 16; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define XFB_BUFFER_SIZE 12 #define MAX_VERTICES 9 diff --git a/tests/spec/ext_transform_feedback/position.c b/tests/spec/ext_transform_feedback/position.c index 405c918b5..c9f509349 100644 --- a/tests/spec/ext_transform_feedback/position.c +++ b/tests/spec/ext_transform_feedback/position.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char *vstext = { "void main() {" diff --git a/tests/spec/ext_transform_feedback/separate.c b/tests/spec/ext_transform_feedback/separate.c index 55c919f2a..c48f61bba 100644 --- a/tests/spec/ext_transform_feedback/separate.c +++ b/tests/spec/ext_transform_feedback/separate.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char *vstext = { "varying vec3 v3;" diff --git a/tests/spec/ext_transform_feedback/tessellation.c b/tests/spec/ext_transform_feedback/tessellation.c index ba5c07060..c1c42dc41 100644 --- a/tests/spec/ext_transform_feedback/tessellation.c +++ b/tests/spec/ext_transform_feedback/tessellation.c @@ -120,10 +120,13 @@ #define BUFFER_SIZE 20 -PIGLIT_GL_TEST_MAIN( - 256 /*window_width*/, - 256 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 256; + config.window_height = 256; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END /* Test parameters */ static GLenum draw_mode; diff --git a/tests/spec/ext_unpack_subimage/ext_unpack_subimage.c b/tests/spec/ext_unpack_subimage/ext_unpack_subimage.c index 96166775d..b4e407fb3 100644 --- a/tests/spec/ext_unpack_subimage/ext_unpack_subimage.c +++ b/tests/spec/ext_unpack_subimage/ext_unpack_subimage.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLboolean extension_supported; static GLboolean pass; diff --git a/tests/spec/gl-1.0/edgeflag-quads.c b/tests/spec/gl-1.0/edgeflag-quads.c index f420a4550..3e635ee65 100644 --- a/tests/spec/gl-1.0/edgeflag-quads.c +++ b/tests/spec/gl-1.0/edgeflag-quads.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" #include "minmax-test.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/gl-1.0/edgeflag.c b/tests/spec/gl-1.0/edgeflag.c index 6f2e01d34..a3ee04559 100644 --- a/tests/spec/gl-1.0/edgeflag.c +++ b/tests/spec/gl-1.0/edgeflag.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" #include "minmax-test.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/gl-2.0/api/clip-flag-behavior.c b/tests/spec/gl-2.0/api/clip-flag-behavior.c index 0b635411b..9191954c0 100644 --- a/tests/spec/gl-2.0/api/clip-flag-behavior.c +++ b/tests/spec/gl-2.0/api/clip-flag-behavior.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/gl-2.0/api/getattriblocation-conventional.c b/tests/spec/gl-2.0/api/getattriblocation-conventional.c index dbe99a312..c24cd99dc 100644 --- a/tests/spec/gl-2.0/api/getattriblocation-conventional.c +++ b/tests/spec/gl-2.0/api/getattriblocation-conventional.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_code = "attribute vec4 not_used;\n" diff --git a/tests/spec/gl-2.0/edgeflag.c b/tests/spec/gl-2.0/edgeflag.c index 4c6b2e924..1214f17bd 100644 --- a/tests/spec/gl-2.0/edgeflag.c +++ b/tests/spec/gl-2.0/edgeflag.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" #include "minmax-test.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint color_index; diff --git a/tests/spec/gl-2.0/vertex-program-two-side.c b/tests/spec/gl-2.0/vertex-program-two-side.c index c2cf18db8..0fe4238a1 100644 --- a/tests/spec/gl-2.0/vertex-program-two-side.c +++ b/tests/spec/gl-2.0/vertex-program-two-side.c @@ -45,10 +45,13 @@ #define _GNU_SOURCE #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLint prog; diff --git a/tests/spec/gl-2.1/minmax.c b/tests/spec/gl-2.1/minmax.c index 384dac384..0eddb23e8 100644 --- a/tests/spec/gl-2.1/minmax.c +++ b/tests/spec/gl-2.1/minmax.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" #include "minmax-test.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/gl-3.0/api/bindfragdata-invalid-parameters.c b/tests/spec/gl-3.0/api/bindfragdata-invalid-parameters.c index f8116c833..5afad840d 100644 --- a/tests/spec/gl-3.0/api/bindfragdata-invalid-parameters.c +++ b/tests/spec/gl-3.0/api/bindfragdata-invalid-parameters.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/gl-3.0/api/bindfragdata-link-error.c b/tests/spec/gl-3.0/api/bindfragdata-link-error.c index e580328ba..f938b4704 100644 --- a/tests/spec/gl-3.0/api/bindfragdata-link-error.c +++ b/tests/spec/gl-3.0/api/bindfragdata-link-error.c @@ -27,10 +27,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_text = "#version 130\n" diff --git a/tests/spec/gl-3.0/api/bindfragdata-nonexistent-variable.c b/tests/spec/gl-3.0/api/bindfragdata-nonexistent-variable.c index 1afcd65f1..8664a27fc 100644 --- a/tests/spec/gl-3.0/api/bindfragdata-nonexistent-variable.c +++ b/tests/spec/gl-3.0/api/bindfragdata-nonexistent-variable.c @@ -28,10 +28,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_text = "#version 130\n" diff --git a/tests/spec/gl-3.0/api/clearbuffer-common.c b/tests/spec/gl-3.0/api/clearbuffer-common.c index b41a99f68..1f723e9d9 100644 --- a/tests/spec/gl-3.0/api/clearbuffer-common.c +++ b/tests/spec/gl-3.0/api/clearbuffer-common.c @@ -30,10 +30,13 @@ const float default_color[4] = { 0.2, 0.4, 0.6, 1.0 }; const float default_depth = 0.2; const int default_stencil = 0x7a; -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END GLuint generate_simple_fbo(bool color, bool stencil, bool depth, bool packed) diff --git a/tests/spec/gl-3.0/api/clearbuffer-invalid-buffer.c b/tests/spec/gl-3.0/api/clearbuffer-invalid-buffer.c index cbc86e443..fca3adad7 100644 --- a/tests/spec/gl-3.0/api/clearbuffer-invalid-buffer.c +++ b/tests/spec/gl-3.0/api/clearbuffer-invalid-buffer.c @@ -28,10 +28,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* These enums don't really exist, but they were accidentally shipped in some * versions of glext.h. diff --git a/tests/spec/gl-3.0/api/clearbuffer-invalid-drawbuffer.c b/tests/spec/gl-3.0/api/clearbuffer-invalid-drawbuffer.c index 23e381bb5..f6966e633 100644 --- a/tests/spec/gl-3.0/api/clearbuffer-invalid-drawbuffer.c +++ b/tests/spec/gl-3.0/api/clearbuffer-invalid-drawbuffer.c @@ -29,10 +29,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/gl-3.0/api/getfragdatalocation.c b/tests/spec/gl-3.0/api/getfragdatalocation.c index 608f7dc33..6ccd08175 100644 --- a/tests/spec/gl-3.0/api/getfragdatalocation.c +++ b/tests/spec/gl-3.0/api/getfragdatalocation.c @@ -27,10 +27,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_text = "#version 130\n" diff --git a/tests/spec/gl-3.0/api/integer-errors.c b/tests/spec/gl-3.0/api/integer-errors.c index 7dc99a60c..a68a1a75a 100644 --- a/tests/spec/gl-3.0/api/integer-errors.c +++ b/tests/spec/gl-3.0/api/integer-errors.c @@ -30,9 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN(100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static bool test_api_errors(void) diff --git a/tests/spec/gl-3.0/minmax.c b/tests/spec/gl-3.0/minmax.c index a295e74be..89a766698 100644 --- a/tests/spec/gl-3.0/minmax.c +++ b/tests/spec/gl-3.0/minmax.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" #include "minmax-test.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/gl-3.0/required-renderbuffer-attachment-formats.c b/tests/spec/gl-3.0/required-renderbuffer-attachment-formats.c index eae9592ff..5502b235a 100644 --- a/tests/spec/gl-3.0/required-renderbuffer-attachment-formats.c +++ b/tests/spec/gl-3.0/required-renderbuffer-attachment-formats.c @@ -32,10 +32,13 @@ * page 180 "Required Texture Formats". */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/gl-3.0/required-sized-texture-formats.c b/tests/spec/gl-3.0/required-sized-texture-formats.c index e0f64c472..0a7f721a5 100644 --- a/tests/spec/gl-3.0/required-sized-texture-formats.c +++ b/tests/spec/gl-3.0/required-sized-texture-formats.c @@ -37,10 +37,13 @@ * in tables 3.16- 3.17:" */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END GLenum type_queries[CHANNELS] = { GL_TEXTURE_RED_TYPE, diff --git a/tests/spec/gl-3.0/required-texture-attachment-formats.c b/tests/spec/gl-3.0/required-texture-attachment-formats.c index d1c1dfbce..6a9c696a2 100644 --- a/tests/spec/gl-3.0/required-texture-attachment-formats.c +++ b/tests/spec/gl-3.0/required-texture-attachment-formats.c @@ -32,10 +32,13 @@ * 180 "Required Texture Formats". */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/gl-3.0/texture-integer.c b/tests/spec/gl-3.0/texture-integer.c index 3e6f55ef3..1612a36d9 100644 --- a/tests/spec/gl-3.0/texture-integer.c +++ b/tests/spec/gl-3.0/texture-integer.c @@ -29,9 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN(100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE); +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "texture-integer"; static GLint TexWidth = 16, TexHeight = 16; diff --git a/tests/spec/gl-3.1/minmax.c b/tests/spec/gl-3.1/minmax.c index 15d38f3fe..904b4575f 100644 --- a/tests/spec/gl-3.1/minmax.c +++ b/tests/spec/gl-3.1/minmax.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" #include "minmax-test.h" -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/glsl-1.10/execution/clipping/clip-plane-transformation.c b/tests/spec/glsl-1.10/execution/clipping/clip-plane-transformation.c index e18d7409f..2e915dd63 100644 --- a/tests/spec/glsl-1.10/execution/clipping/clip-plane-transformation.c +++ b/tests/spec/glsl-1.10/execution/clipping/clip-plane-transformation.c @@ -170,10 +170,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END GLint position_angle_loc; GLint clipVertex_angle_loc; diff --git a/tests/spec/glsl-1.10/execution/glsl-render-after-bad-attach.c b/tests/spec/glsl-1.10/execution/glsl-render-after-bad-attach.c index cfc8c613c..38bfbf618 100644 --- a/tests/spec/glsl-1.10/execution/glsl-render-after-bad-attach.c +++ b/tests/spec/glsl-1.10/execution/glsl-render-after-bad-attach.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END const char *vs_source = "void main()\n" diff --git a/tests/spec/glsl-1.20/recursion/recursion.c b/tests/spec/glsl-1.20/recursion/recursion.c index 2a8aac04f..a64335f34 100644 --- a/tests/spec/glsl-1.20/recursion/recursion.c +++ b/tests/spec/glsl-1.20/recursion/recursion.c @@ -49,10 +49,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char simple_text[] = "#version 120\n" diff --git a/tests/spec/glsl-1.30/execution/clipping/max-clip-distances.c b/tests/spec/glsl-1.30/execution/clipping/max-clip-distances.c index 19f485dfa..82406ba12 100644 --- a/tests/spec/glsl-1.30/execution/clipping/max-clip-distances.c +++ b/tests/spec/glsl-1.30/execution/clipping/max-clip-distances.c @@ -59,10 +59,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vert[] = "#version 130\n" diff --git a/tests/spec/glsl-1.30/execution/fs-discard-exit-2.c b/tests/spec/glsl-1.30/execution/fs-discard-exit-2.c index ed975ef58..94b248ead 100644 --- a/tests/spec/glsl-1.30/execution/fs-discard-exit-2.c +++ b/tests/spec/glsl-1.30/execution/fs-discard-exit-2.c @@ -44,10 +44,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int coord1_location, coord2_location; diff --git a/tests/spec/glsl-1.30/execution/fs-execution-ordering.c b/tests/spec/glsl-1.30/execution/fs-execution-ordering.c index 1cfa05b72..4589e839d 100644 --- a/tests/spec/glsl-1.30/execution/fs-execution-ordering.c +++ b/tests/spec/glsl-1.30/execution/fs-execution-ordering.c @@ -37,10 +37,13 @@ #define SHIFT_COUNT 64 -PIGLIT_GL_TEST_MAIN( - 100 /* window_width */, - 100 /* window_height */, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END #define SMALL_COMPOSITE 4 #define LARGE_PRIME 7919 diff --git a/tests/spec/glsl-1.30/execution/fs-texelFetch-2D.c b/tests/spec/glsl-1.30/execution/fs-texelFetch-2D.c index 941d1595d..126cbf1aa 100644 --- a/tests/spec/glsl-1.30/execution/fs-texelFetch-2D.c +++ b/tests/spec/glsl-1.30/execution/fs-texelFetch-2D.c @@ -31,10 +31,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 90 /*window_width*/, - 150 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 90; + config.window_height = 150; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END const int tex_size = 64; diff --git a/tests/spec/glsl-1.30/execution/fs-texelFetchOffset-2D.c b/tests/spec/glsl-1.30/execution/fs-texelFetchOffset-2D.c index d9d03add7..4b89ffa4b 100644 --- a/tests/spec/glsl-1.30/execution/fs-texelFetchOffset-2D.c +++ b/tests/spec/glsl-1.30/execution/fs-texelFetchOffset-2D.c @@ -31,10 +31,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 90 /*window_width*/, - 150 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 90; + config.window_height = 150; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END const int tex_size = 64; diff --git a/tests/spec/glsl-1.30/execution/isinf-and-isnan.c b/tests/spec/glsl-1.30/execution/isinf-and-isnan.c index 1d09e52f4..0b82ef672 100644 --- a/tests/spec/glsl-1.30/execution/isinf-and-isnan.c +++ b/tests/spec/glsl-1.30/execution/isinf-and-isnan.c @@ -110,10 +110,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static float gl_version; diff --git a/tests/spec/glsl-1.30/execution/vertexid-beginend.c b/tests/spec/glsl-1.30/execution/vertexid-beginend.c index 86c24b481..071c039b6 100644 --- a/tests/spec/glsl-1.30/execution/vertexid-beginend.c +++ b/tests/spec/glsl-1.30/execution/vertexid-beginend.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 70 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 70; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "#version 130\n" diff --git a/tests/spec/glsl-1.30/execution/vertexid-drawarrays.c b/tests/spec/glsl-1.30/execution/vertexid-drawarrays.c index 410a8991d..05f6da4db 100644 --- a/tests/spec/glsl-1.30/execution/vertexid-drawarrays.c +++ b/tests/spec/glsl-1.30/execution/vertexid-drawarrays.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 70 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 70; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "#version 130\n" diff --git a/tests/spec/glsl-1.30/execution/vertexid-drawelements.c b/tests/spec/glsl-1.30/execution/vertexid-drawelements.c index ea82e02c0..883ee33a5 100644 --- a/tests/spec/glsl-1.30/execution/vertexid-drawelements.c +++ b/tests/spec/glsl-1.30/execution/vertexid-drawelements.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 70 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 70; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vs_text[] = "#version 130\n" diff --git a/tests/spec/glsl-1.30/linker/clipping/mixing-clip-distance-and-clip-vertex-disallowed.c b/tests/spec/glsl-1.30/linker/clipping/mixing-clip-distance-and-clip-vertex-disallowed.c index f4852c404..bc1d6aa9b 100644 --- a/tests/spec/glsl-1.30/linker/clipping/mixing-clip-distance-and-clip-vertex-disallowed.c +++ b/tests/spec/glsl-1.30/linker/clipping/mixing-clip-distance-and-clip-vertex-disallowed.c @@ -36,10 +36,13 @@ */ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char vert[] = "#version 130\n" diff --git a/tests/spec/glsl-1.30/texel-offset-limits.c b/tests/spec/glsl-1.30/texel-offset-limits.c index 7a49d20e7..e35d04713 100644 --- a/tests/spec/glsl-1.30/texel-offset-limits.c +++ b/tests/spec/glsl-1.30/texel-offset-limits.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display() diff --git a/tests/spec/glsl-1.40/tf-no-position.c b/tests/spec/glsl-1.40/tf-no-position.c index 7f067dfd6..4baa5843a 100644 --- a/tests/spec/glsl-1.40/tf-no-position.c +++ b/tests/spec/glsl-1.40/tf-no-position.c @@ -32,10 +32,13 @@ #define BUFFER_SIZE 4 -PIGLIT_GL_TEST_MAIN( - 10 /*window_width*/, - 10 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 10; + config.window_height = 10; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_source = "#version 140\n" diff --git a/tests/spec/nv_conditional_render/begin-while-active.c b/tests/spec/nv_conditional_render/begin-while-active.c index 23cbb8e0a..f622e4791 100644 --- a/tests/spec/nv_conditional_render/begin-while-active.c +++ b/tests/spec/nv_conditional_render/begin-while-active.c @@ -40,10 +40,13 @@ * OPERATION is generated." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/nv_conditional_render/begin-zero.c b/tests/spec/nv_conditional_render/begin-zero.c index e1519c029..eb7c7f892 100644 --- a/tests/spec/nv_conditional_render/begin-zero.c +++ b/tests/spec/nv_conditional_render/begin-zero.c @@ -40,10 +40,13 @@ * OPERATION is generated." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/nv_conditional_render/bitmap.c b/tests/spec/nv_conditional_render/bitmap.c index 311229401..ea88ef14b 100644 --- a/tests/spec/nv_conditional_render/bitmap.c +++ b/tests/spec/nv_conditional_render/bitmap.c @@ -40,10 +40,13 @@ * 5.1) have no effect." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/nv_conditional_render/blitframebuffer.c b/tests/spec/nv_conditional_render/blitframebuffer.c index b330d9521..c50bd0e0a 100644 --- a/tests/spec/nv_conditional_render/blitframebuffer.c +++ b/tests/spec/nv_conditional_render/blitframebuffer.c @@ -34,10 +34,13 @@ * accidentally disable during conditional rendering. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static void fill_tex(int level, int w, int h, const GLfloat *color) { diff --git a/tests/spec/nv_conditional_render/clear.c b/tests/spec/nv_conditional_render/clear.c index 22883f1d9..e24aedfba 100644 --- a/tests/spec/nv_conditional_render/clear.c +++ b/tests/spec/nv_conditional_render/clear.c @@ -40,10 +40,13 @@ * 5.1) have no effect." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/nv_conditional_render/copypixels.c b/tests/spec/nv_conditional_render/copypixels.c index c83eb0a34..ebb646832 100644 --- a/tests/spec/nv_conditional_render/copypixels.c +++ b/tests/spec/nv_conditional_render/copypixels.c @@ -40,10 +40,13 @@ * 5.1) have no effect." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/nv_conditional_render/copyteximage.c b/tests/spec/nv_conditional_render/copyteximage.c index 3baa45d9c..23608dfee 100644 --- a/tests/spec/nv_conditional_render/copyteximage.c +++ b/tests/spec/nv_conditional_render/copyteximage.c @@ -34,10 +34,13 @@ * accidentally disable during conditional rendering. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static void fill_tex(int level, int w, int h, const GLfloat *color) diff --git a/tests/spec/nv_conditional_render/copytexsubimage.c b/tests/spec/nv_conditional_render/copytexsubimage.c index 254ebaa55..b2c410c4e 100644 --- a/tests/spec/nv_conditional_render/copytexsubimage.c +++ b/tests/spec/nv_conditional_render/copytexsubimage.c @@ -34,10 +34,13 @@ * accidentally disable during conditional rendering. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static void fill_tex(int level, int w, int h, const GLfloat *color) diff --git a/tests/spec/nv_conditional_render/dlist.c b/tests/spec/nv_conditional_render/dlist.c index c2202a3ef..6eb5d852b 100644 --- a/tests/spec/nv_conditional_render/dlist.c +++ b/tests/spec/nv_conditional_render/dlist.c @@ -30,10 +30,13 @@ * inside of display lists. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/nv_conditional_render/drawpixels.c b/tests/spec/nv_conditional_render/drawpixels.c index 97f4ac056..c24320127 100644 --- a/tests/spec/nv_conditional_render/drawpixels.c +++ b/tests/spec/nv_conditional_render/drawpixels.c @@ -40,10 +40,13 @@ * 5.1) have no effect." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/nv_conditional_render/generatemipmap.c b/tests/spec/nv_conditional_render/generatemipmap.c index 0bfbcd2e8..1092c87b9 100644 --- a/tests/spec/nv_conditional_render/generatemipmap.c +++ b/tests/spec/nv_conditional_render/generatemipmap.c @@ -33,10 +33,13 @@ * accidentally disable during conditional rendering. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static void fill_level(int level, int size, const GLfloat *color) diff --git a/tests/spec/nv_conditional_render/vertex_array.c b/tests/spec/nv_conditional_render/vertex_array.c index 8fd96c298..d17bb1058 100644 --- a/tests/spec/nv_conditional_render/vertex_array.c +++ b/tests/spec/nv_conditional_render/vertex_array.c @@ -41,10 +41,13 @@ * 5.1) have no effect." */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/nv_texture_barrier/blending-in-shader.c b/tests/spec/nv_texture_barrier/blending-in-shader.c index 6d9d00ff5..c11a2d9c2 100644 --- a/tests/spec/nv_texture_barrier/blending-in-shader.c +++ b/tests/spec/nv_texture_barrier/blending-in-shader.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex, fbo, prog, texloc; static float tex_data[16*16*4], res_data[16*16*4]; diff --git a/tests/spec/oes_compressed_etc1_rgb8_texture/oes_compressed_etc1_rgb8_texture-basic.c b/tests/spec/oes_compressed_etc1_rgb8_texture/oes_compressed_etc1_rgb8_texture-basic.c index 9fdd35384..197d81c9d 100644 --- a/tests/spec/oes_compressed_etc1_rgb8_texture/oes_compressed_etc1_rgb8_texture-basic.c +++ b/tests/spec/oes_compressed_etc1_rgb8_texture/oes_compressed_etc1_rgb8_texture-basic.c @@ -27,10 +27,13 @@ #define GL_ETC1_RGB8_OES 0x8D64 #endif -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/spec/oes_compressed_etc1_rgb8_texture/oes_compressed_etc1_rgb8_texture-miptree.c b/tests/spec/oes_compressed_etc1_rgb8_texture/oes_compressed_etc1_rgb8_texture-miptree.c index 2ee90e007..c1e53ca95 100644 --- a/tests/spec/oes_compressed_etc1_rgb8_texture/oes_compressed_etc1_rgb8_texture-miptree.c +++ b/tests/spec/oes_compressed_etc1_rgb8_texture/oes_compressed_etc1_rgb8_texture-miptree.c @@ -53,9 +53,13 @@ static const int window_width = 2 * level0_width; static const int window_height = 2 * level0_height; -PIGLIT_GL_TEST_MAIN( - window_width, window_height, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = window_width; + config.window_height = window_height; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint prog; diff --git a/tests/spec/oes_compressed_paletted_texture/oes_compressed_paletted_texture-api.c b/tests/spec/oes_compressed_paletted_texture/oes_compressed_paletted_texture-api.c index 5c61e44f5..7e70caa09 100644 --- a/tests/spec/oes_compressed_paletted_texture/oes_compressed_paletted_texture-api.c +++ b/tests/spec/oes_compressed_paletted_texture/oes_compressed_paletted_texture-api.c @@ -23,10 +23,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END struct test_vector { GLenum internal_format; diff --git a/tests/spec/oes_draw_texture/oes_draw_texture.c b/tests/spec/oes_draw_texture/oes_draw_texture.c index b9f91fe07..5f26b1032 100644 --- a/tests/spec/oes_draw_texture/oes_draw_texture.c +++ b/tests/spec/oes_draw_texture/oes_draw_texture.c @@ -34,10 +34,13 @@ #define TEXTURE_SIZE 2 -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /* see piglit_rgbw_texture */ static const float red[4] = { 1.0f, 0.0f, 0.0f, 0.0f }; diff --git a/tests/texturing/1-1-linear-texture.c b/tests/texturing/1-1-linear-texture.c index 213c480a8..295aa87f4 100644 --- a/tests/texturing/1-1-linear-texture.c +++ b/tests/texturing/1-1-linear-texture.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define DATA_SIZE (piglit_width * piglit_height * 4) diff --git a/tests/texturing/array-depth-roundtrip.c b/tests/texturing/array-depth-roundtrip.c index 5c4d14c4a..851a96996 100644 --- a/tests/texturing/array-depth-roundtrip.c +++ b/tests/texturing/array-depth-roundtrip.c @@ -52,10 +52,13 @@ #define TEX_DEPTH (NUM_TILES_ACROSS * NUM_TILES_DOWN) -PIGLIT_GL_TEST_MAIN( - TEX_WIDTH * NUM_TILES_ACROSS, - TEX_HEIGHT * NUM_TILES_DOWN, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = TEX_WIDTH*NUM_TILES_ACROSS; + config.window_height = TEX_HEIGHT*NUM_TILES_DOWN; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END GLuint tex; diff --git a/tests/texturing/array-texture.c b/tests/texturing/array-texture.c index e0765823d..60adeed51 100644 --- a/tests/texturing/array-texture.c +++ b/tests/texturing/array-texture.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END int height = 100, ybase = 0; diff --git a/tests/texturing/compressedteximage.c b/tests/texturing/compressedteximage.c index 02721782b..535cc4aac 100644 --- a/tests/texturing/compressedteximage.c +++ b/tests/texturing/compressedteximage.c @@ -36,10 +36,13 @@ #define SIZE 128 -PIGLIT_GL_TEST_MAIN( - (SIZE * 2) + 60 /*window_width*/, - SIZE + 20 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (SIZE*2)+60; + config.window_height = SIZE+20; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END struct format { const char *name; diff --git a/tests/texturing/copyteximage-border.c b/tests/texturing/copyteximage-border.c index 7492d8f74..c73fc83a1 100644 --- a/tests/texturing/copyteximage-border.c +++ b/tests/texturing/copyteximage-border.c @@ -32,10 +32,13 @@ /* Size of the body of the texture, not counting border. */ #define TEX_SIZE 64 -PIGLIT_GL_TEST_MAIN( - TEX_SIZE * 2 + 30 /*window_width*/, - TEX_SIZE + 20 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = TEX_SIZE*2+30; + config.window_height = TEX_SIZE+20; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/texturing/copyteximage-clipping.c b/tests/texturing/copyteximage-clipping.c index ea02928fb..37f15a464 100644 --- a/tests/texturing/copyteximage-clipping.c +++ b/tests/texturing/copyteximage-clipping.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLboolean test(void) diff --git a/tests/texturing/copyteximage.c b/tests/texturing/copyteximage.c index b67251050..a5d816353 100644 --- a/tests/texturing/copyteximage.c +++ b/tests/texturing/copyteximage.c @@ -106,10 +106,13 @@ static const struct { static int test_target = -1; -PIGLIT_GL_TEST_MAIN( - IMAGE_SIZE * (ARRAY_SIZE(test_vectors) + 1) /*window_width*/, - IMAGE_SIZE /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = IMAGE_SIZE*(ARRAY_SIZE(test_vectors)+1); + config.window_height = IMAGE_SIZE; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DEPTH | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static const float texCoords_1d[2] = { 0.0, 1.0 }; static const float texCoords_2d[4][2] = { diff --git a/tests/texturing/copytexsubimage.c b/tests/texturing/copytexsubimage.c index ffb893718..7b1143bff 100644 --- a/tests/texturing/copytexsubimage.c +++ b/tests/texturing/copytexsubimage.c @@ -27,10 +27,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END /** Should GL_TEXTURE_RECTANGLE_ARB be tested? */ int have_rect = 0; diff --git a/tests/texturing/crossbar.c b/tests/texturing/crossbar.c index 59752b861..a2eba94d4 100644 --- a/tests/texturing/crossbar.c +++ b/tests/texturing/crossbar.c @@ -55,10 +55,13 @@ static const GLint tests[][8] = { #define NUM_TESTS (sizeof(tests) / sizeof(tests[0])) -PIGLIT_GL_TEST_MAIN( - 100 * (NUM_TESTS + 1) /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100*(NUM_TESTS+1); + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static void DoFrame( void ) { diff --git a/tests/texturing/cubemap.c b/tests/texturing/cubemap.c index f986ea214..258e3a211 100644 --- a/tests/texturing/cubemap.c +++ b/tests/texturing/cubemap.c @@ -29,10 +29,13 @@ #define PAD 5 -PIGLIT_GL_TEST_MAIN( - (64 * 6 + PAD * 9) * 2 /*window_width*/, - 400 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (64*6+PAD*9)*2; + config.window_height = 400; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END int max_size; diff --git a/tests/texturing/depth-cube-map.c b/tests/texturing/depth-cube-map.c index c2db7f3c5..95c5259f4 100644 --- a/tests/texturing/depth-cube-map.c +++ b/tests/texturing/depth-cube-map.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex; static GLint prog; diff --git a/tests/texturing/depth-level-clamp.c b/tests/texturing/depth-level-clamp.c index 8add593c8..0f05049c3 100644 --- a/tests/texturing/depth-level-clamp.c +++ b/tests/texturing/depth-level-clamp.c @@ -41,10 +41,13 @@ #define MAX_LOD 6 #define PAD 5 -PIGLIT_GL_TEST_MAIN( - (MAX_SIZE * 2 + PAD * 3) /*window_width*/, - (MAX_SIZE * MAX_LOD + PAD * (MAX_LOD + 1)) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = (MAX_SIZE*2+PAD*3); + config.window_height = (MAX_SIZE*MAX_LOD+PAD*(MAX_LOD+1)); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static void set_level_value(int level, int size, float val) diff --git a/tests/texturing/depth-tex-compare.c b/tests/texturing/depth-tex-compare.c index 6bb71dbea..a56e869fa 100644 --- a/tests/texturing/depth-tex-compare.c +++ b/tests/texturing/depth-tex-compare.c @@ -35,10 +35,13 @@ #define BOX_SIZE 25 -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex; diff --git a/tests/texturing/depth-tex-modes-glsl.c b/tests/texturing/depth-tex-modes-glsl.c index 6008fe0ea..ccbe9cc10 100644 --- a/tests/texturing/depth-tex-modes-glsl.c +++ b/tests/texturing/depth-tex-modes-glsl.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex[3]; static GLint prog; diff --git a/tests/texturing/depth-tex-modes-rg.c b/tests/texturing/depth-tex-modes-rg.c index 4780f2fc4..ec27b27be 100644 --- a/tests/texturing/depth-tex-modes-rg.c +++ b/tests/texturing/depth-tex-modes-rg.c @@ -39,10 +39,13 @@ static const GLenum depth_texture_modes[] = { #define TEST_ROWS 4 #define TEST_COLS ARRAY_SIZE(depth_texture_modes) -PIGLIT_GL_TEST_MAIN( - 1 + (TEST_COLS * (BOX_SIZE + 1)) /*window_width*/, - 1 + (TEST_ROWS * (BOX_SIZE + 1)) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 1+(TEST_COLS*(BOX_SIZE+1)); + config.window_height = 1+(TEST_ROWS*(BOX_SIZE+1)); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END GLuint tex[2]; diff --git a/tests/texturing/depth-tex-modes.c b/tests/texturing/depth-tex-modes.c index 951a4f43c..993a0c467 100644 --- a/tests/texturing/depth-tex-modes.c +++ b/tests/texturing/depth-tex-modes.c @@ -39,10 +39,13 @@ static const GLenum depth_texture_modes[] = { #define TEST_ROWS 4 #define TEST_COLS ARRAY_SIZE(depth_texture_modes) -PIGLIT_GL_TEST_MAIN( - 1 + (TEST_COLS * (BOX_SIZE + 1)) /*window_width*/, - 1 + (TEST_ROWS * (BOX_SIZE + 1)) /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 1+(TEST_COLS*(BOX_SIZE+1)); + config.window_height = 1+(TEST_ROWS*(BOX_SIZE+1)); + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END GLuint tex[2]; diff --git a/tests/texturing/depthstencil-render-miplevels.cpp b/tests/texturing/depthstencil-render-miplevels.cpp index 7498f29f6..894f22dc0 100644 --- a/tests/texturing/depthstencil-render-miplevels.cpp +++ b/tests/texturing/depthstencil-render-miplevels.cpp @@ -86,10 +86,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 16 /*window_width*/, - 16 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 16; + config.window_height = 16; + config.window_visual = PIGLIT_GL_VISUAL_RGBA; + +PIGLIT_GL_TEST_CONFIG_END namespace { diff --git a/tests/texturing/fragment-and-vertex-texturing.c b/tests/texturing/fragment-and-vertex-texturing.c index 420aca9b7..5512a0af1 100644 --- a/tests/texturing/fragment-and-vertex-texturing.c +++ b/tests/texturing/fragment-and-vertex-texturing.c @@ -32,10 +32,13 @@ #include <string.h> #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *vs_source = "uniform sampler2D vertex_tex; \n" diff --git a/tests/texturing/fxt1-teximage.c b/tests/texturing/fxt1-teximage.c index c7d0bdbae..a41d040c5 100644 --- a/tests/texturing/fxt1-teximage.c +++ b/tests/texturing/fxt1-teximage.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 300 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 300; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define SIZE 128 diff --git a/tests/texturing/gen-compressed-teximage.c b/tests/texturing/gen-compressed-teximage.c index 7aff23a0c..3ddd4246f 100644 --- a/tests/texturing/gen-compressed-teximage.c +++ b/tests/texturing/gen-compressed-teximage.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 512 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 512; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define SIZE 128 diff --git a/tests/texturing/gen-nonzero-unit.c b/tests/texturing/gen-nonzero-unit.c index 558da61c8..e5b481098 100644 --- a/tests/texturing/gen-nonzero-unit.c +++ b/tests/texturing/gen-nonzero-unit.c @@ -41,10 +41,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 512 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 512; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static PFNGLACTIVETEXTUREPROC ActiveTexture = NULL; diff --git a/tests/texturing/gen-teximage.c b/tests/texturing/gen-teximage.c index f63b4533f..3a88db6a5 100644 --- a/tests/texturing/gen-teximage.c +++ b/tests/texturing/gen-teximage.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 512 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 512; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define SIZE 128 diff --git a/tests/texturing/gen-texsubimage.c b/tests/texturing/gen-texsubimage.c index 0e30a3c6e..12a2446b8 100644 --- a/tests/texturing/gen-texsubimage.c +++ b/tests/texturing/gen-texsubimage.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 512 /*window_width*/, - 512 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 512; + config.window_height = 512; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static void display_mipmaps(int start_x, int start_y) { diff --git a/tests/texturing/getteximage-formats.c b/tests/texturing/getteximage-formats.c index f0660bd85..3aae36c34 100644 --- a/tests/texturing/getteximage-formats.c +++ b/tests/texturing/getteximage-formats.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" #include "../fbo/fbo-formats.h" -PIGLIT_GL_TEST_MAIN( - 600 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 600; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "getteximage-formats"; diff --git a/tests/texturing/getteximage-luminance.c b/tests/texturing/getteximage-luminance.c index 33b47c11f..c2301e643 100644 --- a/tests/texturing/getteximage-luminance.c +++ b/tests/texturing/getteximage-luminance.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "getteximage-luminance"; static float tolerance = 2.0 / 255.0; diff --git a/tests/texturing/getteximage-simple.c b/tests/texturing/getteximage-simple.c index bffd55719..824ef494c 100644 --- a/tests/texturing/getteximage-simple.c +++ b/tests/texturing/getteximage-simple.c @@ -12,10 +12,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLubyte data[4096]; /* 64*16*4 */ diff --git a/tests/texturing/incomplete-texture.c b/tests/texturing/incomplete-texture.c index f958e19b5..84a3d5abb 100644 --- a/tests/texturing/incomplete-texture.c +++ b/tests/texturing/incomplete-texture.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 150 /*window_width*/, - 50 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 150; + config.window_height = 50; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define TEST_FIXED_FUNC 1 #define TEST_ARB_FP 2 diff --git a/tests/texturing/levelclamp.c b/tests/texturing/levelclamp.c index ccf05c5f5..1ae7bbf34 100644 --- a/tests/texturing/levelclamp.c +++ b/tests/texturing/levelclamp.c @@ -36,10 +36,13 @@ #define MAX_LEVEL 5 #define PAD 5 -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 600 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 600; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLfloat colors[][3] = { {1.0, 0.0, 0.0}, diff --git a/tests/texturing/lodbias.c b/tests/texturing/lodbias.c index 037a3d546..7ebedd08f 100644 --- a/tests/texturing/lodbias.c +++ b/tests/texturing/lodbias.c @@ -44,10 +44,13 @@ #define SquareSize 32 -PIGLIT_GL_TEST_MAIN( - 3*SquareSize /*window_width*/, - 3*SquareSize /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 3*SquareSize; + config.window_height = 3*SquareSize; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int CurrentTest = 0; static int CurrentBias = 0; diff --git a/tests/texturing/lodclamp-between-max.c b/tests/texturing/lodclamp-between-max.c index 6e6d8cc80..80e57c664 100644 --- a/tests/texturing/lodclamp-between-max.c +++ b/tests/texturing/lodclamp-between-max.c @@ -38,10 +38,13 @@ #define MAX_LOD 5 #define PAD 5 -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLfloat colors[][3] = { {1.0, 0.0, 0.0}, diff --git a/tests/texturing/lodclamp-between.c b/tests/texturing/lodclamp-between.c index 16f1cfbca..42381bd37 100644 --- a/tests/texturing/lodclamp-between.c +++ b/tests/texturing/lodclamp-between.c @@ -38,10 +38,13 @@ #define MAX_LOD 5 #define PAD 5 -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLfloat colors[][3] = { {1.0, 0.0, 0.0}, diff --git a/tests/texturing/lodclamp.c b/tests/texturing/lodclamp.c index 3539306dc..f0aa7e65f 100644 --- a/tests/texturing/lodclamp.c +++ b/tests/texturing/lodclamp.c @@ -36,10 +36,13 @@ #define MAX_LOD 5 #define PAD 5 -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 600 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 600; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static GLfloat colors[][3] = { {1.0, 0.0, 0.0}, diff --git a/tests/texturing/max-texture-size-level.c b/tests/texturing/max-texture-size-level.c index c30de82a5..1abff78dc 100644 --- a/tests/texturing/max-texture-size-level.c +++ b/tests/texturing/max-texture-size-level.c @@ -38,8 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN(100, 100, PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) { diff --git a/tests/texturing/max-texture-size.c b/tests/texturing/max-texture-size.c index fa91a3cf4..c5d2f40f9 100644 --- a/tests/texturing/max-texture-size.c +++ b/tests/texturing/max-texture-size.c @@ -44,10 +44,13 @@ #include "piglit-util-gl-common.h" #define COLOR_COMPONENTS 4 /*GL_RGBA*/ -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const GLenum target[] = { GL_TEXTURE_1D, diff --git a/tests/texturing/mipmap-setup.c b/tests/texturing/mipmap-setup.c index dee790211..6ec6354cc 100644 --- a/tests/texturing/mipmap-setup.c +++ b/tests/texturing/mipmap-setup.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 200 /*window_width*/, - 200 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END #define MAX_LEVEL 7 diff --git a/tests/texturing/proxy-texture.c b/tests/texturing/proxy-texture.c index 60b81db97..c8f7ec91c 100644 --- a/tests/texturing/proxy-texture.c +++ b/tests/texturing/proxy-texture.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END static void diff --git a/tests/texturing/rg-draw-pixels.c b/tests/texturing/rg-draw-pixels.c index 4231cd063..4ad1dd611 100644 --- a/tests/texturing/rg-draw-pixels.c +++ b/tests/texturing/rg-draw-pixels.c @@ -30,10 +30,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 40 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 40; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/texturing/rg-teximage-01.c b/tests/texturing/rg-teximage-01.c index 173f58a8e..6a5635bdb 100644 --- a/tests/texturing/rg-teximage-01.c +++ b/tests/texturing/rg-teximage-01.c @@ -50,10 +50,13 @@ GLuint tex[Elements(internal_formats)]; const unsigned num_tex = Elements(tex); GLboolean pass = GL_TRUE; -PIGLIT_GL_TEST_MAIN( - WIDTH * Elements(tex) /*window_width*/, - HEIGHT /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = WIDTH*Elements(tex); + config.window_height = HEIGHT; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/texturing/rg-teximage-02.c b/tests/texturing/rg-teximage-02.c index 62d23cffe..f8e84d400 100644 --- a/tests/texturing/rg-teximage-02.c +++ b/tests/texturing/rg-teximage-02.c @@ -50,10 +50,13 @@ GLuint tex[Elements(internal_formats)]; const unsigned num_tex = Elements(tex); GLboolean pass = GL_TRUE; -PIGLIT_GL_TEST_MAIN( - WIDTH * Elements(tex) /*window_width*/, - HEIGHT /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = WIDTH*Elements(tex); + config.window_height = HEIGHT; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/texturing/rgtc-teximage-01.c b/tests/texturing/rgtc-teximage-01.c index 4770a9f51..82d86d1a2 100644 --- a/tests/texturing/rgtc-teximage-01.c +++ b/tests/texturing/rgtc-teximage-01.c @@ -51,10 +51,13 @@ GLuint tex[Elements(internal_formats)]; const unsigned num_tex = Elements(tex); GLboolean pass = GL_TRUE; -PIGLIT_GL_TEST_MAIN( - WIDTH * Elements(tex) /*window_width*/, - HEIGHT /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = WIDTH*Elements(tex); + config.window_height = HEIGHT; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/texturing/rgtc-teximage-02.c b/tests/texturing/rgtc-teximage-02.c index 2337ad15d..d3fd2e5c6 100644 --- a/tests/texturing/rgtc-teximage-02.c +++ b/tests/texturing/rgtc-teximage-02.c @@ -51,10 +51,13 @@ GLuint tex[Elements(internal_formats)]; const unsigned num_tex = Elements(tex); GLboolean pass = GL_TRUE; -PIGLIT_GL_TEST_MAIN( - WIDTH * Elements(tex) /*window_width*/, - HEIGHT /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = WIDTH*Elements(tex); + config.window_height = HEIGHT; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END void piglit_init(int argc, char **argv) diff --git a/tests/texturing/s3tc-errors.c b/tests/texturing/s3tc-errors.c index e4853b3e1..ff35aebc6 100644 --- a/tests/texturing/s3tc-errors.c +++ b/tests/texturing/s3tc-errors.c @@ -34,8 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN(200, 200, PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + config.window_width = 200; + config.window_height = 200; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const float red[4] = {1.0, 0.0, 0.0, 1.0}; static const float green[4] = {0.0, 1.0, 0.0, 1.0}; diff --git a/tests/texturing/s3tc-teximage.c b/tests/texturing/s3tc-teximage.c index 99cdb9599..9fef43096 100644 --- a/tests/texturing/s3tc-teximage.c +++ b/tests/texturing/s3tc-teximage.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 600 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 600; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define SIZE 128 diff --git a/tests/texturing/s3tc-texsubimage.c b/tests/texturing/s3tc-texsubimage.c index 52251ff00..19cc6824e 100644 --- a/tests/texturing/s3tc-texsubimage.c +++ b/tests/texturing/s3tc-texsubimage.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 500 /*window_width*/, - 600 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 500; + config.window_height = 600; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define SIZE 128 diff --git a/tests/texturing/sampler-cube-shadow.c b/tests/texturing/sampler-cube-shadow.c index a3a0f75a8..c8c8739cd 100644 --- a/tests/texturing/sampler-cube-shadow.c +++ b/tests/texturing/sampler-cube-shadow.c @@ -34,10 +34,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex; static GLint prog; diff --git a/tests/texturing/shaders/texelFetch.c b/tests/texturing/shaders/texelFetch.c index 696a36767..81a82d7f0 100644 --- a/tests/texturing/shaders/texelFetch.c +++ b/tests/texturing/shaders/texelFetch.c @@ -78,10 +78,13 @@ */ #include "common.h" -PIGLIT_GL_TEST_MAIN( - 355 /*window_width*/, - 250 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 355; + config.window_height = 250; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** Vertex shader attribute locations */ const int pos_loc = 0; diff --git a/tests/texturing/shaders/textureSize.c b/tests/texturing/shaders/textureSize.c index 565b6bbef..35055448b 100644 --- a/tests/texturing/shaders/textureSize.c +++ b/tests/texturing/shaders/textureSize.c @@ -46,10 +46,13 @@ */ #include "common.h" -PIGLIT_GL_TEST_MAIN( - 150 /*window_width*/, - 30 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 150; + config.window_height = 30; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static int lod_location; static int vertex_location; diff --git a/tests/texturing/sized-texture-format-channels.c b/tests/texturing/sized-texture-format-channels.c index f7fdcfe0f..5cd9513c2 100644 --- a/tests/texturing/sized-texture-format-channels.c +++ b/tests/texturing/sized-texture-format-channels.c @@ -48,10 +48,13 @@ * exactly match. */ -PIGLIT_GL_TEST_MAIN( - 32 /*window_width*/, - 32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 32; + config.window_height = 32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END GLenum type_queries[CHANNELS] = { GL_TEXTURE_RED_TYPE, diff --git a/tests/texturing/streaming-texture-leak.c b/tests/texturing/streaming-texture-leak.c index ca5ae8495..5190174aa 100644 --- a/tests/texturing/streaming-texture-leak.c +++ b/tests/texturing/streaming-texture-leak.c @@ -38,10 +38,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define TEX_SIZE 1024 static int tex_buffer[TEX_SIZE * TEX_SIZE]; diff --git a/tests/texturing/tex-border-1.c b/tests/texturing/tex-border-1.c index 2f2ee966c..d493196e3 100644 --- a/tests/texturing/tex-border-1.c +++ b/tests/texturing/tex-border-1.c @@ -39,10 +39,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 50 /*window_width*/, - 50 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 50; + config.window_height = 50; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END enum piglit_result piglit_display(void) diff --git a/tests/texturing/tex-miplevel-selection.c b/tests/texturing/tex-miplevel-selection.c index a43f0d351..1185929ce 100644 --- a/tests/texturing/tex-miplevel-selection.c +++ b/tests/texturing/tex-miplevel-selection.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 900 /*window_width*/, - 600 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 900; + config.window_height = 600; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define TEX_WIDTH 32 #define TEX_HEIGHT 32 diff --git a/tests/texturing/tex-skipped-unit.c b/tests/texturing/tex-skipped-unit.c index 14ddcee56..bc95eb66a 100644 --- a/tests/texturing/tex-skipped-unit.c +++ b/tests/texturing/tex-skipped-unit.c @@ -30,10 +30,13 @@ #define TEXSIZE 32 -PIGLIT_GL_TEST_MAIN( - TEXSIZE * 2 /*window_width*/, - TEXSIZE * 2 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = TEXSIZE*2; + config.window_height = TEXSIZE*2; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END GLvoid draw_rect_tex(float x, float y, float w, float h, diff --git a/tests/texturing/tex-srgb.c b/tests/texturing/tex-srgb.c index 48ca5c292..81b6ab553 100644 --- a/tests/texturing/tex-srgb.c +++ b/tests/texturing/tex-srgb.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END #define SIZE 128 diff --git a/tests/texturing/tex-swizzle.c b/tests/texturing/tex-swizzle.c index 0264bd22a..7581943d3 100644 --- a/tests/texturing/tex-swizzle.c +++ b/tests/texturing/tex-swizzle.c @@ -33,10 +33,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 400 /*window_width*/, - 300 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 400; + config.window_height = 300; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static GLuint tex[1]; diff --git a/tests/texturing/tex3d-depth1.c b/tests/texturing/tex3d-depth1.c index 8e2edfc8b..980562ecb 100644 --- a/tests/texturing/tex3d-depth1.c +++ b/tests/texturing/tex3d-depth1.c @@ -32,10 +32,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 64 /*window_width*/, - 64 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 64; + config.window_height = 64; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END #define TEX_SIZE 8 diff --git a/tests/texturing/tex3d-maxsize.c b/tests/texturing/tex3d-maxsize.c index 55c3e4c8c..529639be6 100644 --- a/tests/texturing/tex3d-maxsize.c +++ b/tests/texturing/tex3d-maxsize.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "tex3d-maxsize"; diff --git a/tests/texturing/tex3d-npot.c b/tests/texturing/tex3d-npot.c index 392b2c55e..aab1ba2cf 100644 --- a/tests/texturing/tex3d-npot.c +++ b/tests/texturing/tex3d-npot.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint Texture; diff --git a/tests/texturing/tex3d.c b/tests/texturing/tex3d.c index 1786f213f..4043edad7 100644 --- a/tests/texturing/tex3d.c +++ b/tests/texturing/tex3d.c @@ -28,10 +28,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static GLuint Texture; diff --git a/tests/texturing/texdepth.c b/tests/texturing/texdepth.c index 864c28ddd..b2c303069 100644 --- a/tests/texturing/texdepth.c +++ b/tests/texturing/texdepth.c @@ -14,10 +14,13 @@ #define COLS 8 static int Width = COLS*32, Height = ROWS*32; -PIGLIT_GL_TEST_MAIN( - COLS*32 /*window_width*/, - ROWS*32 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = COLS*32; + config.window_height = ROWS*32; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DEPTH; + +PIGLIT_GL_TEST_CONFIG_END static int CellWidth, CellHeight; static int CurrentTest = 0; diff --git a/tests/texturing/teximage-errors.c b/tests/texturing/teximage-errors.c index 4186d3dfa..4e479448e 100644 --- a/tests/texturing/teximage-errors.c +++ b/tests/texturing/teximage-errors.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 100 /*window_width*/, - 100 /*window_height*/, - PIGLIT_GL_VISUAL_RGB) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 100; + config.window_height = 100; + config.window_visual = PIGLIT_GL_VISUAL_RGB; + +PIGLIT_GL_TEST_CONFIG_END diff --git a/tests/texturing/texrect-many.c b/tests/texturing/texrect-many.c index cc2038a08..2924201cc 100644 --- a/tests/texturing/texrect-many.c +++ b/tests/texturing/texrect-many.c @@ -8,10 +8,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 16 * 16 /*window_width*/, - 11 * 16 /*window_height*/, - PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 16*16; + config.window_height = 11*16; + config.window_visual = PIGLIT_GL_VISUAL_DOUBLE | PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA; + +PIGLIT_GL_TEST_CONFIG_END static int NumTextures = 16; static GLuint Textures[16]; diff --git a/tests/texturing/texredefine.c b/tests/texturing/texredefine.c index a8af697c2..af5fe1d50 100644 --- a/tests/texturing/texredefine.c +++ b/tests/texturing/texredefine.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const int CellSize = 8; /* see cell_coords */ diff --git a/tests/texturing/texsubimage.c b/tests/texturing/texsubimage.c index 1e0e16c9d..ee8fc655b 100644 --- a/tests/texturing/texsubimage.c +++ b/tests/texturing/texsubimage.c @@ -35,10 +35,13 @@ #include "piglit-util-gl-common.h" #include "../fbo/fbo-formats.h" -PIGLIT_GL_TEST_MAIN( - 150 /*window_width*/, - 150 /*window_height*/, - PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 150; + config.window_height = 150; + config.window_visual = PIGLIT_GL_VISUAL_RGBA | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END /** * This is a subset of the formats in fbo-formats.h diff --git a/tests/texturing/texture-al.c b/tests/texturing/texture-al.c index 4b9caf596..90ed002b9 100644 --- a/tests/texturing/texture-al.c +++ b/tests/texturing/texture-al.c @@ -31,10 +31,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "texture-al"; diff --git a/tests/texturing/texture-packed-formats.c b/tests/texturing/texture-packed-formats.c index 62e1c9ac6..664dcdc93 100644 --- a/tests/texturing/texture-packed-formats.c +++ b/tests/texturing/texture-packed-formats.c @@ -39,10 +39,13 @@ #include <string.h> #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 700 /*window_width*/, - 620 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 700; + config.window_height = 620; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END struct pixel_format { const char *name; diff --git a/tests/texturing/texture-rg.c b/tests/texturing/texture-rg.c index a52e82388..f4b59bbd3 100644 --- a/tests/texturing/texture-rg.c +++ b/tests/texturing/texture-rg.c @@ -29,10 +29,13 @@ #include "piglit-util-gl-common.h" -PIGLIT_GL_TEST_MAIN( - 128 /*window_width*/, - 128 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 128; + config.window_height = 128; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END static const char *TestName = "texture-rg"; diff --git a/tests/texturing/texwrap.c b/tests/texturing/texwrap.c index 156638ca0..84e4128a7 100644 --- a/tests/texturing/texwrap.c +++ b/tests/texturing/texwrap.c @@ -386,10 +386,13 @@ static int border_x = 0, border_y = 0, border_z = 0; /* 0 or 1 */ /* Piglit stuff. */ -PIGLIT_GL_TEST_MAIN( - 872 /*window_width*/, - 230 /*window_height*/, - PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE) +PIGLIT_GL_TEST_CONFIG_BEGIN + + config.window_width = 872; + config.window_height = 230; + config.window_visual = PIGLIT_GL_VISUAL_RGB | PIGLIT_GL_VISUAL_ALPHA | PIGLIT_GL_VISUAL_DOUBLE; + +PIGLIT_GL_TEST_CONFIG_END extern int piglit_automatic; diff --git a/tests/util/piglit-framework-gl.h b/tests/util/piglit-framework-gl.h index 3310d294b..5481bc5f8 100644 --- a/tests/util/piglit-framework-gl.h +++ b/tests/util/piglit-framework-gl.h @@ -104,13 +104,7 @@ piglit_gl_test_run(int argc, char *argv[], # define PIGLIT_EXTERN_C_END #endif -/** - * Define a boilerplate main() that should be suitable for most OpenGL test - * executables. - */ -#define PIGLIT_GL_TEST_MAIN(_window_width, \ - _window_height, \ - _window_visual) \ +#define PIGLIT_GL_TEST_CONFIG_BEGIN \ \ PIGLIT_EXTERN_C_BEGIN \ \ @@ -129,12 +123,10 @@ piglit_gl_test_run(int argc, char *argv[], \ piglit_gl_test_config_init(&config); \ \ - config.window_width = _window_width; \ - config.window_height = _window_height; \ - config.window_visual = _window_visual; \ - \ config.init = piglit_init; \ config.display = piglit_display; \ + +#define PIGLIT_GL_TEST_CONFIG_END \ \ piglit_gl_test_run(argc, argv, &config); \ \ |