vkd3d: Validate tiled resources support during reserved resource creation.

Check directly for Vulkan support because the D3D12 tiled resources
tier may in future be modified by a config option.
This commit is contained in:
Conor McCarthy
2023-06-13 00:21:44 +10:00
committed by Alexandre Julliard
parent e93f2e7746
commit 1a0d85b8d6
Notes: Alexandre Julliard 2023-06-27 23:33:57 +02:00
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Henri Verbeet (@hverbeet)
Approved-by: Alexandre Julliard (@julliard)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/216
3 changed files with 10 additions and 1 deletions

View File

@@ -1740,6 +1740,12 @@ static HRESULT d3d12_resource_init(struct d3d12_resource *resource, struct d3d12
resource->desc = *desc;
if (!heap_properties && !device->vk_info.sparse_binding)
{
WARN("The device does not support tiled images.\n");
return E_INVALIDARG;
}
if (heap_properties && !d3d12_resource_validate_heap_properties(resource, heap_properties, initial_state))
return E_INVALIDARG;