Module: Mesa Branch: staging/22.1 Commit: 624c6f94683ccdcc831b717eca98c983d0071f80 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=624c6f94683ccdcc831b717eca98c983d0071f80
Author: Dave Airlie <[email protected]> Date: Fri Jul 22 13:59:11 2022 +1000 llvmpipe: fix aniso cube map arrays. There was a coordinate missing when you have cube map arrays, and aniso sampling. Reviewed-By: Mike Blumenkrantz <[email protected]> Fixes: ce2b711c0a5d ("gallivm: add support for anisotropic sampling.") Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17704> (cherry picked from commit 21dd30569450b05a98c71b116df03c46f29c4da5) --- .pick_status.json | 2 +- src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.pick_status.json b/.pick_status.json index 0717b7e4f8e..28415343620 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -2434,7 +2434,7 @@ "description": "llvmpipe: fix aniso cube map arrays.", "nominated": true, "nomination_type": 1, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "ce2b711c0a5d2c1d595f783e7a7bc92388cef4e7" }, diff --git a/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c b/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c index 004da18867c..940a51d4ee3 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c +++ b/src/gallium/auxiliary/gallivm/lp_bld_sample_soa.c @@ -2390,10 +2390,11 @@ lp_build_sample_aniso(struct lp_build_sample_context *bld, wnz = LLVMBuildSExt(builder, wnz, bld->int_coord_bld.vec_type, ""); wnz = lp_build_any_true_range(&bld->coord_bld, bld->coord_bld.type.length, wnz); lp_build_if(&noloadw0, gallivm, wnz); - LLVMValueRef new_coords[3]; + LLVMValueRef new_coords[4]; new_coords[0] = lp_build_div(coord_bld, lp_build_int_to_float(coord_bld, u_val), width_dim); new_coords[1] = lp_build_div(coord_bld, lp_build_int_to_float(coord_bld, v_val), height_dim); new_coords[2] = coords[2]; + new_coords[3] = coords[3]; /* lookup q in filter table */ LLVMValueRef temp_colors[4];
