From 5306b662dd59ac8accccf25b81ee97742ce71849 Mon Sep 17 00:00:00 2001 From: Ilia Mirkin Date: Sat, 29 Feb 2020 22:08:14 -0500 Subject: [PATCH] mesa: fix _mesa_draw_nonzero_divisor_bits to return nonzero divisors MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit The bitmask is _EffEnabledNonZeroDivisor, so no need to invert it before returning. Fixes: fd6636ebc06d (st/mesa: simplify determination whether a draw needs min/max index) Signed-off-by: Ilia Mirkin Reviewed-by: Marek Olšák Tested-by: Marge Bot Part-of: --- src/mesa/main/arrayobj.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/main/arrayobj.h b/src/mesa/main/arrayobj.h index 19ab65b3242..3efcd577ae5 100644 --- a/src/mesa/main/arrayobj.h +++ b/src/mesa/main/arrayobj.h @@ -221,7 +221,7 @@ _mesa_draw_nonzero_divisor_bits(const struct gl_context *ctx) { const struct gl_vertex_array_object *const vao = ctx->Array._DrawVAO; assert(vao->NewArrays == 0); - return ~vao->_EffEnabledNonZeroDivisor & ctx->Array._DrawVAOEnabledAttribs; + return vao->_EffEnabledNonZeroDivisor & ctx->Array._DrawVAOEnabledAttribs; } -- 2.30.2