summaryrefslogtreecommitdiffstats
path: root/src/video_core/renderer_vulkan
diff options
context:
space:
mode:
authorRodrigo Locatti <reinuseslisp@airmail.cc>2021-04-12 01:41:48 +0200
committerGitHub <noreply@github.com>2021-04-12 01:41:48 +0200
commit9f1cf99ea079cab4f176c35de6b23f029fbc0021 (patch)
treed3ec12a992f37947c6f6c2f9f84231876e77202d /src/video_core/renderer_vulkan
parentMerge pull request #6170 from Morph1984/more-time-fixes (diff)
parentvk_buffer_cache: Fix offset for NULL vertex buffers (diff)
downloadyuzu-9f1cf99ea079cab4f176c35de6b23f029fbc0021.tar
yuzu-9f1cf99ea079cab4f176c35de6b23f029fbc0021.tar.gz
yuzu-9f1cf99ea079cab4f176c35de6b23f029fbc0021.tar.bz2
yuzu-9f1cf99ea079cab4f176c35de6b23f029fbc0021.tar.lz
yuzu-9f1cf99ea079cab4f176c35de6b23f029fbc0021.tar.xz
yuzu-9f1cf99ea079cab4f176c35de6b23f029fbc0021.tar.zst
yuzu-9f1cf99ea079cab4f176c35de6b23f029fbc0021.zip
Diffstat (limited to 'src/video_core/renderer_vulkan')
-rw-r--r--src/video_core/renderer_vulkan/vk_buffer_cache.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/video_core/renderer_vulkan/vk_buffer_cache.cpp b/src/video_core/renderer_vulkan/vk_buffer_cache.cpp
index 668633e7b..8cb65e588 100644
--- a/src/video_core/renderer_vulkan/vk_buffer_cache.cpp
+++ b/src/video_core/renderer_vulkan/vk_buffer_cache.cpp
@@ -176,7 +176,7 @@ void BufferCacheRuntime::BindVertexBuffer(u32 index, VkBuffer buffer, u32 offset
u32 stride) {
if (device.IsExtExtendedDynamicStateSupported()) {
scheduler.Record([index, buffer, offset, size, stride](vk::CommandBuffer cmdbuf) {
- const VkDeviceSize vk_offset = offset;
+ const VkDeviceSize vk_offset = buffer != VK_NULL_HANDLE ? offset : 0;
const VkDeviceSize vk_size = buffer != VK_NULL_HANDLE ? size : VK_WHOLE_SIZE;
const VkDeviceSize vk_stride = stride;
cmdbuf.BindVertexBuffers2EXT(index, 1, &buffer, &vk_offset, &vk_size, &vk_stride);