diff options
author | Keith Whitwell <[email protected]> | 2001-03-19 02:25:35 +0000 |
---|---|---|
committer | Keith Whitwell <[email protected]> | 2001-03-19 02:25:35 +0000 |
commit | 709892459922a32096fe9dd8261d0d92337bb02f (patch) | |
tree | 87782215d4531207c97b236a5dfa0d15c45aef8a /src/mesa/swrast/s_context.c | |
parent | d9bf6ccce9f5fea22d6a478c4afafea3c3c525c5 (diff) |
Split driver struct into swrast/tnl/core components.
Diffstat (limited to 'src/mesa/swrast/s_context.c')
-rw-r--r-- | src/mesa/swrast/s_context.c | 31 |
1 files changed, 30 insertions, 1 deletions
diff --git a/src/mesa/swrast/s_context.c b/src/mesa/swrast/s_context.c index ffcdc718c2c..20090bdb12e 100644 --- a/src/mesa/swrast/s_context.c +++ b/src/mesa/swrast/s_context.c @@ -1,4 +1,4 @@ -/* $Id: s_context.c,v 1.17 2001/03/12 00:48:41 gareth Exp $ */ +/* $Id: s_context.c,v 1.18 2001/03/19 02:25:36 keithw Exp $ */ /* * Mesa 3-D graphics library @@ -316,6 +316,27 @@ _swrast_invalidate_state( GLcontext *ctx, GLuint new_state ) if (new_state & _SWRAST_NEW_TEXTURE_SAMPLE_FUNC) for (i = 0 ; i < ctx->Const.MaxTextureUnits ; i++) swrast->TextureSample[i] = _swrast_validate_texture_sample; + + + if (ctx->Visual.rgbMode) { + ASSERT(swrast->Driver.WriteRGBASpan); + ASSERT(swrast->Driver.WriteRGBSpan); + ASSERT(swrast->Driver.WriteMonoRGBASpan); + ASSERT(swrast->Driver.WriteRGBAPixels); + ASSERT(swrast->Driver.WriteMonoRGBAPixels); + ASSERT(swrast->Driver.ReadRGBASpan); + ASSERT(swrast->Driver.ReadRGBAPixels); + } + else { + ASSERT(swrast->Driver.WriteCI32Span); + ASSERT(swrast->Driver.WriteCI8Span); + ASSERT(swrast->Driver.WriteMonoCISpan); + ASSERT(swrast->Driver.WriteCI32Pixels); + ASSERT(swrast->Driver.WriteMonoCIPixels); + ASSERT(swrast->Driver.ReadCI32Span); + ASSERT(swrast->Driver.ReadCI32Pixels); + } + } @@ -471,6 +492,14 @@ _swrast_DestroyContext( GLcontext *ctx ) } +struct swrast_device_driver * +_swrast_GetDeviceDriverReference( GLcontext *ctx ) +{ + SWcontext *swrast = SWRAST_CONTEXT(ctx); + return &swrast->Driver; +} + + void _swrast_print_vertex( GLcontext *ctx, const SWvertex *v ) { |