From 8589935420b4934046911cb1928f0ee89d89912c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B3zef=20Kucia?= Date: Thu, 4 Jul 2019 16:41:08 +0200 Subject: [PATCH] vkd3d: Set VK_BUFFER_USAGE_CONDITIONAL_RENDERING_BIT_EXT for upload buffers. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Józef Kucia Signed-off-by: Henri Verbeet Signed-off-by: Alexandre Julliard --- libs/vkd3d/resource.c | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/libs/vkd3d/resource.c b/libs/vkd3d/resource.c index f0864ab9..9d563303 100644 --- a/libs/vkd3d/resource.c +++ b/libs/vkd3d/resource.c @@ -723,16 +723,13 @@ HRESULT vkd3d_create_buffer(struct d3d12_device *device, | VK_BUFFER_USAGE_VERTEX_BUFFER_BIT | VK_BUFFER_USAGE_INDIRECT_BUFFER_BIT; - if (heap_type == D3D12_HEAP_TYPE_DEFAULT) - { - if (device->vk_info.EXT_conditional_rendering) - buffer_info.usage |= VK_BUFFER_USAGE_CONDITIONAL_RENDERING_BIT_EXT; + if (device->vk_info.EXT_conditional_rendering) + buffer_info.usage |= VK_BUFFER_USAGE_CONDITIONAL_RENDERING_BIT_EXT; - if (device->vk_info.EXT_transform_feedback) - { - buffer_info.usage |= VK_BUFFER_USAGE_TRANSFORM_FEEDBACK_BUFFER_BIT_EXT - | VK_BUFFER_USAGE_TRANSFORM_FEEDBACK_COUNTER_BUFFER_BIT_EXT; - } + if (heap_type == D3D12_HEAP_TYPE_DEFAULT && device->vk_info.EXT_transform_feedback) + { + buffer_info.usage |= VK_BUFFER_USAGE_TRANSFORM_FEEDBACK_BUFFER_BIT_EXT + | VK_BUFFER_USAGE_TRANSFORM_FEEDBACK_COUNTER_BUFFER_BIT_EXT; } if (heap_type == D3D12_HEAP_TYPE_UPLOAD)