mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-22 20:00:10 +01:00
panfrost: Identify texture layout field
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4680>
This commit is contained in:
parent
ad4024968e
commit
36d49b1fb1
3 changed files with 6 additions and 9 deletions
|
|
@ -271,7 +271,7 @@ panfrost_new_texture_bifrost(
|
|||
descriptor->width = MALI_POSITIVE(u_minify(width, first_level));
|
||||
descriptor->height = MALI_POSITIVE(u_minify(height, first_level));
|
||||
descriptor->swizzle = swizzle;
|
||||
descriptor->unk0 = 0x1;
|
||||
descriptor->layout = layout;
|
||||
descriptor->levels = last_level - first_level;
|
||||
descriptor->unk1 = 0x0;
|
||||
descriptor->levels_unk = 0;
|
||||
|
|
|
|||
|
|
@ -1255,7 +1255,7 @@ struct bifrost_texture_descriptor {
|
|||
|
||||
/* OpenGL swizzle */
|
||||
unsigned swizzle : 12;
|
||||
unsigned unk0 : 4; /* 1 */
|
||||
enum mali_texture_layout layout : 4;
|
||||
uint8_t levels : 8; /* Number of levels-1 if mipmapped, 0 if not */
|
||||
unsigned unk1 : 4;
|
||||
|
||||
|
|
|
|||
|
|
@ -2161,7 +2161,6 @@ pandecode_bifrost_texture(const struct bifrost_texture_descriptor *t, unsigned j
|
|||
pandecode_prop("width = %" PRId32, t->width);
|
||||
pandecode_prop("height = %" PRId32, t->height);
|
||||
pandecode_prop("swizzle = 0x%" PRIx32, t->swizzle);
|
||||
pandecode_prop("unk0 = 0x%" PRIx32, t->unk0);
|
||||
pandecode_prop("levels = %" PRId32, t->levels);
|
||||
pandecode_prop("unk1 = 0x%" PRIx32, t->unk1);
|
||||
pandecode_prop("levels_unk = %" PRId32, t->levels_unk);
|
||||
|
|
@ -2178,19 +2177,17 @@ pandecode_bifrost_texture(const struct bifrost_texture_descriptor *t, unsigned j
|
|||
bool is_cube = t->type == MALI_TEX_CUBE;
|
||||
unsigned dimension = is_cube ? 2 : t->type;
|
||||
|
||||
#if 0
|
||||
/* Print the layout. Default is linear; a modifier can denote AFBC or
|
||||
* u-interleaved/tiled modes */
|
||||
|
||||
if (f.layout == MALI_TEXTURE_AFBC)
|
||||
if (t->layout == MALI_TEXTURE_AFBC)
|
||||
pandecode_log_cont("afbc");
|
||||
else if (f.layout == MALI_TEXTURE_TILED)
|
||||
else if (t->layout == MALI_TEXTURE_TILED)
|
||||
pandecode_log_cont("tiled");
|
||||
else if (f.layout == MALI_TEXTURE_LINEAR)
|
||||
else if (t->layout == MALI_TEXTURE_LINEAR)
|
||||
pandecode_log_cont("linear");
|
||||
else
|
||||
pandecode_msg("XXX: invalid texture layout 0x%X\n", f.layout);
|
||||
#endif
|
||||
pandecode_msg("XXX: invalid texture layout 0x%X\n", t->layout);
|
||||
|
||||
pandecode_swizzle(t->swizzle, t->format);
|
||||
pandecode_log_cont(" ");
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue