added packed types to glGetMinMax and glGetHistogram error checks
authorBrian Paul <brian.paul@tungstengraphics.com>
Tue, 30 Jan 2001 17:46:34 +0000 (17:46 +0000)
committerBrian Paul <brian.paul@tungstengraphics.com>
Tue, 30 Jan 2001 17:46:34 +0000 (17:46 +0000)
src/mesa/main/histogram.c

index 80ed72b6dbe9e12bb65a32e7980de39e40357bb2..7a3f7f477318411241c0416ab0a5f4cbaef272e5 100644 (file)
@@ -1,10 +1,10 @@
-/* $Id: histogram.c,v 1.5 2000/12/26 05:09:28 keithw Exp $ */
+/* $Id: histogram.c,v 1.6 2001/01/30 17:46:34 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
  * Version:  3.5
  *
- * Copyright (C) 1999-2000  Brian Paul   All Rights Reserved.
+ * Copyright (C) 1999-2001  Brian Paul   All Rights Reserved.
  *
  * Permission is hereby granted, free of charge, to any person obtaining a
  * copy of this software and associated documentation files (the "Software"),
@@ -623,7 +623,19 @@ _mesa_GetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvo
        type != GL_SHORT &&
        type != GL_UNSIGNED_INT &&
        type != GL_INT &&
-       type != GL_FLOAT) {
+       type != GL_FLOAT &&
+       type != GL_UNSIGNED_BYTE_3_3_2 &&
+       type != GL_UNSIGNED_BYTE_2_3_3_REV &&
+       type != GL_UNSIGNED_SHORT_5_6_5 &&
+       type != GL_UNSIGNED_SHORT_5_6_5_REV &&
+       type != GL_UNSIGNED_SHORT_4_4_4_4 &&
+       type != GL_UNSIGNED_SHORT_4_4_4_4_REV &&
+       type != GL_UNSIGNED_SHORT_5_5_5_1 &&
+       type != GL_UNSIGNED_SHORT_1_5_5_5_REV &&
+       type != GL_UNSIGNED_INT_8_8_8_8 &&
+       type != GL_UNSIGNED_INT_8_8_8_8_REV &&
+       type != GL_UNSIGNED_INT_10_10_10_2 &&
+       type != GL_UNSIGNED_INT_2_10_10_10_REV) {
       gl_error(ctx, GL_INVALID_ENUM, "glGetMinmax(type)");
       return;
    }
@@ -678,7 +690,19 @@ _mesa_GetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, G
        type != GL_SHORT &&
        type != GL_UNSIGNED_INT &&
        type != GL_INT &&
-       type != GL_FLOAT) {
+       type != GL_FLOAT &&
+       type != GL_UNSIGNED_BYTE_3_3_2 &&
+       type != GL_UNSIGNED_BYTE_2_3_3_REV &&
+       type != GL_UNSIGNED_SHORT_5_6_5 &&
+       type != GL_UNSIGNED_SHORT_5_6_5_REV &&
+       type != GL_UNSIGNED_SHORT_4_4_4_4 &&
+       type != GL_UNSIGNED_SHORT_4_4_4_4_REV &&
+       type != GL_UNSIGNED_SHORT_5_5_5_1 &&
+       type != GL_UNSIGNED_SHORT_1_5_5_5_REV &&
+       type != GL_UNSIGNED_INT_8_8_8_8 &&
+       type != GL_UNSIGNED_INT_8_8_8_8_REV &&
+       type != GL_UNSIGNED_INT_10_10_10_2 &&
+       type != GL_UNSIGNED_INT_2_10_10_10_REV) {
       gl_error(ctx, GL_INVALID_ENUM, "glGetHistogram(type)");
       return;
    }