diff options
author | Danny Holman <dholman@gymli.org> | 2024-10-25 23:20:31 -0500 |
---|---|---|
committer | Danny Holman <dholman@gymli.org> | 2024-10-25 23:20:31 -0500 |
commit | cf048261bc5169b647f3681e016773d7cc585d38 (patch) | |
tree | d6bbaebf48df5790156864ccc69eed35bb42cf21 | |
parent | b13c7d59a91fa1790f132e08791c31940b475426 (diff) |
render: fix a build bug in the vulkan renderer
Fix a bug causing the build to fail during the compile step of the
Vulkan renderer. The frame number has been moved into the swapchain
struct and no longer exists in the context struct. Therefore, its
initialization should be done inside the swapchain init function.
Signed-off-by: Danny Holman <dholman@gymli.org>
-rw-r--r-- | render/vulkan/context.c | 1 | ||||
-rw-r--r-- | render/vulkan/swapchain.c | 1 |
2 files changed, 1 insertions, 1 deletions
diff --git a/render/vulkan/context.c b/render/vulkan/context.c index c0fa650..afa1648 100644 --- a/render/vulkan/context.c +++ b/render/vulkan/context.c @@ -123,7 +123,6 @@ struct vkcontext* create_vkcontext(struct vklayer_container *vklayers, struct ex log_output(LOG_INFO, "Validation layers disabled"); } - ret->frame = 0; return ret; } diff --git a/render/vulkan/swapchain.c b/render/vulkan/swapchain.c index 18b87a5..1ecb644 100644 --- a/render/vulkan/swapchain.c +++ b/render/vulkan/swapchain.c @@ -81,6 +81,7 @@ struct vkswapchain* create_swapchain(struct vksurface *surface, struct vkdev *de VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT, VK_IMAGE_ASPECT_DEPTH_BIT, 1); + swapchain->frame = 0; log_output(LOG_DEBUG, "Initialized swapchain"); return swapchain; } |