Skip to content
Snippets Groups Projects
Commit 1d826d63 authored by Jonathan Marek's avatar Jonathan Marek Committed by Eric Engestrom
Browse files

freedreno/a2xx: fix compressed textures


Two problems:
* Multiply has higher priority than shift
* rsc->layout.format isn't initialized for a2xx

Fixes: 5a8718f0 ("freedreno: Make the slice pitch be bytes, not pixels.")

Signed-off-by: default avatarJonathan Marek <jonathan@marek.ca>
Part-of: <mesa/mesa!5796>
(cherry picked from commit 344e764b)
parent 33a9a040
No related branches found
No related tags found
No related merge requests found
......@@ -4576,7 +4576,7 @@
"description": "freedreno/a2xx: fix compressed textures",
"nominated": true,
"nomination_type": 1,
"resolution": 0,
"resolution": 1,
"master_sha": null,
"because_sha": "5a8718f01b3976e1bc82362a907befef68a7f525"
},
......
......@@ -187,8 +187,8 @@ fd2_sampler_view_create(struct pipe_context *pctx, struct pipe_resource *prsc,
A2XX_SQ_TEX_0_SIGN_Y(fmt.sign) |
A2XX_SQ_TEX_0_SIGN_Z(fmt.sign) |
A2XX_SQ_TEX_0_SIGN_W(fmt.sign) |
A2XX_SQ_TEX_0_PITCH(slice0->pitch >> fdl_cpp_shift(&rsc->layout) *
util_format_get_blockwidth(rsc->layout.format)) |
A2XX_SQ_TEX_0_PITCH((slice0->pitch >> fdl_cpp_shift(&rsc->layout)) *
util_format_get_blockwidth(prsc->format)) |
COND(rsc->layout.tile_mode, A2XX_SQ_TEX_0_TILED);
so->tex1 =
A2XX_SQ_TEX_1_FORMAT(fmt.format) |
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment