Module: Mesa
Branch: master
Commit: cc298023c9b302a7a24ee01fe2da1c93f5b44666
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=cc298023c9b302a7a24ee01fe2da1c93f5b44666

Author: Eric Anholt <e...@anholt.net>
Date:   Mon Oct 20 21:14:57 2014 +0100

vc4: Fix stencil writemask handling.

If the writemask doesn't compress, then we want to put in the uncompressed
writemask, not the compressed writemask failure value (all-on).

Fixes glean's stencil2 and fbo-clear-formats on stencil.

---

 src/gallium/drivers/vc4/vc4_state.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/gallium/drivers/vc4/vc4_state.c 
b/src/gallium/drivers/vc4/vc4_state.c
index 99b5b3c..bbbb73d 100644
--- a/src/gallium/drivers/vc4/vc4_state.c
+++ b/src/gallium/drivers/vc4/vc4_state.c
@@ -223,8 +223,8 @@ vc4_create_depth_stencil_alpha_state(struct pipe_context 
*pctx,
 
                 if (front_writemask_bits == 0xff ||
                     back_writemask_bits == 0xff) {
-                        so->stencil_uniforms[2] = (front_writemask_bits |
-                                                   (back_writemask_bits << 8));
+                        so->stencil_uniforms[2] = (front->writemask |
+                                                   (back_writemask << 8));
                 }
         }
 

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to