aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/swrast/s_span.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2010-03-07 16:00:29 +0000
committermarha <marha@users.sourceforge.net>2010-03-07 16:00:29 +0000
commitb40894093babb10f3cd155f11ff2d6c710372395 (patch)
treee6e94e5aa39ca9d5a653af567145e4b5dda25d61 /mesalib/src/mesa/swrast/s_span.c
parentd27419efcdaaccb40e0f10c549a6b732a2f29e81 (diff)
parent14b1cb8d5a27ec9716d3f790fce95f0469e35605 (diff)
downloadvcxsrv-b40894093babb10f3cd155f11ff2d6c710372395.tar.gz
vcxsrv-b40894093babb10f3cd155f11ff2d6c710372395.tar.bz2
vcxsrv-b40894093babb10f3cd155f11ff2d6c710372395.zip
svn merge ^/branches/released .
Diffstat (limited to 'mesalib/src/mesa/swrast/s_span.c')
-rw-r--r--mesalib/src/mesa/swrast/s_span.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/mesalib/src/mesa/swrast/s_span.c b/mesalib/src/mesa/swrast/s_span.c
index 0e2793b47..d36c8132f 100644
--- a/mesalib/src/mesa/swrast/s_span.c
+++ b/mesalib/src/mesa/swrast/s_span.c
@@ -885,6 +885,9 @@ _swrast_write_index_span( GLcontext *ctx, SWspan *span)
if (!(span->arrayMask & SPAN_Z))
_swrast_span_interpolate_z(ctx, span);
+ if (ctx->Transform.DepthClamp)
+ _swrast_depth_clamp_span(ctx, span);
+
if (ctx->Stencil._Enabled) {
if (!_swrast_stencil_and_ztest_span(ctx, span)) {
span->arrayMask = origArrayMask;
@@ -901,7 +904,6 @@ _swrast_write_index_span( GLcontext *ctx, SWspan *span)
}
}
-#if FEATURE_ARB_occlusion_query
if (ctx->Query.CurrentOcclusionObject) {
/* update count of 'passed' fragments */
struct gl_query_object *q = ctx->Query.CurrentOcclusionObject;
@@ -909,7 +911,6 @@ _swrast_write_index_span( GLcontext *ctx, SWspan *span)
for (i = 0; i < span->end; i++)
q->Result += span->array->mask[i];
}
-#endif
/* we have to wait until after occlusion to do this test */
if (ctx->Color.IndexMask == 0) {
@@ -1355,6 +1356,10 @@ _swrast_write_rgba_span( GLcontext *ctx, SWspan *span)
if (ctx->Stencil._Enabled || ctx->Depth.Test) {
if (!(span->arrayMask & SPAN_Z))
_swrast_span_interpolate_z(ctx, span);
+
+ if (ctx->Transform.DepthClamp)
+ _swrast_depth_clamp_span(ctx, span);
+
if (ctx->Stencil._Enabled) {
/* Combined Z/stencil tests */
if (!_swrast_stencil_and_ztest_span(ctx, span)) {
@@ -1373,7 +1378,6 @@ _swrast_write_rgba_span( GLcontext *ctx, SWspan *span)
}
}
-#if FEATURE_ARB_occlusion_query
if (ctx->Query.CurrentOcclusionObject) {
/* update count of 'passed' fragments */
struct gl_query_object *q = ctx->Query.CurrentOcclusionObject;
@@ -1381,7 +1385,6 @@ _swrast_write_rgba_span( GLcontext *ctx, SWspan *span)
for (i = 0; i < span->end; i++)
q->Result += span->array->mask[i];
}
-#endif
/* We had to wait until now to check for glColorMask(0,0,0,0) because of
* the occlusion test.