Module: Mesa Branch: 7.9 Commit: bd009df1cc545e8f461e252784abfd86d0d990b4 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=bd009df1cc545e8f461e252784abfd86d0d990b4
Author: Luca Barbieri <l...@luca-barbieri.com> Date: Sun Sep 19 21:48:28 2010 +0200 auxiliary: fix depth-only and stencil-only clears Depth-only and stencil-only clears should mask out depth/stencil from the output, mask out stencil/input from input, and OR or ADD them together. However, due to a typo they were being ANDed, resulting in zeroing the buffer. --- src/gallium/auxiliary/util/u_surface.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/src/gallium/auxiliary/util/u_surface.c b/src/gallium/auxiliary/util/u_surface.c index af99163..f78b683 100644 --- a/src/gallium/auxiliary/util/u_surface.c +++ b/src/gallium/auxiliary/util/u_surface.c @@ -332,7 +332,7 @@ util_clear_depth_stencil(struct pipe_context *pipe, uint32_t *row = (uint32_t *)dst_map; for (j = 0; j < width; j++) { uint32_t tmp = *row & dst_mask; - *row++ = tmp & (zstencil & ~dst_mask); + *row++ = tmp | (zstencil & ~dst_mask); } dst_map += dst_stride; } _______________________________________________ mesa-commit mailing list mesa-commit@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-commit