mirror of
https://github.com/seekrs/MacroLibX.git
synced 2026-01-11 22:53:34 +00:00
fixing window resizing
This commit is contained in:
@@ -27,6 +27,7 @@ namespace mlx
|
||||
if(m_resize)
|
||||
{
|
||||
RenderCore::Get().WaitDeviceIdle();
|
||||
Destroy();
|
||||
CreateSwapchain();
|
||||
EventBus::SendBroadcast(Internal::ResizeEventBroadcast{});
|
||||
}
|
||||
@@ -76,8 +77,6 @@ namespace mlx
|
||||
extent = { size.x, size.y };
|
||||
} while(extent.width == 0 || extent.height == 0);
|
||||
|
||||
Destroy();
|
||||
|
||||
m_surface = p_window->CreateVulkanSurface(RenderCore::Get().GetInstance());
|
||||
DebugLog("Vulkan: surface created");
|
||||
m_swapchain = kvfCreateSwapchainKHR(RenderCore::Get().GetDevice(), RenderCore::Get().GetPhysicalDevice(), m_surface, extent, VK_NULL_HANDLE, false);
|
||||
|
||||
Reference in New Issue
Block a user