1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-01-19 05:52:11 +01:00

[d3d11] Mark raw and structured buffers as potential storage buffers

This commit is contained in:
Philip Rebohle 2018-12-13 14:00:40 +01:00
parent 0d230eb447
commit 3fff5d56b3
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99

View File

@ -73,6 +73,11 @@ namespace dxvk {
info.access |= VK_ACCESS_INDIRECT_COMMAND_READ_BIT; info.access |= VK_ACCESS_INDIRECT_COMMAND_READ_BIT;
} }
if (pDesc->MiscFlags & (
D3D11_RESOURCE_MISC_BUFFER_ALLOW_RAW_VIEWS |
D3D11_RESOURCE_MISC_BUFFER_STRUCTURED))
info.usage |= VK_BUFFER_USAGE_STORAGE_BUFFER_BIT;
// Default constant buffers may get updated frequently, in which // Default constant buffers may get updated frequently, in which
// case mapping the buffer is faster than using update commands. // case mapping the buffer is faster than using update commands.
VkMemoryPropertyFlags memoryFlags = GetMemoryFlagsForUsage(pDesc->Usage); VkMemoryPropertyFlags memoryFlags = GetMemoryFlagsForUsage(pDesc->Usage);