Om  1.0.0
A universal framework for multimedia simulation
Public Member Functions | List of all members
om::graphics::materials::ConstantBinding Class Reference

A class used to represent the binding between a constant shader variable and its value and usage. More...

#include <omGraphicsConstantBinding.h>

Inheritance diagram for om::graphics::materials::ConstantBinding:
om::graphics::materials::ShaderBinding

Public Member Functions

 ConstantBinding ()
 Create a new constant binding object with no name, UNDEFINED usage, and no value. More...
 
 ConstantBinding (const ShaderSourceString &newName, const ShaderBindingFlags &newFlags, const ConstantUsage &newUsage, const AttributeType &newType, Size newArraySize, Index newByteOffset)
 Create a new constant binding with the specified name, flags, usage, type, array size, and offset in the constant storage. More...
 
const ConstantUsagegetUsage () const
 Return the semantic usage for this shader attribute binding. More...
 
void setUsage (const ConstantUsage &newUsage)
 Set an enum value indicating the semantic usage of this constant binding. More...
 
const AttributeTypegetType () const
 Return the type of attribute stored by this constant binding. More...
 
void setUsage (const AttributeType &newType)
 Set the type of attribute stored by this constant binding. More...
 
Index getArraySize () const
 Return the number of values of the attribute type that are part of this binding's array. More...
 
void setArraySize (Size newArraySize)
 Set the number of values of the attribute type that are part of this binding's array. More...
 
Index getOffset () const
 Return the offset in bytes for this binding's value in its shader pass's constant storage buffer. More...
 
void setOffset (Index newByteOffset)
 Set the offset in bytes for this binding's value in its shader pass's constant storage buffer. More...
 
- Public Member Functions inherited from om::graphics::materials::ShaderBinding
 ShaderBinding ()
 Create a shader binding with no name and the default flags. More...
 
 ShaderBinding (const ShaderSourceString &newName, const ShaderBindingFlags &newFlags)
 Create a shader binding with the given name and flags. More...
 
const ShaderSourceStringgetName () const
 Return a string representing the name of the shader binding's variable. More...
 
void setName (const ShaderSourceString &newName)
 Set a string representing the name of the shader binding's variable. More...
 
ShaderBindingFlagsgetFlags ()
 Return a reference to an object that contains boolean parameters of the shader binding. More...
 
const ShaderBindingFlagsgetFlags () const
 Return an object that contains boolean parameters of the shader binding. More...
 
void setFlags (const ShaderBindingFlags &newFlags)
 Set an object that contains boolean parameters of the shader binding. More...
 
Bool flagIsSet (ShaderBindingFlags::Flag flag) const
 Return whether or not the specified boolan flag is set for this shader binding. More...
 
void setFlag (ShaderBindingFlags::Flag flag, Bool newIsSet=true)
 Set whether or not the specified boolan flag is set for this shader binding. More...
 
Bool getIsDynamicInput () const
 Return whether or not this shader binding is a dynamic input. More...
 
void setIsDynamicInput (Bool newIsInput)
 Set whether or not this shader binding is a dynamic input. More...
 

Additional Inherited Members

- Protected Attributes inherited from om::graphics::materials::ShaderBinding
ShaderSourceString name
 A string representing the name of the shader binding. More...
 
ShaderBindingFlags flags
 An object that contains boolean configuration information for the binding. More...
 

Detailed Description

A class used to represent the binding between a constant shader variable and its value and usage.

Constructor & Destructor Documentation

om::graphics::materials::ConstantBinding::ConstantBinding ( )
inline

Create a new constant binding object with no name, UNDEFINED usage, and no value.

om::graphics::materials::ConstantBinding::ConstantBinding ( const ShaderSourceString newName,
const ShaderBindingFlags newFlags,
const ConstantUsage newUsage,
const AttributeType newType,
Size  newArraySize,
Index  newByteOffset 
)
inline

Create a new constant binding with the specified name, flags, usage, type, array size, and offset in the constant storage.

Member Function Documentation

const ConstantUsage& om::graphics::materials::ConstantBinding::getUsage ( ) const
inline

Return the semantic usage for this shader attribute binding.

void om::graphics::materials::ConstantBinding::setUsage ( const ConstantUsage newUsage)
inline

Set an enum value indicating the semantic usage of this constant binding.

const AttributeType& om::graphics::materials::ConstantBinding::getType ( ) const
inline

Return the type of attribute stored by this constant binding.

void om::graphics::materials::ConstantBinding::setUsage ( const AttributeType newType)
inline

Set the type of attribute stored by this constant binding.

Index om::graphics::materials::ConstantBinding::getArraySize ( ) const
inline

Return the number of values of the attribute type that are part of this binding's array.

void om::graphics::materials::ConstantBinding::setArraySize ( Size  newArraySize)
inline

Set the number of values of the attribute type that are part of this binding's array.

Index om::graphics::materials::ConstantBinding::getOffset ( ) const
inline

Return the offset in bytes for this binding's value in its shader pass's constant storage buffer.

void om::graphics::materials::ConstantBinding::setOffset ( Index  newByteOffset)
inline

Set the offset in bytes for this binding's value in its shader pass's constant storage buffer.


The documentation for this class was generated from the following file: