vkd3d: Use correct allocation size for memory block.

We cannot use the memory requirement output, since we will zero-clear
memory with a size that might be larger than the VkBuffer size.

Signed-off-by: Hans-Kristian Arntzen <post@arntzen-software.no>
This commit is contained in:
Hans-Kristian Arntzen 2021-06-09 19:56:44 +02:00
parent fda8cba2b8
commit abe0995e88
1 changed files with 1 additions and 1 deletions

View File

@ -417,7 +417,7 @@ static HRESULT vkd3d_memory_allocation_init(struct vkd3d_memory_allocation *allo
flags_info.flags |= VK_MEMORY_ALLOCATE_DEVICE_ADDRESS_BIT_KHR;
}
allocation->resource.size = memory_requirements.size;
allocation->resource.size = info->memory_requirements.size;
if (info->heap_flags & D3D12_HEAP_FLAG_ALLOW_WRITE_WATCH)
{