improve swapchain framebuffer creation
This commit is contained in:
parent
b31dd0d797
commit
7dc9a329ad
1 changed files with 5 additions and 3 deletions
|
@ -937,7 +937,9 @@ bool create_graphics_pipeline(void) {
|
|||
bool create_framebuffers(void) {
|
||||
m_swapchain_framebuffers = PTK_LIST_NEW(VkFramebuffer, m_swapchain_image_views.size);
|
||||
|
||||
PTK_LIST_FOR_EACH_E(VkImageView, m_swapchain_image_views, i, swapchain_image_view, {
|
||||
VkFramebuffer fb;
|
||||
|
||||
PTK_LIST_FOR_EACH(VkImageView, m_swapchain_image_views, swapchain_image_view, {
|
||||
VK_TRY(false,
|
||||
vkCreateFramebuffer(
|
||||
g_dev,
|
||||
|
@ -953,10 +955,10 @@ bool create_framebuffers(void) {
|
|||
.layers = 1,
|
||||
},
|
||||
NULL,
|
||||
&m_swapchain_framebuffers.data[i]
|
||||
&fb
|
||||
)
|
||||
);
|
||||
m_swapchain_framebuffers.size += 1;
|
||||
PTK_LIST_ADD(VkFramebuffer, m_swapchain_framebuffers, fb);
|
||||
})
|
||||
|
||||
return true;
|
||||
|
|
Loading…
Reference in a new issue