summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorKeith Whitwell <[email protected]>2005-05-12 09:07:12 +0000
committerKeith Whitwell <[email protected]>2005-05-12 09:07:12 +0000
commit714be699be31352af0faef0d99d11b8c4364ef00 (patch)
tree9000f660a43d6cebb616762ebf066871664bc1e5 /src/mesa
parent10432bcc0a2c89916bc98921bcf01e0fbb422dc5 (diff)
Add check for mask == NULL to the one routine missing it.
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/common/depthtmp.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/common/depthtmp.h b/src/mesa/drivers/dri/common/depthtmp.h
index 74273165e45..93088293232 100644
--- a/src/mesa/drivers/dri/common/depthtmp.h
+++ b/src/mesa/drivers/dri/common/depthtmp.h
@@ -153,8 +153,17 @@ static void TAG(WriteDepthPixels)( GLcontext *ctx,
#else
HW_CLIPLOOP()
{
- for ( i = 0 ; i < n ; i++ ) {
- if ( mask[i] ) {
+ if ( mask ) {
+ for ( i = 0 ; i < n ; i++ ) {
+ if ( mask[i] ) {
+ const int fy = Y_FLIP( y[i] );
+ if ( CLIPPIXEL( x[i], fy ) )
+ WRITE_DEPTH( x[i], fy, depth[i] );
+ }
+ }
+ }
+ else {
+ for ( i = 0 ; i < n ; i++ ) {
const int fy = Y_FLIP( y[i] );
if ( CLIPPIXEL( x[i], fy ) )
WRITE_DEPTH( x[i], fy, depth[i] );