Mercurial > games > semicongine
changeset 703:120a1baf2f8d
del: possible bad use of variable
author | Sam <sam@basx.dev> |
---|---|
date | Sun, 21 May 2023 01:04:55 +0700 |
parents | 8a5521174cc0 |
children | 782b4df0d99d |
files | src/semicongine/renderer.nim src/semicongine/vulkan/instance.nim |
diffstat | 2 files changed, 4 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/src/semicongine/renderer.nim Sun May 21 00:33:38 2023 +0700 +++ b/src/semicongine/renderer.nim Sun May 21 01:04:55 2023 +0700 @@ -251,10 +251,9 @@ commandBuffer.beginRenderCommands(renderer.renderPass, renderer.swapchain.currentFramebuffer()) for i in 0 ..< renderer.renderPass.subpasses.len: - var subpass = renderer.renderPass.subpasses[i] - for pipeline in subpass.pipelines.mitems: - commandBuffer.vkCmdBindPipeline(subpass.pipelineBindPoint, pipeline.vk) - commandBuffer.vkCmdBindDescriptorSets(subpass.pipelineBindPoint, pipeline.layout, 0, 1, addr(renderer.scenedata[scene].descriptorSets[pipeline.vk][renderer.swapchain.currentInFlight].vk), 0, nil) + for pipeline in renderer.renderPass.subpasses[i].pipelines.mitems: + commandBuffer.vkCmdBindPipeline(renderer.renderPass.subpasses[i].pipelineBindPoint, pipeline.vk) + commandBuffer.vkCmdBindDescriptorSets(renderer.renderPass.subpasses[i].pipelineBindPoint, pipeline.layout, 0, 1, addr(renderer.scenedata[scene].descriptorSets[pipeline.vk][renderer.swapchain.currentInFlight].vk), 0, nil) debug "Scene buffers:" for (location, buffer) in renderer.scenedata[scene].vertexBuffers.pairs:
--- a/src/semicongine/vulkan/instance.nim Sun May 21 00:33:38 2023 +0700 +++ b/src/semicongine/vulkan/instance.nim Sun May 21 01:04:55 2023 +0700 @@ -58,6 +58,7 @@ for i in layers: if i in getLayers(): availableLayers.add i + debug "Enabled layers: " & $availableLayers var layersC = allocCStringArray(availableLayers) instanceExtensionsC = allocCStringArray(requiredExtensions)