![]() |
Murl Engine API
Version 2018.3
|
The IConstantBuffer property interface. More...
#include <murl_graph_i_constant_buffer.h>
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.
Public Member Functions | |
virtual SInt32 | GetIndex () const =0 |
Get the zero-based index of this constant buffer. More... | |
virtual const String & | GetName () 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... | |
![]() | |
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 String & | GetUniformName (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 IUniform * | GetUniform (UInt32 index) const =0 |
Get the uniform object at a given index. More... | |
virtual IFloatUniform * | GetFloatUniform (UInt32 index) const =0 |
Get the attribute at a given index as a scalar 32bit floating point object. More... | |
virtual IFloatVector2Uniform * | GetFloatVector2Uniform (UInt32 index) const =0 |
Get the uniform at a given index as a 2-component 32bit floating point vector object. More... | |
virtual IFloatVector3Uniform * | GetFloatVector3Uniform (UInt32 index) const =0 |
Get the uniform at a given index as a 3-component 32bit floating point vector object. More... | |
virtual IFloatVector4Uniform * | GetFloatVector4Uniform (UInt32 index) const =0 |
Get the uniform at a given index as a 4-component 32bit floating point vector object. More... | |
virtual IFloatMatrix2Uniform * | GetFloatMatrix2Uniform (UInt32 index) const =0 |
Get the uniform at a given index as a 2x2-component 32bit floating point matrix object. More... | |
virtual IFloatMatrix3Uniform * | GetFloatMatrix3Uniform (UInt32 index) const =0 |
Get the uniform at a given index as a 3x3-component 32bit floating point matrix object. More... | |
virtual IFloatMatrix4Uniform * | GetFloatMatrix4Uniform (UInt32 index) const =0 |
Get the uniform at a given index as a 4x4-component 32bit floating point matrix object. More... | |
virtual ISInt32Uniform * | GetSInt32Uniform (UInt32 index) const =0 |
Get the attribute at a given index as a scalar 32bit signed integer object. More... | |
virtual ISInt32Vector2Uniform * | GetSInt32Vector2Uniform (UInt32 index) const =0 |
Get the uniform at a given index as a 2-component 32bit signed integer vector object. More... | |
virtual ISInt32Vector3Uniform * | GetSInt32Vector3Uniform (UInt32 index) const =0 |
Get the uniform at a given index as a 3-component 32bit signed integer vector object. More... | |
virtual ISInt32Vector4Uniform * | GetSInt32Vector4Uniform (UInt32 index) const =0 |
Get the uniform at a given index as a 4-component 32bit signed integer vector object. More... | |
|
pure virtual |
Get the zero-based index of this constant buffer.
|
pure virtual |
Get the constant buffer's name.
|
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.
|
pure virtual |
Set the maximum byte size of the constant buffer.
maxByteSize | The maximum capacity in bytes. |
preserveContents | If true, existing contents will be copied; but existing data beyond the new capacity is discarded. |
|
pure virtual |
Get the maximum capacity of the constant buffer in bytes.
Set the total byte size of all variables in the constant buffer.
byteSize | The currently used total number of bytes for all variables. |
|
pure virtual |
Get the total byte size of all variables in the constant buffer.
|
pure virtual |
Retrieve a mutable pointer to the variable data stored in the buffer.
|
pure virtual |
Retrieve a constant pointer to the variable data stored in the buffer.
|
pure virtual |
Mark the constant buffer as modified.