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

Vulkan implementation of IPushConstantsLayout. More...

#include <VulkanPushConstantsLayout.h>

Inheritance diagram for spark::render::vk::VulkanPushConstantsLayout:
spark::render::PushConstantsLayout< VulkanPushConstantsRange > spark::render::IPushConstantsLayout

Classes

struct  Impl
 

Public Member Functions

 VulkanPushConstantsLayout (std::vector< std::unique_ptr< VulkanPushConstantsRange > > &&ranges, unsigned int size)
 Initializes a new VulkanPushConstantsLayout.
 
 VulkanPushConstantsLayout (const VulkanPushConstantsLayout &other)=delete
 
 VulkanPushConstantsLayout (VulkanPushConstantsLayout &&other) noexcept=delete
 
VulkanPushConstantsLayoutoperator= (const VulkanPushConstantsLayout &other)=delete
 
VulkanPushConstantsLayoutoperator= (VulkanPushConstantsLayout &&other) noexcept=delete
 
const VulkanPipelineLayoutpipelineLayout () const
 Gets the parent pipeline layout, the push constants are described for.
 
unsigned size () const noexcept override
 Get the size (in bytes) of the push constants backing memory.
 
const VulkanPushConstantsRangerange (ShaderStage stage) const override
 Get the push constants range associated with the shader stage provided.
 
std::vector< const VulkanPushConstantsRange * > ranges () const noexcept override
 Get all push constants ranges .
 
- Public Member Functions inherited from spark::render::IPushConstantsLayout
std::vector< const IPushConstantsRange * > ranges () const noexcept
 Get all push constants ranges .
 

Additional Inherited Members

- Public Types inherited from spark::render::PushConstantsLayout< VulkanPushConstantsRange >
using PushConstantsRange
 

Detailed Description

Vulkan implementation of IPushConstantsLayout.

Constructor & Destructor Documentation

◆ VulkanPushConstantsLayout()

spark::render::vk::VulkanPushConstantsLayout::VulkanPushConstantsLayout ( std::vector< std::unique_ptr< VulkanPushConstantsRange > > && ranges,
unsigned int size )
explicit

Initializes a new VulkanPushConstantsLayout.

Parameters
rangesThe ranges contained in this layout.
sizeThe overall size (in bytes) of the push constants backing memory.
Exceptions
base::BadArgumentExceptionIf more than one range is specified for the same shader stage.

Member Function Documentation

◆ pipelineLayout()

const VulkanPipelineLayout & spark::render::vk::VulkanPushConstantsLayout::pipelineLayout ( ) const
nodiscard

Gets the parent pipeline layout, the push constants are described for.

Returns
A const reference of the parent pipeline layout.

◆ range()

const VulkanPushConstantsRange & spark::render::vk::VulkanPushConstantsLayout::range ( ShaderStage stage) const
nodiscardoverridevirtual

Get the push constants range associated with the shader stage provided.

Returns
The push constants range associated with the shader stage provided.
Exceptions
spark::base::ArgumentOutOfRangeExceptionif no range is mapped to the provided shader stage.
spark::base::BadArgumentExceptionif stage contains multiple shader stages.

Implements spark::render::PushConstantsLayout< VulkanPushConstantsRange >.

◆ ranges()

std::vector< const VulkanPushConstantsRange * > spark::render::vk::VulkanPushConstantsLayout::ranges ( ) const
nodiscardoverridevirtualnoexcept

◆ size()

unsigned spark::render::vk::VulkanPushConstantsLayout::size ( ) const
nodiscardoverridevirtualnoexcept

Get the size (in bytes) of the push constants backing memory.

Returns
The size (in bytes) of the push constants backing memory.

Implements spark::render::IPushConstantsLayout.