Module: Mesa Branch: main Commit: 09578e141c1fb437829282193bc564e277dc908a URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=09578e141c1fb437829282193bc564e277dc908a
Author: David Rosca <[email protected]> Date: Sat Sep 2 17:19:44 2023 +0200 gallium/auxiliary/vl: Use chroma offset in YUV to RGB weave compute shader Acked-by: Leo Liu <[email protected]> Reviewed-by: Thong Thai <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25258> --- src/gallium/auxiliary/vl/vl_compositor_cs.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/gallium/auxiliary/vl/vl_compositor_cs.c b/src/gallium/auxiliary/vl/vl_compositor_cs.c index ae56a19c0b1..5889f93a72b 100644 --- a/src/gallium/auxiliary/vl/vl_compositor_cs.c +++ b/src/gallium/auxiliary/vl/vl_compositor_cs.c @@ -130,7 +130,7 @@ const char *compute_shader_weave = "DCL SV[0], THREAD_ID\n" "DCL SV[1], BLOCK_ID\n" - "DCL CONST[0..7]\n" + "DCL CONST[0..8]\n" "DCL SVIEW[0..2], 2D_ARRAY, FLOAT\n" "DCL SAMP[0..2]\n" @@ -160,8 +160,9 @@ const char *compute_shader_weave = /* Top UV */ "MOV TEMP[3].xy, TEMP[2].xyyy\n" + /* Chroma offset */ + "ADD TEMP[3].xy, TEMP[3].xyyy, CONST[8].xyxy\n" "DIV TEMP[3].xy, TEMP[3], IMM[1].yyyy\n" - "TRUNC TEMP[3].xy, TEMP[3].xyyy\n" "DIV TEMP[3].y, TEMP[3].yyyy, IMM[1].yyyy\n" /* Down UV */ "MOV TEMP[13].xy, TEMP[3].xyyy\n"
