aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/main/enable.c
diff options
context:
space:
mode:
authorBrian <[email protected]>2007-03-16 09:36:12 -0600
committerBrian <[email protected]>2007-03-16 09:36:12 -0600
commit7573b58db659b32f3589fc955959710d44353239 (patch)
treefc7519d69026218e0a61707b71763cc68667c40d /src/mesa/main/enable.c
parentd7049431a09a71a51768fc8cea292653557fc261 (diff)
Colortable re-org.
The pixel transfer path has three color table lookups. Use an array [3] to store that info, rather than separate variables.
Diffstat (limited to 'src/mesa/main/enable.c')
-rw-r--r--src/mesa/main/enable.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/mesa/main/enable.c b/src/mesa/main/enable.c
index 0d54c29949b..11b4ad6400e 100644
--- a/src/mesa/main/enable.c
+++ b/src/mesa/main/enable.c
@@ -663,24 +663,24 @@ _mesa_set_enable(GLcontext *ctx, GLenum cap, GLboolean state)
/* GL_SGI_color_table */
case GL_COLOR_TABLE_SGI:
CHECK_EXTENSION(SGI_color_table, cap);
- if (ctx->Pixel.ColorTableEnabled == state)
+ if (ctx->Pixel.ColorTableEnabled[COLORTABLE_PRECONVOLUTION] == state)
return;
FLUSH_VERTICES(ctx, _NEW_PIXEL);
- ctx->Pixel.ColorTableEnabled = state;
+ ctx->Pixel.ColorTableEnabled[COLORTABLE_PRECONVOLUTION] = state;
break;
case GL_POST_CONVOLUTION_COLOR_TABLE_SGI:
CHECK_EXTENSION(SGI_color_table, cap);
- if (ctx->Pixel.PostConvolutionColorTableEnabled == state)
+ if (ctx->Pixel.ColorTableEnabled[COLORTABLE_POSTCONVOLUTION] == state)
return;
FLUSH_VERTICES(ctx, _NEW_PIXEL);
- ctx->Pixel.PostConvolutionColorTableEnabled = state;
+ ctx->Pixel.ColorTableEnabled[COLORTABLE_POSTCONVOLUTION] = state;
break;
case GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI:
CHECK_EXTENSION(SGI_color_table, cap);
- if (ctx->Pixel.PostColorMatrixColorTableEnabled == state)
+ if (ctx->Pixel.ColorTableEnabled[COLORTABLE_POSTCOLORMATRIX] == state)
return;
FLUSH_VERTICES(ctx, _NEW_PIXEL);
- ctx->Pixel.PostColorMatrixColorTableEnabled = state;
+ ctx->Pixel.ColorTableEnabled[COLORTABLE_POSTCOLORMATRIX] = state;
break;
case GL_TEXTURE_COLOR_TABLE_SGI:
CHECK_EXTENSION(SGI_texture_color_table, cap);
@@ -1192,13 +1192,13 @@ _mesa_IsEnabled( GLenum cap )
/* GL_SGI_color_table */
case GL_COLOR_TABLE_SGI:
CHECK_EXTENSION(SGI_color_table);
- return ctx->Pixel.ColorTableEnabled;
+ return ctx->Pixel.ColorTableEnabled[COLORTABLE_PRECONVOLUTION];
case GL_POST_CONVOLUTION_COLOR_TABLE_SGI:
CHECK_EXTENSION(SGI_color_table);
- return ctx->Pixel.PostConvolutionColorTableEnabled;
+ return ctx->Pixel.ColorTableEnabled[COLORTABLE_POSTCONVOLUTION];
case GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI:
CHECK_EXTENSION(SGI_color_table);
- return ctx->Pixel.PostColorMatrixColorTableEnabled;
+ return ctx->Pixel.ColorTableEnabled[COLORTABLE_POSTCOLORMATRIX];
/* GL_SGI_texture_color_table */
case GL_TEXTURE_COLOR_TABLE_SGI: