mesa: added glEnable/Disable state for transform feedback
[mesa.git] / src / mesa / main / colortab.c
index 5ede76c1fb1a90048ef05233358e0f268424a790..52d5badf39c81b2c2952e9e8ce4447274b4086ce 100644 (file)
@@ -32,7 +32,7 @@
 #include "state.h"
 #include "teximage.h"
 #include "texstate.h"
-#include "glapi/dispatch.h"
+#include "main/dispatch.h"
 
 
 #if FEATURE_colortable
@@ -407,8 +407,8 @@ _mesa_ColorTable( GLenum target, GLenum internalFormat,
       _mesa_free_colortable_data(table);
 
       if (width > 0) {
-         table->TableF = (GLfloat *) _mesa_malloc(comps * width * sizeof(GLfloat));
-         table->TableUB = (GLubyte *) _mesa_malloc(comps * width * sizeof(GLubyte));
+         table->TableF = (GLfloat *) malloc(comps * width * sizeof(GLfloat));
+         table->TableUB = (GLubyte *) malloc(comps * width * sizeof(GLubyte));
 
         if (!table->TableF || !table->TableUB) {
            _mesa_error(ctx, GL_OUT_OF_MEMORY, "glColorTable");
@@ -684,7 +684,7 @@ _mesa_GetColorTable( GLenum target, GLenum format,
       }
       break;
    case GL_RGBA:
-      _mesa_memcpy(rgba, table->TableF, 4 * table->Size * sizeof(GLfloat));
+      memcpy(rgba, table->TableF, 4 * table->Size * sizeof(GLfloat));
       break;
    default:
       _mesa_problem(ctx, "bad table format in glGetColorTable");
@@ -1095,11 +1095,11 @@ void
 _mesa_free_colortable_data( struct gl_color_table *p )
 {
    if (p->TableF) {
-      _mesa_free(p->TableF);
+      free(p->TableF);
       p->TableF = NULL;
    }
    if (p->TableUB) {
-      _mesa_free(p->TableUB);
+      free(p->TableUB);
       p->TableUB = NULL;
    }
 }