A class that represents a function operand (its the combination of a parameter the in/out semantic and the used fields). More...
#include <OgreShaderFunctionAtom.h>
Public Types | |
enum | OpSemantic { OPS_IN, OPS_OUT, OPS_INOUT } |
enum | OpMask { OPM_ALL = 1 << 0, OPM_X = 1 << 1, OPM_Y = 1 << 2, OPM_Z = 1 << 3, OPM_W = 1 << 4 } |
Public Member Functions | |
Operand (ParameterPtr parameter, Operand::OpSemantic opSemantic, int opMask=Operand::OPM_ALL, ushort indirectionLevel=0) | |
Class constructor. | |
Operand (const Operand &rhs) | |
Copy constructor. | |
Operand & | operator= (const Operand &rhs) |
Copy the given Operand to this Operand. | |
~Operand () | |
Class destructor. | |
const ParameterPtr & | getParameter () const |
Returns the parameter object as weak reference. | |
bool | hasFreeFields () const |
Returns true if not all fields used. | |
int | getMask () const |
Returns the mask bitfield. | |
OpSemantic | getSemantic () const |
Returns the operand semantic (do we read/write or both with the parameter). | |
ushort | getIndirectionLevel () const |
Returns the level of indirection. | |
String | toString () const |
Returns the parameter name and the usage mask like this 'color.xyz'. | |
void * | operator new (size_t sz, const char *file, int line, const char *func) |
operator new, with debug line info | |
void * | operator new (size_t sz) |
void * | operator new (size_t sz, void *ptr) |
placement operator new | |
void * | operator new[] (size_t sz, const char *file, int line, const char *func) |
array operator new, with debug line info | |
void * | operator new[] (size_t sz) |
void | operator delete (void *ptr) |
void | operator delete (void *ptr, void *) |
void | operator delete (void *ptr, const char *, int, const char *) |
void | operator delete[] (void *ptr) |
void | operator delete[] (void *ptr, const char *, int, const char *) |
Static Public Member Functions | |
static String | getMaskAsString (int mask) |
Returns the given mask as string representation. | |
static int | getFloatCount (int mask) |
Return the float count of the given mask. | |
static GpuConstantType | getGpuConstantType (int mask) |
Return the gpu constant type of the given mask. | |
Protected Attributes | |
ParameterPtr | mParameter |
OpSemantic | mSemantic |
The parameter being carried by the operand. | |
int | mMask |
Tells if the parameter is of type input,output or both. | |
ushort | mIndirectionLevel |
Which part of the parameter should be passed (x,y,z,w). |
A class that represents a function operand (its the combination of a parameter the in/out semantic and the used fields).
Definition at line 78 of file OgreShaderFunctionAtom.h.
Definition at line 94 of file OgreShaderFunctionAtom.h.
OPS_IN |
The parameter is a input parameter. |
OPS_OUT |
The parameter is a output parameter. |
OPS_INOUT |
The parameter is a input/output parameter. |
Definition at line 83 of file OgreShaderFunctionAtom.h.
Ogre::RTShader::Operand::Operand | ( | ParameterPtr | parameter, | |
Operand::OpSemantic | opSemantic, | |||
int | opMask = Operand::OPM_ALL , |
|||
ushort | indirectionLevel = 0 | |||
) |
Class constructor.
parameter | A function parameter. | |
opSemantic | The in/out semantic of the parameter. | |
opMask | The field mask of the parameter. |
Ogre::RTShader::Operand::Operand | ( | const Operand & | rhs | ) |
Copy constructor.
Ogre::RTShader::Operand::~Operand | ( | ) |
Class destructor.
static int Ogre::RTShader::Operand::getFloatCount | ( | int | mask | ) | [static] |
Return the float count of the given mask.
static GpuConstantType Ogre::RTShader::Operand::getGpuConstantType | ( | int | mask | ) | [static] |
Return the gpu constant type of the given mask.
ushort Ogre::RTShader::Operand::getIndirectionLevel | ( | ) | const |
Returns the level of indirection.
The greater the indirection level the more the parameter needs to be nested in brackets. For example given 4 parameters x1...x4 with the indirections levels 0,1,1,2 respectively. The parameters should form the following string: x1[x2][x3[x4]].
Definition at line 138 of file OgreShaderFunctionAtom.h.
int Ogre::RTShader::Operand::getMask | ( | ) | const |
Returns the mask bitfield.
Definition at line 128 of file OgreShaderFunctionAtom.h.
static String Ogre::RTShader::Operand::getMaskAsString | ( | int | mask | ) | [static] |
Returns the given mask as string representation.
const ParameterPtr& Ogre::RTShader::Operand::getParameter | ( | ) | const |
Returns the parameter object as weak reference.
Definition at line 122 of file OgreShaderFunctionAtom.h.
OpSemantic Ogre::RTShader::Operand::getSemantic | ( | ) | const |
Returns the operand semantic (do we read/write or both with the parameter).
Definition at line 131 of file OgreShaderFunctionAtom.h.
bool Ogre::RTShader::Operand::hasFreeFields | ( | ) | const |
Returns true if not all fields used.
(usage is described through semantic)
Definition at line 125 of file OgreShaderFunctionAtom.h.
void Ogre::AllocatedObject< Alloc >::operator delete | ( | void * | ptr, | |
const char * | , | |||
int | , | |||
const char * | ||||
) | [inherited] |
Definition at line 107 of file OgreMemoryAllocatedObject.h.
void Ogre::AllocatedObject< Alloc >::operator delete | ( | void * | ptr, | |
void * | ||||
) | [inherited] |
Definition at line 101 of file OgreMemoryAllocatedObject.h.
void Ogre::AllocatedObject< Alloc >::operator delete | ( | void * | ptr | ) | [inherited] |
Definition at line 95 of file OgreMemoryAllocatedObject.h.
void Ogre::AllocatedObject< Alloc >::operator delete[] | ( | void * | ptr, | |
const char * | , | |||
int | , | |||
const char * | ||||
) | [inherited] |
Definition at line 118 of file OgreMemoryAllocatedObject.h.
void Ogre::AllocatedObject< Alloc >::operator delete[] | ( | void * | ptr | ) | [inherited] |
Definition at line 112 of file OgreMemoryAllocatedObject.h.
void* Ogre::AllocatedObject< Alloc >::operator new | ( | size_t | sz, | |
void * | ptr | |||
) | [inherited] |
placement operator new
Definition at line 78 of file OgreMemoryAllocatedObject.h.
void* Ogre::AllocatedObject< Alloc >::operator new | ( | size_t | sz | ) | [inherited] |
Definition at line 72 of file OgreMemoryAllocatedObject.h.
void* Ogre::AllocatedObject< Alloc >::operator new | ( | size_t | sz, | |
const char * | file, | |||
int | line, | |||
const char * | func | |||
) | [inherited] |
operator new, with debug line info
Definition at line 67 of file OgreMemoryAllocatedObject.h.
void* Ogre::AllocatedObject< Alloc >::operator new[] | ( | size_t | sz | ) | [inherited] |
Definition at line 90 of file OgreMemoryAllocatedObject.h.
void* Ogre::AllocatedObject< Alloc >::operator new[] | ( | size_t | sz, | |
const char * | file, | |||
int | line, | |||
const char * | func | |||
) | [inherited] |
array operator new, with debug line info
Definition at line 85 of file OgreMemoryAllocatedObject.h.
String Ogre::RTShader::Operand::toString | ( | ) | const |
Returns the parameter name and the usage mask like this 'color.xyz'.
ushort Ogre::RTShader::Operand::mIndirectionLevel [protected] |
Which part of the parameter should be passed (x,y,z,w).
Definition at line 156 of file OgreShaderFunctionAtom.h.
int Ogre::RTShader::Operand::mMask [protected] |
Tells if the parameter is of type input,output or both.
Definition at line 155 of file OgreShaderFunctionAtom.h.
ParameterPtr Ogre::RTShader::Operand::mParameter [protected] |
Definition at line 153 of file OgreShaderFunctionAtom.h.
OpSemantic Ogre::RTShader::Operand::mSemantic [protected] |
The parameter being carried by the operand.
Definition at line 154 of file OgreShaderFunctionAtom.h.
Copyright © 2012 Torus Knot Software Ltd
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.
Last modified Fri May 25 23:42:34 2012