PVRVk Structs#

ComputePipelinePopulate#

Struct Documentation#

struct ComputePipelinePopulate#

Contains everything needed to define a VkComputePipelineCreateInfo, with provision for all memory required.

Public Functions

inline VkComputePipelineCreateInfo &operator*()#

Dereference operator - returns the underlying vulkan object.

Returns

The vulkan object

inline void init(const ComputePipelineCreateInfo &cpcp)#

Initialize this compute pipeline.

Parameters

cpcp – A framework compute pipeline create param to be generated from

Returns

Returns return if success

Public Members

VkComputePipelineCreateInfo createInfo#

After construction, will contain the ready-to-use create info.

VkPipelineShaderStageCreateInfo _shader#

The pipeline shader stage creation information.

VkSpecializationInfo specializationInfos#

The specialization creation information.

unsigned char specializationInfoData[FrameworkCaps::MaxSpecialisationInfoDataSize]#

Specialization data.

std::vector<VkSpecializationMapEntry> specilizationEntries#

Specialization entry mappings.

Device_::QueueFamily#

Nested Relationships#

This struct is a nested type of Device_.

Struct Documentation#

struct QueueFamily#

Public Members

uint32_t queueFamily#
std::vector<Queue> queues#

GraphicsPipelinePopulate#

Struct Documentation#

struct GraphicsPipelinePopulate#

Contains everything needed to define a VkGraphicsPipelineCreateInfo, with provision for all memory required.

Public Functions

inline GraphicsPipelinePopulate()#

Default constructor.

inline const VkGraphicsPipelineCreateInfo &getVkCreateInfo() const#

Returns the underlying vulkan object.

Returns

The vulkan object

inline bool init(const GraphicsPipelineCreateInfo &gpcp)#

Initialize this graphics pipeline.

Parameters

gpcp – A framework graphics pipeline create param to be generated from

Returns

Returns return if success

RaytracingPipelinePopulate#

Struct Documentation#

struct RaytracingPipelinePopulate#

Contains everything needed to define a VkRayTracingPipelineCreateInfoKHR.

Public Functions

inline VkRayTracingPipelineCreateInfoKHR &operator*()#

Dereference operator - returns the underlying vulkan object.

Returns

The vulkan object

inline void init(const RaytracingPipelineCreateInfo &raytracingPipeline)#

Initialize this ray tracing pipeline.

Parameters

raytracingPipeline – A framework ray tracing pipeline create param to be generated from

Returns

Returns return if success

Public Members

VkRayTracingPipelineCreateInfoKHR createInfo#

After construction, will contain the ready-to-use create info.

std::vector<VkPipelineShaderStageCreateInfo> stages#

Used to store the shader stage vreate info structs in VkPipelineShaderStageCreateInfo format when gathering information from raytracingPipeline.stages, which use PipelineShaderStageCreateInfo.

std::vector<VkRayTracingShaderGroupCreateInfoKHR> shaderGroups#

Used to store the shader group create info structs in VkRayTracingShaderGroupCreateInfoKHR format when gathering information from raytracingPipeline.stages, which use RayTracingShaderGroupCreateInfo.

AccelerationStructureCreateGeometryTypeInfo#

Struct Documentation#

struct AccelerationStructureCreateGeometryTypeInfo#

Public Functions

inline AccelerationStructureCreateGeometryTypeInfo()#

Constructor (zero initialization)

inline AccelerationStructureCreateGeometryTypeInfo(GeometryTypeKHR geometryType, uint32_t maxPrimitiveCount, IndexType indexType, uint32_t maxVertexCount, Format vertexFormat, Bool32 allowsTransforms)#

Constructor.

Parameters
  • size – The buffer creation size

  • usageFlags – The buffer creation usage flags

  • flags – The buffer creation flags

  • sharingMode – The buffer creation sharing mode

  • queueFamilyIndices – A pointer to a list of supported queue families

  • numQueueFamilyIndices – The number of supported queue family indices

inline GeometryTypeKHR getGeometryType() const#
inline void setGeometryType(GeometryTypeKHR geometryType)#
inline uint32_t getMaxPrimitiveCount() const#
inline void setMaxPrimitiveCount(uint32_t maxPrimitiveCount)#
inline IndexType getIndexType() const#
inline void setIndexType(IndexType indexType)#
inline uint32_t getMaxVertexCount() const#
inline void setMaxVertexCount(uint32_t maxVertexCount)#
inline Format getVertexFormat() const#
inline void setVertexFormat(Format vertexFormat)#
inline Bool32 getAllowsTransforms() const#
inline void setAllowsTransforms(Bool32 allowsTransforms)#

AccelerationStructureCreateInfo#

Struct Documentation#

struct AccelerationStructureCreateInfo#

Public Functions

inline AccelerationStructureCreateInfo()#

Constructor (zero initialization)

inline StructureType getSType() const#
inline void setSType(StructureType sType)#
inline VkAccelerationStructureCreateFlagsKHR getCreateFlags() const#
inline void setCompactedSize(VkAccelerationStructureCreateFlagsKHR createFlags)#
inline VkBuffer getBuffer() const#
inline void setBuffer(VkBuffer buffer)#
inline VkDeviceSize getOffset() const#
inline void setOffset(VkDeviceSize offset)#
inline VkDeviceSize getSize() const#
inline void setSize(VkDeviceSize size)#
inline AccelerationStructureTypeKHR getType() const#
inline void setType(AccelerationStructureTypeKHR type)#
inline VkDeviceAddress getDeviceAddress() const#
inline void setDeviceAddress(VkDeviceAddress deviceAddress)#
inline const void *getpNext() const#
inline void setpNext(const void *pNext)#

ApplicationInfo#

Struct Documentation#

struct ApplicationInfo#

Containes application info used for creating vulkan instance.

Public Functions

inline ApplicationInfo()#

Constructor.

inline ApplicationInfo(const std::string &applicationName, uint32_t applicationVersion = 0, const std::string &engineName = nullptr, uint32_t engineVersion = 0, uint32_t apiVersion = 0)#

Constructor.

Parameters
  • applicationName – The name of the application

  • applicationVersion – The version of the application

  • engineName – The name of the engine

  • engineVersion – The version of the engine

  • apiVersion – The api version to be used by the application

inline const std::string &getApplicationName() const#

Get the Application name.

Returns

The application name

inline void setApplicationName(const std::string &inApplicationName)#

Sets the application name.

Parameters

applicationName – The application name to use

inline uint32_t getApplicationVersion() const#

Get the Application version.

Returns

The application version

inline void setApplicationVersion(uint32_t inApplicationVersion)#

Sets the application version.

Parameters

applicationVersion – The application version to use

inline const std::string &getEngineName() const#

Get the Engine name.

Returns

The engine name

inline void setEngineName(const std::string &inEngineName)#

Sets the engine name.

Parameters

engineName – The engine name to use

inline uint32_t getEngineVersion() const#

Get the Engine version.

Returns

The engine version

inline void setEngineVersion(uint32_t inEngineVersion)#

Sets the engine version.

Parameters

engineVersion – The engine version to use

inline uint32_t getApiVersion() const#

Get the api version.

Returns

The api version

inline void setApiVersion(uint32_t inApiVersion)#

Sets the api version.

Parameters

apiVersion – The api version to use

AttachmentDescription#

Inheritance Relationships#

Base Type#

  • private VkAttachmentDescription

Struct Documentation#

struct AttachmentDescription : private VkAttachmentDescription#

Contains attachment configuration of a renderpass (format, loadop, storeop, samples).

Public Functions

inline AttachmentDescription()#

Constructor to undefined layouts/clear/store.

inline AttachmentDescription(const pvrvk::Format format, const pvrvk::ImageLayout initialLayout, const pvrvk::ImageLayout finalLayout, const pvrvk::AttachmentLoadOp loadOp, const pvrvk::AttachmentStoreOp storeOp, const pvrvk::AttachmentLoadOp stencilLoadOp = pvrvk::AttachmentLoadOp::e_DONT_CARE, const pvrvk::AttachmentStoreOp stencilStoreOp = pvrvk::AttachmentStoreOp::e_DONT_CARE, const pvrvk::SampleCountFlags numSamples = pvrvk::SampleCountFlags::e_1_BIT)#

Constructor.

Parameters
  • format – Attachment format

  • initialLayout – The initial layout that the output image will be on. Must match the actual layout of the Image.

  • finalLayout – A layout to transition the image to at the end of this renderpass.

  • loadOp – Color/Depth attachment load operation. For performance, prefer ‘Don’t Care’ if possible for your application.

  • storeOp – Color/Depth attachment store operator. For performance, prefer ‘Don’t Care’ if possible for your application.

  • stencilLoadOp – Stencil load operation. Default is ‘Don’t Care’. Don’t forget to change this if you’re using stencil components.

  • stencilStoreOp – Stencil store operator. Default is ‘Don’t Care’. Don’t forget to change this if you’re using stencil components.

  • numSamples – Number of samples. Default is 1.

inline AttachmentDescriptionFlags getFlags() const#

Get the AttachmentDescriptionFlags.

Returns

A set of AttachmentDescriptionFlags

inline void setFlags(const AttachmentDescriptionFlags &inFlags)#

Set the attachment description flags.

Parameters

inFlags – The attachment description flags

inline Format getFormat() const#

Get the attachment Format.

Returns

The attachment format

inline void setFormat(const Format &inFormat)#

Set the attachment format.

Parameters

inFormat – The attachment format

inline SampleCountFlags getSamples() const#

Get the sample count for the attachment.

Returns

The sample count for the attachment

inline void setSamples(const SampleCountFlags &inSamples)#

Set the attachment sample count flags.

Parameters

inSamples – The attachment sample count flags

inline AttachmentLoadOp getLoadOp() const#

Get the attachment load operation.

Returns

The attachment load operation

inline void setLoadOp(const AttachmentLoadOp &inLoadOp)#

Set the attachment load operation.

Parameters

inLoadOp – The attachment load operation

inline AttachmentStoreOp getStoreOp() const#

Get the attachment store operation.

Returns

The attachment store operation

inline void setStoreOp(const AttachmentStoreOp &inStoreOp)#

Set the attachment store operation.

Parameters

inStoreOp – The attachment store operation

inline AttachmentLoadOp getStencilLoadOp() const#

Get the attachment stencil load operation.

Returns

The attachment stencil load operation

inline void setStencilLoadOp(const AttachmentLoadOp &inStencilLoadOp)#

Set the attachment stencil load operation.

Parameters

inStencilLoadOp – The attachment stencil load operation

inline AttachmentStoreOp getStencilStoreOp() const#

Get the attachment stencil store operation.

Returns

The attachment stencil store operation

inline void setStencilStoreOp(const AttachmentStoreOp &inStencilStoreOp)#

Set the attachment stencil store operation.

Parameters

inStencilStoreOp – The attachment stencil store operation

inline ImageLayout getInitialLayout() const#

Get the attachment initial layout.

Returns

The attachment initial layout

inline void setInitialLayout(const ImageLayout &inInitialLayout)#

Set the attachment initial layout.

Parameters

inInitialLayout – The attachment initial layout

inline ImageLayout getFinalLayout() const#

Get the attachment final layout.

Returns

The attachment final layout

inline void setFinalLayout(const ImageLayout &inFinalLayout)#

Set the attachment final layout.

Parameters

inFinalLayout – The attachment final layout

Public Static Functions

static inline AttachmentDescription createColorDescription(const pvrvk::Format format, const pvrvk::ImageLayout initialLayout = pvrvk::ImageLayout::e_COLOR_ATTACHMENT_OPTIMAL, const pvrvk::ImageLayout finalLayout = pvrvk::ImageLayout::e_COLOR_ATTACHMENT_OPTIMAL, const pvrvk::AttachmentLoadOp loadOp = pvrvk::AttachmentLoadOp::e_CLEAR, const pvrvk::AttachmentStoreOp storeOp = pvrvk::AttachmentStoreOp::e_STORE, const pvrvk::SampleCountFlags numSamples = pvrvk::SampleCountFlags::e_1_BIT)#

Create color description.

Parameters
  • formatColor format

  • initialLayoutColor initial layout

  • finalLayoutColor final layout

  • loadOp – Attachment loadop

  • storeOp – Attachment storeop

  • numSamples – Number of samples

Returns

AttachmentDescription

static inline AttachmentDescription createDepthStencilDescription(const pvrvk::Format format, const pvrvk::ImageLayout initialLayout = pvrvk::ImageLayout::e_DEPTH_STENCIL_ATTACHMENT_OPTIMAL, const pvrvk::ImageLayout finalLayout = pvrvk::ImageLayout::e_DEPTH_STENCIL_ATTACHMENT_OPTIMAL, const pvrvk::AttachmentLoadOp loadOp = pvrvk::AttachmentLoadOp::e_CLEAR, const pvrvk::AttachmentStoreOp storeOp = pvrvk::AttachmentStoreOp::e_DONT_CARE, const pvrvk::AttachmentLoadOp stencilLoadOp = pvrvk::AttachmentLoadOp::e_CLEAR, const pvrvk::AttachmentStoreOp stencilStoreOp = pvrvk::AttachmentStoreOp::e_DONT_CARE, const pvrvk::SampleCountFlags numSamples = pvrvk::SampleCountFlags::e_1_BIT)#

Create depthstencil description.

Parameters
  • format – Attachment format

  • initialLayout – Attachment initial layout

  • finalLayout – Attachment final layout

  • loadOp – Depth load op.

  • storeOp – Depth store op

  • stencilLoadOp – Stencil load op

  • stencilStoreOp – Stencil store op

  • numSamples – Number of samples

Returns

AttachmentDescription

AttachmentReference2#

Inheritance Relationships#

Base Type#

  • private VkAttachmentReference2

Struct Documentation#

struct AttachmentReference2 : private VkAttachmentReference2#

Public Functions

inline AttachmentReference2()#
inline AttachmentReference2(const uint32_t attachment, const ImageLayout layout, const ImageAspectFlags aspectMask)#
inline VkAttachmentReference2 get()#
inline VkAttachmentReference2 *getVkPtr()#
inline void setAttachment(const uint32_t inAttachment)#
inline void setLayout(const ImageLayout inLayout)#
inline void setAspectMask(const ImageAspectFlags inAspectMask)#
inline uint32_t getAttachment() const#
inline ImageLayout getLayout() const#
inline ImageAspectFlags getAspectMask() const#

BindSparseInfo#

Struct Documentation#

struct BindSparseInfo#

BindSparseInfo specifying a sparse binding submission batch.

Public Members

std::vector<SparseBufferMemoryBindInfo> bufferBinds#

Array of SparseBufferMemoryBindInfo structures, indicating sparse buffer bindings to perform.

std::vector<SparseImageOpaqueMemoryBindInfo> imageOpaqueBinds#

Array of SparseImageOpaqueMemoryBindInfo structures, indicating opaque sparse image bindings to perform.

std::vector<SparseImageMemoryBindInfo> imageBinds#

Array of SparseImageMemoryBindInfo structures, indicating sparse image bindings to perform.

std::vector<Semaphore> waitSemaphores#

Array of semaphores upon which to wait on before the sparse binding operations for this batch begin execution.

std::vector<Semaphore> signalSemaphore#

Array of semaphores which will be signaled when the sparse binding operations for this batch have completed execution.

BufferCreateInfo#

Struct Documentation#

struct BufferCreateInfo#

Buffer creation descriptor.

Public Functions

inline BufferCreateInfo()#

Constructor (zero initialization)

inline BufferCreateInfo(pvrvk::DeviceSize size, pvrvk::BufferUsageFlags usageFlags, pvrvk::BufferCreateFlags flags = pvrvk::BufferCreateFlags::e_NONE, SharingMode sharingMode = SharingMode::e_EXCLUSIVE, const uint32_t *queueFamilyIndices = nullptr, uint32_t numQueueFamilyIndices = 0)#

Constructor.

Parameters
  • size – The buffer creation size

  • usageFlags – The buffer creation usage flags

  • flags – The buffer creation flags

  • sharingMode – The buffer creation sharing mode

  • queueFamilyIndices – A pointer to a list of supported queue families

  • numQueueFamilyIndices – The number of supported queue family indices

inline BufferCreateFlags getFlags() const#

Get the buffer creation flags.

Returns

The set of buffer creation flags

inline void setFlags(BufferCreateFlags flags)#

Set the buffer creation flags.

Parameters

flags – The buffer creation flags

inline DeviceSize getSize() const#

Get the buffer creation size.

Returns

The set of buffer creation size

inline void setSize(DeviceSize size)#

Set the buffer creation size.

Parameters

size – The buffer creation size

inline SharingMode getSharingMode() const#

Get the buffer creation sharing mode.

Returns

The set of buffer creation sharing mode

inline void setSharingMode(SharingMode sharingMode)#

Set the buffer creation sharing mode.

Parameters

sharingMode – The buffer creation sharing mode

inline BufferUsageFlags getUsageFlags() const#

Get the buffer creation usage flags.

Returns

The set of buffer creation usage flags

inline void setUsageFlags(BufferUsageFlags usageFlags)#

Set the buffer creation usage flags.

Parameters

usageFlags – The buffer creation usage flags

inline uint32_t getNumQueueFamilyIndices() const#

Get the number of queue family indices pointed to.

Returns

The number of queue family indices pointed to

inline void setNumQueueFamilyIndices(uint32_t numQueueFamilyIndices)#

Set the number of queue family indices pointed to.

Parameters

numQueueFamilyIndices – The number of queue family indices pointed to

inline const uint32_t *getQueueFamilyIndices() const#

Get this buffer creation infos pointer to a list of supported queue family indices.

Returns

A pointer to a list of supported queue family indices

BufferViewCreateInfo#

Struct Documentation#

struct BufferViewCreateInfo#

Buffer view creation descriptor.

Public Functions

inline BufferViewCreateInfo()#

Constructor (zero initialization)

inline BufferViewCreateInfo(const Buffer &buffer, Format format, DeviceSize offset = 0, DeviceSize range = VK_WHOLE_SIZE, BufferViewCreateFlags flags = BufferViewCreateFlags::e_NONE)#

Constructor.

Parameters
  • buffer – The buffer to be used in the buffer view

  • format – The format of the data in the buffer

  • offset – The buffer offset

  • range – The range of the buffer view

  • flags – A set of flags used for creating the buffer view

inline BufferViewCreateFlags getFlags() const#

Get the buffer view creation flags.

Returns

The set of buffer view creation flags

inline void setFlags(BufferViewCreateFlags flags)#

Set the buffer view creation flags.

Parameters

flags – The buffer view creation flags

inline const Buffer &getBuffer() const#

Get Buffer.

Returns

The Buffer used in the buffer view

inline void setBuffer(const Buffer &buffer)#

Set PVRVk Buffer view creation image.

Parameters

buffer – Buffer to use for creating a PVRVk buffer view

inline Format getFormat() const#

Get Buffer view format.

Returns

Buffer view format (Format)

inline void setFormat(Format format)#

Set the Buffer view format for PVRVk Buffer creation.

Parameters

format – The buffer view format to use for creating a PVRVk buffer

inline DeviceSize getOffset() const#

Get the buffer view creation offset.

Returns

The set of buffer view creation offset

inline void setOffset(DeviceSize offset)#

Set the buffer view creation offset.

Parameters

offset – The buffer view creation offset

inline DeviceSize getRange() const#

Get the buffer view creation range.

Returns

The set of buffer view creation range

inline void setRange(DeviceSize range)#

Set the buffer view creation range.

Parameters

range – The buffer view creation range

ClearAttachment#

Inheritance Relationships#

Base Type#

  • private VkClearAttachment

Struct Documentation#

struct ClearAttachment : private VkClearAttachment#

ClearAttachment structures defining the attachments to clear and the clear values to use. Used in Commandbuffer::ClearAttachments command.

Public Functions

ClearAttachment() = default#

Constructor. Initialisation undefined.

inline ClearAttachment(ImageAspectFlags aspectMask, uint32_t colorAttachment, const ClearValue &clearValue)#

Constructor.

Parameters
  • aspectMask – Mask selecting the color, depth and/or stencil aspects of the attachment to be cleared.

  • colorAttachment – Index of the renderpass color attachment. It is only meaningful if VkImageAspectFlags::e_ASPECT_COLOR_BIT is set in aspectMask

  • clearValue – color or depth/stencil value to clear the attachment

inline ImageAspectFlags getAspectMask() const#

Get the attachment aspect masks.

Returns

The attachment aspect mask

inline void setAspectMask(const ImageAspectFlags &inAspectMask)#

Set the attachment aspect masks.

Parameters

inAspectMask – The attachment aspect mask.

inline uint32_t getColorAttachment() const#

Get the attachment color attachment index.

Returns

The attachment color attachment index

inline void setColorAttachment(const uint32_t &inColorAttachment)#

Set the attachment color attachment index.

Parameters

inColorAttachment – The attachment color attachment index.

inline ClearValue getClearValue() const#

Get the attachment clear value.

Returns

The attachment value value

inline void setClearValue(const ClearValue &inClearValue)#

Set the attachment clear value.

Parameters

inClearValue – The attachment clear value.

Public Static Functions

static inline ClearAttachment createStencilClearAttachment(uint32_t stencil)#

Create stencil-clear-attachment factory function.

Parameters

stencil – Stencil clear value

Returns

Returns stencil clear attachment

static inline ClearAttachment createDepthStencilClearAttachment(float depth, uint32_t stencil)#

Create depth-clear-attachment factory function.

Parameters
  • depth – Depth clear value

  • stencil – Stencil clear value

Returns

Returns depth-stencil clear attachment

static inline ClearAttachment createColorClearAttachment(uint32_t colorAttachment, const ClearValue &clearValue)#

Create color-clear-attachmemnt factory function.

Parameters
  • colorAttachment – Index of the renderpass color attachment.

  • clearValueColor clear values

Returns

Returns color clear attachment

ClearColorValue#

Struct Documentation#

struct ClearColorValue#

Contains clear color values (rgba). This is used in Commandbuffer::clearColorImage.

Public Functions

inline ClearColorValue()#

Constructor, Initialise with default r:0, g:0, b:0, a:1.

inline ClearColorValue(float r, float g, float b, float a)#

Constructor, Intialise with rgba floating point.

Parameters
  • r – red component

  • g – green component

  • b – blue component

  • a – alpha component

inline ClearColorValue(int32_t r, int32_t g, int32_t b, int32_t a)#

Constructor, initialise with interger rgba values.

Parameters
  • r – red component

  • g – green component

  • b – blue component

  • a – alpha component

inline ClearColorValue(uint32_t r, uint32_t g, uint32_t b, uint32_t a)#

Constructor, initialise with unsigned interger rgba values.

Parameters
  • r – red component

  • g – green component

  • b – blue component

  • a – alpha component

inline float getR() const#

Get red floating point component.

Returns

Red component

inline void setR(const float r)#

Set red floating point component.

Parameters

r – Red component

inline float getG() const#

Get green floating point component.

Returns

Green component

inline void setG(const float g)#

Set green floating point component.

Parameters

g – green component

inline float getB() const#

Get blue floating point component.

Returns

Blue component

inline void setB(const float b)#

Set blue floating point component.

Parameters

b – Blue component

inline float getA() const#

Get alpha floating point component.

Returns

Alpha component

inline void setA(const float a)#

Set alpha floating point component.

Parameters

a – Alpha component

inline int32_t getRInt() const#

Get red interger component.

Returns

Red component

inline void setR(const int32_t r)#

Set red integer point component.

Parameters

r – Red component

inline int32_t getGInt() const#

Get green interger component.

Returns

Green component

inline void setG(const int32_t g)#

Set green integer point component.

Parameters

g – Green component

inline int32_t getBInt() const#

Get blue interger component.

Returns

Blue component

inline void setB(const int32_t b)#

Set blue integer point component.

Parameters

b – Blue component

inline int32_t getAInt() const#

Get alpha interger component.

Returns

alpha component

inline void setA(const int32_t a)#

Set alpha integer point component.

Parameters

a – alpha component

inline uint32_t getRUint() const#

Get red unsiged interger component.

Returns

Red component

inline void setRUint(const uint32_t r)#

Set red unsiged integer point component.

Parameters

r – Red component

inline uint32_t getGUint() const#

Get green unsiged interger component.

Returns

Green component

inline void setGUint(const uint32_t g)#

Set green unsiged integer point component.

Parameters

g – Green component

inline uint32_t getBUint() const#

Get blue unsiged interger component.

Returns

Blue component

inline void setBUint(const uint32_t b)#

Set blue unsiged integer point component.

Parameters

b – Blue component

inline uint32_t getAUint() const#

Get alpha unsiged interger component.

Returns

Alpha component

inline void setAUint(const uint32_t a)#

Set alpha unsiged integer point component.

Parameters

a – Alpha component

inline const VkClearColorValue &getColor() const#

Get color clear value.

Returns

VkClearColorValue

ClearValue#

Struct Documentation#

struct ClearValue#

The ClearValue struct. Color or depth/stencil value to clear the attachment to.

Public Functions

inline ClearValue()#

Constructor. initialise with rgb: 0 and alpha 1 clear values.

inline ClearValue(float depth, uint32_t stencil)#

Constructor. Initialise with depth stencil clear values.

Parameters
  • depth – Depth clear value

  • stencil – Stencil clear value

inline ClearValue(float r, float g, float b, float a)#

Constructor. Initialise with rgba floating point.

Parameters
  • r – Red component

  • g – Green component

  • b – Blue component

  • a – Alpha component

inline ClearValue(int32_t r, int32_t g, int32_t b, int32_t a)#

Constructor. Initialise with rgba interger.

Parameters
  • r – Red component

  • g – Green component

  • b – Blue component

  • a – Alpha component

inline ClearValue(uint32_t r, uint32_t g, uint32_t b, uint32_t a)#

Constructor. Initialise with rgba unsigned interger.

Parameters
  • r – Red component

  • g – Green component

  • b – Blue component

  • a – Alpha component

inline void setColorValue(float r, float g, float b, float a)#

Set rgba color clear value.

Parameters
  • r – Red component

  • g – Green component

  • b – Blue component

  • a – Alpha component

inline void setDepthStencilValue(float depth = 1.f, uint32_t stencil = 0u)#

Set depth stencil clear value.

Parameters
  • depth – Depth clear value, default 1

  • stencil – Stencil clear value, default 0

inline VkClearValue toVkValue()#

Get vulkan representation of this object.

Returns

Returns vulkan clear value

inline const VkClearValue toVkValue() const#

Get vulkan representation of this object (const)

Returns

Returns (const) vulkan clear value

Public Static Functions

static inline ClearValue createDefaultDepthStencilClearValue()#

Create default depth stencil clear value factory function.

Returns

Returns default depth stencil clear value

static inline ClearValue createStencilClearValue(uint32_t stencil)#

Create stencil clear value factory function.

Parameters

stencil – Stencil clear value

Returns

Returns stencil clear value

static inline ClearValue createDepthStencilClearValue(float depth, uint32_t stencil)#

Create depth-stencil clear value factory function.

Parameters
  • depth – Depth clear value

  • stencil – Stencil value

Returns

Returns depth-stencil clear value

Color#

Struct Documentation#

struct Color#

Floating point Color data (rgba). Values from 0-1 inclusive.

Public Functions

inline Color(float r = 0.f, float g = 0.f, float b = 0.f, float a = 1.f)#

Constructor, default r:0, g:0, b:0, a:1.

Parameters
  • r – Red

  • g – Green

  • b – Blue

  • a – Alpha

inline Color(const float rgba[4])#

Constructor. Initialize with rgba values.

Parameters

rgba – Pointer to rgba values

inline float getR() const#

Get the red component (const)

Returns

The red component

inline float getG() const#

Get green component (const)

Returns

Green component

inline float getB() const#

Get blue component (const)

Returns

Blue component

inline float getA() const#

Get alpha component (const)

Returns

Alpha component

CommandPoolCreateInfo#

Struct Documentation#

struct CommandPoolCreateInfo#

Command pool creation descriptor.

Public Functions

inline explicit CommandPoolCreateInfo(uint32_t queueFamilyIndex, CommandPoolCreateFlags flags = CommandPoolCreateFlags::e_NONE)#

Constructor.

Parameters
  • queueFamilyIndex – Designates a queue family, all command buffers allocated from this command pool must be submitted to queues from the same queue family

  • flags – Flags to use for creating the command pool

inline CommandPoolCreateFlags getFlags() const#

Get the command pool creation flags.

Returns

The set of command pool creation flags

inline void setFlags(CommandPoolCreateFlags flags)#

Set the command pool creation flags.

Parameters

flags – The command pool creation flags

inline uint32_t getQueueFamilyIndex() const#

Get Queue family index.

Returns

The queue family index to which all command buffers allocated from this pool can be submitted to

inline void setQueueFamilyIndex(uint32_t queueFamilyIndex)#

Set the Queue family index.

Parameters

queueFamilyIndex – The queue family index to which all command buffers allocated from this pool can be submitted to

ComputePipelineCreateInfo#

Inheritance Relationships#

Base Type#

Struct Documentation#

struct ComputePipelineCreateInfo : public pvrvk::PipelineCreateInfo<ComputePipeline>#

Compute pipeline create parameters.

Public Functions

inline ComputePipelineCreateInfo()#

Public Members

PipelineShaderStageCreateInfo computeShader#

Compute shader information.

CopyDescriptorSet#

Struct Documentation#

struct CopyDescriptorSet#

Copy descriptor set.

Public Members

DescriptorSet srcSet#

Source descriptor set to copy from.

uint32_t srcBinding#

source binding to copy

uint32_t srcArrayElement#

source array element to copy from

DescriptorSet dstSet#

Destination descriptor set.

uint32_t dstBinding#

Destination binding to copy in to.

uint32_t dstArrayElement#

Destination array element to copy into.

uint32_t descriptorCount#

Number of descriptor to copy.

DebugMarkerMarkerInfo#

Struct Documentation#

struct DebugMarkerMarkerInfo#

DebugMarkerMarkerInfo used to define a debug marker.

Public Functions

inline DebugMarkerMarkerInfo()#

Constructor.

inline DebugMarkerMarkerInfo(const std::string &markerName, float colorR = 183.0f / 255.0f, float colorG = 26.0f / 255.0f, float colorB = 139.0f / 255.0f, float colorA = 1.0f)#

Constructor.

Parameters
  • markerName – The marker name to use

  • colorR – The red color component

  • colorG – The green color component

  • colorB – The blue color component

  • colorA – The alpha color component

inline const std::string &getMarkerName() const#

Get the marker.

Returns

The marker name

inline void setMarkerName(const std::string &markerName)#

Set the label.

Parameters

markerName – A new marker name

inline float getR() const#

Get red floating point component.

Returns

Red component

inline void setR(const float r)#

Set red floating point component.

Parameters

r – Red component

inline float getG() const#

Get green floating point component.

Returns

Green component

inline void setG(const float g)#

Set green floating point component.

Parameters

g – green component

inline float getB() const#

Get blue floating point component.

Returns

Blue component

inline void setB(const float b)#

Set blue floating point component.

Parameters

b – Blue component

inline float getA() const#

Get alpha floating point component.

Returns

Alpha component

inline void setA(const float a)#

Set alpha floating point component.

Parameters

a – Alpha component

DebugReportCallbackCreateInfo#

Struct Documentation#

struct DebugReportCallbackCreateInfo#

DebugReportCallback creation descriptor.

Public Functions

inline DebugReportCallbackCreateInfo()#

Constructor (zero initialization)

inline DebugReportCallbackCreateInfo(DebugReportFlagsEXT flags, PFN_vkDebugReportCallbackEXT callback, void *pUserData = nullptr)#

Constructor.

Parameters
  • flags – A set of DebugReportFlagsEXT which specify the events causing this callback to be called.

  • callback – The application callback function to call.

  • pUserData – The userdata which will be passed to the application callback function.

inline DebugReportFlagsEXT getFlags() const#

Get the flags for the creation info.

Returns

The DebugReportFlagsEXT

inline DebugReportCallbackCreateInfo &setFlags(const DebugReportFlagsEXT &flags)#

Set the DebugReportFlagsEXT which specify the events causing this callback to be called.

Parameters

flags – A set of DebugReportFlagsEXT which specify the events causing this callback to be called.

Returns

this (allow chaining)

inline PFN_vkDebugReportCallbackEXT getCallback() const#

Get the application callback function.

Returns

The PFN_vkDebugReportCallbackEXT callback function

inline DebugReportCallbackCreateInfo &setCallback(const PFN_vkDebugReportCallbackEXT &callback)#

Set the PFN_vkDebugReportCallbackEXT specifying the callback function which will be called.

Parameters

callback – The application callback function to call.

Returns

this (allow chaining)

inline void *getPUserData() const#

Get the user data passed to the callback.

Returns

The userdata which will be passed to the application callback function

inline void setPUserData(void *pUserData)#

Set the user data passed to the callback.

Parameters

pUserData – The userdata which will be passed to the application callback function.

Returns

this (allow chaining)

DebugUtilsLabel#

Struct Documentation#

struct DebugUtilsLabel#

DebugUtilsLabel used to define a label.

Public Functions

inline DebugUtilsLabel()#

Constructor.

inline DebugUtilsLabel(const std::string &labelName, float colorR = 183.0f / 255.0f, float colorG = 26.0f / 255.0f, float colorB = 139.0f / 255.0f, float colorA = 1.0f)#

Constructor.

Parameters
  • labelName – The label to use

  • colorR – The red color component

  • colorG – The green color component

  • colorB – The blue color component

  • colorA – The alpha color component

inline const std::string &getLabelName() const#

Get the label.

Returns

The label name

inline void setLabelName(const std::string &labelName)#

Set the label.

Parameters

labelName – A new label name

inline float getR() const#

Get red floating point component.

Returns

Red component

inline void setR(const float r)#

Set red floating point component.

Parameters

r – Red component

inline float getG() const#

Get green floating point component.

Returns

Green component

inline void setG(const float g)#

Set green floating point component.

Parameters

g – green component

inline float getB() const#

Get blue floating point component.

Returns

Blue component

inline void setB(const float b)#

Set blue floating point component.

Parameters

b – Blue component

inline float getA() const#

Get alpha floating point component.

Returns

Alpha component

inline void setA(const float a)#

Set alpha floating point component.

Parameters

a – Alpha component

DebugUtilsMessengerCallbackData#

Struct Documentation#

struct DebugUtilsMessengerCallbackData#

DebugUtilsMessengerCallbackData callback data structure.

Public Functions

inline DebugUtilsMessengerCallbackData()#

Constructor (zero initialization)

inline DebugUtilsMessengerCallbackData(DebugUtilsMessengerCallbackDataFlagsEXT flags, const std::string &messageIdName, int32_t messageIdNumber, const std::string &message, std::vector<DebugUtilsLabel> &queueLabels, std::vector<DebugUtilsLabel> &cmdBufLabels, std::vector<DebugUtilsObjectNameInfo> &objects)#

Constructor.

Parameters
  • flags – A set of flags reserved for future use.

  • messageIdName – A bitmask specifying the type of events which will cause the callback to be called.

  • messageIdNumber – The application callback function to call.

  • message – The userdata which will be passed to the application callback function.

  • queueLabels – A list of relevant queue labels.

  • cmdBufLabels – A list of relevant command buffer labels.

  • objects – A list of relevant objects.

inline DebugUtilsMessengerCallbackDataFlagsEXT getFlags() const#

Get the message callback flags.

Returns

The message callback flags

inline void setFlags(DebugUtilsMessengerCallbackDataFlagsEXT flags)#

Set the message callback flags.

Parameters

flags – The message callback flags

inline const std::string &getMessageIdName() const#

Get the message id name.

Returns

The id name of the message

inline void setMessageIdName(const std::string &messageIdName)#

Set the id name of the message.

Parameters

messageIdName – A new id name for the message

inline int32_t getMessageIdNumber() const#

Get the message id number.

Returns

The id of the message

inline void setMessageIdName(int32_t messageIdNumber)#

Set the id of the message.

Parameters

messageIdNumber – A new id for the message

inline const std::string &getMessage() const#

Get the message.

Returns

The message

inline void setMessage(const std::string &message)#

Set the message.

Parameters

message – A new message

inline uint32_t getNumQueueLabels() const#

Get the number of queue labels.

Returns

The number of queue labels

inline const std::vector<DebugUtilsLabel> &getQueueLabels() const#

Get the list of queue labels.

Returns

The list of queue labels

inline const DebugUtilsLabel &getQueueLabel(uint32_t index) const#

Get the queue label at the index specified.

Parameters

index – The index of the queue label to retrieve

Returns

The queue label retrieved

inline void setQueueLabels(const std::vector<DebugUtilsLabel> &queueLabels)#

Sets the queue labels list.

Parameters

queueLabels – A list of queue labels to add

inline void addQueueLabel(const DebugUtilsLabel &queueLabel)#

Adds a new queue label to the list of queue labels.

Parameters

queueLabel – A new queue label to add to the existing list of queue labels

inline uint32_t getNumCmdBufLabels() const#

Get the number of cmdBuf labels.

Returns

The number of cmdBuf labels

inline const std::vector<DebugUtilsLabel> &getCmdBufLabels() const#

Get the list of cmdBuf labels.

Returns

The list of cmdBuf labels

inline const DebugUtilsLabel &getCmdBufLabel(uint32_t index) const#

Get the cmdBuf label at the index specified.

Parameters

index – The index of the cmdBuf label to retrieve

Returns

The cmdBuf label retrieved

inline void setCmdBufLabels(const std::vector<DebugUtilsLabel> &cmdBufLabels)#

Sets the cmdBuf labels list.

Parameters

cmdBufLabels – A list of cmdBuf labels to add

inline void addCmdBufLabel(const DebugUtilsLabel &cmdBufLabel)#

Adds a new cmdBuf label to the list of cmdBuf labels.

Parameters

cmdBufLabel – A new cmdBuf label to add to the existing list of cmdBuf labels

inline uint32_t getNumObjects() const#

Get the number of objects.

Returns

The number of objects

inline const std::vector<DebugUtilsObjectNameInfo> &getObjects() const#

Get the list of objects.

Returns

The list of objects

inline const DebugUtilsObjectNameInfo &getObject(uint32_t index) const#

Get the cmdBuf label at the index specified.

Parameters

index – The index of the cmdBuf label to retrieve

Returns

The cmdBuf label retrieved

inline void setObjects(const std::vector<DebugUtilsObjectNameInfo> &objects)#

Sets the objects list.

Parameters

objects – A list of objects to add

inline void addCmdBufLabel(const DebugUtilsObjectNameInfo &cmdBufLabel)#

Adds a new cmdBuf label to the list of objects.

Parameters

cmdBufLabel – A new cmdBuf label to add to the existing list of objects

DebugUtilsMessengerCreateInfo#

Struct Documentation#

struct DebugUtilsMessengerCreateInfo#

DebugUtilsMessengerCreateInfo creation descriptor.

Public Functions

inline DebugUtilsMessengerCreateInfo()#

Constructor (zero initialization)

inline DebugUtilsMessengerCreateInfo(DebugUtilsMessageSeverityFlagsEXT messageSeverity, DebugUtilsMessageTypeFlagsEXT messageType, PFN_vkDebugUtilsMessengerCallbackEXT callback, void *pUserData = nullptr, DebugUtilsMessengerCreateFlagsEXT flags = DebugUtilsMessengerCreateFlagsEXT::e_NONE)#

Constructor.

Parameters
  • messageSeverity – A bitmask specifying which severity of events will cause the callback to be called.

  • messageType – A bitmask specifying the type of events which will cause the callback to be called.

  • callback – The application callback function to call.

  • pUserData – The userdata which will be passed to the application callback function.

  • flags – Reserved for future use.

inline DebugUtilsMessengerCreateFlagsEXT getFlags() const#

Get the flags for the creation info.

Returns

The DebugUtilsMessengerCreateFlagsEXT

inline DebugUtilsMessengerCreateInfo &setFlags(const DebugUtilsMessengerCreateFlagsEXT &flags)#

Set the DebugReportFlagsEXT which are reserved for future use.

Parameters

flags – Reserved for future use.

Returns

this (allow chaining)

inline DebugUtilsMessageSeverityFlagsEXT getMessageSeverity() const#

Get the severity flags for the creation info.

Returns

The DebugUtilsMessageSeverityFlagsEXT

inline DebugUtilsMessengerCreateInfo &setMessageSeverity(const DebugUtilsMessageSeverityFlagsEXT &messageSeverity)#

Set the DebugUtilsMessageSeverityFlagsEXT specifying which severity of events will cause the callback to be called.

Parameters

messageSeverity – A bitmask specifying which severity of events will cause the callback to be called.

Returns

this (allow chaining)

inline DebugUtilsMessageTypeFlagsEXT getMessageType() const#

Get the message type for the creation info.

Returns

The DebugUtilsMessageTypeFlagsEXT

inline DebugUtilsMessengerCreateInfo &setMessageType(const DebugUtilsMessageTypeFlagsEXT &messageType)#

Set the DebugUtilsMessageTypeFlagsEXT specifying the type of events which will cause the callback to be called.

Parameters

messageType – A bitmask specifying the type of events which will cause the callback to be called

Returns

this (allow chaining)

inline PFN_vkDebugUtilsMessengerCallbackEXT getCallback() const#

Get the application callback function.

Returns

The PFN_vkDebugUtilsMessengerCallbackEXT callback function

inline DebugUtilsMessengerCreateInfo &setCallback(const PFN_vkDebugUtilsMessengerCallbackEXT &callback)#

Set the PFN_vkDebugUtilsMessengerCallbackEXT specifying the callback function which will be called.

Parameters

callback – The application callback function to call.

Returns

this (allow chaining)

inline void *getPUserData() const#

Get the user data passed to the callback.

Returns

The userdata which will be passed to the application callback function

inline void setPUserData(void *pUserData)#

Set the user data passed to the callback.

Parameters

pUserData – The userdata which will be passed to the application callback function.

Returns

this (allow chaining)

DebugUtilsObjectNameInfo#

Struct Documentation#

struct DebugUtilsObjectNameInfo#

DebugUtilsObjectNameInfo structure used to set the name associated with an object.

Public Functions

inline DebugUtilsObjectNameInfo()#

Constructor.

inline DebugUtilsObjectNameInfo(ObjectType objectType, uint64_t objectHandle, const std::string &objectName)#

Constructor.

Parameters
  • objectType – The ObjectType of the object

  • objectHandle – The object handle

  • objectName – The name of the object

inline ObjectType getObjectType() const#

Get the object type.

Returns

The object type of the structure

inline void setObjectType(ObjectType objectType)#

Set the type of the object.

Parameters

objectType – A new object type

inline uint64_t getObjectHandle() const#

Get the object handle.

Returns

The object handle of the structure

inline void setObjectHandle(uint64_t objectHandle)#

Set the handle of the object.

Parameters

objectHandle – A new object handle

inline const std::string &getObjectName() const#

Get the object name.

Returns

The object name of the structure

inline void setObjectName(const std::string &objectName)#

Set the name of the object.

Parameters

objectName – A new object name

DebugUtilsObjectTagInfo#

Struct Documentation#

struct DebugUtilsObjectTagInfo#

DebugUtilsObjectTagInfo structure used to set the tag associated with an object.

Public Functions

inline DebugUtilsObjectTagInfo()#

Constructor.

inline DebugUtilsObjectTagInfo(ObjectType objectType, uint64_t objectHandle, uint64_t tagName, size_t tagSize, const void *pTag)#

Constructor.

Parameters
  • objectType – The ObjectType of the object

  • objectHandle – The object handle

  • tagName – The name of the object

  • tagSize – The size of a tag

  • pTag – A tag to use

inline ObjectType getObjectType() const#

Get the object type.

Returns

The object type of the structure

inline void setObjectType(ObjectType objectType)#

Set the type of the object.

Parameters

objectType – A new object type

inline uint64_t getObjectHandle() const#

Get the object handle.

Returns

The object handle of the structure

inline void setObjectHandle(uint64_t objectHandle)#

Set the handle of the object.

Parameters

objectHandle – A new object handle

inline uint64_t getTagName() const#

Get the object tag name.

Returns

The object tag name of the structure

inline void setTagName(uint64_t tagName)#

Set the tag name of the object.

Parameters

tagName – A new object tag name

inline size_t getTagSize() const#

Get the object handle.

Returns

The object handle of the structure

inline void setTagSize(size_t tagSize)#

Set the tag size for the object.

Parameters

tagSize – A new tag size for the object

inline const void *getTag() const#

Get the object tag.

Returns

The object tag of the structure

inline void setTag(const void *tag)#

Set the tag for the object.

Parameters

tag – A new tag for the object handle

DescriptorBufferInfo#

Struct Documentation#

struct DescriptorBufferInfo#

A struct describing a descriptor buffer binding.

Public Functions

inline DescriptorBufferInfo()#

Constructor. Zero initialize.

inline DescriptorBufferInfo(const Buffer &buffer, VkDeviceSize offset, VkDeviceSize range)#

Constructor. Individual elements.

Parameters
  • buffer – The referenced buffer

  • offset – An offset into the buffer, if the buffer is piecemally bound

  • range – A range of the buffer, if the buffer is piecemally bound

Public Members

Buffer buffer#

The buffer object.

VkDeviceSize offset#

The offset into the buffer.

VkDeviceSize range#

The range of the buffer

DescriptorImageInfo#

Struct Documentation#

struct DescriptorImageInfo#

This class contains all the information necessary to populate a Descriptor Set with the actual API objects. Use with the method update of the DescriptorSet. Populate this object with actual Descriptor objects (UBOs, textures etc).

Public Functions

inline DescriptorImageInfo()#

Constructor. Initalizes to pvrvk::ImageLayout::e_UNDEFINED.

inline explicit DescriptorImageInfo(const Sampler &sampler)#

Constructor from a sampler object.

Parameters

sampler – Sampler handle, and is used in descriptor updates for types pvrvk::DescriptorType::e_SAMPLER and pvrvk::DescriptorType::e_COMBINED_IMAGE_SAMPLER if the binding being updated does not use immutable samplers

inline DescriptorImageInfo(const ImageView &imageView, const Sampler &sampler, pvrvk::ImageLayout imageLayout = pvrvk::ImageLayout::e_SHADER_READ_ONLY_OPTIMAL)#

Constructor from all elements.

Parameters
  • imageView – Image view handle, and is used in descriptor updates for types pvrvk::DescriptorType::e_SAMPLED_IMAGE, pvrvk::DescriptorType::e_STORAGE_IMAGE, pvrvk::DescriptorType::e_COMBINED_IMAGE_SAMPLER, and pvrvk::DescriptorType::e_INPUT_ATTACHMENT

  • sampler – Sampler handle, and is used in descriptor updates for types pvrvk::DescriptorType::e_SAMPLER and pvrvk::DescriptorType::e_COMBINED_IMAGE_SAMPLER if the binding being updated does not use immutable samplers

  • imageLayout – Layout that the image subresources accessible from imageView will be in at the time this descriptor is accessed. imageLayout is used in descriptor updates for types pvrvk::DescriptorType::e_SAMPLED_IMAGE, pvrvk::DescriptorType::e_STORAGE_IMAGE, pvrvk::DescriptorType::e_COMBINED_IMAGE_SAMPLER, and pvrvk::DescriptorType::e_INPUT_ATTACHMENT

inline DescriptorImageInfo(const ImageView &imageView, pvrvk::ImageLayout imageLayout = pvrvk::ImageLayout::e_SHADER_READ_ONLY_OPTIMAL)#

Constructor from all elements except sampler.

Parameters
  • imageView – Image view handle, and is used in descriptor updates for types pvrvk::DescriptorType::e_SAMPLED_IMAGE, pvrvk::DescriptorType::e_STORAGE_IMAGE, pvrvk::DescriptorType::e_COMBINED_IMAGE_SAMPLER, and pvrvk::DescriptorType::e_INPUT_ATTACHMENT

  • imageLayout – Layout that the image subresources accessible from imageView will be in at the time this descriptor is accessed. imageLayout is used in descriptor updates for types pvrvk::DescriptorType::e_SAMPLED_IMAGE, pvrvk::DescriptorType::e_STORAGE_IMAGE, pvrvk::DescriptorType::e_COMBINED_IMAGE_SAMPLER, and pvrvk::DescriptorType::e_INPUT_ATTACHMENT

Public Members

Sampler sampler#

Sampler handle, and is used in descriptor updates for types pvrvk::DescriptorType::e_SAMPLER and pvrvk::DescriptorType::e_COMBINED_IMAGE_SAMPLER if the binding being updated does not use immutable samplers

ImageView imageView#

Image view handle, and is used in descriptor updates for types pvrvk::DescriptorType::e_SAMPLED_IMAGE, pvrvk::DescriptorType::e_STORAGE_IMAGE, pvrvk::DescriptorType::e_COMBINED_IMAGE_SAMPLER, and pvrvk::DescriptorType::e_INPUT_ATTACHMENT

pvrvk::ImageLayout imageLayout#

Layout that the image subresources accessible from imageView will be in at the time this descriptor is accessed. imageLayout is used in descriptor updates for types pvrvk::DescriptorType::e_SAMPLED_IMAGE, pvrvk::DescriptorType::e_STORAGE_IMAGE, pvrvk::DescriptorType::e_COMBINED_IMAGE_SAMPLER, and pvrvk::DescriptorType::e_INPUT_ATTACHMENT

DescriptorPoolCreateInfo#

Struct Documentation#

struct DescriptorPoolCreateInfo#

Descriptor Pool create parameter.

Public Functions

inline DescriptorPoolCreateInfo()#

Constructor.

inline explicit DescriptorPoolCreateInfo(uint16_t maxSets, uint16_t combinedImageSamplers = 32, uint16_t inputAttachments = 0, uint16_t staticUbos = 32, uint16_t dynamicUbos = 32, uint16_t staticSsbos = 0, uint16_t dynamicSsbos = 0)#

Constructor.

Parameters
  • maxSets – The maximum number of descriptor sets which can be allocated by this descriptor pool

  • combinedImageSamplers – The maximum number of combined image samplers descriptor types which can be used in descriptor sets allocated by this descriptor pool.

  • inputAttachments – The maximum number of input attachment descriptor types which can be used in descriptor sets allocated by this descriptor pool.

  • staticUbos – The maximum number of uniform buffer descriptor types which can be used in descriptor sets allocated by this descriptor pool.

  • dynamicUbos – The maximum number of dynamic uniform buffers descriptor types which can be used in descriptor sets allocated by this descriptor pool.

  • staticSsbos – The maximum number of storage buffer descriptor types which can be used in descriptor sets allocated by this descriptor pool.

  • dynamicSsbos – The maximum number of dynamic storage buffer descriptor types which can be used in descriptor sets allocated by this descriptor pool.

inline explicit DescriptorPoolCreateInfo(std::initializer_list<pvrvk::DescriptorPoolSize> descriptorPoolSizes, uint16_t maxSets = 200)#
inline DescriptorPoolCreateInfo &addDescriptorInfo(const pvrvk::DescriptorPoolSize &descriptorPoolSize)#
inline DescriptorPoolCreateInfo &addDescriptorInfo(pvrvk::DescriptorType descType, uint16_t count)#

Add the maximum number of the specified descriptor types that the pool will contain.

Parameters
  • descType – Descriptor type

  • count – Maximum number of descriptors of (type)

Returns

this (allow chaining)

inline DescriptorPoolCreateInfo &setMaxDescriptorSets(uint16_t maxSets)#

Set the maximum number of descriptor sets.

Parameters

maxSets – The maximum number of descriptor sets

Returns

this (allow chaining)

inline uint32_t getNumPoolSizes() const#

Get the number of descriptor pool sizes (const).

Returns

Number of descriptor pool sizes.

inline const pvrvk::DescriptorPoolSize &getPoolSize(uint32_t index) const#

Get the pool size at the given index (const).

Parameters

index – The pool index

Returns

The DescriptorPoolSize at index

inline uint32_t getMaxDescriptorSets() const#

Get maximum sets supported on this pool.

Returns

uint32_t

DescriptorSetLayoutCreateInfo#

Nested Relationships#

Nested Types#

Struct Documentation#

struct DescriptorSetLayoutCreateInfo#

Public Functions

DescriptorSetLayoutCreateInfo() = default#
inline DescriptorSetLayoutCreateInfo(std::initializer_list<DescriptorSetLayoutBinding> bindingList)#
inline DescriptorSetLayoutCreateInfo &setBinding(const DescriptorSetLayoutBinding &layoutBinding)#
inline DescriptorSetLayoutCreateInfo &setBinding(uint16_t binding, pvrvk::DescriptorType descriptorType, uint16_t descriptorCount = 1, pvrvk::ShaderStageFlags stageFlags = pvrvk::ShaderStageFlags::e_ALL, Sampler immutableSampler = Sampler())#

Set the buffer binding of Descriptor Objects in the specified shader stages.

Parameters
  • binding – The index to which the binding will be added

  • descriptorType – The type of descriptor

  • descriptorCount – The number of descriptors to add starting at that index

  • stageFlags – The shader stages for which the number of bindings is set to (count)

  • immutableSampler – If an immutable sampler is set, pass it here. See vulkan spec

Returns

This object (allows chaining of calls)

inline DescriptorSetLayoutCreateInfo &clear()#

Clear all entries.

Returns

Return this for chaining

inline uint16_t getNumBindings() const#

Return the number of images in this object.

Returns

the number of images in this object

inline bool operator==(const DescriptorSetLayoutCreateInfo &rhs) const#

Equality operator. Does deep comparison of the contents.

Parameters

rhs – The right-hand side argument of the operator.

Returns

True if the layouts have identical bindings

inline const DescriptorSetLayoutBinding *getBinding(uint16_t bindingId) const#

Get descriptor binding.

Parameters

bindingId – Binding Index

Returns

The binding layout object (DescriptorBindingLayout)

inline const DescriptorSetLayoutBinding *getAllBindings() const#

Get all layout bindings.

Returns

const DescriptorSetLayoutBinding*

Friends

friend class ::pvrvk::impl::DescriptorSetLayout_
friend struct ::pvrvk::WriteDescriptorSet
struct DescriptorSetLayoutBinding#

Public Functions

inline DescriptorSetLayoutBinding()#
inline DescriptorSetLayoutBinding(uint16_t bindIndex, pvrvk::DescriptorType descType, uint16_t descriptorCount = 1, pvrvk::ShaderStageFlags stageFlags = pvrvk::ShaderStageFlags::e_ALL, const Sampler &immutableSampler = Sampler())#
inline bool operator==(const DescriptorSetLayoutBinding &rhs) const#
inline bool operator!=(const DescriptorSetLayoutBinding &rhs) const#

Public Members

uint16_t binding#
pvrvk::DescriptorType descriptorType#
uint16_t descriptorCount#
pvrvk::ShaderStageFlags stageFlags#
Sampler immutableSampler#

DescriptorSetLayoutCreateInfo::DescriptorSetLayoutBinding#

Nested Relationships#

This struct is a nested type of DescriptorSetLayoutCreateInfo.

Struct Documentation#

struct DescriptorSetLayoutBinding

Public Functions

inline DescriptorSetLayoutBinding()
inline DescriptorSetLayoutBinding(uint16_t bindIndex, pvrvk::DescriptorType descType, uint16_t descriptorCount = 1, pvrvk::ShaderStageFlags stageFlags = pvrvk::ShaderStageFlags::e_ALL, const Sampler &immutableSampler = Sampler())
inline bool operator==(const DescriptorSetLayoutBinding &rhs) const
inline bool operator!=(const DescriptorSetLayoutBinding &rhs) const

Public Members

uint16_t binding
pvrvk::DescriptorType descriptorType
uint16_t descriptorCount
pvrvk::ShaderStageFlags stageFlags
Sampler immutableSampler

DeviceCreateInfo#

Struct Documentation#

struct DeviceCreateInfo#

Containes device create info.

Public Functions

inline explicit DeviceCreateInfo(const std::vector<DeviceQueueCreateInfo> &queueCreateInfos = std::vector<DeviceQueueCreateInfo>(), const VulkanExtensionList &enabledExtensions = VulkanExtensionList(), const PhysicalDeviceFeatures *enabledFeatures = nullptr, DeviceCreateFlags flags = DeviceCreateFlags::e_NONE)#

Constructor for the creation information structure for a Device.

Parameters
  • queueCreateInfos – A list of pvrvk::DeviceQueueCreateInfo structures specifying which queue families should be initialised with the device as well as the number of queues to retrieve from each queue family along with their corresponding priorities.

  • enabledExtensions – A set of Vulkan device extensions to enable for the device.

  • enabledFeatures – A set of Vulkan device features to enable for the device.

  • flags – A set of reserved device creation flags.

inline const DeviceCreateFlags &getFlags() const#

Get the device creation flags.

Returns

A set of DeviceCreateFlags

inline void setFlags(const DeviceCreateFlags &inFlags)#

Sets the device creation info flags.

Parameters

inFlags – A set of DeviceCreateFlags specifying how the device will be created.

inline uint32_t getNumDeviceQueueCreateInfos() const#

Get the number of queue create info structures.

Returns

The number of device queue create infos

inline const std::vector<DeviceQueueCreateInfo> &getDeviceQueueCreateInfos() const#

Get the queue create info structures.

Returns

The device queue create infos

inline const DeviceQueueCreateInfo &getDeviceQueueCreateInfo(uint32_t index) const#

Get the queue create info structure at the specified index (const)

Parameters

index – The specific index of the queue create info structure to set.

Returns

The device queue create info at the specified index (const)

inline DeviceQueueCreateInfo &getDeviceQueueCreateInfo(uint32_t index)#

Get the queue create info structure at the specified index.

Parameters

index – The specific index of the queue create info structure to get.

Returns

The device queue create info at the specified index

inline void setDeviceQueueCreateInfos(const std::vector<DeviceQueueCreateInfo> &inQueueCreateInfos)#

Sets the device queue creation info structures.

Parameters

inQueueCreateInfos – A list of DeviceQueueCreateInfo specifying the queue family indices and corresponding queues (and priorites) to create.

inline void addDeviceQueue(DeviceQueueCreateInfo deviceQueueCreateInfo = DeviceQueueCreateInfo())#

Adds a new device queue creation info structure.

Parameters

deviceQueueCreateInfo – A DeviceQueueCreateInfo specifying a queue family index and its corresponding queues (and priorites) to create.

inline void addDeviceQueueAtIndex(uint32_t index, DeviceQueueCreateInfo deviceQueueCreateInfo = DeviceQueueCreateInfo())#

Adds a new device queue creation info structure at the specified index.

Parameters
  • index – The index of the device queue create info structure to set.

  • deviceQueueCreateInfo – A DeviceQueueCreateInfo specifying a queue family index and its corresponding queues (and priorites) to create.

inline void clearDeviceQueueCreateInfos()#

Clears the device queue create info structures.

inline const VulkanExtensionList &getExtensionList() const#

Get the list of enabled extensions.

Returns

The list of enabled instance extensions

inline void setExtensionList(const VulkanExtensionList &inEnabledExtensions)#

Sets the enabled extension list.

Parameters

inEnabledExtensions – A VulkanExtensionList

inline const PhysicalDeviceFeatures *getEnabledFeatures() const#

Get a pointer to the physical device features structure.

Returns

A pointer to the enabled physical device features

inline void setEnabledFeatures(const PhysicalDeviceFeatures *inEnabledFeatures)#

Sets the enabled physical device features.

Parameters

inEnabledFeatures – A pointer to a set of PhysicalDeviceFeatures.

inline void setLastRequestedExtensionFeature(void *inLastRequestedExtensionFeature)#

Sets the pointer to the extension feature.

Parameters

inLastRequestedExtensionFeature – A pointer to the extension feature.

inline const void *getLastRequestedExtensionFeature() const#

Get a pointer to the extension feature.

Returns

A pointer to the extension feature

DeviceQueueCreateInfo#

Struct Documentation#

struct DeviceQueueCreateInfo#

Contains information about the queues to create for a single queue family. A set of DeviceQueueCreateInfo structures for each queue families are passed in to DeviceCreateInfo when creating the device.

Public Functions

inline DeviceQueueCreateInfo()#

Constructor.

inline DeviceQueueCreateInfo(uint32_t queueFamilyIndex, uint32_t queueCount)#

Constructor. Each of queueCount queues will have a default priority of 1.0f.

Parameters
  • queueFamilyIndex – The queue family index

  • queueCount – The number of queues to create in the particular family type

inline DeviceQueueCreateInfo(uint32_t queueFamilyIndex, const std::vector<float> &queuePriorities)#

Constructor.

Parameters
  • queueFamilyIndex – The queue family index

  • queuePriorities – A list of queue priorities specifying both the number of queues to create in the particular family type and their priority

inline uint32_t getQueueFamilyIndex() const#

Retrieve the queue family index.

Returns

The queue family index

inline void setQueueFamilyIndex(uint32_t inQueueFamilyIndex)#

Sets the queue family index.

Parameters

inQueueFamilyIndex – The queue family index

inline const uint32_t getNumQueues() const#

Retrieve the number of queues created in the queue family index.

Returns

The number of queues in the particular queue family index

inline const std::vector<float> &getQueuePriorities() const#

Retrieve the queues created in the queue family index (const)

Returns

The queues in the particular queue family index (const)

inline std::vector<float> &getQueuePriorities()#

Retrieve the queues created in the queue family index.

Returns

The queues in the particular queue family index

inline float getQueuePriority(uint32_t index) const#

Retrieve the queue priority of the queue at the specified index.

Parameters

index – The index of the queue priority to get

Returns

The queue priority of the queue at the specified index

inline void addQueue(float priority = 1.0f)#

Adds a queue with a particular priority.

Parameters

priority – The queue priority

inline void addQueueAtIndex(uint32_t index, float priority = 1.0f)#

Sets a queues priority.

Parameters
  • index – The index of queue priority to set

  • priority – The new queue priority

inline void clearQueues()#

Clears all the queue priorities.

DisplayModeCreateInfo#

Struct Documentation#

struct DisplayModeCreateInfo#

Display Mode creation descriptor.

Public Functions

inline DisplayModeCreateInfo()#

Constructor (zero initialization)

inline DisplayModeCreateInfo(DisplayModeParametersKHR parameters, DisplayModeCreateFlagsKHR flags = DisplayModeCreateFlagsKHR::e_NONE)#

Constructor.

Parameters
  • parameters – Display mode parameters used to initialise the display mode creation structure

  • flags – A set of pvrvk::DisplayModeCreateFlagsKHR defining how to create a given pvrvk::DisplayMode

inline DisplayModeCreateFlagsKHR getFlags() const#

Getter for the display mode creation flags.

Returns

A DisplayModeCreateFlagsKHR structure

inline DisplayModeCreateInfo &setFlags(DisplayModeCreateFlagsKHR flags)#

Setter for the display mode creation flags.

Parameters

flags – A set of DisplayModeCreateFlagsKHR

Returns

This object

inline DisplayModeParametersKHR getParameters() const#

Getter for the display mode parameters.

Returns

A DisplayModeParametersKHR structure

inline DisplayModeCreateInfo &setParameters(DisplayModeParametersKHR parameters)#

Setter for the display mode parameters.

Parameters

parameters – A set of DisplayModeParametersKHR

Returns

This object

DynamicStatesCreateInfo#

Struct Documentation#

struct DynamicStatesCreateInfo#

Create params for Pipeline Dynamic states. Enable each state that you want to be able to dynamically set.

Public Functions

inline DynamicStatesCreateInfo()#

Constructor.

inline bool isDynamicStateEnabled(DynamicState state) const#

Check if a specific dynamic state is enabled.

Parameters

state – The state to check

Returns

true if state is enabled, otherwise false

inline const std::vector<DynamicState> &getDynamicStates() const#

Get a copy of the dynamic states that have been enabled.

Returns

Vector containing the dynamic states that have been enabled

inline DynamicStatesCreateInfo &setDynamicState(DynamicState state, bool enable)#

Enable/disable a dynamic state.

Parameters
  • state – The state to enable or disable

  • enable – True to enable, false to disable

Returns

Return this object(allows chained calls)

EventCreateInfo#

Struct Documentation#

struct EventCreateInfo#

Event creation descriptor.

Public Functions

inline explicit EventCreateInfo(EventCreateFlags flags = EventCreateFlags::e_NONE)#

Constructor.

Parameters

flags – Flags to use for creating the event

inline EventCreateFlags getFlags() const#

Get the event creation flags.

Returns

The set of event creation flags

inline void setFlags(EventCreateFlags flags)#

Set the event creation flags.

Parameters

flags – The event creation flags

ExportMemoryAllocateInfoKHR#

Struct Documentation#

struct ExportMemoryAllocateInfoKHR#

Implementation of the VkExportMemoryAllocateInfoKHR class used by the VK_KHR_external_memory extension.

Public Functions

inline ExportMemoryAllocateInfoKHR()#

Constructor. handleTypes are initialized to zero.

inline ExportMemoryAllocateInfoKHR(ExternalMemoryHandleTypeFlags handleTypes)#

Constructor. handleTypes are initialized to the parameter passed.

Parameters

handleTypes – The ExternalMemoryHandleTypeFlags used to initialise handleTypes.

Public Members

ExternalMemoryHandleTypeFlags handleTypes#

HandleTypes member.

Extent2Df#

Struct Documentation#

struct Extent2Df#

2 dimensional extent which contains the width and height

Public Functions

inline Extent2Df()#

default Constructor

inline Extent2Df(float width, float height)#

Constructor.

Parameters
  • width – An extent width

  • height – An extent height

inline float getWidth() const#

Get the extent width.

Returns

The extent width

inline void setWidth(float inWidth)#

Sets the extent width.

Parameters

inWidth – An extent width

inline float getHeight() const#

Get the extent height.

Returns

The extent height

inline void setHeight(float inHeight)#

Sets the extent height.

Parameters

inHeight – An extent height

FenceCreateInfo#

Struct Documentation#

struct FenceCreateInfo#

fence creation descriptor.

Public Functions

inline FenceCreateInfo(FenceCreateFlags flags = FenceCreateFlags::e_NONE)#

Constructor.

Parameters

flags – Flags to use for creating the fence

inline FenceCreateFlags getFlags() const#

Get the fence creation flags.

Returns

The set of fence creation flags

inline void setFlags(FenceCreateFlags flags)#

Set the fence creation flags.

Parameters

flags – The fence creation flags

FragmentShadingRateAttachmentInfo#

Struct Documentation#

struct FragmentShadingRateAttachmentInfo#

Public Functions

inline FragmentShadingRateAttachmentInfo()#
inline FragmentShadingRateAttachmentInfo(bool enabled, const AttachmentReference2 &attachment, const Extent2D texelSize = Extent2D(1u, 1u))#
inline FragmentShadingRateAttachmentInfo(const bool enabled, const uint32_t attachment, const ImageLayout imageLayout, const ImageAspectFlags aspectMask, const Extent2D texelSize = Extent2D(1u, 1u))#
inline FragmentShadingRateAttachmentInfo &setEnabled(const bool enabled)#
inline FragmentShadingRateAttachmentInfo &setFragmentShadingRateAttachment(const AttachmentReference2 &attachment)#
inline FragmentShadingRateAttachmentInfo &setTexelSize(const Extent2D texelSize)#
inline bool getEnabled() const#
inline AttachmentReference2 getAttachment() const#
inline Extent2D getTexelSize() const#

FragmentShadingRateStateCreateInfo#

Struct Documentation#

struct FragmentShadingRateStateCreateInfo#

Creation parameters for fragment shading rate functionality.

Be sure to check wherever FSR is supported by the physical device in use and enable the feature during logical device creation as FSR is an extension and is not in core vulkan

Public Functions

inline explicit FragmentShadingRateStateCreateInfo(bool fragmentShadingRateEnabled = false, Extent2D fragmentSize = Extent2D(1, 1), FragmentShadingRateCombinerOpKHR combinerOpPipelinePrimitive = FragmentShadingRateCombinerOpKHR::e_KEEP_KHR, FragmentShadingRateCombinerOpKHR combinerOpResultAttachment = FragmentShadingRateCombinerOpKHR::e_KEEP_KHR)#

Constructor. Initialise with inidividual values.

Disabled by default<remarks>

Parameters
  • fragmentShadingRateEnabled – Determines wherever fragment shading rate is enabled

  • fragmentSize – The fragment size to be used for pipeline fragment shading rate

  • combinerOpPipelinePrimitive – Defines how the pipeline fragment size (Axy) interacts with the primitive fragment size (Bxy). The resulting fragment size is Cxy = CombineOp(Axy, Bxy) as described in the vulkan spec. Default value is KEEP, resulting in Cxy = Axy.

  • combinerOpResultAttachment – Defines how the resulting fragment size from the pipeline/primitive combine operation (Axy) interacts with the attachment fragment size (Bxy). The final fragment size is Cxy = CombineOp(Axy, Bxy) as described in the vulkan spec. Default value is KEEP, resulting in Cxy = Axy.

inline bool isEnabled() const#

Is fragment shading rate functionality enabled?

Returns

Boolean is true if enabled

inline const Extent2D &getFragmentSize() const#

Get the pipeline FSR fragment size.

Returns

{X,Y} value indicating fragment size

inline FragmentShadingRateCombinerOpKHR getCombinerOpPipelinePrimitive() const#

Get the currently set primitive/pipeline combiner op. This value defines the first of 2 combine-operations performed to determine the final fragment size to be rendered at. The first input Axy is the pipeline fragment size, the second input Bxy is the primitive fragment size and they are combined according to this combiner op resulting in Cxy = CombineOp(Axy, Bxy). For example if this combiner op is set to KEEP then Cxy = Axy.

Returns

The first combiner operation

inline FragmentShadingRateCombinerOpKHR getCombinerOpResultAttachment() const#

Get the currently set result/attachment combiner op. This value defines the second of 2 combine-operations performed to determine the final fragment size to be rendered at. The first input Axy is the result of the first combiner op (combinerOpPipelinePrimitive), the second input Bxy is the attachment fragment size and they are combined according to this combiner op resulting in Cxy = CombineOp(Axy, Bxy). For example if this combiner op is set to KEEP then Cxy = Axy.

Returns

The second combiner opteration

inline FragmentShadingRateStateCreateInfo &enable()#

Enables fragment shading rate functionality.

inline FragmentShadingRateStateCreateInfo &disable()#

Disables fragment shading rate functionality.

inline FragmentShadingRateStateCreateInfo &setFragmentSize(Extent2D fragmentSize)#

Sets the pipeline FSR fragment size.

Parameters

fragmentSize – {X,Y} value indicating fragment size

inline FragmentShadingRateStateCreateInfo &setCombinerOpPipelinePrimitive(FragmentShadingRateCombinerOpKHR combinerOpPipelinePrimitive)#

Set the primitive/pipeline combiner op. This value defines the first of 2 combine-operations performed to determine the final fragment size to be rendered at. The first input Axy is the pipeline fragment size, the second input Bxy is the primitive fragment size and they are combined according to this combiner op resulting in Cxy = CombineOp(Axy, Bxy). For example if this combiner op is set to KEEP then Cxy = Axy.

Parameters

combinerOpPipelinePrimitive – The first combiner operation

inline FragmentShadingRateStateCreateInfo &setCombinerOpResultAttachment(FragmentShadingRateCombinerOpKHR combinerOpResultAttachment)#

Get the currently set result/attachment combiner op. This value defines the second of 2 combine-operations performed to determine the final fragment size to be rendered at. The first input Axy is the result of the first combiner op (combinerOpPipelinePrimitive), the second input Bxy is the attachment fragment size and they are combined according to this combiner op resulting in Cxy = CombineOp(Axy, Bxy). For example if this combiner op is set to KEEP then Cxy = Axy.

Parameters

combinerOpResultAttachment – The second combiner opteration

FramebufferCreateInfo#

Struct Documentation#

struct FramebufferCreateInfo#

Framebuffer creation descriptor.

Public Functions

inline void clear()#

Reset this object.

inline FramebufferCreateInfo()#

Constructor (zero initialization)

inline FramebufferCreateInfo(uint32_t width, uint32_t height, uint32_t layers, const RenderPass &renderPass, uint32_t numAttachments = 0, ImageView *attachments = nullptr)#

Constructor (zero initialization)

Parameters
  • width – The width of the framebuffer to create

  • height – The height of the framebuffer to create

  • layers – The number of array layers which will be used by the framebuffer to create

  • renderPass – The renderPass which will be used by the framebuffer

  • numAttachments – The number of attachments used by the framebuffer to create

  • attachments – The numAttachments size list of pvrvk::ImageView elements to be used as framebuffer attachments

inline uint32_t getNumAttachments() const#

Return number of color attachment.

Returns

Number of color attachments

inline const ImageView &getAttachment(uint32_t index) const#

Get a color attachment TextureView.

Parameters

index – The index of the Colorattachment to retrieve

Returns

This object

inline ImageView &getAttachment(uint32_t index)#

Get a color attachment TextureView.

Parameters

index – The index of the Colorattachment to retrieve

Returns

This object

inline const RenderPass &getRenderPass() const#

Get the RenderPass (const)

Returns

The RenderPass (const)

inline RenderPass &getRenderPass()#

Get the RenderPass.

Returns

The RenderPass

inline Extent2D getDimensions() const#

Get the dimensions of the framebuffer.

Returns

The framebuffer dimensions

inline FramebufferCreateInfo &setDimensions(uint32_t inWidth, uint32_t inHeight)#

Set the framebuffer dimension.

Parameters
  • inWidth – Width

  • inHeight – Height

Returns

This object (allow chaining)

inline FramebufferCreateInfo &setDimensions(const Extent2D &extent)#

Set the framebuffer dimension.

Parameters

extent – dimension

Returns

This object (allow chaining)

inline FramebufferCreateInfo &setAttachment(uint32_t index, const ImageView &colorView)#

Add a color attachment to a specified attachment point.

Parameters
  • index – The attachment point, the index must be consecutive

  • colorView – The color attachment

Returns

this (allow chaining)

inline uint32_t getLayers() const#

Get Layers.

Returns

Layers

inline FramebufferCreateInfo &setNumLayers(uint32_t numLayers)#

Set the number of layers.

Parameters

numLayers – The number of array_layers.

Returns

this (allow chaining)

inline FramebufferCreateInfo &setRenderPass(const RenderPass &renderPass)#

Set the RenderPass which this Framebuffer will be invoking when bound.

Parameters

_renderPass – A renderpass. When binding this Framebuffer, this renderpass will be the one to be bound.

Returns

this (allow chaining)

Friends

friend class impl::Framebuffer_

GraphicsPipelineCreateInfo#

Inheritance Relationships#

Base Type#

Struct Documentation#

struct GraphicsPipelineCreateInfo : public pvrvk::PipelineCreateInfo<GraphicsPipeline>#

This represents all the information needed to create a GraphicsPipeline. All items must have proper values for a pipeline to be successfully created, but all those for which it is possible (except, for example, Shaders and Vertex Formats) will have defaults same as their default values OpenGL ES graphics API.

NOTES: The folloowing are required

  • at least one viewport & scissor

  • renderpass

  • pipeline layout

Public Functions

inline GraphicsPipelineCreateInfo()#

Public Members

PipelineDepthStencilStateCreateInfo depthStencil#

Depth and stencil buffer creation info.

PipelineColorBlendStateCreateInfo colorBlend#

Color blending and attachments info.

PipelineViewportStateCreateInfo viewport#

Viewport creation info.

PipelineRasterizationStateCreateInfo rasterizer#

Rasterizer configuration creation info.

PipelineVertexInputStateCreateInfo vertexInput#

Vertex Input creation info.

PipelineInputAssemblerStateCreateInfo inputAssembler#

Input Assembler creation info.

PipelineShaderStageCreateInfo vertexShader#

Vertex shader information.

PipelineShaderStageCreateInfo fragmentShader#

Fragment shader information.

PipelineShaderStageCreateInfo geometryShader#

Geometry shader information.

TesselationStageCreateInfo tesselationStates#

Tesselation Control and evaluation shader information.

PipelineMultisampleStateCreateInfo multiSample#

Multisampling information.

DynamicStatesCreateInfo dynamicStates#

Dynamic state Information.

FragmentShadingRateStateCreateInfo fragmentShadingRate#

Fragment shading rate information (added to pNext chain if enabled)

RenderPass renderPass#

The RenderPass.

uint32_t subpass#

The subpass index.

ImageAreaOffset#

Inheritance Relationships#

Base Types#

  • public ImageSubresource

  • public Offset3D

Struct Documentation#

struct ImageAreaOffset : public ImageSubresource, public Offset3D#

Represents the geometric offset (distance from 0,0,0 in x-y-z) and offset of array and mipmap layers of an image.

Public Functions

ImageAreaOffset() = default#

Constructor. Initialise with default values.

inline ImageAreaOffset(const ImageSubresource &baseLayers, const Offset3D &offset)#

Constructor.

Parameters
  • baseLayers – Image sub resource

  • offset – 3-dimensional offset

ImageAreaSize#

Inheritance Relationships#

Base Types#

Struct Documentation#

struct ImageAreaSize : public Extent3D, public pvrvk::ImageLayersSize#

Represents the geometric size (number of rows/columns/slices in x-y-z) and number of array and mipmap layers of an image.

Public Functions

ImageAreaSize() = default#

Constructor. Initialise with default values.

inline ImageAreaSize(const ImageLayersSize &layersSize, const Extent3D &extents)#

Constructor. Initialise with layer size and extent.

Parameters
  • layersSize – Image layer size

  • extents – Image extent in 3D

inline ImageAreaSize(const ImageLayersSize &layersSize, const Extent2D &extents)#

Constructor. Initialise with layer size and extent.

Parameters
  • layersSize – Image layer size

  • extents – Image extent in 3D

ImageCreateInfo#

Struct Documentation#

struct ImageCreateInfo#

Image creation descriptor.

Public Functions

inline ImageCreateInfo()#

Constructor (zero initialization)

inline ImageCreateInfo(ImageType imageType, pvrvk::Format format, const pvrvk::Extent3D &extent, pvrvk::ImageUsageFlags usage, uint32_t numMipLevels = 1, uint32_t numArrayLayers = 1, pvrvk::SampleCountFlags samples = pvrvk::SampleCountFlags::e_1_BIT, pvrvk::ImageCreateFlags flags = pvrvk::ImageCreateFlags::e_NONE, ImageTiling tiling = ImageTiling::e_OPTIMAL, SharingMode sharingMode = SharingMode::e_EXCLUSIVE, ImageLayout initialLayout = ImageLayout::e_UNDEFINED, const uint32_t *queueFamilyIndices = nullptr, uint32_t numQueueFamilyIndices = 0)#

Constructor.

Parameters
  • imageType – Image creation type (ImageType)

  • format – Image creation format (Format)

  • extent – Image creation extent (Extent3D)

  • usage – Image creation usage (ImageUsageFlags)

  • numMipLevels – The number of Image mip map levels

  • numArrayLayers – The number of Image array layers

  • samples – The number of Image samples (SampleCountFlags)

  • flags – Image creation flags (ImageCreateFlags)

  • tiling – The Image tiling mode (ImageTiling)

  • sharingMode – The Image sharing mode (SharingMode)

  • initialLayout – The initial layout of the Image (ImageLayout)

  • queueFamilyIndices – A pointer to a list of queue family indices specifying the list of queue families which can make use of the image

  • numQueueFamilyIndices – The number of queue family indices pointed to by queueFamilyIndices

inline ImageCreateFlags getFlags() const#

Get Image creation Flags.

Returns

Image creation flags (ImageCreateFlags)

inline void setFlags(ImageCreateFlags flags)#

Set PVRVk Image creation flags.

Parameters

flags – Flags to use for creating a PVRVk image

inline ImageType getImageType() const#

Get Image creation type.

Returns

Image creation type (ImageType)

inline void setImageType(ImageType imageType)#

Set PVRVk Image creation image type.

Parameters

imageType – ImageType to use for creating a PVRVk image

inline const Extent3D &getExtent() const#

Get Extent.

Returns

Extent

inline void setExtent(Extent3D extent)#

Set PVRVk Image creation image extents.

Parameters

extent – extent to use for creating a PVRVk image

inline uint32_t getNumMipLevels() const#

Get the number of Image mip map levels.

Returns

Image mip map levels

inline void setNumMipLevels(uint32_t numMipLevels)#

Set the number of mipmap levels for PVRVk Image creation.

Parameters

numMipLevels – The number of mipmap levels to use for creating a PVRVk image

inline uint32_t getNumArrayLayers() const#

Get the number of Image array layers.

Returns

Image array layers

inline void setNumArrayLayers(uint32_t numArrayLayers)#

Set the number of array layers for PVRVk Image creation.

Parameters

numArrayLayers – The number of array layers to use for creating a PVRVk image

inline SampleCountFlags getNumSamples() const#

Get the number of samples taken for the Image.

Returns

Image number of samples (SampleCountFlags)

inline void setNumSamples(SampleCountFlags numSamples)#

Set the number of samples for PVRVk Image creation.

Parameters

numSamples – The number of samples to use for creating a PVRVk image

inline Format getFormat() const#

Get Image format.

Returns

Image format (Format)

inline void setFormat(Format format)#

Set the Image format for PVRVk Image creation.

Parameters

format – The image format to use for creating a PVRVk image

inline SharingMode getSharingMode() const#

Get Image sharing mode.

Returns

Image sharing mode (SharingMode)

inline void setSharingMode(SharingMode sharingMode)#

Set the Image sharing mode for PVRVk Image creation.

Parameters

sharingMode – The image sharing mode to use for creating a PVRVk image

inline ImageUsageFlags getUsageFlags() const#

Get Image usage flags.

Returns

Image usage flags (ImageUsageFlags)

inline void setUsageFlags(ImageUsageFlags usageFlags)#

Set the Image usage flags for PVRVk Image creation.

Parameters

usageFlags – The image usage flags to use for creating a PVRVk image

inline ImageLayout getInitialLayout() const#

Get Image initial layout.

Returns

Image initial layout (ImageLayout)

inline void setInitialLayout(ImageLayout initialLayout)#

Set the Image initial layout for PVRVk Image creation.

Parameters

initialLayout – The image initial layout to use for creating a PVRVk image

inline ImageTiling getTiling() const#

Get Image tiling mode.

Returns

Image initial tiling mode (ImageTiling)

inline void setTiling(ImageTiling tiling)#

Set the Image tiling for PVRVk Image creation.

Parameters

tiling – The image tiling to use for creating a PVRVk image

inline uint32_t getNumQueueFamilyIndices() const#

Get the number of queue family inidices for the image.

Returns

The number of Image queue families

inline void setNumQueueFamilyIndices(uint32_t numQueueFamilyIndices)#

Set the number of queue family inidices specifying the number of queue families which can use the PVRVk Image.

Parameters

numQueueFamilyIndices – The number of queue family inidices specifying the number of queue families which can use the PVRVk Image

inline const uint32_t *getQueueFamilyIndices() const#

Get a pointer to a list of queue family inidices for the image.

Returns

A pointer to the list of Image queue families

inline void setQueueFamilyIndices(const uint32_t *queueFamilyIndices)#

Set a pointer to a list of queue family inidices for the image.

Parameters

queueFamilyIndices – A pointer to the list of Image queue families

ImageLayersSize#

Inheritance Relationships#

Derived Type#

Struct Documentation#

struct ImageLayersSize#

Represents the geometric size (number of rows/columns/slices in x-y-z) and number of array and mipmap layers of an image.

Subclassed by pvrvk::ImageAreaSize

Public Functions

inline ImageLayersSize()#
inline ImageLayersSize(uint32_t numArrayLevels, uint32_t numMipLevels)#

Constructor (takes individual values)

Parameters
  • numArrayLevels – Number of array levels

  • numMipLevels – Number of mip levels

inline uint32_t getNumArrayLevels() const#

Get the number of array levels.

Returns

Num array levels

inline void setNumArrayLevels(const uint32_t &inNumArrayLevels)#

Set Num array levels.

Parameters

inNumArrayLevels – Number of array levels

inline uint32_t getNumMipLevels() const#

Get num mip levels.

Returns

Number of mipmap levels

inline void setNumMipLevels(const uint32_t &inNumMipLevels)#

Set the number of mip map levels.

Parameters

inNumMipLevels – Num mip map levels

ImageViewCreateInfo#

Struct Documentation#

struct ImageViewCreateInfo#

Image view creation descriptor.

Public Functions

inline ImageViewCreateInfo()#

Constructor (zero initialization)

inline ImageViewCreateInfo(const Image &image, const ComponentMapping &components = ComponentMapping(), const void *pNext = nullptr)#

Constructor.

Parameters
  • image – Image to use in the ImageView

  • components – Specifies a set of remappings of color components

inline ImageViewCreateInfo(const Image &image, pvrvk::ImageViewType viewType, pvrvk::Format format, const ImageSubresourceRange &subresourceRange, const ComponentMapping &components = ComponentMapping(), ImageViewCreateFlags flags = ImageViewCreateFlags::e_NONE, const void *pNext = nullptr)#

Constructor.

Parameters
  • image – Image to use in the ImageView

  • viewType – The image view type to use in the image view

  • format – The format to use in the image view

  • subresourceRange – A set of mipmap levels and array layers to be accessible to the view

  • components – Specifies a set of remappings of color components

  • flags – A set of pvrvk::ImageViewCreateFlags controlling how the ImageView will be created

inline ImageViewCreateFlags getFlags() const#

Get Image view creation Flags.

Returns

Image view creation flags (ImageViewCreateFlags)

inline void setFlags(ImageViewCreateFlags flags)#

Set PVRVk Image view creation flags.

Parameters

flags – Flags to use for creating a PVRVk image view

inline Image &getImage()#

Get Image.

Returns

The Image used in the image view

inline const Image &getImage() const#

Get Image.

Returns

The Image used in the image view

inline void setImage(const Image &image)#

Set PVRVk Image view creation image.

Parameters

image – Image to use for creating a PVRVk image view

inline ImageViewType getViewType() const#

Get Image view creation type.

Returns

Image view creation image view type (ImageViewType)

inline void setViewType(ImageViewType viewType)#

Set PVRVk Image view creation view type.

Parameters

viewType – Flags to use for creating a PVRVk image view

inline Format getFormat() const#

Get Image view format.

Returns

Image view format (Format)

inline void setFormat(Format format)#

Set the Image view format for PVRVk Image creation.

Parameters

format – The image view format to use for creating a PVRVk image

inline const ComponentMapping &getComponents() const#

Get Image view components.

Returns

The Image view components used for remapping color components

inline void setComponents(const ComponentMapping &components)#

Set PVRVk Image view creation components.

Parameters

components – Specifies a set of remappings of color components

inline const ImageSubresourceRange &getSubresourceRange() const#

Get Image view sub resource range.

Returns

The Image view sub resource range used for selecting mipmap levels and array layers to be accessible to the view

inline void setSubresourceRange(const ImageSubresourceRange &subresourceRange)#

Set PVRVk Image view creation sub resource range.

Parameters

subresourceRange – Selects the set of mipmap levels and array layers to be accessible to the view

inline const void *getpNext() const#

Get pNext chain for samplers.

Returns

Get pNext chain for samplers

inline void setpNext(const void *pNext)#

Set pNext chain for samplers.

Parameters

subresourceRange – Set pNext chain for samplers

InstanceCreateInfo#

Struct Documentation#

struct InstanceCreateInfo#

Contains instant info used for creating Vulkan instance.

Public Functions

inline InstanceCreateInfo()#

Constructor. Default initialised to 0.

inline explicit InstanceCreateInfo(const ApplicationInfo &applicationInfo, const VulkanExtensionList &extensions = VulkanExtensionList(), const VulkanLayerList &layers = VulkanLayerList(), InstanceCreateFlags flags = InstanceCreateFlags::e_NONE, pvrvk::DebugUtilsMessengerCreateInfo debugUtilsMessengerCreateInfo = pvrvk::DebugUtilsMessengerCreateInfo())#

Constructor.

Parameters
  • applicationInfo – A an application info structure

  • extensions – A set of extensions to enable

  • layers – A set of layers to enable

  • flags – A set of InstanceCreateFlags to use

  • debugUtilsMessengerCreateInfo – A creation structure which will optionally make use of a debug utils callback for validation of the instance construction

inline const pvrvk::DebugUtilsMessengerCreateInfo getDebugUtilsMessengerCreateInfo() const#

Get the DebugUtilsMessengerCreateInfo which will be linked to the pNext element of the VkInstanceCreateInfo structure given to vkCreateInstance.

Returns

A DebugUtilsMessengerCreateInfo which will be used to determine whether events triggered during instance creation/destruction will be captured

inline void setDebugUtilsMessengerCreateInfo(pvrvk::DebugUtilsMessengerCreateInfo &createInfo)#

By setting a DebugUtilsMessengerCreateInfo the application will link a VkDebugUtilsMessengerCreateInfoEXT structure to the pNext element of the VkInstanceCreateInfo structure given to vkCreateInstance. This callback is only valid for the duration of the vkCreateInstance and the vkDestroyInstance call.

Parameters

createInfo – A DebugUtilsMessengerCreateInfo which will determine the extent to which events will be captured when creating/destroying the instance

inline const pvrvk::ValidationFeatures getValidationFeatures() const#

Get the ValidationFeatures which will be linked to the pNext element of the VkInstanceCreateInfo structure given to vkCreateInstance.

Returns

A ValidationFeatures structure which will be used to determine the validation features to use

inline void setValidationFeatures(pvrvk::ValidationFeatures &inValidationFeatures)#

By setting a ValidationFeatures the application will link a VkValidationFeaturesEXT structure to the pNext element of the VkInstanceCreateInfo structure given to vkCreateInstance. This structure will determine the types of validation used.

Parameters

inValidationFeatures – A ValidationFeatures which will determine the types of validation used

inline const InstanceCreateFlags &getFlags() const#

Get the instance creation flags.

Returns

The instance creation flags

inline void setFlags(const InstanceCreateFlags &inFlags)#

Sets the instance creation flags.

Parameters

inFlags – A set of InstanceCreateFlags to use

inline const ApplicationInfo &getApplicationInfo() const#

Get the instance application info.

Returns

The instance application info

inline void setApplicationInfo(const ApplicationInfo &inApplicationInfo)#

Sets the application info structure.

Parameters

inApplicationInfo – A new application info structure

inline const VulkanExtensionList &getExtensionList() const#

Get the list of extensions.

Returns

The list of instance extensions

inline void setExtensionList(const VulkanExtensionList &inExtensions)#

Sets the extension list.

Parameters

inExtensions – A VulkanExtensionList

inline const VulkanLayerList &getLayerList() const#

Get the list of layers.

Returns

The list of instance layers

inline void setLayerList(const VulkanLayerList &inLayers)#

Sets the layer list.

Parameters

inLayers – A VulkanLayerList

MemoryAllocationInfo#

Struct Documentation#

struct MemoryAllocationInfo#

Parameter object used to create a Memory Allocation using the VMA.

Public Functions

inline MemoryAllocationInfo()#

Constructor. Initialized to unknown values (size 0, index -1)

inline MemoryAllocationInfo(DeviceSize allocationSize, uint32_t memoryTypeIndex)#

Constructor. Initialized by user=provided values.

Parameters
  • allocationSize – The total size of the allocation, in bytes.

  • memoryTypeIndex – The index of the Vulkan memory type required. (retrieve using the various get memory property functions)

inline DeviceSize getAllocationSize() const#

Retrieve the size of the allocation.

Returns

The size of the allocation)

inline void setAllocationSize(DeviceSize sizeInBytes)#

Set the size of the allocation.

Parameters

sizeInBytes – The total size of the allocation.

inline uint32_t getMemoryTypeIndex() const#

Retrieve the Memory Index of the memory type of the allocation.

Returns

The index of the memory type of the allocation)

inline void setMemoryTypeIndex(uint32_t memoryTypeIndex)#

Set the memory index of the allocation.

Parameters

memoryTypeIndex – The memory index of the allocation.

inline void setExportMemoryAllocationInfoKHR(const ExportMemoryAllocateInfoKHR &info)#

Set this field in order to use the VK_KHR_external_memory extension.

Parameters

info – The ExportMemoryAllocateInfoKHR object describing the source of the allocation.

inline const ExportMemoryAllocateInfoKHR &getExportMemoryAllocateInfoKHR() const#

Get the ExportMemoryAllocateInfoKHR object used.

Returns

The ExportMemoryAllocateInfoKHR object contained.

inline ExportMemoryAllocateInfoKHR &getExportMemoryAllocateInfoKHR()#

Get the ExportMemoryAllocateInfoKHR object used.

Returns

The ExportMemoryAllocateInfoKHR object contained.

Offset2Df#

Struct Documentation#

struct Offset2Df#

2 dimensional offset which contains the x and y

Public Functions

inline Offset2Df()#

Default Constructor.

inline Offset2Df(float x, float y)#

Constructor.

Parameters
  • x – An offset x value

  • y – An offset y value

inline float getX() const#

Get the offset x.

Returns

The offset x

inline void setX(float inX)#

Sets the offset x.

Parameters

inX – The new offset x

inline float getY() const#

Get the offset y.

Returns

The offset y

inline void setY(float inY)#

Sets the offset y.

Parameters

inY – The new offset y

PhysicalDeviceTransformFeedbackFeatures#

Struct Documentation#

struct PhysicalDeviceTransformFeedbackFeatures#

Containes a PhysicalDeviceTransformFeedbackFeaturesEXT structure which specifies the implementation dependent features for transform feedback.

Public Functions

PhysicalDeviceTransformFeedbackFeatures() = default#

Constructor. Default initialised to 0.

inline PhysicalDeviceTransformFeedbackFeatures(VkPhysicalDeviceTransformFeedbackFeaturesEXT features)#

Constructor.

Parameters

features – A VkPhysicalDeviceTransformFeedbackFeaturesEXT which specifies the implementation dependent transform feedback features.

inline void setTransformFeedback(bool transformFeedback)#

Sets the transformFeedback.

Parameters

transformFeedback – The transformFeedback.

inline bool getTransformFeedback()#

Gets the transformFeedback.

Returns

The transformFeedback

inline void setGeometryStreams(bool geometryStreams)#

Sets the geometryStreams.

Parameters

geometryStreams – The geometryStreams.

inline bool getGeometryStreams()#

Gets the geometryStreams.

Returns

The geometryStreams

PhysicalDeviceTransformFeedbackProperties#

Struct Documentation#

struct PhysicalDeviceTransformFeedbackProperties#

Containes a PhysicalDeviceTransformFeedbackProperties structure which specifies the implementation dependent limits for transform feedback.

Public Functions

PhysicalDeviceTransformFeedbackProperties() = default#

Constructor. Default initialised to 0.

inline PhysicalDeviceTransformFeedbackProperties(VkPhysicalDeviceTransformFeedbackPropertiesEXT properties)#

Constructor.

Parameters

properties – A VkPhysicalDeviceTransformFeedbackPropertiesEXT which specifies the implementation dependent transform feedback limits.

inline void setMaxTransformFeedbackStreams(uint32_t maxTransformFeedbackStreams)#

Sets the maxTransformFeedbackStreams.

Parameters

maxTransformFeedbackStreams – The maxTransformFeedbackStreams.

inline uint32_t getMaxTransformFeedbackStreams()#

Gets the maxTransformFeedbackStreams.

Returns

The maxTransformFeedbackStreams

inline void setMaxTransformFeedbackBuffers(uint32_t maxTransformFeedbackBuffers)#

Sets the maxTransformFeedbackBuffers.

Parameters

maxTransformFeedbackBuffers – The maxTransformFeedbackBuffers.

inline uint32_t getMaxTransformFeedbackBuffers()#

Gets the maxTransformFeedbackBuffers.

Returns

The maxTransformFeedbackBuffers

inline void setMaxTransformFeedbackBufferSize(VkDeviceSize maxTransformFeedbackBufferSize)#

Sets the maxTransformFeedbackBufferSize.

Parameters

maxTransformFeedbackBufferSize – The maxTransformFeedbackBufferSize.

inline VkDeviceSize getMaxTransformFeedbackBufferSize()#

Gets the maxTransformFeedbackBufferSize.

Returns

The maxTransformFeedbackBufferSize

inline void setMaxTransformFeedbackStreamDataSize(uint32_t maxTransformFeedbackStreamDataSize)#

Sets the maxTransformFeedbackStreamDataSize.

Parameters

maxTransformFeedbackStreamDataSize – The maxTransformFeedbackStreamDataSize.

inline uint32_t getMaxTransformFeedbackStreamDataSize()#

Gets the maxTransformFeedbackStreamDataSize.

Returns

The maxTransformFeedbackStreamDataSize

inline void setMaxTransformFeedbackBufferDataSize(uint32_t maxTransformFeedbackBufferDataSize)#

Sets the maxTransformFeedbackBufferDataSize.

Parameters

maxTransformFeedbackBufferDataSize – The maxTransformFeedbackBufferDataSize.

inline uint32_t getMaxTransformFeedbackBufferDataSize()#

Gets the maxTransformFeedbackBufferDataSize.

Returns

The maxTransformFeedbackBufferDataSize

inline void setMaxTransformFeedbackBufferDataStride(uint32_t maxTransformFeedbackBufferDataStride)#

Sets the maxTransformFeedbackBufferDataStride.

Parameters

maxTransformFeedbackBufferDataStride – The maxTransformFeedbackBufferDataStride.

inline uint32_t getMaxTransformFeedbackBufferDataStride()#

Gets the maxTransformFeedbackBufferDataStride.

Returns

The maxTransformFeedbackBufferDataStride

inline void setTransformFeedbackQueries(bool transformFeedbackQueries)#

Sets the transformFeedbackQueries.

Parameters

transformFeedbackQueries – The transformFeedbackQueries.

inline bool getTransformFeedbackQueries()#

Gets the transformFeedbackQueries.

Returns

The transformFeedbackQueries

inline void setTransformFeedbackStreamsLinesTriangles(bool transformFeedbackStreamsLinesTriangles)#

Sets the transformFeedbackStreamsLinesTriangles.

Parameters

transformFeedbackStreamsLinesTriangles – The transformFeedbackStreamsLinesTriangles.

inline bool getTransformFeedbackStreamsLinesTriangles()#

Gets the transformFeedbackStreamsLinesTriangles.

Returns

The transformFeedbackStreamsLinesTriangles

inline void setTransformFeedbackRasterizationStreamSelect(bool transformFeedbackRasterizationStreamSelect)#

Sets the transformFeedbackRasterizationStreamSelect.

Parameters

transformFeedbackRasterizationStreamSelect – The transformFeedbackRasterizationStreamSelect.

inline bool getTransformFeedbackRasterizationStreamSelect()#

Gets the transformFeedbackRasterizationStreamSelect.

Returns

The transformFeedbackRasterizationStreamSelect

inline void setTransformFeedbackDraw(bool transformFeedbackDraw)#

Sets the transformFeedbackDraw.

Parameters

transformFeedbackDraw – The transformFeedbackDraw.

inline bool getTransformFeedbackDraw()#

Gets the transformFeedbackDraw.

Returns

The transformFeedbackDraw

PipelineCacheCreateInfo#

Struct Documentation#

struct PipelineCacheCreateInfo#

Pipeline cache creation descriptor.

Public Functions

inline explicit PipelineCacheCreateInfo(size_t initialDataSize = 0, const void *pInitialData = nullptr, PipelineCacheCreateFlags flags = PipelineCacheCreateFlags::e_NONE)#

Constructor.

Parameters
  • initialDataSize – The number of bytes in the initialData pointer

  • pInitialData – A pointer to previously retrieved pipeline cache data

  • flags – Flags to use for creating the pipeline cache

inline PipelineCacheCreateFlags getFlags() const#

Get the pipeline cache creation flags.

Returns

The set of pipeline cache creation flags

inline void setFlags(PipelineCacheCreateFlags flags)#

Set the pipeline cache creation flags.

Parameters

flags – The pipeline cache creation flags

inline size_t getInitialDataSize() const#

Get the initial data size of the pipeline cache.

Returns

The initial data size of the pipeline cache

inline void setInitialDataSize(size_t initialDataSize)#

Set the pipeline cache creation initial data size.

Parameters

initialDataSize – The pipeline cache creation initial data size

inline const void *getInitialData() const#

Get the initial data of the pipeline cache.

Returns

The initial data of the pipeline cache

inline void setInitialData(const void *pInitialData)#

Set the pipeline cache creation initial data.

Parameters

pInitialData – The pipeline cache creation initial data

PipelineColorBlendStateCreateInfo#

Struct Documentation#

struct PipelineColorBlendStateCreateInfo#

Pipeline Color blending state configuration (alphaToCoverage, logicOp).

Defaults: Enable alpha to coverage:false, Enable logic op: false, Logic Op: Set, Attachments: 0

Public Functions

inline const PipelineColorBlendAttachmentState *getAttachmentStates() const#

Get color blend attachment states.

Returns

const PipelineColorBlendAttachmentState*

inline PipelineColorBlendStateCreateInfo(bool alphaToCoverageEnable, bool logicOpEnable, pvrvk::LogicOp logicOp, Color colorBlendConstants, PipelineColorBlendAttachmentState *attachmentStates, uint32_t numAttachmentStates)#

Create a Color Blend state object.

Parameters
  • alphaToCoverageEnable – enable/ disable alpa to coverage (default:disable)

  • colorBlendConstants – Blending constants

  • logicOpEnable – enable/disable logicOp (default:disable)

  • logicOp – Select logic operation (default:Set)

  • attachmentStates – An array of color blend attachment states (default: NULL)

  • numAttachmentStates – Number of color attachment states in array (default: 0)

inline explicit PipelineColorBlendStateCreateInfo(bool alphaToCoverageEnable = false, bool logicOpEnable = false, pvrvk::LogicOp logicOp = pvrvk::LogicOp::e_SET, Color colorBlendConstants = Color(0., 0., 0., 0.))#

Create a Color Blend state object.

Parameters
  • alphaToCoverageEnable – enable/ disable alpa to coverage (default:disable

  • logicOpEnable – enable/disable logicOp (default:disable)

  • logicOp – Select logic operation (default:Set)

  • colorBlendConstants – Set color blend constants. Default (0,0,0,0)

inline PipelineColorBlendStateCreateInfo &setColorBlendConst(const Color &blendConst)#

Set a constant for color blending.

Parameters

blendConst – The color blend constant

Returns

Return this object (allows chained calls)

inline const Color &getColorBlendConst() const#

Get the constant for color blending.

Returns

The color blend constant

inline const PipelineColorBlendAttachmentState &getAttachmentState(uint32_t index) const#

Get color-blend attachment state (const).

Parameters

index – attachment index

Returns

const PipelineColorBlendAttachmentState&

inline uint32_t getNumAttachmentStates() const#

Get number of attachment states.

Returns

uint32_t

inline PipelineColorBlendStateCreateInfo &setAlphaToCoverageEnable(bool alphaToCoverageEnable)#

Enable/ disable alpha to coverage.

Parameters

alphaToCoverageEnable – Boolean flags indicating to enable/ disable alpha coverage

Returns

this object (allows chained calls)

inline PipelineColorBlendStateCreateInfo &setLogicOpEnable(bool logicOpEnable)#

Enable/ disable logic op.

Parameters

logicOpEnable – Boolean flags indicating to enable/ disable logic op

Returns

this object (allows chained calls)

inline PipelineColorBlendStateCreateInfo &setLogicOp(pvrvk::LogicOp logicOp)#

Set the logic op.

Parameters

logicOp – New logic op to set

Returns

this object (allows chained calls)

inline PipelineColorBlendStateCreateInfo &clearAttachments()#

Append a color attachment blend configuration (appended to the end of the attachments list).

Returns

this object (allows chained calls)

inline PipelineColorBlendStateCreateInfo &setAttachmentState(uint32_t index, const PipelineColorBlendAttachmentState &state)#

Add a color attachment state blend configuration to a specified index.

Parameters
  • index – Which index this color attachment will be

  • state – The color attachment state to add

Returns

this object (allows chained calls)

inline PipelineColorBlendStateCreateInfo &setAttachmentStates(uint32_t count, PipelineColorBlendAttachmentState const *states)#

Set all color attachment states as an array. Replaces any that had already been added.

Parameters
  • state – An array of color attachment states

  • count – The number of color attachment states in (state)

Returns

this object (allows chained calls)

inline bool isAlphaToCoverageEnabled() const#

Check if Alpha to Coverage is enabled.

Returns

True if enabled, otherwise false

inline bool isLogicOpEnabled() const#

Check if Logic Op is enabled.

Returns

True if enabled, otherwise false

inline pvrvk::LogicOp getLogicOp() const#

Get the Logic Op (regardless if enabled or not)

Returns

The logic op

Friends

friend class ::pvrvk::impl::GraphicsPipeline_

PipelineCreateInfo#

Struct Documentation#

template<class PVRVkPipeline>
struct PipelineCreateInfo#

This represents all the information needed to create a GraphicsPipeline. All items must have proper values for a pipeline to be successfully created, but all those for which it is possible (except, for example, Shaders and Vertex Formats) will have defaults same as their default values OpenGL ES graphics API. NOTES: The folloowing are required.

  • at least one viewport & scissor

  • renderpass

  • pipeline layout

Public Functions

inline virtual ~PipelineCreateInfo()#

Public Members

PipelineLayout pipelineLayout#

The pipeline layout.

pvrvk::PipelineCreateFlags flags#

Any flags used for pipeline creation.

PVRVkPipeline basePipeline#

The parent pipeline, in case of pipeline derivative.

int32_t basePipelineIndex#

The index of the base pipeline.

Protected Functions

inline PipelineCreateInfo()#

PipelineDepthStencilStateCreateInfo#

Struct Documentation#

struct PipelineDepthStencilStateCreateInfo#

Contains parameters needed to set depth stencil states to a pipeline create params. This object can be added to a PipelineCreateInfo to set a depth-stencil state to values other than their defaults.

&#8212; Defaults: &#8212; depthWrite:enabled, depthTest:enabled, DepthComparison:Less, Stencil Text: disabled, All stencil ops:Keep,

Public Functions

inline explicit PipelineDepthStencilStateCreateInfo(bool depthWrite = true, bool depthTest = false, pvrvk::CompareOp depthCompareFunc = pvrvk::CompareOp::e_LESS, bool stencilTest = false, bool depthBoundTest = false, const StencilOpState &stencilFront = StencilOpState(), const StencilOpState &stencilBack = StencilOpState(), float minDepth = 0.f, float maxDepth = 1.f)#

Set all Depth and Stencil parameters.

Parameters
  • depthWrite – Enable/ Disable depth write

  • depthTest – Enable/ Disable depth test

  • depthCompareFunc – Depth compare op

  • stencilTest – Enable/ Disable stencil test

  • depthBoundTest – Enable/ Disable depth bound test

  • stencilFront – Stencil front state

  • stencilBack – Stencil back state

  • minDepth – Min depth value

  • maxDepth – Max depth value

inline bool isDepthTestEnable() const#

Return true if depth test is enable.

Returns

bool

inline bool isDepthWriteEnable() const#

Return true if depth write is enable.

Returns

bool

inline bool isDepthBoundTestEnable() const#

Return true if depth bound is enable.

Returns

bool

inline bool isStencilTestEnable() const#

Return true if stencil test is enable.

Returns

bool

inline float getMinDepth() const#

Return minimum depth value.

Returns

float

inline float getMaxDepth() const#

Return maximum depth value.

Returns

float

inline pvrvk::CompareOp getDepthComapreOp() const#

Return depth comparison operator.

Returns

pvrvk::CompareOp

inline bool isAllStatesEnabled() const#

Return true if this state is enabled.

Returns

bool

inline PipelineDepthStencilStateCreateInfo &enableAllStates(bool flag)#

Enable/ Disale the entire state.

Parameters

flag – True:enable, False:disable

Returns

this object (allows chained calls)

inline PipelineDepthStencilStateCreateInfo &enableDepthWrite(bool depthWrite)#

Enable/disable writing into the Depth Buffer.

Parameters

depthWrite – True:enable, False:disable

Returns

this object (allows chained calls)

inline PipelineDepthStencilStateCreateInfo &enableDepthTest(bool depthTest)#

Enable/disable depth test (initial state: enabled)

Parameters

depthTest – True:enable, False:disable

Returns

this object (allows chained calls)

inline PipelineDepthStencilStateCreateInfo &setDepthCompareFunc(pvrvk::CompareOp compareFunc)#

Set the depth compare function (initial state: LessEqual)

Parameters

compareFunc – A ComparisonMode (Less, Greater, Less etc.)

Returns

this object (allows chained calls)

inline PipelineDepthStencilStateCreateInfo &enableStencilTest(bool stencilTest)#

Enable/disable stencil test.

Parameters

stencilTest – True:enable, False:disable

Returns

this object (allows chained calls)

inline PipelineDepthStencilStateCreateInfo &setStencilFront(const StencilOpState &stencil)#

Set the stencil front state.

Parameters

stencil – Stencil state

Returns

this object (allows chained calls)

inline PipelineDepthStencilStateCreateInfo &setStencilBack(const StencilOpState &stencil)#

Set the stencil back state.

Parameters

stencil – Stencil state

Returns

this object (allows chained calls)

inline PipelineDepthStencilStateCreateInfo &setStencilFrontAndBack(StencilOpState &stencil)#

Set the stencil front and back state.

Parameters

stencil – Stencil state

Returns

this object (allows chained calls)

inline const StencilOpState &getStencilFront() const#

Return stencil front state.

Returns

const StencilOpState&

inline const StencilOpState &getStencilBack() const#

Return stencil back state.

Returns

const StencilOpState&

inline PipelineDepthStencilStateCreateInfo &setDepthBoundEnabled(bool enabled)#

Enable/ Disable depth bound testing.

Parameters

enabled – True:enable, False:disable

Returns

this object (allows chained calls)

inline PipelineDepthStencilStateCreateInfo &setMinDepthBound(float minDepth)#

Set the minimum depth bound.

Parameters

minDepth – The minimum depth bound

Returns

this object (allows chained calls)

inline PipelineDepthStencilStateCreateInfo &setMaxDepthBound(float maxDepth)#

Set the maximum depth bound.

Parameters

maxDepth – The maximum depth bound

Returns

this object (allows chained calls)

PipelineInputAssemblerStateCreateInfo#

Struct Documentation#

struct PipelineInputAssemblerStateCreateInfo#

Add Input Assembler configuration to this buffer object (primitive topology, vertex restart, vertex reuse etc).

&#8212; Default settings &#8212; Primitive Topology: TriangleList, Primitive Restart: False, Vertex Reuse: Disabled, Primitive Restart Index: 0xFFFFFFFF

Public Functions

inline explicit PipelineInputAssemblerStateCreateInfo(pvrvk::PrimitiveTopology topology = pvrvk::PrimitiveTopology::e_TRIANGLE_LIST, bool disableVertexReuse = true, bool primitiveRestartEnable = false, uint32_t primitiveRestartIndex = 0xFFFFFFFF)#

Create and configure an InputAssembler configuration.

Parameters
  • topology – Primitive Topology (default: TriangleList)

  • disableVertexReuse – Disable Vertex Reuse (true:disabled false:enabled). Default:true

  • primitiveRestartEnable – (true: enabled, false: disabled) Default:false

  • primitiveRestartIndex – Primitive Restart Index. Default 0xFFFFFFFF

Returns

this object (allows chained calls)

inline PipelineInputAssemblerStateCreateInfo &setPrimitiveRestartEnable(bool enable)#

Enable/ disable primitive restart.

Parameters

enable – true for enable, false for disable.

Returns

this object (allows chained calls)

inline PipelineInputAssemblerStateCreateInfo &setVertexReuseDisable(bool disable)#

Enable/ disable vertex reuse.

Parameters

disable – true for disable, false for enable.

Returns

this object (allows chained calls)

inline PipelineInputAssemblerStateCreateInfo &setPrimitiveTopology(pvrvk::PrimitiveTopology topology)#

Set primitive topology.

Parameters

topology – The primitive topology to interpret the vertices as (TriangleList, Lines etc)

Returns

this object (allows chained calls)

inline bool isVertexReuseDisabled() const#

Check if Vertex Reuse is disabled.

Returns

True if vertex reuse is disabled, otherwise false

inline bool isPrimitiveRestartEnabled() const#

Check if primitive restart is enabled.

Returns

True if primitive restart is enabled, otherwise false

inline uint32_t getPrimitiveRestartIndex() const#

Get the primitive restart index.

Returns

The primitive restart index

inline pvrvk::PrimitiveTopology getPrimitiveTopology() const#

Get primitive topology.

Returns

Returns primitive topology.

Friends

friend class ::pvrvk::impl::GraphicsPipeline_

PipelineLayoutCreateInfo#

Struct Documentation#

struct PipelineLayoutCreateInfo#

Pipeline Layout create information. The descriptor set layouts must be known to create a Pipeline layout.

Public Functions

inline PipelineLayoutCreateInfo &addDescSetLayout(const DescriptorSetLayout &descLayout)#

Add a descriptor set layout to this pipeline layout. Added to the end of the list of layouts.

Parameters

descLayout – A descriptor set layout

Returns

this (allow chaining)

inline PipelineLayoutCreateInfo &setDescSetLayout(uint32_t index, const DescriptorSetLayout &descLayout)#

Add a descriptor set layout to this pipeline layout. Added to the specified index.

Parameters
  • index – The index where the layout will be created on

  • descLayout – A descriptor set layout

Returns

this (allow chaining)

inline uint32_t getNumDescriptorSetLayouts() const#

Return number of descriptor set layouts.

Returns

Return number of descriptor set layouts

inline const DescriptorSetLayout &getDescriptorSetLayout(uint32_t index) const#

Get descriptor set layout.

Parameters

index – Descriptor set layout index

Returns

Descritpor set layout

inline void clear()#

Clear the entries.

inline const std::array<DescriptorSetLayout, FrameworkCaps::MaxDescriptorSetBindings> &getDescriptorSetLayouts() const#

Get all descriptor set layouts.

Returns

An array of 4 descriptor set layouts. Unused one will be empty references (isNull() returns true)

inline bool operator==(const PipelineLayoutCreateInfo &rhs) const#

Return if this object is equal.

Parameters

rhs – Object to compare with

Returns

Return true if equal

inline void addPushConstantRange(const PushConstantRange &pushConstantRange)#
inline void setPushConstantRange(uint32_t index, const PushConstantRange &pushConstantRange)#

Set push constant range.

Parameters
  • index – Push constant range index

  • pushConstantRange – push constant range to set

inline const PushConstantRange &getPushConstantRange(uint32_t index) const#

Get push constant range.

Parameters

index – Push cinstant range index

Returns

Returns push constant range

inline uint32_t getNumPushConstantRanges() const#

Get number of push constants.

Returns

Number of push constants

inline PipelineLayoutCreateInfo()#

PipelineLayoutCreateInfo.

Friends

friend class ::pvrvk::impl::PipelineLayout_
friend class ::pvrvk::impl::GraphicsPipeline_

PipelineMultisampleStateCreateInfo#

Struct Documentation#

struct PipelineMultisampleStateCreateInfo#

Pipeline Multisampling state configuration: Number of samples, alpha to coverage, alpha to one, sampling mask.

Defaults: No multisampling

Public Functions

inline explicit PipelineMultisampleStateCreateInfo(bool sampleShadingEnable = false, bool alphaToCoverageEnable = false, bool alphaToOneEnable = false, pvrvk::SampleCountFlags rasterizationSamples = pvrvk::SampleCountFlags::e_1_BIT, float minSampleShading = 0.f, pvrvk::SampleMask sampleMask = 0xffffffff)#

Constructor. Create a multisampling configuration.

Parameters
  • sampleShadingEnable – Enable/disable sample shading (defalt false)

  • alphaToCoverageEnable – Enable/disable alpha-to-coverage

  • alphaToOneEnable – Enable/disable alpha-to-one

  • rasterizationSamples – The number of rasterization samples (default 1)

  • minSampleShading – The minimum sample Shading (default 0)

  • sampleMask – sampleMask (default 0)

inline PipelineMultisampleStateCreateInfo &setAlphaToCoverage(bool enable)#

Enable/ Disable alpha to coverage.

Parameters

enable – True to enable Alpha to Coverage, false to Disable

Returns

Return this object (allows chained calls)

inline PipelineMultisampleStateCreateInfo &setSampleShading(bool enable)#

Enable/ disable sampler shading (Multi Sampling Anti Aliasing).

Parameters

enable – true enable per-sample shading, false to disable

Returns

this (allow chaining)

inline PipelineMultisampleStateCreateInfo &setAlphaToOne(bool enable)#

Controls whether the alpha component of the fragment’s first color output is replaced with one.

Parameters

enable – true enable alpha to one, false disable

Returns

this (allow chaining)

inline PipelineMultisampleStateCreateInfo &setNumRasterizationSamples(pvrvk::SampleCountFlags numSamples)#

Set the number of samples per pixel used in rasterization (Multi sample anti aliasing)

Parameters

numSamples – The number of samples

Returns

this (allow chaining)

inline PipelineMultisampleStateCreateInfo &setMinSampleShading(float minSampleShading)#

Set minimum sample shading.

Parameters

minSampleShading – The number of minimum samples to shade

Returns

this (allow chaining)

inline PipelineMultisampleStateCreateInfo &setSampleMask(pvrvk::SampleMask mask)#

Set a bitmask of static coverage information that is ANDed with the coverage information generated during rasterization.

Parameters

mask – The sample mask. See the corresponding API spec for exact bit usage of the mask.

Returns

this (allow chaining)

inline const pvrvk::SampleMask &getSampleMask() const#

Get the sample mask.

Returns

The sample mask

inline pvrvk::SampleCountFlags getRasterizationSamples() const#

Return the number of rasterization (MSAA) samples.

Returns

The number of rasterization samples

inline float getMinSampleShading() const#

Get the number of minimum samples.

Returns

The number of minimum samples

inline bool isSampleShadingEnabled() const#

Get the sample shading state.

Returns

true if sample shading enabled, false if disabled

inline bool isAlphaToCoverageEnabled() const#

Get alpha to coverage state.

Returns

True if enabled, false if disabled

inline bool isAlphaToOneEnabled() const#

Get alpha to one state.

Returns

Return true if alpha to one is enabled, false if disabled

Friends

friend class ::pvrvk::impl::GraphicsPipeline_

PipelineRasterizationStateCreateInfo#

Struct Documentation#

struct PipelineRasterizationStateCreateInfo#

Pipeline Rasterisation, clipping and culling state configuration. Culling, winding order, depth clipping, raster discard, point size, fill mode, provoking vertex.

Defaults: Cull face: back, Front face: CounterClockWise, Depth Clipping: true, Rasterizer Discard: false, Program Point Size: false, Point Origin: Lower left, Fill Mode: Front&Back, Provoking Vertex: First

Public Functions

inline explicit PipelineRasterizationStateCreateInfo(pvrvk::CullModeFlags cullFace = pvrvk::CullModeFlags::e_NONE, pvrvk::FrontFace frontFaceWinding = pvrvk::FrontFace::e_COUNTER_CLOCKWISE, bool enableDepthClip = true, bool enableRasterizerDiscard = false, bool enableProgramPointSize = false, pvrvk::PolygonMode fillMode = pvrvk::PolygonMode::e_FILL, float lineWidth = 1.0f, bool enableDepthBias = false, float depthBiasClamp = 0.f, float depthBiasConstantFactor = 0.f, float depthBiasSlopeFactor = 0.f, uint32_t rasterizationStream = 0)#

Create a rasterization and polygon state configuration.

Parameters
  • cullFace – Face culling (default Back)

  • frontFaceWinding – The polygon winding order (default, Front face is counterclockwise)

  • enableDepthClip – Enable depth clipping. If set to false , depth Clamping happens instead of clipping (default true)

  • enableRasterizerDiscard – Enable rasterizer discard (default false)

  • enableProgramPointSize – Enable program point size (default true)

  • fillMode – Polygon fill mode (default: Front and Back)

  • lineWidth – Width of rendered lines (default One)

  • enableDepthBias – Enable depth bias (default false)

  • enableDepthBias – Enable depth bias (default false)

  • depthBiasClamp – If depth bias is enabled, the clamping value for depth bias (default 0)

  • depthBiasConstantFactor – If depth bias is enabled, the constant value by which to bias depth(default 0)

  • depthBiasSlopeFactor – If depth bias is enabled, the slope value by which to bias depth(default:0)

  • rasterizationStream – Controls the use of vertex shader based transform feedback

inline PipelineRasterizationStateCreateInfo &setCullMode(pvrvk::CullModeFlags face)#

Set the face that will be culled (front/back/both/none).

Parameters

face – Cull face

Returns

this object (allows chained calls)

inline PipelineRasterizationStateCreateInfo &setLineWidth(float lineWidth)#

Set the line width.

Parameters

lineWidth – The width of lines (in pixels) when drawing line primitives.

Returns

Return this object (allows chained calls)

inline PipelineRasterizationStateCreateInfo &setRasterizationStream(uint32_t rasterizationStream)#

Set the Rasterization stream.

Parameters

rasterizationStream – The vertex stream selected for rasterization. This parameter controls usage of transform feedback if it is supported.

Returns

Return this object (allows chained calls)

inline PipelineRasterizationStateCreateInfo &setDepthClip(bool enableDepthClip)#

Select between depth Clipping and depth Clamping.

Parameters

enableDepthClip – Set to true to clip polygons at the Z-sides of the view frustum Set to false to clamp the depth to the min/max values and not clip based on depth

Returns

Return this object (allows chained calls)

inline PipelineRasterizationStateCreateInfo &setDepthBias(bool enableDepthBias, bool depthBiasClamp = 0.f, bool depthBiasConstantFactor = 0.f, bool depthBiasSlopeFactor = 0.f)#

Enable depth bias (add a value to the calculated fragment depth)

Parameters
  • enableDepthBias – Set to true to enable depth bias, false to disable

  • depthBiasClamp – The maximum (or minimum) value of depth biasing

  • depthBiasConstantFactor – A constant value added to all fragment depths

  • depthBiasSlopeFactor – Depth slope factor for multiply fragment depths

Returns

Return this object (allows chained calls)

inline PipelineRasterizationStateCreateInfo &setFrontFaceWinding(pvrvk::FrontFace frontFaceWinding)#

Set which polygon winding order is considered the “front” face (The opposite order is considered back face).

Parameters

frontFaceWinding – The winding order that will represent front faces

Returns

this object (allows chained calls)

inline PipelineRasterizationStateCreateInfo &setRasterizerDiscard(bool enable)#

Disable all phases after transform feedback (rasterization and later)

Parameters

enable – Set to “false” for normal rendering, “true” to enable rasterization discard

Returns

this object (allows chained calls)

inline PipelineRasterizationStateCreateInfo &setProgramPointSize(bool enable)#

Enable/disable Program Point Size.

Parameters

enable – Set to “true” to control point size for the entire program

Returns

this object (allows chained calls)

inline PipelineRasterizationStateCreateInfo &setPolygonMode(pvrvk::PolygonMode mode)#

Set polygon fill mode.

Parameters

mode – New polygon mode to set

Returns

this object (allows chained calls)

inline pvrvk::CullModeFlags getCullFace() const#

Get which of the faces (Front/Back/None/Both) will not be rendered (will be culled)

Returns

The faces that will be culled (“None” means everything drawn, “Both” means nothing drawn)

inline pvrvk::FrontFace getFrontFaceWinding() const#

Get which winding order is considered the FRONT face (CCW means front faces are the counterclockwise, CW clockwise)

Returns

The winding order that is considered FRONT facing

inline bool isDepthClipEnabled() const#

Check if depth clipping is enabled (i.e. depth clamping disabled). If disabled, polygons will not be clipped against the front and back clipping plane clipping planes: instead, the primitives’ depth will be clamped to min and max depth instead.

Returns

True if depth clipping is enabled (depth clamping is disabled). False if depth clamping is enabled (depth clipping disabled).

inline bool isRasterizerDiscardEnabled() const#

Check if rasterization is skipped (so all parts of the pipeline after transform feedback)

Returns

True if rasterization discard is enabled, false for normal rendering.

inline bool isProgramPointSizeEnabled() const#

Check if program point size is enabled.

Returns

True if program point size is enabled, otherwise false

inline bool isDepthBiasEnabled() const#

Check if depth bias is enabled. (If enabled, clamp, constant factor and slope factor can be checked)

Returns

True if depth bias is enabled, otherwise false.

inline float getDepthBiasClamp() const#

Get the maximum(minimum) value of depth bias.

Returns

The maximum(minimum) value of depth bias

inline float getDepthBiasConstantFactor() const#

Get the constant factor of depth bias.

Returns

The constant factor depth bias

inline float getDepthBiasSlopeFactor() const#

Get the slope factor of depth bias.

Returns

The slope factor depth bias

inline pvrvk::PolygonMode getPolygonMode() const#

Get the slope factor of depth bias.

Returns

The slope factor depth bias

inline float getLineWidth() const#

Get the slope factor of depth bias.

Returns

The slope factor depth bias

inline uint32_t getRasterizationStream() const#

Get the vertex stream selected for rasterization.

Returns

The vertex stream selected for rasterization

Friends

friend class ::pvrvk::impl::GraphicsPipeline_

PipelineShaderStageCreateInfo#

Struct Documentation#

struct PipelineShaderStageCreateInfo#

Pipeline vertex ShaderModule stage create param.

Public Functions

inline PipelineShaderStageCreateInfo()#

Constructor.

inline PipelineShaderStageCreateInfo(const ShaderModule &shader)#

Construct from a pvrvk::ShaderModule object.

Parameters

shader – A vertex shader

inline const ShaderModule &getShader() const#

Get the shader of this shader stage object.

Returns

The shader

inline bool isActive() const#

Return true if this state is active (contains a shader)

Returns

True if valid, otherwise false

inline void setShader(const ShaderModule &shader)#

Set the shader.

Parameters

shader – A shader

inline void setEntryPoint(const std::string &entryPoint)#

Set the shader entry point function (default: “main”). Only supported for specific APIs.

Parameters

entryPoint – A name of a function that will be used as an entry point in the shader

inline const std::string &getEntryPoint() const#

Get the entry point of the shader.

Returns

The entry point of the shader

inline PipelineShaderStageCreateInfo &operator=(const ShaderModule &shader)#

operator =

Parameters

shader – ShaderModule object

Returns

PipelineShaderStageCreateInfo&

inline PipelineShaderStageCreateInfo &setShaderConstant(uint32_t index, const ShaderConstantInfo &shaderConst)#

Set a shader constants to the shader.

Parameters
  • index – The index of the shader constant to set (does not have to be in order)

  • shaderConst – The shader constant to set to index index

Returns

Return this (allow chaining)

inline PipelineShaderStageCreateInfo &setShaderConstants(const ShaderConstantInfo *shaderConsts, uint32_t numConstants)#

Set all shader constants.

Uses better memory reservation than the setShaderConstant counterpart.

Parameters
  • shaderConsts – A c-style array containing the shader constants

  • numConstants – The number of shader constants in shaderConsts

Returns

Return this (allow chaining)

inline const ShaderConstantInfo &getShaderConstant(uint32_t index) const#

Retrieve a ShaderConstant by index.

Parameters

index – The index of the ShaderConstant to retrieve

Returns

The shader constant

inline const ShaderConstantInfo *getAllShaderConstants() const#

Get all shader constants.

Returns

Return an array of all defined shader constants

inline uint32_t getNumShaderConsts() const#

Get the number of shader constants.

Returns

The number of shader constants

inline pvrvk::ShaderStageFlags getShaderStage() const#

Get the shader stage.

Returns

The shader stage

inline void setShaderStage(pvrvk::ShaderStageFlags shaderStage)#

Set the shader stage.

Parameters

shaderStage – New value for the shader stage

Friends

friend class ::pvrvk::impl::GraphicsPipeline_

PipelineVertexInputStateCreateInfo#

Struct Documentation#

struct PipelineVertexInputStateCreateInfo#

Contains parameters needed to configure the Vertex Input for a pipeline object. (vertex attrubutes, input bindings etc.). Use by adding the buffer bindings with (setInputBinding) and then configure the attributes with (addVertexAttribute). Default settings: 0 Vertext buffers, 0 vertex attributes.

Public Functions

inline const std::vector<VertexInputBindingDescription> &getInputBindings() const#

Return the input bindings.

Returns

const std::vector<VertexInputBindingDescription>&

inline const std::vector<VertexInputAttributeDescription> &getAttributes() const#

Return the vertex attributes.

Returns

const std::vector<VertexInputAttributeDescription>&

inline PipelineVertexInputStateCreateInfo &clear()#

Clear this object.

Returns

this object (allows chained calls)

inline PipelineVertexInputStateCreateInfo &addInputBinding(const VertexInputBindingDescription &bindingDesc)#

Set the vertex input buffer bindings.

Parameters

bindingDesc – New input binding description

Returns

this object (allows chained calls)

inline const VertexInputBindingDescription *getInputBinding(uint32_t bufferBinding) const#

Return a VertexBindingInfo for a buffer binding index, else return NULL if not found.

Parameters

bufferBinding – Buffer binding index

Returns

const VertexInputBindingDescription*

inline const VertexInputBindingDescription &getInputBindingByIndex(uint32_t index) const#

Returns an input binding at a given index.

Parameters

index – The index of the VertexInputBindingDescription to retrieve.

Returns

const VertexInputBindingDescription&

inline PipelineVertexInputStateCreateInfo &addInputAttribute(const VertexInputAttributeDescription &attributeInfo)#

Add vertex layout information to a buffer binding index using a VertexAttributeInfo object.

Parameters

attributeInfo – Vertex attribute info.

Returns

this object (allows chained calls)

inline PipelineVertexInputStateCreateInfo &addInputAttributes(const VertexInputAttributeDescription *attributeInfo, uint32_t numAttributes)#

Add vertex layout information to a buffer binding index using a VertexAttributeInfo object.

Parameters
  • attributeInfo – Pointer to vertex attribute info

  • numAttributes – Number of vertex attributes

Returns

this object (allows chained calls)

Friends

friend class ::pvrvk::impl::GraphicsPipeline_

PipelineViewportStateCreateInfo#

Struct Documentation#

struct PipelineViewportStateCreateInfo#

Pipeline Viewport state descriptor. Sets the base configuration of all viewports.

Defaults: Number of Viewports:1, Clip Origin: lower lef, Depth range: 0..1

Public Functions

inline PipelineViewportStateCreateInfo()#

Constructor.

inline PipelineViewportStateCreateInfo &setViewportAndScissor(uint32_t index, const Viewport &viewport, const Rect2D &scissor)#

Configure the viewport with its corresponding scissor rectangle for an attachment.

Parameters
  • index – The index of the attachment for which to set the viewport and scissor rectangle

  • viewport – The viewport to set for attachment index

  • scissor – The scissor rectangle of the viewport

Returns

return this object (allows chained calls)

inline PipelineViewportStateCreateInfo &clear()#

Clear all states.

Returns

Return this object (allows chained calls)

inline const Rect2D &getScissor(uint32_t index) const#

Get the scissor rectangle for the specified attachment intex.

Parameters

index – The index for which to return the scissor rectangle

Returns

Get the scissor rectangle for the specified attachment intex

inline const Viewport &getViewport(uint32_t index) const#

Get the viewport for the specified attachment intex.

Parameters

index – The index for which to return the scissor rectangle

Returns

Get the scissor rectangle for the specified attachment intex

inline uint32_t getNumViewportScissors() const#

Return number of viewport and scissor.

Returns

uint32_t

Friends

friend class ::pvrvk::impl::GraphicsPipeline_

PresentInfo#

Struct Documentation#

struct PresentInfo#

Swapchain present info. Containes information for presentation such as swapchains, swapchain indices and wait semaphores.

Public Functions

inline PresentInfo()#

Constructor. Default initialised to 0.

inline PresentInfo(uint32_t numWaitSemaphores, Semaphore *waitSemaphores, uint32_t numSwapchains, const pvrvk::Swapchain *swapchains, const uint32_t *imageIndices)#

Constructor. Initialise with inidividual values.

Parameters
  • numWaitSemaphores – The number of wait semaphores

  • waitSemaphores – Pointer to an array of semaphores

  • numSwapchains – The number of swapchains being presented by this command

  • swapchains – Pointer to an array of swapchains to use for presentation

  • imageIndices – Pointer to an array of indices into the array of swapchain’s presentatble images

Public Members

uint32_t numWaitSemaphores#

The number of wait semaphores.

Semaphore *waitSemaphores#

Pointer to an array of semaphores.

uint32_t numSwapchains#

The number of swapchains being presented by this command.

const pvrvk::Swapchain *swapchains#

Pointer to an array of swapchains to use for presentation.

const uint32_t *imageIndices#

Pointer to an array of indices into the array of swapchain’s presentatble images.

QueryPoolCreateInfo#

Struct Documentation#

struct QueryPoolCreateInfo#

QueryPool creation descriptor.

Public Functions

inline QueryPoolCreateInfo(QueryType queryType, uint32_t queryCount, QueryPipelineStatisticFlags pipelineStatistics = QueryPipelineStatisticFlags::e_NONE, QueryPoolCreateFlags flags = QueryPoolCreateFlags::e_NONE)#

Constructor.

Parameters
  • queryType – The type of queries managed by the pool

  • queryCount – The number of queries managed by the pool

  • pipelineStatistics – Specifies which counters will be returned in queries on the pool

  • flags – Flags to use for creating the query pool

inline QueryPoolCreateFlags getFlags() const#

Get the query pool creation flags.

Returns

The set of query pool creation flags

inline void setFlags(QueryPoolCreateFlags flags)#

Set the query pool creation flags.

Parameters

flags – The query pool creation flags

inline QueryPipelineStatisticFlags getPipelineStatisticFlags() const#

Get the set of counters which will be returned in queries on the pool.

Returns

The set of counters which will be returned in queries on the pool

inline void setPipelineStatisticFlags(QueryPipelineStatisticFlags pipelineStatistics)#

Set the set counters will be returned in queries on the pool.

Parameters

pipelineStatistics – The set of counters which will be returned in queries on the pool

inline QueryType getQueryType() const#

Get the type of queries managed by this query pool.

Returns

The type of queries managed by this query pool

inline void setQueryType(QueryType queryType)#

Set the type of queries this query pool can manage.

Parameters

queryType – The type of queries the query pool can manage

inline uint32_t getNumQueries() const#

Get the number of queries managed by the pool.

Returns

The number of queries managed by the pool

inline void setNumQueries(uint32_t queryCount)#

Set the number queries managed by the pool.

Parameters

queryCount – The number of queries to be managed by the pool

RaytracingPipelineCreateInfo#

Inheritance Relationships#

Base Type#

Struct Documentation#

struct RaytracingPipelineCreateInfo : public pvrvk::PipelineCreateInfo<RaytracingPipeline>#

Ray tracing pipeline create parameters.

Public Functions

inline RaytracingPipelineCreateInfo()#

Public Members

std::vector<PipelineShaderStageCreateInfo> stages#

Ray tracing stages used in this pipeline.

std::vector<RayTracingShaderGroupCreateInfo> shaderGroups#

Shader groups matching the ray tracing stages used in this pipeline.

uint32_t maxRecursionDepth#

Maximum recursion depth used in this pipeline.

RayTracingShaderGroupCreateInfo#

Struct Documentation#

struct RayTracingShaderGroupCreateInfo#

Ray tracing shader group create info parameter.

Public Functions

inline RayTracingShaderGroupCreateInfo()#
inline RayTracingShaderGroupCreateInfo(RayTracingShaderGroupTypeKHR type)#
inline pvrvk::RayTracingShaderGroupTypeKHR getType() const#

Get the shader group type.

Returns

The shader group type

inline void setType(pvrvk::RayTracingShaderGroupTypeKHR type)#

Set the shader group type.

Parameters

type – New value for the shader group type

inline uint32_t getGeneralShader() const#

Get the general shader amount.

Returns

The general shader amount

inline void setGeneralShader(uint32_t generalShader)#

Set the general shader amount.

Parameters

generalShader – New value for the general shader amount

inline uint32_t getClosestHitShader() const#

Get the closest hit shader amount.

Returns

The closest hit shader amount

inline void setClosestHitShader(uint32_t closestHitShader)#

Set the closest hit shader amount.

Parameters

closestHitShader – New value for the closest hit shader amount

inline uint32_t getAnyHitShader() const#

Get the any hit shader amount.

Returns

The any hit shader amount

inline void setAnyHitShader(uint32_t anyHitShader)#

Set the any hit shader amount.

Parameters

anyHitShader – New value for the any hit shader amount

inline uint32_t getIntersectionShader() const#

Get the intersection hit shader amount.

Returns

The intersection hit shader amount

inline void setIntersectionShader(uint32_t intersectionShader)#

Set the intersection hit shader amount.

Parameters

intersectionShader – New value for the intersection hit shader amount

inline const void *getShaderGroupCaptureReplayHandle() const#

Get the shader group capture replay handle.

Returns

The shader group capture replay handle

inline void setShaderGroupCaptureReplayHandle(void *pShaderGroupCaptureReplayHandle)#

Set the shader group capture replay handle.

Parameters

pShaderGroupCaptureReplayHandle – New value for the shader group capture replay handle

Rect2Df#

Struct Documentation#

struct Rect2Df#

2-dimensional floating point rectangle

Public Functions

inline Rect2Df(float myx, float myy, float mywidth, float myheight)#

Constructor, takes individual values.

Parameters
  • myx – offset x

  • myy – offset y

  • mywidth – extent width

  • myheight – extent height

inline Rect2Df()#

Constructor, sets to offset(0,0) and extent(1,1)

inline const Offset2Df &getOffset() const#

Get Offset.

Returns

Offset

inline void setOffset(const Offset2Df &inOffset)#

Set Offset.

Parameters

inOffset – Offset

inline const Extent2Df &getExtent() const#

Get Extent.

Returns

Extent

inline void setExtent(const Extent2Df &inExtent)#

Set Extent.

Parameters

inExtent – Extent

RenderPassCreateInfo#

Struct Documentation#

struct RenderPassCreateInfo#

RenderPass creation parameters.

Public Functions

inline RenderPassCreateInfo()#

RenderPassCreateInfo.

inline void clear()#

Clear all entries.

inline uint32_t getNumSubpasses() const#

Return number of subpasses (const)

Returns

Number of subpasses

inline const SubpassDescription &getSubpass(uint32_t index) const#

Get subpass (const)

Parameters

index – Subpass index

Returns

Subpas

inline uint32_t getNumSubpassDependencies() const#

Get number of subpass dependencies (const)

Returns

Number of subpass dependencies

inline const SubpassDependency &getSubpassDependency(uint32_t index) const#

Get subpass dependency (const)

Parameters

index – Subpass dependency index

Returns

SubpassDependency

inline uint32_t getNumAttachmentDescription() const#

Return number of color attachments (const)

Returns

Number of color attachments

inline const AttachmentDescription &getAttachmentDescription(uint32_t index) const#

Get render pass color info (const)

Parameters

indexColor info index

Returns

RenderPassColorInfo

inline RenderPassCreateInfo &setAttachmentDescription(uint32_t index, const AttachmentDescription &attachmentDescription)#

Add color info to the specified color attachment point.

Parameters
  • index – The color attachment point to add the color info, index must be consecutive

  • attachmentDescription – The attachment description to add to the attachment point

Returns

Reference to this object. (allow chaining)

inline RenderPassCreateInfo &setSubpass(uint32_t index, const SubpassDescription &subpass)#

Add a subpass to this renderpass.

Parameters
  • index – Index where to add the subpass, the index must be consective

  • subpass – The Subpass to add

Returns

Reference to this object. (allow chaining)

inline RenderPassCreateInfo &addSubpassDependency(const SubpassDependency &subPassDependency)#

Add a subpass dependecy to this renderpass.

Parameters

subPassDependency – The Subpass dependency to add

Returns

Reference to this object. (allow chaining)

inline RenderPassCreateInfo &addSubpassDependencies(const SubpassDependency *subPassDependencies, uint32_t numDependencies)#

Add subpass dependencies.

Parameters
  • subPassDependencies – Pointer to supass dependencies

  • numDependencies – Number of supass dependencies

Returns

Return this.

inline bool extendedSupportRequired() const#

Friends

friend class impl::RenderPass_

SamplerCreateInfo#

Struct Documentation#

struct SamplerCreateInfo#

Object describing the state of a sampler. Also used to construct a full-blown Sampler object.

Public Functions

inline SamplerCreateInfo()#

Default constructor.

Creates a Sampler with following configs. Can be edited after construction magnification filter: nearest, minifictation filter: nearest, mipmap filter: linear,wrap UVW: Repeat no comparison, no lod-bias, no anisotropy.

inline SamplerCreateInfo(pvrvk::Filter magniFilter, pvrvk::Filter miniFilter, pvrvk::SamplerMipmapMode mipMapFilter = pvrvk::SamplerMipmapMode::e_LINEAR, pvrvk::SamplerAddressMode wrapModeU = pvrvk::SamplerAddressMode::e_REPEAT, pvrvk::SamplerAddressMode wrapModeV = pvrvk::SamplerAddressMode::e_REPEAT, pvrvk::SamplerAddressMode wrapModeW = pvrvk::SamplerAddressMode::e_REPEAT)#

Constructor that sets the filters. Set the filtering mode explicitly. Wrap. Creates a Sampler with wrap:Repeat, no comparison, no lod bias, no anisotropy. Can be edited after construction.

Parameters
  • miniFilter – Minification filter: Nearest or Linear

  • magniFilter – Magnification filter: Nearest or Linear

  • mipMapFilter – Mipmap interpolation filter: Nearest or Linear

  • wrapModeU – The wrapping mode for the U coordinate

  • wrapModeV – The wrapping mode for the V coordinate

  • wrapModeW – The wrapping mode for the W coordinate

Public Members

pvrvk::Filter magFilter#

Texture Magnification interpolation filter. Nearest or Linear. Default Nearest.

pvrvk::Filter minFilter#

Texture Minification interpolation filter. Nearest or Linear. Default Nearest.

pvrvk::SamplerMipmapMode mipMapMode#

Texture Mipmap interpolation filter. Nearest, Linear or None (for no mipmaps). Default Linear.

pvrvk::SamplerAddressMode wrapModeU#

Texture Wrap mode, U (x) direction (Repeat, Mirror, MirrorRepeat, Border, Clamp). Default Repeat.

pvrvk::SamplerAddressMode wrapModeV#

Texture Wrap mode, V (y) direction (Repeat, Mirror, MirrorRepeat, Border, Clamp). Default Repeat.

pvrvk::SamplerAddressMode wrapModeW#

Texture Wrap mode, W (z) direction (Repeat, Mirror, MirrorRepeat, Border, Clamp). Default Repeat.

pvrvk::CompareOp compareOp#

Comparison mode for comparison samplers. Default None.

bool compareOpEnable#

Enable the compare op.

bool enableAnisotropy#

Enable anisotropic filtering.

float anisotropyMaximum#

Texture anisotropic filtering. Default 1.

float lodBias#

Texture level-of-detail bias (bias of mipmap to select). Default 0.

float lodMinimum#

Texture minimum level-of-detail (mipmap). Default 0.

float lodMaximum#

Texture maximum level-of-detail (mipmap). Default 0.

bool unnormalizedCoordinates#

Texture Coordinates are Un-Normalized.

pvrvk::BorderColor borderColor#

In case of a border address mode, the border color.

const void *pNext#

pNext chain for samplers

SemaphoreCreateInfo#

Struct Documentation#

struct SemaphoreCreateInfo#

Semaphore creation descriptor.

Public Functions

inline SemaphoreCreateInfo(SemaphoreCreateFlags flags = SemaphoreCreateFlags::e_NONE)#

Constructor.

Parameters

flags – Flags to use for creating the Semaphore

inline SemaphoreCreateFlags getFlags() const#

Get the Semaphore creation flags.

Returns

The set of Semaphore creation flags

inline void setFlags(SemaphoreCreateFlags flags)#

Set the Semaphore creation flags.

Parameters

flags – The Semaphore creation flags

inline void setSemaphoreType(SemaphoreType semaphoreType)#

Set the Semaphore type.

Parameters

semaphoreType – The Semaphore type

inline SemaphoreType getSemaphoreType() const#

Get the Semaphore type.

Returns

The Semaphore type

ShaderConstantInfo#

Struct Documentation#

struct ShaderConstantInfo#

A representation of a Shader constant.

Public Functions

inline ShaderConstantInfo()#

Constructor (Zero initialization)

inline bool isValid() const#

Return if this is a valid constant info.

Returns

bool

inline ShaderConstantInfo(uint32_t constantId, const void *data, uint32_t sizeOfData)#

Constructor. Initialise with inidividual values.

Parameters
  • constantId – ID of the specialization constant in SPIR-V.

  • data – Data, max can hold 4x4 matrix

  • sizeOfData – Data size in bytes

Public Members

uint32_t constantId#

ID of the specialization constant in SPIR-V.

unsigned char data[64]#

Data, max can hold 4x4 matrix.

uint32_t sizeInBytes#

Data size in bytes.

ShaderModuleCreateInfo#

Struct Documentation#

struct ShaderModuleCreateInfo#

ShaderModule creation descriptor.

Public Functions

inline ShaderModuleCreateInfo(ShaderModuleCreateFlags flags = ShaderModuleCreateFlags::e_NONE)#

Default Constructor.

Parameters

flags – A set of pvrvk::ShaderModuleCreateFlags defining how the ShaderModule will be created

inline ShaderModuleCreateInfo(const std::vector<uint32_t> &shaderSources, ShaderModuleCreateFlags flags = ShaderModuleCreateFlags::e_NONE)#

Constructor.

Parameters
  • shaderSources – Points to code that is used to create the shader module

  • flags – A set of pvrvk::ShaderModuleCreateFlags defining how the ShaderModule will be created

inline ShaderModuleCreateInfo(const uint32_t *shaderSources, uint32_t shaderSourcesSize, ShaderModuleCreateFlags flags = ShaderModuleCreateFlags::e_NONE)#

Constructor.

Parameters
  • shaderSources – Points to code that is used to create the shader module

  • shaderSourcesSize – The size of the shader sources in bytes

  • flags – A set of pvrvk::ShaderModuleCreateFlags defining how the ShaderModule will be created

inline ShaderModuleCreateFlags getFlags() const#

Get the ShaderModule creation flags.

Returns

The set of ShaderModule creation flags

inline void setFlags(ShaderModuleCreateFlags flags)#

Set the ShaderModule creation flags.

Parameters

flags – The ShaderModule creation flags

inline uint32_t getCodeSize() const#

Get the size of the shader sources.

Returns

The size of shader sources

inline const std::vector<uint32_t> &getShaderSources() const#

Get the shader sources.

Returns

The set of shader sources

inline void setShaderSources(const std::vector<uint32_t> &shaderSources)#

Set the shader sources to use for creating a shader module.

Parameters

shaderSources – Shader sources to use for creating a shader module

SparseBufferMemoryBindInfo#

Struct Documentation#

struct SparseBufferMemoryBindInfo#

Bind memory to sparse buffer object which has been created with VK_BUFFER_CREATE_SPARSE_BINDING_BIT flag.

Public Members

Buffer buffer#

Buffer object to be bound.

std::vector<SparseMemoryBind> binds#

array of sparse memory binds

SparseImageMemoryBind#

Struct Documentation#

struct SparseImageMemoryBind#

Bind memory to sparse image which has been created with pvrvk::ImageCreateFlags::e_SPARSE_BINDING_BIT flag.

Public Members

ImageSubresource subresource#

The aspectMask and region of interest in the image.

pvrvk::Offset3D offset#

Coordinates of the first texel within the image subresource to bind.

pvrvk::Extent3D extent#

the size in texels of the region within the image subresource to bind. The extent must be a multiple of the sparse image block dimensions, except when binding sparse image blocks along the edge of an image subresource it can instead be such that any coordinate of offset + extent equals the corresponding dimensions of the image subresource

DeviceMemory memory#

DeviceMemory object that the sparse image blocks of the image are bound to. If memory is null handle, the sparse image blocks are unbound.

uint64_t memoryOffset#

Offset into VkDeviceMemory object. If memory is null handle, this value is ignored.

pvrvk::SparseMemoryBindFlags flags#

Sparse memory binding flags.

SparseImageMemoryBindInfo#

Struct Documentation#

struct SparseImageMemoryBindInfo#

Bind memory sparse image blocks of image objects created with the VK_IMAGE_CREATE_SPARSE_RESIDENCY_BIT flag.

Public Members

Image image#

Buffer object to be bound.

std::vector<SparseImageMemoryBind> binds#

array of sparse memory binds

SparseImageOpaqueMemoryBindInfo#

Struct Documentation#

struct SparseImageOpaqueMemoryBindInfo#

Bind memory to opaque regions of image objects created with the VK_IMAGE_CREATE_SPARSE_BINDING_BIT flag.

Public Members

Image image#

Image object to be bound.

std::vector<SparseMemoryBind> binds#

array of sparse memory binds

SparseMemoryBind#

Struct Documentation#

struct SparseMemoryBind#

Containes memory bind data for SparseImageMemoryBind and SparseBufferMemoryBindInfo.

Public Members

uint64_t resourceOffset#

offset in to the resource

uint64_t size#

Size of the memory region to be bound.

DeviceMemory memory#

is the DeviceMemory object that the range of the resource is bound to. If memory is null handle, the range is unbound

uint64_t memoryOffset#

is the offset into the DeviceMemory object to bind the resource range to. If memory is null handle, this value is ignored

pvrvk::SparseMemoryBindFlags flags#

is a bitmask of pvrvk::SparseMemoryBindFlagBits specifying usage of the binding operation

SubmitInfo#

Struct Documentation#

struct SubmitInfo#

Queue submit info. Contains the commandbuffers to be summited to the queue.

Public Functions

inline SubmitInfo()#

Constructor. Default initialised to 0.

inline SubmitInfo(const pvrvk::PipelineStageFlags *waitDstStageMask, const CommandBuffer *commandBuffers, uint32_t numCommandBuffers, const Semaphore *waitSemaphores, uint32_t numWaitSemaphores, const Semaphore *signalSemaphores, uint32_t numSignalSemaphores)#

Constructor. Initialise with inidividual values.

Parameters
  • waitDstStageMask – pointer to an array of pipeline stages at which each corresponding semaphore wait will occur

  • commandBuffers – Pointer to an array of command buffers to execute in the batch

  • numCommandBuffers – The number of command buffers to execute in the batch

  • waitSemaphores – ointer to an array of semaphores upon which to wait before the command buffers for this batch begin execution

  • numWaitSemaphores – The number of semaphores upon which to wait before executing the command buffers for the batch

  • signalSemaphores – Pointer to an array of semaphores which will be signaled when the command buffers for this batch have completed execution

  • numSignalSemaphores – Number of semaphores to be signaled once the commands specified in pCommandBuffers have completed execution

Public Members

const PipelineStageFlags *waitDstStageMask#

pointer to an array of pipeline stages at which each corresponding semaphore wait will occur

const CommandBuffer *commandBuffers#

Pointer to an array of command buffers to execute in the batch.

uint32_t numCommandBuffers#

The number of command buffers to execute in the batch.

const Semaphore *waitSemaphores#

Pointer to an array of semaphores upon which to wait before the command buffers for this batch begin execution.

uint32_t numWaitSemaphores#

The number of semaphores upon which to wait before executing the command buffers for the batch.

const Semaphore *signalSemaphores#

Pointer to an array of semaphores which will be signaled when the command buffers for this batch have completed execution.

uint32_t numSignalSemaphores#

Number of semaphores to be signaled once the commands specified in pCommandBuffers have completed execution.

TimelineSemaphoreSubmitInfo *timelineSemaphoreSubmitInfo#

Additional struct required with timeline semaphores. It contains signal values.

SubpassDescription#

Struct Documentation#

struct SubpassDescription#

Render pass subpass. Subpasses allow intermediate draws to be chained and communicating with techniques like Pixel Local Storage without outputting to the FrameBuffer until the end of the RenderPass.

Public Functions

inline SubpassDescription(pvrvk::PipelineBindPoint pipeBindPoint = pvrvk::PipelineBindPoint::e_GRAPHICS)#

Constructor.

Parameters

pipeBindPoint – The binding point for this subpass (Graphics, Compute). Default Graphics.

inline SubpassDescription &setPipelineBindPoint(pvrvk::PipelineBindPoint bindingPoint)#

Set the pipeline binding point.

Parameters

bindingPoint – New pipeline binding point

Returns

Reference to this(allows chaining)

inline SubpassDescription &setColorAttachmentReference(uint32_t bindingIndex, const AttachmentReference &attachmentReference)#

Activate the specified color output attachment of the framebuffer.

Parameters
  • bindingIndex – Corresponding fragment shader output location. The Index must start from 0 and must be consective.

  • attachmentReference – Attachment to activate as output

Returns

Reference to this(allows chaining)

inline SubpassDescription &setInputAttachmentReference(uint32_t bindingIndex, const AttachmentReference &attachmentReference)#

Set the specified color attachment as input.

Parameters
  • bindingIndex – Corresponding fragment shader input location. The Index must start from 0 and must be consective.

  • attachmentReference – Attachment to set as input

Returns

Reference to this(allows chaining)

inline SubpassDescription &setResolveAttachmentReference(uint32_t bindingIndex, const AttachmentReference &attachmentReference)#

Activate the specified Resolve attachment of the framebuffer.

Parameters
  • bindingIndex – Corresponding fragment shader input location. The Index must start from 0 and must be consective.

  • attachmentReference – Attachment to set as resolve

Returns

this (allow chaining)

inline SubpassDescription &setPreserveAttachmentReference(uint32_t bindingIndex, const uint32_t preserveAttachment)#

Set preserve attachment from the framebuffer.

Parameters
  • bindingIndex – The Index must start from 0 and must be consective.

  • preserveAttachment – Attachment to set as preserve

Returns

Reference to this(allows chaining)

this (allow chaining)

inline SubpassDescription &setDepthStencilAttachmentReference(const AttachmentReference &attachmentReference)#

Sets depth stencil attachment reference.

Parameters

attachmentReference – New depth-stencil attachment reference

Returns

Reference to this(allows chaining)

inline SubpassDescription &setFragmentShadingRateAttachment(const FragmentShadingRateAttachmentInfo &attachmentInfo)#
inline uint8_t getNumColorAttachmentReference() const#

Return number of color attachments.

Returns

Return number of color attachment references

inline uint8_t getNumInputAttachmentReference() const#

Return number of input attachments.

Returns

Return number of input attachment references

inline uint8_t getNumResolveAttachmentReference() const#

Get number of resolve attachments (const)

Returns

Number of resolve attachments

inline uint8_t getNumPreserveAttachmentReference() const#

Return number of preserve attachments (const)

/

Returns

Number of preserve attachments

inline pvrvk::PipelineBindPoint getPipelineBindPoint() const#

Get pipeline binding point (const)

Returns

Returns Pipeline binding point

inline const AttachmentReference &getInputAttachmentReference(uint8_t index) const#

Get input attachment id (const)

Parameters

index – Attachment index

Returns

Input attachment id

inline const AttachmentReference &getDepthStencilAttachmentReference() const#

Get depth stencil attachment reference (const).

Returns

Return depth-stencil attachment reference id

inline const AttachmentReference &getColorAttachmentReference(uint8_t index) const#

Get color attachment id (const)

Parameters

index – Attachment index

Returns

Color attachment id

inline const AttachmentReference &getResolveAttachmentReference(uint8_t index) const#

Get resolve attachment id (const)

Parameters

index – Attachment index

Returns

Resolve attachment id

inline uint32_t getPreserveAttachmentReference(uint8_t index) const#

Get preserve attachment id (const)

Parameters

index – Attachment index

Returns

Preserve attachment id

inline const uint32_t *getAllPreserveAttachments() const#

Get all preserve attahments ids (const)

(const)

Returns

Return all preserve attachments id

inline const FragmentShadingRateAttachmentInfo &getFragmentShadingRateAttachment() const#
inline SubpassDescription &clear()#

clear all entries

Returns

Returns this object (allows chained calls)

SwapchainCreateInfo#

Struct Documentation#

struct SwapchainCreateInfo#

Contains swapchain create informations.

Public Functions

inline SwapchainCreateInfo()#

Constructor. Default intialised.

inline SwapchainCreateInfo(Surface surface, uint32_t minImageCount, Extent2D imageExtent, SwapchainCreateFlagsKHR flags, uint32_t numQueueFamilyIndex, const uint32_t *queueFamilyIndices, ImageUsageFlags imageUsage, Format imageFormat = Format::e_R8G8B8A8_UNORM, ColorSpaceKHR imageColorSpace = ColorSpaceKHR::e_PASS_THROUGH_EXT, PresentModeKHR presentMode = PresentModeKHR::e_FIFO_KHR, uint32_t imageArrayLayers = 1, SharingMode imageSharingMode = SharingMode::e_EXCLUSIVE, SurfaceTransformFlagsKHR preTransform = SurfaceTransformFlagsKHR::e_IDENTITY_BIT_KHR, CompositeAlphaFlagsKHR compositeAlpha = CompositeAlphaFlagsKHR::e_OPAQUE_BIT_KHR, bool clipped = true, Swapchain oldSwapchain = Swapchain())#

Constructor.

Parameters
  • surface – The surface onto which the swapchain will present images

  • minImageCount – The minimum number of presentable images that the application needs

  • imageExtent – The size (in pixels) of the swapchain image(s)

  • flags – A set of pvrvk::SwapchainCreateFlagsKHR indicating parameters of the swapchain creation.

  • numQueueFamilyIndex – The number of queue families having access to the image(s) of the swapchain when imageSharingMode is VK_SHARING_MODE_CONCURRENT

  • queueFamilyIndices – An array of queue family indices having access to the images(s) of the swapchain when imageSharingMode is VK_SHARING_MODE_CONCURRENT

  • imageUsage – A set of pvrvk::ImageUsageFlags describing the intended usage of the (acquired) swapchain images.

  • imageFormat – A pvrvk::Format value specifying the format the swapchain image(s) will be created with.

  • imageColorSpace – A pvrvk::ColorSpaceKHR value specifying the way the swapchain interprets image data.

  • presentMode – The presentation mode the swapchain will use.

  • imageArrayLayers – The number of views in a multiview/stereo surface

  • imageSharingMode – The sharing mode used for the image(s) of the swapchain.

  • preTransform – A pvrvk::SurfaceTransformFlagsKHR value describing the transform, relative to the presentation engine’s natural orientation, applied to the image content prior to presentation. If it does not match the currentTransform value returned by vkGetPhysicalDeviceSurfaceCapabilitiesKHR, the presentation engine will transform the image content as part of the presentation operation.

  • compositeAlpha – A pvrvk::CompositeAlphaFlagsKHR value indicating the alpha compositing mode to use when this surface is composited together with other surfaces on certain window systems.

  • clipped – Specifies whether the Vulkan implementation is allowed to discard rendering operations that affect regions of the surface that are not visible.

  • oldSwapchain – Is a null pvrvk::Swapchain, or the existing non-retired swapchain currently associated with surface.

Public Members

SwapchainCreateFlagsKHR flags#

Bitmask of SwapchainCreateFlagBitsKHR indicating parameters of swapchain creation.

Surface surface#

The surface that the swapchain will present images to.

uint32_t minImageCount#

The minimum number of presentable images that the application needs. The platform will either create the swapchain with at least that many images, or will fail to create the swapchain

Format imageFormat#

Format that is valid for swapchains on the specified surface.

ColorSpaceKHR imageColorSpace#

ColorSpaceKHR that is valid for swapchains on the specified surface.

Extent2D imageExtent#

Size (in pixels) of the swapchain. Behavior is platform-dependent when the image extent does not match the surface’s currentExtent as returned by PysicalDevice::getSurfaceCapabilities

uint32_t imageArrayLayers#

Number of views in a multiview/stereo surface. For non-stereoscopic-3D applications, this value is 1.

ImageUsageFlags imageUsage#

Bitmask of ImageUsageFlagBits, indicating how the application will use the swapchain’s presentable images.

SharingMode imageSharingMode#

Sharing mode used for the images of the swapchain.

uint32_t numQueueFamilyIndex#

Number of queue families having access to the images of the swapchain in case imageSharingMode is VKSharingMode::e_CONCURRENT.

const uint32_t *queueFamilyIndices#

Array of queue family indices having access to the images of the swapchain in case imageSharingMode is VKSharingMode::e_CONCURRENT.

SurfaceTransformFlagsKHR preTransform#

Bitmask of SurfaceTransformFlagBitsKHR, describing the transform, relative to the presentation engine’s natural orientation, applied to the image content prior to presentation

CompositeAlphaFlagsKHR compositeAlpha#

Bitmask of CompositeAlphaFlagBitsKHR indicating the alpha compositing mode to use when this surface is composited together with other surfaces on certain window systems

PresentModeKHR presentMode#

Presentation mode the swapchain will use. A swapchain’s present mode determines how incoming present requests will be processed and queued internally.

bool clipped#

indicates whether the Vulkan implementation is allowed to discard rendering operations that affect regions of the surface which are not visible

Swapchain oldSwapchain#

If not null handle, specifies the swapchain that will be replaced by the new swapchain being created. The new swapchain will be a descendant of oldSwapchain. Further, any descendants of the new swapchain will also be descendants of oldSwapchain

TesselationStageCreateInfo#

Struct Documentation#

struct TesselationStageCreateInfo#

Creation parameters for all Tesselation shaders.

Public Functions

inline TesselationStageCreateInfo()#

Constructor.

inline const ShaderModule &getControlShader() const#

Get the Tessellation Control shader.

Returns

The Tessellation Control shader

inline const ShaderModule &getEvaluationShader() const#

Get the Tessellation Evaluation shader.

Returns

The Tessellation Evaluation shader

inline bool isControlShaderActive() const#

Check if the Tessellation Control shader has been set.

Returns

true if the Tessellation Control shader has been set

inline bool isEvaluationShaderActive() const#

Check if the Tessellation Evaluation shader has been set.

Returns

true if the Tessellation Evaluation shader has been set

inline TesselationStageCreateInfo &setControlShader(const ShaderModule &shader)#

Set the control shader.

Parameters

shader – A shader to set to the Tessellation Control stage

Returns

this (allow chaining)

inline TesselationStageCreateInfo &setControlShaderEntryPoint(const char *entryPoint)#

Set control shader entry point.

Parameters

entryPoint – Entrypoint

Returns

TesselationStageCreateInfo&

inline TesselationStageCreateInfo &setEvaluationShaderEntryPoint(const char *entryPoint)#

Set evaluation shader entry point.

Parameters

entryPoint – Entrypoint

Returns

TesselationStageCreateInfo&

inline TesselationStageCreateInfo &setEvaluationShader(const ShaderModule &shader)#

Set the control shader.

Parameters

shader – A shader to set to the Tessellation Control stage

Returns

this (allow chaining)

inline TesselationStageCreateInfo &setNumPatchControlPoints(uint32_t controlPoints)#

Set number of control points.

Parameters

controlPoints – The number of control points per patch

Returns

this (allow chaining)

inline uint32_t getNumPatchControlPoints() const#

Get number of control points.

Returns

The number of patch control points

inline TesselationStageCreateInfo &setControlShaderConstant(uint32_t index, const ShaderConstantInfo &shaderConst)#

Set a shader constant for the Tessellation Control shader.

Parameters
  • index – Index of the constant to set

  • shaderConst – Value of the constant to set

Returns

Return this for chaining

inline TesselationStageCreateInfo &setControlShaderConstants(const ShaderConstantInfo *shaderConsts, uint32_t numConstants)#

Set all Tessellation Control shader constants.

Uses better memory reservation than the setShaderConstant counterpart.

Parameters
  • shaderConsts – A c-style array containing the shader constants

  • numConstants – The number of shader constants in shaderConsts

Returns

Return this (allow chaining)

inline const ShaderConstantInfo &getControlShaderConstant(uint32_t index) const#

Get a Control shader constant.

Parameters

index – The index of the constant to get. It is undefined to retrieve a constant that does not exist.

Returns

The Constant to get

inline const ShaderConstantInfo *getAllControlShaderConstants() const#

Return all control shader constants as a c-style array.

Returns

C-style array of all shader constants

inline uint32_t getNumControlShaderConstants() const#

Return number of control shader constants.

Returns

uint32_t

inline void setEvaluationShaderConstant(uint32_t index, const ShaderConstantInfo &shaderConst)#

Set a shader constant for the Tessellation Evaluation shader.

Parameters
  • index – Index of the constant to set

  • shaderConst – Value of the constant to set

Returns

Return this for chaining

inline TesselationStageCreateInfo &setEvaluationShaderConstants(const ShaderConstantInfo *shaderConsts, uint32_t numConstants)#

Set all Tessellation Evaluation shader constants.

Uses better memory reservation than the setShaderConstant counterpart.

Parameters
  • shaderConsts – A c-style array containing the shader constants

  • numConstants – The number of shader constants in shaderConsts

Returns

Return this (allow chaining)

inline const ShaderConstantInfo &getEvaluationlShaderConstant(uint32_t index) const#

Get Evaluation shader constants.

Parameters

index – The index of the constant to retrieve. It is undefined to retrieve a constant that does not exist.

Returns

The ShaderConstantInfo at index index

inline const ShaderConstantInfo *getAllEvaluationShaderConstants() const#

Return all evaluationshader constants.

Returns

const ShaderConstantInfo*

inline uint32_t getNumEvaluatinonShaderConstants() const#

Return number of evaluatinon shader constants.

Returns

The number of evaluatinon shader constants

inline const char *getEvaluationShaderEntryPoint() const#

Get evaluation shader entry point.

Returns

const char*

inline const char *getControlShaderEntryPoint() const#

Get control shader entry point.

Returns

const char*

Friends

friend class ::pvrvk::impl::GraphicsPipeline_

TimelineSemaphoreSubmitInfo#

Struct Documentation#

struct TimelineSemaphoreSubmitInfo#

Timeline Semaphore submit info. Contains the information on timeline semaphores.

Public Functions

inline TimelineSemaphoreSubmitInfo()#

Constructor. Default initialised to 0.

inline TimelineSemaphoreSubmitInfo(uint32_t waitSemaphoreValueCount, const uint64_t *waitSemaphoreValues, uint32_t signalSemaphoreValueCount, const uint64_t *signalSemaphoreValues)#

Public Members

uint32_t waitSemaphoreValueCount#
const uint64_t *waitSemaphoreValues#
uint32_t signalSemaphoreValueCount#
const uint64_t *signalSemaphoreValues#

ValidationFeatures#

Struct Documentation#

struct ValidationFeatures#

Containes a ValidationFeatures structure which specifies a set of validation features which should be enabled or disabled.

Public Functions

ValidationFeatures() = default#

Constructor. Default initialised to 0.

inline void addEnabledValidationFeature(ValidationFeatureEnableEXT enabledFeature)#

Adds a new Enabled Validation Feature.

Parameters

enabledFeature – A ValidationFeatureEnableEXT which specifies a validation feature to enable.

inline void addDisabledValidationFeature(ValidationFeatureDisableEXT disabledFeature)#

Adds a new Disabled Validation Feature.

Parameters

disabledFeature – A ValidationFeatureDisableEXT which specifies a validation feature to disable.

inline uint32_t getNumEnabledValidationFeatures() const#

Get the number of enabled validation features.

Returns

The number of enabled validation features

inline uint32_t getNumDisabledValidationFeatures() const#

Get the number of disabled validation features.

Returns

The number of disabled validation features

inline const std::vector<ValidationFeatureEnableEXT> &getEnabledValidationFeatures() const#

Get the list of enabled validation features (const)

Returns

The list of enabled validation features (const)

inline std::vector<ValidationFeatureEnableEXT> &getEnabledValidationFeatures()#

Get the list of enabled validation features.

Returns

The list of enabled validation features

inline const ValidationFeatureEnableEXT &getEnabledValidationFeature(uint32_t index) const#

Get the the enabled validation feature at index.

Parameters

index – The index of the enabled validation feature to retrieve.

Returns

The enabled validation feature at index

inline const std::vector<ValidationFeatureDisableEXT> &getDisabledValidationFeatures() const#

Get the list of disabled validation features (const)

Returns

The list of disabled validation features (const)

inline std::vector<ValidationFeatureDisableEXT> &getDisabledValidationFeatures()#

Get the list of disabled validation features.

Returns

The list of disabled validation features

inline const ValidationFeatureDisableEXT &getDisabledValidationFeature(uint32_t index) const#

Get the the disabled validation feature at index.

Parameters

index – The index of the disabled validation feature to retrieve.

Returns

The disabled validation feature at index

inline void setEnabledValidationFeatures(const std::vector<ValidationFeatureEnableEXT> &enabledValidationFeatures)#

Sets the list of enabled validation features.

Parameters

enabledValidationFeatures – A list of validation features to enable.

inline void setDisabledValidationFeatures(const std::vector<ValidationFeatureDisableEXT> &disabledValidationFeatures)#

Sets the list of disabled validation features.

Parameters

disabledValidationFeatures – A list of validation features to disable.

inline void clearEnabledValidationFeatures()#

Clears the list of validation features to enable.

inline void clearDisabledValidationFeatures()#

Clears the list of validation features to disable.

VulkanExtension#

Struct Documentation#

struct VulkanExtension#

A wrapper for a Vulkan extension and its specification version.

Public Functions

inline VulkanExtension(std::string name = "", uint32_t specVersion = -1)#

Constructor.

Parameters
  • name – The name of the Vulkan extension

  • specVersion – The spec version of the Vulkan extension

inline const std::string &getName() const#

Get the name of the Vulkan extension.

Returns

The name of the Vulkan extension

inline void setName(std::string name)#

Set the name of the Vulkan extension.

Parameters

name – The name of the Vulkan extension

inline uint32_t getSpecVersion() const#

Get the spec version of the Vulkan extension.

Returns

The spec version of the Vulkan extension

inline void setSpecVersion(uint32_t specVersion)#

Set the spec version of the Vulkan extension.

Parameters

specVersion – The spec version of the Vulkan extension

inline bool operator==(const VulkanExtension &rhs) const#

Overridden operator==.

Parameters

rhs – The VulkanLayer to compare against for equality

Returns

True if the VulkanExtension matches this

VulkanExtensionList#

Struct Documentation#

struct VulkanExtensionList#

A wrapper for a list of Vulkan extensions.

Public Functions

VulkanExtensionList() = default#

Constructor.

inline uint32_t getNumExtensions() const#

Get the number of extensions.

Returns

Theextensions

inline const std::vector<VulkanExtension> &getExtensions() const#

Get the list of extensions.

Returns

A list of extensions

inline const VulkanExtension &getExtension(uint32_t index) const#

Retrieve the extension at the index specified.

Parameters

index – The index of the extension to retrieve

Returns

The extension at the index specified

inline void setExtensions(const std::vector<VulkanExtension> &extensions)#

Sets the extensions list.

Parameters

extensions – A list of extensions to enable

inline void addExtension(const VulkanExtension &extension)#

Add a new extension.

Parameters

extension – A new extension.

inline void addExtension(const std::string &extensionName)#

Add a new extension to add by name.

Parameters

extensionName – A new extension.

inline void removeExtension(const VulkanExtension &extension)#

Removes a particular extension from the list of extensions.

Parameters

extension – The extension to remove from the existing list of extensions

inline void removeExtension(const std::string &extensionName)#

Removes a particular extension from the list of extensions using only an extension name.

Parameters

extensionName – The extension to remove from the existing list of extensions using only its name

inline bool containsExtension(const std::string &extensionName) const#

Check if extension is enabled.

Parameters

extensionName – Extension name

Returns

Return true if it is enabled

inline bool containsExtension(const VulkanExtension &extension) const#

Check if extension is enabled.

Parameters

extension – Extension

Returns

Return true if it is enabled

inline void *getLastRequestedExtensionFeature() const#

Get the extension feature pointer.

Returns

The extension feature pointer

template<class T>
inline void addExtensionFeatureVk(VkStructureType type, T *extension)#
template<class T>
inline void addExtensionFeatureVk(T *extension)#

Protected Attributes

std::vector<pvrvk::VulkanExtension> _extensions#
std::map<VkStructureType, void*> _extensionFeatures#
void *_lastRequestedExtensionFeature = {nullptr}#

!< Map with extension type and void pointer to a struct of that type

VulkanLayer#

Struct Documentation#

struct VulkanLayer#

A wrapper for a Vulkan layer, its specification version, implementation version and its description.

Public Functions

inline VulkanLayer(const std::string &name = "", uint32_t specVersion = -1, uint32_t implementationVersion = -1, const std::string &description = "")#

Constructor.

Parameters
  • name – The name of the Vulkan extension

  • specVersion – The spec version of the Vulkan extension

  • implementationVersion – The implementation version of the Vulkan layer

  • description – The description of the Vulkan layer

inline const std::string &getName() const#

Get the name of the Vulkan layer.

Returns

The name of the Vulkan layer

inline void setName(std::string name)#

Set the name of the Vulkan layer.

Parameters

name – The name of the Vulkan layer

inline uint32_t getSpecVersion() const#

Get the spec version of the Vulkan layer.

Returns

The spec version of the Vulkan layer

inline void setSpecVersion(uint32_t specVersion)#

Set the spec version of the Vulkan layer.

Parameters

specVersion – The spec version of the Vulkan layer

inline uint32_t getImplementationVersion() const#

Get the implementation version of the Vulkan layer.

Returns

The implementation version of the Vulkan layer

inline void setImplementationVersion(uint32_t implementationVersion)#

Set the implementation version of the Vulkan layer.

Parameters

implementationVersion – The implementation version of the Vulkan layer

inline const std::string &getDescription() const#

Get the description of the Vulkan layer.

Returns

The description of the Vulkan layer

inline void setDescription(std::string description)#

Set the description of the Vulkan layer.

Parameters

description – The description of the Vulkan layer

inline bool operator==(const VulkanLayer &rhs) const#

Overridden operator==.

Parameters

rhs – The VulkanLayer to compare against for equality

Returns

True if the VulkanLayer matches this

VulkanLayerList#

Struct Documentation#

struct VulkanLayerList#

A wrapper for a list of Vulkan layers.

Public Functions

VulkanLayerList() = default#

Constructor.

inline uint32_t getNumLayers() const#

Get the number of layers.

Returns

Thelayers

inline const std::vector<VulkanLayer> &getLayers() const#

Get the list of layers.

Returns

A list of layers

inline const VulkanLayer &getLayer(uint32_t index) const#

Retrieve the layer at the index specified.

Parameters

index – The index of the layer to retrieve

Returns

The layer at the index specified

inline void setLayers(const std::vector<VulkanLayer> &layers)#

Sets the layers list.

Parameters

layers – A list of layers to enable

inline void addLayer(const VulkanLayer &layer)#

Add a new layer.

Parameters

layer – A new layer.

inline void addLayer(const std::string &layerName)#

Add a new layer to add by name.

Parameters

layerName – A new layer.

inline void removeLayer(const VulkanLayer &layer)#

Removes a particular layer from the list of layers.

Parameters

layer – The layer to remove from the existing list of layers

inline void removeLayer(const std::string &layerName)#

Removes a particular layer from the list of layers using only an layer name.

Parameters

layerName – The layer to remove from the existing list of layers using only its name

inline bool containsLayer(const std::string &layerName) const#

Check if layer is enabled.

Parameters

layerName – Layer name

Returns

Return true if enabled

inline bool containsLayer(const VulkanLayer &layer) const#

Check if layer is enabled.

Parameters

layer – Layer

Returns

Return true if enabled

WriteDescriptorSet#

Nested Relationships#

Nested Types#

Struct Documentation#

struct WriteDescriptorSet#

Contains information for an initialization/update of a descriptor set. This class contains both the update AND the descriptor set to be updated, so that multiple descriptor sets can be updated in a single call to Device::updateDescriptorSets.

Public Functions

inline WriteDescriptorSet()#

Constructor. Undefined values.

inline WriteDescriptorSet(pvrvk::DescriptorType descType, DescriptorSet descSet, uint32_t dstBinding = 0, uint32_t dstArrayElement = 0)#

Constructor. Initializes with a specified descriptor into a set.

Parameters
  • descType – The descriptor type of this write

  • descSet – The descriptor set which to update

  • dstBinding – The binding to update

  • dstArrayElement – If the destination is an array, the array index to update

inline WriteDescriptorSet &setDescriptorType(pvrvk::DescriptorType descType)#

Set the descriptor type.

Parameters

descType – The descriptor type

Returns

This object (allow chaining)

inline WriteDescriptorSet &setDescriptorSet(DescriptorSet &descriptorSet)#

Set the descriptor set.

Parameters

descriptorSet – The descriptor set that will be updated

Returns

This object (allow chaining)

inline WriteDescriptorSet &setDestBinding(uint32_t binding)#

Set the destination binding.

Parameters

binding – The binding into the descriptor set

Returns

This object (allow chaining)

inline WriteDescriptorSet &setDestArrayElement(uint32_t arrayElement)#

Set destination array element.

Parameters

arrayElement – Array element.

Returns

This object (allow chaining)

inline WriteDescriptorSet &set(pvrvk::DescriptorType newDescType, const DescriptorSet &descSet, uint32_t dstBinding = 0, uint32_t dstArrayElement = 0)#

Sets all the data of this write.

Parameters
  • newDescType – The new descriptor type

  • descSet – The new descriptor set

  • dstBinding – The new destination Binding in spir-v

  • dstArrayElement – If the target descriptor is an array, the index to update.

Returns

This object (allow chaining)

inline WriteDescriptorSet &setImageInfo(uint32_t arrayIndex, const DescriptorImageInfo &imageInfo)#

If the target descriptor is an image, set the image info image info.

Parameters
  • arrayIndex – The target array index

  • imageInfo – The image info to set

Returns

This object (allow chaining)

inline WriteDescriptorSet &setBufferInfo(uint32_t arrayIndex, const DescriptorBufferInfo &bufferInfo)#

If the target descriptor is a buffer, sets the buffer info.

Parameters
  • arrayIndex – If an array, the target array index

  • bufferInfo – The buffer info to set

Returns

This object(allow chaining)

inline WriteDescriptorSet &setAccelerationStructureInfo(uint32_t arrayIndex, const AccelerationStructure &accelerationStructure)#

If the target descriptor is an acceleration structure, sets the acceleration structure.

Parameters
  • arrayIndex – If an array, the target array index

  • accelerationStructure – The acceleration structure to set

Returns

This object(allow chaining)

inline WriteDescriptorSet &setTexelBufferInfo(uint32_t arrayIndex, const BufferView &bufferView)#

If the target descriptor is a Texel buffer, set the Texel Buffer info.

Parameters
  • arrayIndex – If an array, the target array index

  • bufferView – The Texel Buffer view to set

Returns

This object(allow chaining)

inline WriteDescriptorSet &clearAllInfos()#

Clear all info of this object.

Returns

This object(allow chaining)

inline uint32_t getNumDescriptors() const#

Get the number of descriptors being updated.

Returns

The the number of descriptors

inline pvrvk::DescriptorType getDescriptorType() const#

Get descriptor type.

Returns

The descriptor type

inline DescriptorSet getDescriptorSet()#

Get descriptor set to update.

Returns

The descriptor set

inline const DescriptorSet &getDescriptorSet() const#

Get the descriptor set to update.

Returns

The descriptor set

inline uint32_t getDestArrayElement() const#

If an array, get the destination array element.

Returns

The destination array element

inline uint32_t getDestBinding() const#

Get the destination binding indiex.

Returns

The destination binding index

Friends

friend class ::pvrvk::impl::Device_

WriteDescriptorSet::DescriptorInfos#

Nested Relationships#

This struct is a nested type of WriteDescriptorSet.

Struct Documentation#

struct DescriptorInfos#

Public Functions

DescriptorInfos() = default#
inline bool isValid() const#

Public Members

DescriptorImageInfo imageInfo#
DescriptorBufferInfo bufferInfo#
BufferView texelBuffer#
AccelerationStructure accelerationStructure#