summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2009-09-27 18:53:22 -0600
committerBrian Paul <[email protected]>2009-09-27 18:53:22 -0600
commite8eed5003b01fe8a4349711382411ac80b1c0aa3 (patch)
treeee3fc9e3a9674a5a8af0369638f5c62d549de558
parentcccdc43fa9a8c49cdbdb545de8ff91c528b1ed47 (diff)
mesa: added MESA_FORMAT_NONE
-rw-r--r--src/mesa/main/formats.c11
-rw-r--r--src/mesa/main/formats.h1
2 files changed, 12 insertions, 0 deletions
diff --git a/src/mesa/main/formats.c b/src/mesa/main/formats.c
index 8aa0d107b79..5c2bf5ece3e 100644
--- a/src/mesa/main/formats.c
+++ b/src/mesa/main/formats.c
@@ -37,6 +37,14 @@
static struct gl_format_info format_info[MESA_FORMAT_COUNT] =
{
{
+ MESA_FORMAT_NONE, /* Name */
+ GL_NONE, /* BaseFormat */
+ GL_NONE, /* DataType */
+ 0, 0, 0, 0, /* Red/Green/Blue/AlphaBits */
+ 0, 0, 0, 0, 0, /* Lum/Int/Index/Depth/StencilBits */
+ 0, 0, 0 /* BlockWidth/Height,Bytes */
+ },
+ {
MESA_FORMAT_RGBA8888, /* Name */
GL_RGBA, /* BaseFormat */
GL_UNSIGNED_NORMALIZED, /* DataType */
@@ -617,6 +625,9 @@ _mesa_test_formats(void)
assert(info->Name == i);
+ if (info->Name == MESA_FORMAT_NONE)
+ continue;
+
if (info->BlockWidth == 1 && info->BlockHeight == 1) {
if (info->RedBits > 0) {
GLuint t = info->RedBits + info->GreenBits
diff --git a/src/mesa/main/formats.h b/src/mesa/main/formats.h
index 61bbd8e79aa..e79991ad410 100644
--- a/src/mesa/main/formats.h
+++ b/src/mesa/main/formats.h
@@ -42,6 +42,7 @@
*/
typedef enum
{
+ MESA_FORMAT_NONE = 0,
/**
* \name Basic hardware formats
*/