[Piglit] [PATCH] fbo-generatemipmap-formats: skip integer textures

Brian Paul brianp at vmware.com
Thu Apr 3 10:55:35 PDT 2014


GL doesn't allow auto mipmap generation for integer textures.
Skip those formats to avoid hitting an assertion in the piglit
rgbw texture utility code when using the 'n' key to cycle through
tests manually.
---
 tests/fbo/fbo-generatemipmap-formats.c |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/tests/fbo/fbo-generatemipmap-formats.c b/tests/fbo/fbo-generatemipmap-formats.c
index 666030f..8c17188 100644
--- a/tests/fbo/fbo-generatemipmap-formats.c
+++ b/tests/fbo/fbo-generatemipmap-formats.c
@@ -430,6 +430,11 @@ test_format(const struct format_desc *format, GLenum basetype)
 	int level;
 	GLboolean pass = GL_TRUE;
 
+	if (basetype == GL_INT) {
+		printf("Skipping mipmap generation for integer texture.\n");
+		return GL_TRUE;
+	}
+
 	printf("Testing %s%s\n", format->name, tex_width == 256 ? "" : " (NPOT)");
 	tex = create_tex(format->internalformat, format->base_internal_format,
 			 basetype);
-- 
1.7.10.4



More information about the Piglit mailing list