The IConstantBuffer property interface. More...

#include "murl_graph_i_constant_buffer.h"

Inheritance diagram for Murl::Graph::IConstantBuffer:

Public Member Functions

virtual SInt32 GetIndex () const =0
 Get the zero-based index of this constant buffer. More...
 
virtual const StringGetName () const =0
 Get the constant buffer's name. More...
 
virtual IEnums::ConstantBufferItem GetItem () const =0
 Get the constant buffer's predefined item. More...
 
virtual Bool SetMaxByteSize (UInt32 maxByteSize, Bool preserveContents)=0
 Set the maximum byte size of the constant buffer. More...
 
virtual UInt32 GetMaxByteSize () const =0
 Get the maximum capacity of the constant buffer in bytes. More...
 
virtual Bool SetByteSize (UInt32 byteSize)=0
 Set the total byte size of all variables in the constant buffer. More...
 
virtual UInt32 GetByteSize () const =0
 Get the total byte size of all variables in the constant buffer. More...
 
virtual void * GetConstantData ()=0
 Retrieve a mutable pointer to the variable data stored in the buffer. More...
 
virtual const void * GetConstantData () const =0
 Retrieve a constant pointer to the variable data stored in the buffer. More...
 
virtual Bool SetConstantsModified ()=0
 Mark the constant buffer as modified. More...
 
- Public Member Functions inherited from Murl::Graph::IUniformContainer
virtual SInt32 AddUniform (IEnums::UniformItem item, IEnums::UniformType type, UInt32 &byteOffset)=0
 Add a predefined shader uniform variable. More...
 
virtual SInt32 AddUniform (const String &name, IEnums::UniformType type, UInt32 &byteOffset)=0
 Add a user-defined shader uniform variable. More...
 
virtual SInt32 GetUniformIndex (IEnums::UniformItem item) const =0
 Query the location of a predefined uniform variable in the container. More...
 
virtual SInt32 GetUniformIndex (const String &name) const =0
 Query the location of a user-defined uniform variable in the container. More...
 
virtual UInt32 GetNumberOfUniforms () const =0
 Get the total number of individual uniform variables in the container. More...
 
virtual IEnums::UniformType GetUniformType (UInt32 index) const =0
 Query the type of a uniform variable at a given index. More...
 
virtual IEnums::UniformItem GetUniformItem (UInt32 index) const =0
 Query the predefined item of a uniform variable at a given index. More...
 
virtual const StringGetUniformName (UInt32 index) const =0
 Query the variable name of a uniform at a given index. More...
 
virtual UInt32 GetUniformByteOffset (UInt32 index) const =0
 Get the byte offset of a uniform at a given index. More...
 
virtual IUniformGetUniform (UInt32 index) const =0
 Get the uniform object at a given index. More...
 
virtual IFloatUniformGetFloatUniform (UInt32 index) const =0
 Get the attribute at a given index as a scalar 32bit floating point object. More...
 
virtual IFloatVector2UniformGetFloatVector2Uniform (UInt32 index) const =0
 Get the uniform at a given index as a 2-component 32bit floating point vector object. More...
 
virtual IFloatVector3UniformGetFloatVector3Uniform (UInt32 index) const =0
 Get the uniform at a given index as a 3-component 32bit floating point vector object. More...
 
virtual IFloatVector4UniformGetFloatVector4Uniform (UInt32 index) const =0
 Get the uniform at a given index as a 4-component 32bit floating point vector object. More...
 
virtual IFloatMatrix2UniformGetFloatMatrix2Uniform (UInt32 index) const =0
 Get the uniform at a given index as a 2x2-component 32bit floating point matrix object. More...
 
virtual IFloatMatrix3UniformGetFloatMatrix3Uniform (UInt32 index) const =0
 Get the uniform at a given index as a 3x3-component 32bit floating point matrix object. More...
 
virtual IFloatMatrix4UniformGetFloatMatrix4Uniform (UInt32 index) const =0
 Get the uniform at a given index as a 4x4-component 32bit floating point matrix object. More...
 
virtual ISInt32UniformGetSInt32Uniform (UInt32 index) const =0
 Get the attribute at a given index as a scalar 32bit signed integer object. More...
 
virtual ISInt32Vector2UniformGetSInt32Vector2Uniform (UInt32 index) const =0
 Get the uniform at a given index as a 2-component 32bit signed integer vector object. More...
 
virtual ISInt32Vector3UniformGetSInt32Vector3Uniform (UInt32 index) const =0
 Get the uniform at a given index as a 3-component 32bit signed integer vector object. More...
 
virtual ISInt32Vector4UniformGetSInt32Vector4Uniform (UInt32 index) const =0
 Get the uniform at a given index as a 4-component 32bit signed integer vector object. More...
 

Detailed Description

The IConstantBuffer property interface.

This interface provides properties common to a class representing an array of individual uniform variables, grouped together in order to quickly activate them for a shader program.

Member Function Documentation

◆ GetIndex()

virtual SInt32 Murl::Graph::IConstantBuffer::GetIndex ( ) const
pure virtual

Get the zero-based index of this constant buffer.

Returns
The constant buffer's index inside the parent container.

◆ GetName()

virtual const String& Murl::Graph::IConstantBuffer::GetName ( ) const
pure virtual

Get the constant buffer's name.

Returns
The name.

◆ GetItem()

virtual IEnums::ConstantBufferItem Murl::Graph::IConstantBuffer::GetItem ( ) const
pure virtual

Get the constant buffer's predefined item.

If the constant buffer is a user-defined one, this method always returns IEnums::CONSTANT_BUFFER_ITEM_CUSTOM.

Returns
The constant buffer item.

◆ SetMaxByteSize()

virtual Bool Murl::Graph::IConstantBuffer::SetMaxByteSize ( UInt32  maxByteSize,
Bool  preserveContents 
)
pure virtual

Set the maximum byte size of the constant buffer.

Parameters
maxByteSizeThe maximum capacity in bytes.
preserveContentsIf true, existing contents will be copied; but existing data beyond the new capacity is discarded.
Returns
true if successful.

◆ GetMaxByteSize()

virtual UInt32 Murl::Graph::IConstantBuffer::GetMaxByteSize ( ) const
pure virtual

Get the maximum capacity of the constant buffer in bytes.

Returns
The maximum capacity.

◆ SetByteSize()

virtual Bool Murl::Graph::IConstantBuffer::SetByteSize ( UInt32  byteSize)
pure virtual

Set the total byte size of all variables in the constant buffer.

Parameters
byteSizeThe currently used total number of bytes for all variables.
Returns
true if successful.

◆ GetByteSize()

virtual UInt32 Murl::Graph::IConstantBuffer::GetByteSize ( ) const
pure virtual

Get the total byte size of all variables in the constant buffer.

Returns
The currently used total number of bytes for all variables.

◆ GetConstantData() [1/2]

virtual void* Murl::Graph::IConstantBuffer::GetConstantData ( )
pure virtual

Retrieve a mutable pointer to the variable data stored in the buffer.

Returns
A mutable pointer to the data.

◆ GetConstantData() [2/2]

virtual const void* Murl::Graph::IConstantBuffer::GetConstantData ( ) const
pure virtual

Retrieve a constant pointer to the variable data stored in the buffer.

Returns
A constant pointer to the data.

◆ SetConstantsModified()

virtual Bool Murl::Graph::IConstantBuffer::SetConstantsModified ( )
pure virtual

Mark the constant buffer as modified.

Returns
true if successful.

The documentation for this interface was generated from the following file:
  • murl_graph_i_constant_buffer.h


Copyright © 2011-2024 Spraylight GmbH.