From: Roland Scheidegger Date: Fri, 25 Aug 2023 13:46:35 +0000 (+0200) Subject: lavapipe: further limit accurate_a0 hack X-Git-Tag: upstream/23.3.3~2770 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=35b2af0f0bedc0e0784cff775f150e9646423bf1;p=platform%2Fupstream%2Fmesa.git lavapipe: further limit accurate_a0 hack With lavapipe the previous change to only enable the hack when there's no textures bound doesn't work anymore, since we don't have that information when using the texture handles. So add another random state restriction which is sufficient to pass tests. (This really needs a better long term solution.) Reviewed-by: Brian Paul Part-of: --- diff --git a/src/gallium/drivers/llvmpipe/lp_setup_tri.c b/src/gallium/drivers/llvmpipe/lp_setup_tri.c index 007a1f5..c1fc054 100644 --- a/src/gallium/drivers/llvmpipe/lp_setup_tri.c +++ b/src/gallium/drivers/llvmpipe/lp_setup_tri.c @@ -403,7 +403,8 @@ do_triangle_ccw(struct lp_setup_context *setup, key->num_inputs == 1 && (key->inputs[0].interp == LP_INTERP_LINEAR || key->inputs[0].interp == LP_INTERP_PERSPECTIVE) && - setup->fs.current_tex_num == 0) { + setup->fs.current_tex_num == 0 && + setup->cullmode == 0) { float dist0 = v0[0][0] * v0[0][0] + v0[0][1] * v0[0][1]; float dist1 = v1[0][0] * v1[0][0] + v1[0][1] * v1[0][1]; float dist2 = v2[0][0] * v2[0][0] + v2[0][1] * v2[0][1];