summaryrefslogtreecommitdiffstats
path: root/src/mesa/swrast/s_span.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2006-10-21 22:56:21 +0000
committerBrian Paul <[email protected]>2006-10-21 22:56:21 +0000
commited324db249d068f14646eced55d106b5fe6b889c (patch)
treef06458c1270122cfa00b3e3b91d0385bbedf9229 /src/mesa/swrast/s_span.c
parentbb19e64d12eaf27e2adc3faac7e09555bb66d724 (diff)
fix another logic error in computing deferredTexture
Diffstat (limited to 'src/mesa/swrast/s_span.c')
-rw-r--r--src/mesa/swrast/s_span.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/mesa/swrast/s_span.c b/src/mesa/swrast/s_span.c
index 4fcd4d22517..ad55e1b10c3 100644
--- a/src/mesa/swrast/s_span.c
+++ b/src/mesa/swrast/s_span.c
@@ -1423,11 +1423,15 @@ _swrast_write_rgba_span( GLcontext *ctx, SWspan *span)
deferredTexture = GL_FALSE;
}
else if (shaderOrTexture) {
- if (ctx->FragmentProgram._Enabled &&
- (ctx->FragmentProgram.Current->Base.OutputsWritten
- & (1 << FRAG_RESULT_DEPR))) {
- /* Z comes from fragment program */
- deferredTexture = GL_FALSE;
+ if (ctx->FragmentProgram._Enabled) {
+ if (ctx->FragmentProgram.Current->Base.OutputsWritten
+ & (1 << FRAG_RESULT_DEPR)) {
+ /* Z comes from fragment program */
+ deferredTexture = GL_FALSE;
+ }
+ else {
+ deferredTexture = GL_TRUE;
+ }
}
else if (ctx->ShaderObjects._FragmentShaderPresent) {
/* XXX how do we test if Z is written by shader? */