diff options
author | Eric Anholt <[email protected]> | 2020-04-14 11:14:31 -0700 |
---|---|---|
committer | Marge Bot <[email protected]> | 2020-04-23 16:37:50 +0000 |
commit | 5a8718f01b3976e1bc82362a907befef68a7f525 (patch) | |
tree | 41cd79d33265f29d7249464bc946017c6d9a77ac /src/gallium/drivers/freedreno/ir3/ir3_gallium.c | |
parent | bd76a24fd130bb5a45fea72a3041104ccfb4a8d1 (diff) |
freedreno: Make the slice pitch be bytes, not pixels.
Back in a2xx, HW pitches were in pixels, so storing that was reasonable.
Ever since then, the HW wants pitches in bytes, and we have only one
instance of using pitch in pixels in the code (a3xx sysmem path).
Flip things around so that only a2xx has to worry about the cpp for
looking at pitches.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4558>
Diffstat (limited to 'src/gallium/drivers/freedreno/ir3/ir3_gallium.c')
-rw-r--r-- | src/gallium/drivers/freedreno/ir3/ir3_gallium.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/drivers/freedreno/ir3/ir3_gallium.c b/src/gallium/drivers/freedreno/ir3/ir3_gallium.c index 158869a6101..04474097f55 100644 --- a/src/gallium/drivers/freedreno/ir3/ir3_gallium.c +++ b/src/gallium/drivers/freedreno/ir3/ir3_gallium.c @@ -369,7 +369,7 @@ ir3_emit_image_dims(struct fd_screen *screen, const struct ir3_shader_variant *v * be the same, so use original dimensions for y and z * stride: */ - dims[off + 1] = slice->pitch * rsc->layout.cpp; + dims[off + 1] = slice->pitch; /* see corresponding logic in fd_resource_offset(): */ if (rsc->layout.layer_first) { dims[off + 2] = rsc->layout.layer_size; |