[Piglit] [PATCH] piglit-util-gl-common: fix ES1 / ES2 build error
Jordan Justen
jordan.l.justen at intel.com
Mon Oct 8 17:17:34 PDT 2012
Signed-off-by: Jordan Justen <jordan.l.justen at intel.com>
Cc: Brian Paul <brianp at vmware.com>
Cc: Chad Versace <chad.versace at linux.intel.com>
---
tests/util/piglit-util-gl-common.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/tests/util/piglit-util-gl-common.c b/tests/util/piglit-util-gl-common.c
index 62b5312..4f9fe5f 100644
--- a/tests/util/piglit-util-gl-common.c
+++ b/tests/util/piglit-util-gl-common.c
@@ -447,8 +447,14 @@ piglit_get_compressed_block_size(GLenum format,
unsigned *bw, unsigned *bh, unsigned *bytes)
{
switch (format) {
+#if defined(USE_OPENGL) || defined(USE_OPENGL_ES2)
case GL_COMPRESSED_RGB_S3TC_DXT1_EXT:
case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
+ *bw = *bh = 4;
+ *bytes = 8;
+ return true;
+#endif
+#if defined(USE_OPENGL)
case GL_COMPRESSED_SRGB_S3TC_DXT1_EXT:
case GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT:
case GL_COMPRESSED_RED_RGTC1:
@@ -475,6 +481,7 @@ piglit_get_compressed_block_size(GLenum format,
*bh = 4;
*bytes = 16;
return true;
+#endif
default:
/* return something rather than uninitialized values */
*bw = *bh = *bytes = 1;
--
1.7.9.5
More information about the Piglit
mailing list