diff options
Diffstat (limited to 'src/mesa/pipe')
-rw-r--r-- | src/mesa/pipe/softpipe/sp_quad_stencil.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mesa/pipe/softpipe/sp_quad_stencil.c b/src/mesa/pipe/softpipe/sp_quad_stencil.c index 56cc6907b2f..bf72bb23cd0 100644 --- a/src/mesa/pipe/softpipe/sp_quad_stencil.c +++ b/src/mesa/pipe/softpipe/sp_quad_stencil.c @@ -42,42 +42,42 @@ do_stencil_test(const ubyte stencilVals[QUAD_SIZE], unsigned func, break; case PIPE_FUNC_LESS: for (j = 0; j < QUAD_SIZE; j++) { - if ((stencilVals[j] & valMask) < ref) { + if (ref < (stencilVals[j] & valMask)) { passMask |= (1 << j); } } break; case PIPE_FUNC_EQUAL: for (j = 0; j < QUAD_SIZE; j++) { - if ((stencilVals[j] & valMask) == ref) { + if (ref == (stencilVals[j] & valMask)) { passMask |= (1 << j); } } break; case PIPE_FUNC_LEQUAL: for (j = 0; j < QUAD_SIZE; j++) { - if ((stencilVals[j] & valMask) <= ref) { + if (ref <= (stencilVals[j] & valMask)) { passMask |= (1 << j); } } break; case PIPE_FUNC_GREATER: for (j = 0; j < QUAD_SIZE; j++) { - if ((stencilVals[j] & valMask) > ref) { + if (ref > (stencilVals[j] & valMask)) { passMask |= (1 << j); } } break; case PIPE_FUNC_NOTEQUAL: for (j = 0; j < QUAD_SIZE; j++) { - if ((stencilVals[j] & valMask) != ref) { + if (ref != (stencilVals[j] & valMask)) { passMask |= (1 << j); } } break; case PIPE_FUNC_GEQUAL: for (j = 0; j < QUAD_SIZE; j++) { - if ((stencilVals[j] & valMask) >= ref) { + if (ref >= (stencilVals[j] & valMask)) { passMask |= (1 << j); } } |