[Piglit] [PATCH 28/31] util/sized-internalformats: Remove GLenum stringification macros.
Fabian Bieler
fabianbieler at fastmail.fm
Thu Dec 28 15:57:54 UTC 2017
Replace GLenum stringification macros with calls to piglit_get_gl_enum_name.
---
.../required-renderbuffer-attachment-formats.c | 9 +-
tests/spec/gl-3.0/required-sized-texture-formats.c | 4 +-
.../gl-3.0/required-texture-attachment-formats.c | 9 +-
tests/texturing/sized-texture-format-channels.c | 3 +-
tests/util/sized-internalformats.c | 199 ++++++++++-----------
tests/util/sized-internalformats.h | 1 -
6 files changed, 112 insertions(+), 113 deletions(-)
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 ca716a4da..928980b3b 100644
--- a/tests/spec/gl-3.0/required-renderbuffer-attachment-formats.c
+++ b/tests/spec/gl-3.0/required-renderbuffer-attachment-formats.c
@@ -64,6 +64,7 @@ piglit_init(int argc, char **argv)
continue;
f = get_sized_internalformat(required_formats[i].token);
+ const char *name = piglit_get_gl_enum_name(f->token);
if (f->token == GL_DEPTH24_STENCIL8 ||
f->token == GL_DEPTH32F_STENCIL8) {
@@ -92,7 +93,7 @@ piglit_init(int argc, char **argv)
if (glGetError() != 0) {
printf("Unexpected error creating %s texture\n",
- f->name);
+ name);
pass = false;
continue;
}
@@ -105,7 +106,7 @@ piglit_init(int argc, char **argv)
if (glGetError() != 0) {
printf("Unexpected error binding %s texture\n",
- f->name);
+ name);
pass = false;
continue;
}
@@ -119,10 +120,10 @@ piglit_init(int argc, char **argv)
status = glCheckFramebufferStatus(GL_FRAMEBUFFER);
if (status != GL_FRAMEBUFFER_COMPLETE) {
fprintf(stderr, "%s fbo incomplete (status = 0x%04x)\n",
- f->name, status);
+ name, status);
pass = false;
} else {
- printf("%s: fbo complete\n", f->name);
+ printf("%s: fbo complete\n", name);
}
glDeleteFramebuffers(1, &fbo);
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 4cea5c1e8..e60b7f11b 100644
--- a/tests/spec/gl-3.0/required-sized-texture-formats.c
+++ b/tests/spec/gl-3.0/required-sized-texture-formats.c
@@ -162,7 +162,7 @@ piglit_init(int argc, char **argv)
if (glGetError() != 0) {
printf("Unexpected error creating %s texture\n",
- f->name);
+ piglit_get_gl_enum_name(f->token));
pass = false;
continue;
}
@@ -241,7 +241,7 @@ piglit_init(int argc, char **argv)
if (!format_pass) {
printf("format %s:\n",
- f->name);
+ piglit_get_gl_enum_name(f->token));
printf(" expected: ");
for (c = 0; c < CHANNELS; c++) {
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 701f874ce..32da576b4 100644
--- a/tests/spec/gl-3.0/required-texture-attachment-formats.c
+++ b/tests/spec/gl-3.0/required-texture-attachment-formats.c
@@ -64,6 +64,7 @@ piglit_init(int argc, char **argv)
continue;
f = get_sized_internalformat(required_formats[i].token);
+ const char *name = piglit_get_gl_enum_name(f->token);
if (f->token == GL_DEPTH24_STENCIL8 ||
f->token == GL_DEPTH32F_STENCIL8) {
@@ -96,7 +97,7 @@ piglit_init(int argc, char **argv)
if (glGetError() != 0) {
printf("Unexpected error creating %s texture\n",
- f->name);
+ name);
pass = false;
continue;
}
@@ -115,7 +116,7 @@ piglit_init(int argc, char **argv)
if (glGetError() != 0) {
printf("Unexpected error binding %s texture\n",
- f->name);
+ name);
pass = false;
continue;
}
@@ -129,10 +130,10 @@ piglit_init(int argc, char **argv)
status = glCheckFramebufferStatus(GL_FRAMEBUFFER_EXT);
if (status != GL_FRAMEBUFFER_COMPLETE) {
fprintf(stderr, "%s fbo incomplete (status = 0x%04x)\n",
- f->name, status);
+ name, status);
pass = false;
} else {
- printf("%s: fbo complete\n", f->name);
+ printf("%s: fbo complete\n", name);
}
glDeleteFramebuffers(1, &fbo);
diff --git a/tests/texturing/sized-texture-format-channels.c b/tests/texturing/sized-texture-format-channels.c
index ee757e1af..6b9feae77 100644
--- a/tests/texturing/sized-texture-format-channels.c
+++ b/tests/texturing/sized-texture-format-channels.c
@@ -152,7 +152,8 @@ piglit_init(int argc, char **argv)
if (format_fail || format_print) {
printf("format %s%s:\n",
- f->name, format_fail ? " failure" : "");
+ piglit_get_gl_enum_name(f->token),
+ format_fail ? " failure" : "");
printf(" expected: ");
for (c = 0; c < CHANNELS; c++) {
diff --git a/tests/util/sized-internalformats.c b/tests/util/sized-internalformats.c
index d3d71e17d..a22d2c0b8 100644
--- a/tests/util/sized-internalformats.c
+++ b/tests/util/sized-internalformats.c
@@ -23,9 +23,6 @@
#include "piglit-util-gl.h"
#include "sized-internalformats.h"
-#define FORMAT(token, r, g, b, a, l, i, d, s) \
- { #token, token, { r, g, b, a, l, i, d, s } }
-
/* This list has to match up with the enums in sized-internalformats.h */
static const struct {
int size;
@@ -76,121 +73,121 @@ const struct sized_internalformat sized_internalformats[] = {
/* Sized internal color formats, table 3.16 of the GL 3.0
* specification.
*/
- FORMAT(GL_ALPHA4, NONE, NONE, NONE, UN4, NONE, NONE, NONE, NONE),
- FORMAT(GL_ALPHA8, NONE, NONE, NONE, UN8, NONE, NONE, NONE, NONE),
- FORMAT(GL_ALPHA12, NONE, NONE, NONE, UN12, NONE, NONE, NONE, NONE),
- FORMAT(GL_ALPHA16, NONE, NONE, NONE, UN16, NONE, NONE, NONE, NONE),
- FORMAT(GL_R8, UN8, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_R16, UN16, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG8, UN8, UN8, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG16, UN16, UN16, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_R3_G3_B2, UN3, UN3, UN2, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB4, UN4, UN4, UN4, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB5, UN5, UN5, UN5, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB8, UN8, UN8, UN8, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB10, UN10, UN10, UN10, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB12, UN12, UN12, UN12, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB16, UN16, UN16, UN16, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA2, UN2, UN2, UN2, UN2, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA4, UN4, UN4, UN4, UN4, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB5_A1, UN5, UN5, UN5, UN1, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA8, UN8, UN8, UN8, UN8, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB10_A2, UN10, UN10, UN10, UN2, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB10_A2UI, U10, U10, U10, U2, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA12, UN12, UN12, UN12, UN12, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA16, UN16, UN16, UN16, UN16, NONE, NONE, NONE, NONE),
- FORMAT(GL_SRGB8, UN8, UN8, UN8, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_SRGB8_ALPHA8, UN8, UN8, UN8, UN8, NONE, NONE, NONE, NONE),
- FORMAT(GL_R16F, F16, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG16F, F16, F16, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB16F, F16, F16, F16, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA16F, F16, F16, F16, F16, NONE, NONE, NONE, NONE),
- FORMAT(GL_R32F, F32, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG32F, F32, F32, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB32F, F32, F32, F32, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA32F, F32, F32, F32, F32, NONE, NONE, NONE, NONE),
- FORMAT(GL_R11F_G11F_B10F, F11, F11, F10, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB565, UN5, UN6, UN5, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB9_E5, F9, F9, F9, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_R8I, I8, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_R8UI, U8, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_R16I, I16, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_R16UI, U16, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_R32I, I32, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_R32UI, U32, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG8I, I8, I8, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG8UI, U8, U8, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG16I, I16, I16, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG16UI, U16, U16, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG32I, I32, I32, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG32UI, U32, U32, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB8I, I8, I8, I8, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB8UI, U8, U8, U8, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB16I, I16, I16, I16, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB16UI, U16, U16, U16, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB32I, I32, I32, I32, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB32UI, U32, U32, U32, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA8I, I8, I8, I8, I8, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA8UI, U8, U8, U8, U8, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA16I, I16, I16, I16, I16, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA16UI, U16, U16, U16, U16, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA32I, I32, I32, I32, I32, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA32UI, U32, U32, U32, U32, NONE, NONE, NONE, NONE),
+ { GL_ALPHA4, { NONE, NONE, NONE, UN4, NONE, NONE, NONE, NONE } },
+ { GL_ALPHA8, { NONE, NONE, NONE, UN8, NONE, NONE, NONE, NONE } },
+ { GL_ALPHA12, { NONE, NONE, NONE, UN12, NONE, NONE, NONE, NONE } },
+ { GL_ALPHA16, { NONE, NONE, NONE, UN16, NONE, NONE, NONE, NONE } },
+ { GL_R8, { UN8, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_R16, { UN16, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG8, { UN8, UN8, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG16, { UN16, UN16, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_R3_G3_B2, { UN3, UN3, UN2, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB4, { UN4, UN4, UN4, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB5, { UN5, UN5, UN5, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB8, { UN8, UN8, UN8, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB10, { UN10, UN10, UN10, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB12, { UN12, UN12, UN12, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB16, { UN16, UN16, UN16, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGBA2, { UN2, UN2, UN2, UN2, NONE, NONE, NONE, NONE } },
+ { GL_RGBA4, { UN4, UN4, UN4, UN4, NONE, NONE, NONE, NONE } },
+ { GL_RGB5_A1, { UN5, UN5, UN5, UN1, NONE, NONE, NONE, NONE } },
+ { GL_RGBA8, { UN8, UN8, UN8, UN8, NONE, NONE, NONE, NONE } },
+ { GL_RGB10_A2, { UN10, UN10, UN10, UN2, NONE, NONE, NONE, NONE } },
+ { GL_RGB10_A2UI, { U10, U10, U10, U2, NONE, NONE, NONE, NONE } },
+ { GL_RGBA12, { UN12, UN12, UN12, UN12, NONE, NONE, NONE, NONE } },
+ { GL_RGBA16, { UN16, UN16, UN16, UN16, NONE, NONE, NONE, NONE } },
+ { GL_SRGB8, { UN8, UN8, UN8, NONE, NONE, NONE, NONE, NONE } },
+ { GL_SRGB8_ALPHA8, { UN8, UN8, UN8, UN8, NONE, NONE, NONE, NONE } },
+ { GL_R16F, { F16, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG16F, { F16, F16, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB16F, { F16, F16, F16, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGBA16F, { F16, F16, F16, F16, NONE, NONE, NONE, NONE } },
+ { GL_R32F, { F32, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG32F, { F32, F32, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB32F, { F32, F32, F32, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGBA32F, { F32, F32, F32, F32, NONE, NONE, NONE, NONE } },
+ { GL_R11F_G11F_B10F, { F11, F11, F10, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB565, { UN5, UN6, UN5, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB9_E5, { F9, F9, F9, NONE, NONE, NONE, NONE, NONE } },
+ { GL_R8I, { I8, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_R8UI, { U8, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_R16I, { I16, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_R16UI, { U16, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_R32I, { I32, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_R32UI, { U32, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG8I, { I8, I8, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG8UI, { U8, U8, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG16I, { I16, I16, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG16UI, { U16, U16, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG32I, { I32, I32, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG32UI, { U32, U32, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB8I, { I8, I8, I8, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB8UI, { U8, U8, U8, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB16I, { I16, I16, I16, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB16UI, { U16, U16, U16, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB32I, { I32, I32, I32, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB32UI, { U32, U32, U32, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGBA8I, { I8, I8, I8, I8, NONE, NONE, NONE, NONE } },
+ { GL_RGBA8UI, { U8, U8, U8, U8, NONE, NONE, NONE, NONE } },
+ { GL_RGBA16I, { I16, I16, I16, I16, NONE, NONE, NONE, NONE } },
+ { GL_RGBA16UI, { U16, U16, U16, U16, NONE, NONE, NONE, NONE } },
+ { GL_RGBA32I, { I32, I32, I32, I32, NONE, NONE, NONE, NONE } },
+ { GL_RGBA32UI, { U32, U32, U32, U32, NONE, NONE, NONE, NONE } },
/* SNORM formats introduced as required sized texture formats
* in GL 3.1, but didn't get sizes actually specified until GL
* 3.2's table 3.12.
*/
- FORMAT(GL_R8_SNORM, SN8, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_R16_SNORM, SN16, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG8_SNORM, SN8, SN8, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RG16_SNORM, SN16, SN16, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB8_SNORM, SN8, SN8, SN8, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGB16_SNORM, SN16, SN16, SN16, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA8_SNORM, SN8, SN8, SN8, SN8, NONE, NONE, NONE, NONE),
- FORMAT(GL_RGBA16_SNORM, SN16, SN16, SN16, SN16, NONE, NONE, NONE, NONE),
+ { GL_R8_SNORM, { SN8, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_R16_SNORM, { SN16, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG8_SNORM, { SN8, SN8, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RG16_SNORM, { SN16, SN16, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB8_SNORM, { SN8, SN8, SN8, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGB16_SNORM, { SN16, SN16, SN16, NONE, NONE, NONE, NONE, NONE } },
+ { GL_RGBA8_SNORM, { SN8, SN8, SN8, SN8, NONE, NONE, NONE, NONE } },
+ { GL_RGBA16_SNORM, { SN16, SN16, SN16, SN16, NONE, NONE, NONE, NONE } },
/* Sized internal luminance formats, table 3.17 of the GL 3.0
* specification.
*/
- FORMAT(GL_LUMINANCE4, NONE, NONE, NONE, NONE, UN4, NONE, NONE, NONE),
- FORMAT(GL_LUMINANCE8, NONE, NONE, NONE, NONE, UN8, NONE, NONE, NONE),
- FORMAT(GL_LUMINANCE12, NONE, NONE, NONE, NONE, UN12, NONE, NONE, NONE),
- FORMAT(GL_LUMINANCE16, NONE, NONE, NONE, NONE, UN16, NONE, NONE, NONE),
- FORMAT(GL_LUMINANCE4_ALPHA4, NONE, NONE, NONE, UN4, UN4, NONE, NONE, NONE),
- FORMAT(GL_LUMINANCE8_ALPHA8, NONE, NONE, NONE, UN8, UN8, NONE, NONE, NONE),
- FORMAT(GL_LUMINANCE12_ALPHA12, NONE, NONE, NONE, UN12, UN12, NONE, NONE, NONE),
- FORMAT(GL_LUMINANCE16_ALPHA16, NONE, NONE, NONE, UN16, UN16, NONE, NONE, NONE),
- FORMAT(GL_INTENSITY4, NONE, NONE, NONE, NONE, NONE, UN4, NONE, NONE),
- FORMAT(GL_INTENSITY8, NONE, NONE, NONE, NONE, NONE, UN8, NONE, NONE),
- FORMAT(GL_INTENSITY12, NONE, NONE, NONE, NONE, NONE, UN12, NONE, NONE),
- FORMAT(GL_INTENSITY16, NONE, NONE, NONE, NONE, NONE, UN16, NONE, NONE),
- FORMAT(GL_SLUMINANCE, NONE, NONE, NONE, NONE, UN8, NONE, NONE, NONE),
- FORMAT(GL_SLUMINANCE8_ALPHA8, NONE, NONE, NONE, UN8, UN8, NONE, NONE, NONE),
+ { GL_LUMINANCE4, { NONE, NONE, NONE, NONE, UN4, NONE, NONE, NONE } },
+ { GL_LUMINANCE8, { NONE, NONE, NONE, NONE, UN8, NONE, NONE, NONE } },
+ { GL_LUMINANCE12, { NONE, NONE, NONE, NONE, UN12, NONE, NONE, NONE } },
+ { GL_LUMINANCE16, { NONE, NONE, NONE, NONE, UN16, NONE, NONE, NONE } },
+ { GL_LUMINANCE4_ALPHA4, { NONE, NONE, NONE, UN4, UN4, NONE, NONE, NONE } },
+ { GL_LUMINANCE8_ALPHA8, { NONE, NONE, NONE, UN8, UN8, NONE, NONE, NONE } },
+ { GL_LUMINANCE12_ALPHA12, { NONE, NONE, NONE, UN12, UN12, NONE, NONE, NONE } },
+ { GL_LUMINANCE16_ALPHA16, { NONE, NONE, NONE, UN16, UN16, NONE, NONE, NONE } },
+ { GL_INTENSITY4, { NONE, NONE, NONE, NONE, NONE, UN4, NONE, NONE } },
+ { GL_INTENSITY8, { NONE, NONE, NONE, NONE, NONE, UN8, NONE, NONE } },
+ { GL_INTENSITY12, { NONE, NONE, NONE, NONE, NONE, UN12, NONE, NONE } },
+ { GL_INTENSITY16, { NONE, NONE, NONE, NONE, NONE, UN16, NONE, NONE } },
+ { GL_SLUMINANCE, { NONE, NONE, NONE, NONE, UN8, NONE, NONE, NONE } },
+ { GL_SLUMINANCE8_ALPHA8, { NONE, NONE, NONE, UN8, UN8, NONE, NONE, NONE } },
/* Sized internal depth and stencil formats, table 3.18 of the
* GL 3.0 specification.
*/
- FORMAT(GL_DEPTH_COMPONENT16, NONE, NONE, NONE, NONE, NONE, NONE,
- UN16, NONE),
- FORMAT(GL_DEPTH_COMPONENT24, NONE, NONE, NONE, NONE, NONE, NONE,
- UN24, NONE),
- FORMAT(GL_DEPTH_COMPONENT32, NONE, NONE, NONE, NONE, NONE, NONE,
- UN32, NONE),
- FORMAT(GL_DEPTH_COMPONENT32F, NONE, NONE, NONE, NONE, NONE, NONE,
- F32, NONE),
- FORMAT(GL_DEPTH24_STENCIL8, NONE, NONE, NONE, NONE, NONE, NONE,
- UN24, UN8),
- FORMAT(GL_DEPTH32F_STENCIL8, NONE, NONE, NONE, NONE, NONE, NONE,
- F32, UN8),
+ { GL_DEPTH_COMPONENT16, { NONE, NONE, NONE, NONE, NONE, NONE,
+ UN16, NONE } },
+ { GL_DEPTH_COMPONENT24, { NONE, NONE, NONE, NONE, NONE, NONE,
+ UN24, NONE } },
+ { GL_DEPTH_COMPONENT32, { NONE, NONE, NONE, NONE, NONE, NONE,
+ UN32, NONE } },
+ { GL_DEPTH_COMPONENT32F, { NONE, NONE, NONE, NONE, NONE, NONE,
+ F32, NONE } },
+ { GL_DEPTH24_STENCIL8, { NONE, NONE, NONE, NONE, NONE, NONE,
+ UN24, UN8 } },
+ { GL_DEPTH32F_STENCIL8, { NONE, NONE, NONE, NONE, NONE, NONE,
+ F32, UN8 } },
/* Specific compressed internal formats, table 3.19 of the GL
* 3.0 specification.
*/
- FORMAT(GL_COMPRESSED_RG_RGTC2, UCMP, UCMP, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_COMPRESSED_SIGNED_RG_RGTC2, SCMP, SCMP, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_COMPRESSED_RED_RGTC1, UCMP, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
- FORMAT(GL_COMPRESSED_SIGNED_RED_RGTC1, SCMP, NONE, NONE, NONE, NONE, NONE, NONE, NONE),
+ { GL_COMPRESSED_RG_RGTC2, { UCMP, UCMP, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_COMPRESSED_SIGNED_RG_RGTC2, { SCMP, SCMP, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_COMPRESSED_RED_RGTC1, { UCMP, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
+ { GL_COMPRESSED_SIGNED_RED_RGTC1, { SCMP, NONE, NONE, NONE, NONE, NONE, NONE, NONE } },
{ GL_NONE },
};
diff --git a/tests/util/sized-internalformats.h b/tests/util/sized-internalformats.h
index e71abf564..104a15aed 100644
--- a/tests/util/sized-internalformats.h
+++ b/tests/util/sized-internalformats.h
@@ -84,7 +84,6 @@ enum channel {
};
struct sized_internalformat {
- const char *name;
GLenum token;
enum bits_types bits[CHANNELS];
};
--
2.15.1
More information about the Piglit
mailing list