mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
vkd3d: Avoid using VK_WHOLE_SIZE for uniform buffer descriptors.
It is invalid to use VK_WHOLE_SIZE when a buffer is larger than maxUniformBufferRange. Signed-off-by: Józef Kucia <jkucia@codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
f98866f7d8
commit
22330b5414
@ -3404,7 +3404,8 @@ static void d3d12_command_list_set_root_cbv(struct d3d12_command_list *list,
|
||||
resource = vkd3d_gpu_va_allocator_dereference(&list->device->gpu_va_allocator, gpu_address);
|
||||
buffer_info.buffer = resource->u.vk_buffer;
|
||||
buffer_info.offset = gpu_address - resource->gpu_address;
|
||||
buffer_info.range = VK_WHOLE_SIZE;
|
||||
buffer_info.range = resource->desc.Width - buffer_info.offset;
|
||||
buffer_info.range = min(buffer_info.range, vk_info->device_limits.maxUniformBufferRange);
|
||||
|
||||
if (vk_info->KHR_push_descriptor)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user