From 1e1aac034c986a08248861363c0baa27dc2ae2d5 Mon Sep 17 00:00:00 2001 From: Keith Whitwell Date: Mon, 13 Nov 2000 20:02:56 +0000 Subject: Cleanup of derived state calculation prior to seperating software T&L into a new directory. Specifically the handling of changes to lighting lighting space (light in model vs. light in eye) have been revamped. Moved several derived values used only by swrast into that directory. Removed direct calls to swrast_flush() from vbrender.c -- pushed into ctx->Driver.RenderFinish. Optimized flat-shading case in swrast_setup. --- src/mesa/swrast/s_context.h | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) (limited to 'src/mesa/swrast/s_context.h') diff --git a/src/mesa/swrast/s_context.h b/src/mesa/swrast/s_context.h index 493758ad695..10e162b7056 100644 --- a/src/mesa/swrast/s_context.h +++ b/src/mesa/swrast/s_context.h @@ -93,16 +93,34 @@ typedef void (*swrast_point_func)( GLcontext *ctx, SWvertex *); typedef struct { - GLuint NewState; - GLuint StateChanges; + /* Configuration mechanisms to make software rasterizer match + * characteristics of the hardware rasterizer (if present): + */ + GLboolean AllowVertexFog; + GLboolean AllowPixelFog; + /* Derived values, invalidated on statechanges, updated from + * _swrast_validate_derived(): + */ GLuint _RasterMask; + GLboolean _MultiTextureEnabled; GLuint _MinMagThresh[MAX_TEXTURE_UNITS]; + GLfloat _backface_sign; + GLboolean _PreferPixelFog; + + /* Accum buffer temporaries. + */ + GLboolean _IntegerAccumMode; /* Storing unscaled integers? */ + GLfloat _IntegerAccumScaler; /* Implicit scale factor */ + + /* Working values: + */ struct pixel_buffer* PB; GLuint StippleCounter; /* Line stipple counter */ - - + GLuint NewState; + GLuint StateChanges; + /* Mechanism to allow driver (like X11) to register further * software rasterization routines. */ -- cgit v1.2.3