mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 09:38:07 +02:00
radv: don't overallocate depth/stencil formats
For depth/stencil formats the surface layer allocates the stencil separately, so we don't need to include it in the bpe. This reduces the side of d32s8 allocates to something closer to pro. Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
parent
09d7c7be4f
commit
8950fac6ab
1 changed files with 1 additions and 1 deletions
|
|
@ -72,7 +72,7 @@ radv_init_surface(struct radv_device *device,
|
|||
surface->blk_w = vk_format_get_blockwidth(pCreateInfo->format);
|
||||
surface->blk_h = vk_format_get_blockheight(pCreateInfo->format);
|
||||
|
||||
surface->bpe = vk_format_get_blocksize(pCreateInfo->format);
|
||||
surface->bpe = vk_format_get_blocksize(vk_format_depth_only(pCreateInfo->format));
|
||||
/* align byte per element on dword */
|
||||
if (surface->bpe == 3) {
|
||||
surface->bpe = 4;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue