1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-02-21 22:54:16 +01:00

[dxvk] vkCmdUpdateBuffer can only be used if both offset and size are aligned to four bytes

This commit is contained in:
Philip Rebohle 2017-12-18 12:44:18 +01:00
parent 1e08c0744f
commit 38b989ec91

View File

@ -470,10 +470,10 @@ namespace dxvk {
this->renderPassEnd(); this->renderPassEnd();
if (size != 0) { if (size != 0) {
// Vulkan specifies that small amounts of data (up to 64kB) // Vulkan specifies that small amounts of data (up to 64kB) can
// can be copied to a buffer directly. Anything larger than // be copied to a buffer directly if the size is a multiple of
// that must be copied through a staging buffer. // four. Anything else must be copied through a staging buffer.
if (size <= 65536) { if ((size <= 65536) && ((size & 0x3) == 0)) {
m_cmd->cmdUpdateBuffer( m_cmd->cmdUpdateBuffer(
buffer->handle(), buffer->handle(),
offset, size, data); offset, size, data);