Mercurial > games > semicongine
comparison tests/test_rendering.nim @ 1285:6d16003406fb
add: missing destroy-function for renderpass
author | sam <sam@basx.dev> |
---|---|
date | Mon, 29 Jul 2024 20:21:00 +0700 |
parents | 0369fa1ffbd9 |
children | 6d0162bfe48a |
comparison
equal
deleted
inserted
replaced
1284:feb52b1c18e0 | 1285:6d16003406fb |
---|---|
757 vkFreeMemory(vulkan.device, depthMemory, nil) | 757 vkFreeMemory(vulkan.device, depthMemory, nil) |
758 if msaaImage.Valid: | 758 if msaaImage.Valid: |
759 vkDestroyImageView(vulkan.device, msaaImageView, nil) | 759 vkDestroyImageView(vulkan.device, msaaImageView, nil) |
760 vkDestroyImage(vulkan.device, msaaImage, nil) | 760 vkDestroyImage(vulkan.device, msaaImage, nil) |
761 vkFreeMemory(vulkan.device, msaaMemory, nil) | 761 vkFreeMemory(vulkan.device, msaaMemory, nil) |
762 vkDestroyRenderPass(vulkan.device, offscreenRP.vk, nil) | 762 destroyRenderPass(offscreenRP) |
763 vkDestroyRenderPass(vulkan.device, presentRP.vk, nil) | 763 destroyRenderPass(presentRP) |
764 vkDestroyFramebuffer(vulkan.device, offscreenFB, nil) | 764 vkDestroyFramebuffer(vulkan.device, offscreenFB, nil) |
765 clearSwapchain() | 765 clearSwapchain() |
766 | 766 |
767 when isMainModule: | 767 when isMainModule: |
768 var time = 1'f32 | 768 var time = 1'f32 |
802 | 802 |
803 # load PNG texture | 803 # load PNG texture |
804 test_07_png_texture(time) | 804 test_07_png_texture(time) |
805 | 805 |
806 checkVkResult vkDeviceWaitIdle(vulkan.device) | 806 checkVkResult vkDeviceWaitIdle(vulkan.device) |
807 vkDestroyRenderPass(vulkan.device, renderpass.vk, nil) | 807 destroyRenderPass(renderpass) |
808 clearSwapchain() | 808 clearSwapchain() |
809 | 809 |
810 # test multiple render passes | 810 # test multiple render passes |
811 for i, (depthBuffer, samples) in renderPasses: | 811 for i, (depthBuffer, samples) in renderPasses: |
812 test_08_triangle_2pass(time, depthBuffer, samples) | 812 test_08_triangle_2pass(time, depthBuffer, samples) |