90 void destroy(VkDevice device)
override;
110 VkRenderPass renderpass)
override;
147 VkResult
aquireImage(uint32_t index, VkDevice device,
148 VkSemaphore imageAvailableSemaphore,
149 VkFence inFlightFence,
150 uint32_t &imageIndex)
override;
225 GLFWwindow *_referenceWindow;
230 VkSampleCountFlagBits _msaaSamples = VK_SAMPLE_COUNT_1_BIT;
236 bool _framebufferResized =
false;
243 static std::unordered_map<GLFWwindow *, DesktopSwapchainContext *>
255 static void framebufferSizeCallback(GLFWwindow *window,
int width,
Represents the context for managing the swapchain in the rendering system.
Swapchain context for desktop platforms using GLFW.
void recreateSwapchain(const DeviceContext &deviceContext, VkRenderPass renderpass) override
Recreates the swapchain and associated resources.
void destroy(VkDevice device) override
Destroys the swapchain and releases associated resources.
ViewSet & getViewSet() override
Retrieves the set of views to render (mutable).
VkSampleCountFlagBits getMsaaSamples() const override
Retrieves the MSAA sample count used by this swapchain context.
VkResult aquireImage(uint32_t index, VkDevice device, VkSemaphore imageAvailableSemaphore, VkFence inFlightFence, uint32_t &imageIndex) override
Acquires the next available image from the swapchain for rendering.
void waitForImage(uint32_t index) override
Waits for the specified image to be available for rendering.
bool needsSwapchainRecreation() const override
Desktop swapchains must be recreated when the GLFW window is resized.
bool usesImageAvailableSemaphore() const override
Desktop swapchains signal the image-available semaphore through vkAcquireNextImageKHR.
Represents the device context for the engine, managing Vulkan-related resources and operations.