SPARK  0.1.0
A general purpose game engine written in C++.
Loading...
Searching...
No Matches
spark::render::vk::VulkanSurface Class Referencefinal

Implementation of ISurface for Vulkan. More...

#include <VulkanSurface.h>

Inheritance diagram for spark::render::vk::VulkanSurface:
spark::render::ISurface spark::render::Resource< VkSurfaceKHR > spark::render::IResource< VkSurfaceKHR >

Classes

struct  Impl
 

Public Member Functions

 VulkanSurface (const VkSurfaceKHR &surface, const VkInstance &instance)
 Initializes the surface from a surface, instance and window handle.
 
 VulkanSurface (const VulkanSurface &other)=delete
 
 VulkanSurface (VulkanSurface &&other) noexcept=delete
 
VulkanSurfaceoperator= (const VulkanSurface &other)=delete
 
VulkanSurfaceoperator= (VulkanSurface &&other) noexcept=delete
 
const VkInstance & instance () const noexcept
 Gets the backend handle from which the surface was created.
 
- Public Member Functions inherited from spark::render::Resource< VkSurfaceKHR >
 Resource (VkSurfaceKHR handle) noexcept
 Initializes the managed resource with the given handle.
 
 Resource (const Resource &other)=delete
 
 Resource (Resource &&other) noexcept=delete
 
Resourceoperator= (const Resource &other)=delete
 
Resourceoperator= (Resource &&other) noexcept=delete
 
const VkSurfaceKHR & handle () const final
 Gets the managed resource handle.
 

Additional Inherited Members

- Public Types inherited from spark::render::IResource< VkSurfaceKHR >
using handle_type
 
- Protected Member Functions inherited from spark::render::Resource< VkSurfaceKHR >
VkSurfaceKHR & handle () final
 Gets the managed resource handle.
 

Detailed Description

Implementation of ISurface for Vulkan.

Constructor & Destructor Documentation

◆ VulkanSurface()

spark::render::vk::VulkanSurface::VulkanSurface ( const VkSurfaceKHR & surface,
const VkInstance & instance )

Initializes the surface from a surface, instance and window handle.

Parameters
surfaceA VulkanSurfaceKHR handle to the vulkan surface.
instanceA VkInstance handle to the parent instance.

Member Function Documentation

◆ instance()

const VkInstance & spark::render::vk::VulkanSurface::instance ( ) const
nodiscardnoexcept

Gets the backend handle from which the surface was created.

Returns
A VkInstance handle to the parent instance, from which the surface was created.