summaryrefslogtreecommitdiff
path: root/src/mesa/main
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2006-09-11 15:25:49 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2006-09-11 15:25:49 +0000
commit31a66ada72e5d9eb728f5149b72121bb04776016 (patch)
treedbe894fa7e6b75cee899d746fb88201b136387b7 /src/mesa/main
parent02aa5fba0375a6013cc7cbaeb4883cc1263bbef4 (diff)
undo some accidental changes in _mesa_is_legal_format_and_type()
Diffstat (limited to 'src/mesa/main')
-rw-r--r--src/mesa/main/image.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/mesa/main/image.c b/src/mesa/main/image.c
index b46e323db2..d86c2203a8 100644
--- a/src/mesa/main/image.c
+++ b/src/mesa/main/image.c
@@ -414,6 +414,10 @@ _mesa_is_legal_format_and_type( GLcontext *ctx, GLenum format, GLenum type )
case GL_INT:
case GL_UNSIGNED_INT:
case GL_FLOAT:
+ case GL_UNSIGNED_BYTE_3_3_2:
+ case GL_UNSIGNED_BYTE_2_3_3_REV:
+ case GL_UNSIGNED_SHORT_5_6_5:
+ case GL_UNSIGNED_SHORT_5_6_5_REV:
return GL_TRUE;
case GL_HALF_FLOAT_ARB:
return ctx->Extensions.ARB_half_float_pixel;
@@ -422,6 +426,9 @@ _mesa_is_legal_format_and_type( GLcontext *ctx, GLenum format, GLenum type )
}
case GL_BGR:
switch (type) {
+ /* NOTE: no packed types are supported with BGR. That's
+ * intentional, according to the GL spec.
+ */
case GL_BYTE:
case GL_UNSIGNED_BYTE:
case GL_SHORT:
@@ -429,10 +436,6 @@ _mesa_is_legal_format_and_type( GLcontext *ctx, GLenum format, GLenum type )
case GL_INT:
case GL_UNSIGNED_INT:
case GL_FLOAT:
- case GL_UNSIGNED_BYTE_3_3_2:
- case GL_UNSIGNED_BYTE_2_3_3_REV:
- case GL_UNSIGNED_SHORT_5_6_5:
- case GL_UNSIGNED_SHORT_5_6_5_REV:
return GL_TRUE;
case GL_HALF_FLOAT_ARB:
return ctx->Extensions.ARB_half_float_pixel;