SimpleGL  1.1.0
A framework for platform independent rendering
Public Member Functions | List of all members
sgl::Swapchain Class Reference

This class wraps a Vulkan swapchain. More...

#include <swapchain.hpp>

Public Member Functions

 Swapchain (Surface *surface, glm::ivec2 size)
 Creates a new swapchain. More...
 
 ~Swapchain (void)
 Destroys a swapchain. More...
 
VkSwapchainKHR getHandle ()
 Returns the handle of the swapchain. More...
 
SwapchainData getSwapchainData ()
 Returns the swapchain data. More...
 
void acquireNextImage ()
 Updates the index for the swapchain images. More...
 
void present ()
 Presents the swapchain image. More...
 

Detailed Description

This class wraps a Vulkan swapchain.

Definition at line 51 of file swapchain.hpp.

Constructor & Destructor Documentation

sgl::Swapchain::Swapchain ( Surface surface,
glm::ivec2  size 
)

Creates a new swapchain.

Parameters
surfaceThe surface to use.
sizeThe size of the window drawing area.

Definition at line 19 of file swapchain.cpp.

sgl::Swapchain::~Swapchain ( void  )

Destroys a swapchain.

Definition at line 143 of file swapchain.cpp.

Member Function Documentation

void sgl::Swapchain::acquireNextImage ( )

Updates the index for the swapchain images.

Definition at line 163 of file swapchain.cpp.

VkSwapchainKHR sgl::Swapchain::getHandle ( )

Returns the handle of the swapchain.

Returns
The handle of the swapchain.

Definition at line 155 of file swapchain.cpp.

SwapchainData sgl::Swapchain::getSwapchainData ( )

Returns the swapchain data.

Returns
The swapchain data.

Definition at line 159 of file swapchain.cpp.

void sgl::Swapchain::present ( )

Presents the swapchain image.

Definition at line 182 of file swapchain.cpp.


The documentation for this class was generated from the following files: