OGRE 2.1
Object-Oriented Graphics Rendering Engine
Loading...
Searching...
No Matches
Ogre::ShaderParams::Param Struct Reference

#include <OgreShaderParams.h>

Public Member Functions

template<typename T >
void getManualValue (T &value) const
 Returns the value.
 
template<typename T >
getManualValue (void) const
 See other overload.
 
void setManualValue (const float *value, uint32 numValues)
 
void setManualValue (const int32 *value, uint32 numValues)
 
void setManualValue (const Matrix3 &value)
 
void setManualValue (const Matrix4 &value)
 
void setManualValue (const uint32 *value, uint32 numValues)
 
void setManualValue (const Vector2 &value)
 
void setManualValue (const Vector3 &value)
 
void setManualValue (const Vector4 &value)
 
void setManualValue (float value)
 Shortcut for setting the given value without dealing with mp manually.
 
void setManualValue (int32 value)
 
template<typename T >
void setManualValue (T value, uint32 numValues, ElementType elementType)
 
void setManualValue (uint32 value)
 

Public Attributes

union { 
 
   AutoParam   ap 
 
   ManualParam   mp 
 
};  
 
bool isAutomatic
 
bool isDirty
 
String name
 

Member Function Documentation

◆ getManualValue() [1/2]

template<typename T >
void Ogre::ShaderParams::Param::getManualValue ( T &  value) const
inline

Returns the value.

Assumes this is a manual value. Assumes the param holds enough bytes to fill the type of value you want to retrieve. Examples: uint32 myVal; param->getManualValue( myVal ); Vector4 myVector4; param->getManualValue( myVector4 );

◆ getManualValue() [2/2]

template<typename T >
T Ogre::ShaderParams::Param::getManualValue ( void  ) const
inline

See other overload.

Examples: uint32 myVal = param->getManualValue(); Vector4 myVector4 = param->getManualValue();

◆ setManualValue() [1/12]

void Ogre::ShaderParams::Param::setManualValue ( const float value,
uint32  numValues 
)

◆ setManualValue() [2/12]

void Ogre::ShaderParams::Param::setManualValue ( const int32 value,
uint32  numValues 
)

◆ setManualValue() [3/12]

void Ogre::ShaderParams::Param::setManualValue ( const Matrix3 value)

◆ setManualValue() [4/12]

void Ogre::ShaderParams::Param::setManualValue ( const Matrix4 value)

◆ setManualValue() [5/12]

void Ogre::ShaderParams::Param::setManualValue ( const uint32 value,
uint32  numValues 
)

◆ setManualValue() [6/12]

void Ogre::ShaderParams::Param::setManualValue ( const Vector2 value)

◆ setManualValue() [7/12]

void Ogre::ShaderParams::Param::setManualValue ( const Vector3 value)

◆ setManualValue() [8/12]

void Ogre::ShaderParams::Param::setManualValue ( const Vector4 value)

◆ setManualValue() [9/12]

void Ogre::ShaderParams::Param::setManualValue ( float  value)

Shortcut for setting the given value without dealing with mp manually.

Remarks
You can't write more than 64 bytes of data per parameter. (i.e. 16 uint32, 16 int32, or 16 floats) Remember to call
See also
ShaderParams::setDirty otherwise changes won't take effect.

◆ setManualValue() [10/12]

void Ogre::ShaderParams::Param::setManualValue ( int32  value)

◆ setManualValue() [11/12]

template<typename T >
void Ogre::ShaderParams::Param::setManualValue ( value,
uint32  numValues,
ElementType  elementType 
)

◆ setManualValue() [12/12]

void Ogre::ShaderParams::Param::setManualValue ( uint32  value)

Member Data Documentation

◆ [union]

◆ ap

AutoParam Ogre::ShaderParams::Param::ap

◆ isAutomatic

bool Ogre::ShaderParams::Param::isAutomatic

◆ isDirty

bool Ogre::ShaderParams::Param::isDirty

◆ mp

ManualParam Ogre::ShaderParams::Param::mp

◆ name

String Ogre::ShaderParams::Param::name

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