|
| Window (const vk::Instance &instance, const vk::Device &device, const vk::PhysicalDevice &physicalDevice, uint32_t graphicsQueueFamilyIndex, GLFWwindow *window) |
| Construct a window, surface and swapchain using a GLFW window.
|
|
| Window (const vk::Instance &instance, const vk::Device &device, const vk::PhysicalDevice &physicalDevice, uint32_t graphicsQueueFamilyIndex, vk::SurfaceKHR surface) |
|
void | init (const vk::Instance &instance, const vk::Device &device, const vk::PhysicalDevice &physicalDevice, uint32_t graphicsQueueFamilyIndex, vk::SurfaceKHR surface) |
|
void | dumpCaps (std::ostream &os, vk::PhysicalDevice pd) const |
| Dump the capabilities of the physical device used by this window.
|
|
void | setStaticCommands (const std::function< renderFunc_t > &func) |
| Build a static draw buffer. This will be rendered after any dynamic content generated in draw()
|
|
void | draw (const vk::Device &device, const vk::Queue &graphicsQueue, const std::function< void(vk::CommandBuffer cb, int imageIndex, vk::RenderPassBeginInfo &rpbi)> &dynamic=defaultRenderFunc) |
|
uint32_t | presentQueueFamily () const |
| Return the queue family index used to present the surface to the display.
|
|
const vk::Queue | presentQueue () const |
| Get the queue used to submit graphics jobs.
|
|
bool | ok () const |
| Return true if this window was created sucessfully.
|
|
vk::RenderPass | renderPass () const |
| Return the renderpass used by this window.
|
|
const std::vector< vk::UniqueFramebuffer > & | framebuffers () const |
| Return the frame buffers used by this window.
|
|
| ~Window () |
| Destroy resources when shutting down.
|
|
Window & | operator= (Window &&rhs)=default |
|
uint32_t | width () const |
| Return the width of the display.
|
|
uint32_t | height () const |
| Return the height of the display.
|
|
vk::Format | swapchainImageFormat () const |
| Return the format of the back buffer.
|
|
vk::ColorSpaceKHR | swapchainColorSpace () const |
| Return the colour space of the back buffer (Usually sRGB)
|
|
const vk::SwapchainKHR | swapchain () const |
| Return the swapchain object.
|
|
const std::vector< vk::ImageView > & | imageViews () const |
| Return the views of the swap chain images.
|
|
const std::vector< vk::Image > & | images () const |
| Return the swap chain images.
|
|
const std::vector< vk::UniqueCommandBuffer > & | commandBuffers () const |
| Return the static command buffers.
|
|
const std::vector< vk::Fence > & | commandBufferFences () const |
| Return the fences used to control the static buffers.
|
|
vk::Semaphore | imageAcquireSemaphore () const |
| Return the semaphore signalled when an image is acquired.
|
|
vk::Semaphore | commandCompleteSemaphore () const |
| Return the semaphore signalled when the command buffers are finished.
|
|
vk::CommandPool | commandPool () const |
| Return a defult command Pool to use to create new command buffers.
|
|
int | numImageIndices () const |
| Return the number of swap chain images.
|
|
This class wraps a window, a surface and a swap chain for that surface.