[Piglit] [PATCH] ext_texture_norm16-render: support EXT_render_snorm interactions
Tapani Pälli
tapani.palli at intel.com
Fri Jun 1 08:24:29 UTC 2018
Signed-off-by: Tapani Pälli <tapani.palli at intel.com>
---
tests/spec/ext_texture_norm16/render.c | 17 +++++++++++++++--
1 file changed, 15 insertions(+), 2 deletions(-)
diff --git a/tests/spec/ext_texture_norm16/render.c b/tests/spec/ext_texture_norm16/render.c
index 32f601ad0..14299569a 100644
--- a/tests/spec/ext_texture_norm16/render.c
+++ b/tests/spec/ext_texture_norm16/render.c
@@ -91,7 +91,7 @@ static const GLfloat vertex_data[] = {
1.0f, 0.0f
};
-static const struct fmt_test {
+static struct fmt_test {
GLenum iformat;
GLenum base_format;
unsigned bpp;
@@ -422,8 +422,21 @@ piglit_display(void)
bool pass = true;
+ struct fmt_test *test = tests;
+ /* Toggle 'req_rend' for EXT_render_snorm compatible formats. */
+ if (piglit_is_extension_supported("GL_EXT_render_snorm")) {
+ for (unsigned i = 0; i < ARRAY_SIZE(tests); i++, test++) {
+ switch (test->iformat) {
+ case GL_R16_SNORM_EXT:
+ case GL_RG16_SNORM_EXT:
+ case GL_RGBA16_SNORM_EXT:
+ test->req_render = true;
+ }
+ }
+ }
+
/* Loop over each format. */
- const struct fmt_test *test = tests;
+ test = tests;
for (unsigned i = 0; i < ARRAY_SIZE(tests); i++, test++) {
bool fmt_pass = test_format(test);
piglit_report_subtest_result(PIGLIT_RESULT(fmt_pass),
--
2.13.6
More information about the Piglit
mailing list