Replace the flags Mesa was using for ctx->NewState with a new set
based on the GL attribute groups.
Introduced constants describing the circumstances under which some
key derived values can change:
_SWRAST_NEW_RASTERMASK -- ctx->RasterMask
_SWRAST_NEW_TRIANGLE -- The software rasterizer's triangle
function
_DD_NEW_FEEDBACK -- the 'DD_FEEDBACK' bit in ctx->TriangleCaps
These are helpful in deciding whether you need to recalculate state if your
recalculation involves reference to a derived value.
diff --git a/src/mesa/main/pixel.c b/src/mesa/main/pixel.c
index 131db1d..4cd73ef 100644
--- a/src/mesa/main/pixel.c
+++ b/src/mesa/main/pixel.c
@@ -1,4 +1,4 @@
-/* $Id: pixel.c,v 1.16 2000/10/29 18:12:15 brianp Exp $ */
+/* $Id: pixel.c,v 1.17 2000/10/30 13:32:01 keithw Exp $ */
/*
* Mesa 3-D graphics library
@@ -53,6 +53,7 @@
ctx->Pixel.ZoomX = xfactor;
ctx->Pixel.ZoomY = yfactor;
+ ctx->NewState |= _NEW_PIXEL;
}
@@ -177,6 +178,8 @@
default:
gl_error( ctx, GL_INVALID_ENUM, "glPixelStore" );
}
+
+ ctx->NewState |= _NEW_PACKUNPACK;
}
@@ -295,6 +298,7 @@
default:
gl_error( ctx, GL_INVALID_ENUM, "glPixelMapfv(map)" );
}
+ ctx->NewState |= _NEW_PIXEL;
}
@@ -629,6 +633,7 @@
/* signal to recompute the bitmask */
ctx->ImageTransferState = UPDATE_IMAGE_TRANSFER_STATE;
+ ctx->NewState |= _NEW_PIXEL;
}