changeset 619:78411f3b92cd

fix: forgot to bind buffer
author Sam <sam@basx.dev>
date Sat, 29 Apr 2023 17:12:37 +0700
parents 6e07a8649414
children a2afa6337503
files src/semicongine/vulkan/buffer.nim
diffstat 1 files changed, 1 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/semicongine/vulkan/buffer.nim	Sat Apr 29 16:55:46 2023 +0700
+++ b/src/semicongine/vulkan/buffer.nim	Sat Apr 29 17:12:37 2023 +0700
@@ -57,8 +57,7 @@
   buffer.memoryAllocated = true
   debug "Allocating memory for buffer: ", buffer.size, " bytes of type ", memoryType
   buffer.memory = buffer.device.allocate(requirements.size, memoryType)
-  if buffer.memory.canMap:
-    checkVkResult buffer.device.vk.vkBindBufferMemory(buffer.vk, buffer.memory.vk, VkDeviceSize(0))
+  checkVkResult buffer.device.vk.vkBindBufferMemory(buffer.vk, buffer.memory.vk, VkDeviceSize(0))
 
 # currently no support for extended structure and concurrent/shared use
 # (shardingMode = VK_SHARING_MODE_CONCURRENT not supported)