From 2a182a98973edc9ecf2936b1288485bb2b3fa722 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Sun, 27 Jan 2002 18:32:03 +0000 Subject: LOTS of changes, building upon Klaus's work. struct sw_span is used throughout span/fragment processing. This is leading to less code and more chances for optimization. --- src/mesa/swrast/s_stencil.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'src/mesa/swrast/s_stencil.c') diff --git a/src/mesa/swrast/s_stencil.c b/src/mesa/swrast/s_stencil.c index 6e69fc8d70..3effec2af3 100644 --- a/src/mesa/swrast/s_stencil.c +++ b/src/mesa/swrast/s_stencil.c @@ -1,4 +1,4 @@ -/* $Id: s_stencil.c,v 1.15 2002/01/21 18:12:34 brianp Exp $ */ +/* $Id: s_stencil.c,v 1.16 2002/01/27 18:32:03 brianp Exp $ */ /* * Mesa 3-D graphics library @@ -559,10 +559,11 @@ _mesa_stencil_and_ztest_span(GLcontext *ctx, struct sw_span *span) ASSERT(ctx->Stencil.Enabled); ASSERT(span->end <= MAX_WIDTH); - ASSERT(span->filledMask == GL_TRUE); - ASSERT(span->filledDepth == GL_TRUE); - SW_SPAN_SET_FLAG(span->testedDepth); - +#ifdef DEBUG + if (ctx->Depth.Test) { + ASSERT((span->filledDepth == GL_TRUE) || (span->arrayMask & SPAN_Z)); + } +#endif /* Get initial stencil values */ if (swrast->Driver.WriteStencilSpan) { @@ -578,7 +579,7 @@ _mesa_stencil_and_ztest_span(GLcontext *ctx, struct sw_span *span) /* do all the stencil/depth testing/updating */ result = stencil_and_ztest_span( ctx, span->end, span->x, span->y, - span->depth, stencil, span->mask ); + span->zArray, stencil, span->mask ); if (swrast->Driver.WriteStencilSpan) { /* Write updated stencil values into hardware stencil buffer */ -- cgit v1.2.3