dri/nouveau: Fix stencil mask handling on glClear().
authorFrancisco Jerez <currojerez@riseup.net>
Sun, 21 Feb 2010 13:28:17 +0000 (14:28 +0100)
committerFrancisco Jerez <currojerez@riseup.net>
Thu, 25 Feb 2010 17:37:34 +0000 (18:37 +0100)
src/mesa/drivers/dri/nouveau/nouveau_driver.c

index bf0e20ca81ce352fb8065de42a5a016cae56effe..afaa8de5b3898670d060a79451944119dbefd551 100644 (file)
@@ -112,8 +112,8 @@ nouveau_clear(GLcontext *ctx, GLbitfield buffers)
                        mask = pack_zs_i(s->format,
                                         (buffers & BUFFER_BIT_DEPTH &&
                                          ctx->Depth.Mask) ? ~0 : 0,
-                                        (buffers & BUFFER_BIT_STENCIL &&
-                                         ctx->Stencil.WriteMask[0]) ? ~0 : 0);
+                                        (buffers & BUFFER_BIT_STENCIL ?
+                                         ctx->Stencil.WriteMask[0] : 0));
                        value = pack_zs_f(s->format,
                                          ctx->Depth.Clear,
                                          ctx->Stencil.Clear);