diff --git a/src/Refresh_Driver_Vulkan.c b/src/Refresh_Driver_Vulkan.c index bab452a..f9639fa 100644 --- a/src/Refresh_Driver_Vulkan.c +++ b/src/Refresh_Driver_Vulkan.c @@ -7882,6 +7882,14 @@ static void VULKAN_SetBufferData( vulkanBuffer ); + // this janky call will wait for transfer writes to finish! + VULKAN_INTERNAL_BufferMemoryBarrier( + renderer, + vulkanCommandBuffer->commandBuffer, + RESOURCE_ACCESS_TRANSFER_WRITE, + vulkanBuffer + ); + bufferCopy.srcOffset = transferBuffer->offset; bufferCopy.dstOffset = offsetInBytes; bufferCopy.size = (VkDeviceSize) dataLength;