Mesa (main): st/mesa: fix pbo download store image type

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Wed Aug 11 23:57:00 UTC 2021


Module: Mesa
Branch: main
Commit: fdc5138256aa68dde9ea068f7137023708bbceac
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=fdc5138256aa68dde9ea068f7137023708bbceac

Author: Ilia Mirkin <imirkin at alum.mit.edu>
Date:   Tue Aug 10 21:02:43 2021 -0400

st/mesa: fix pbo download store image type

There's generally not too big of a difference between 1D (default) and
buffer, but can't hurt to be accurate.

Signed-off-by: Ilia Mirkin <imirkin at alum.mit.edu>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12319>

---

 src/mesa/state_tracker/st_pbo.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/mesa/state_tracker/st_pbo.c b/src/mesa/state_tracker/st_pbo.c
index f6d1f34f699..a9d7cec2d8c 100644
--- a/src/mesa/state_tracker/st_pbo.c
+++ b/src/mesa/state_tracker/st_pbo.c
@@ -569,7 +569,8 @@ create_fs(struct st_context *st, bool download,
                             nir_vec4(&b, pbo_addr, zero, zero, zero),
                             zero,
                             result,
-                            nir_imm_int(&b, 0));
+                            nir_imm_int(&b, 0),
+                            .image_dim = GLSL_SAMPLER_DIM_BUF);
    } else {
       nir_variable *color =
          nir_variable_create(b.shader, nir_var_shader_out, glsl_vec4_type(),



More information about the mesa-commit mailing list