OGRE 2.1
Object-Oriented Graphics Rendering Engine
Loading...
Searching...
No Matches
Ogre::RTShader::Function Class Reference

A class that represents a shader based program function. More...

#include <OgreShaderFunction.h>

+ Inheritance diagram for Ogre::RTShader::Function:

Public Types

enum  FunctionType { FFT_INTERNAL , FFT_VS_MAIN , FFT_PS_MAIN }
 

Public Member Functions

void addAtomInstance (FunctionAtom *atomInstance)
 Add a function atom instance to this function.
 
void addInputParameter (ParameterPtr parameter)
 Add input parameter to this function.
 
void addOutputParameter (ParameterPtr parameter)
 Add output parameter to this function.
 
void deleteAllInputParameters ()
 Delete all input parameters from this function.
 
void deleteAllOutputParameters ()
 Delete all output parameters from this function.
 
bool deleteAtomInstance (FunctionAtom *atomInstance)
 Delete a function atom instance from this function.
 
void deleteInputParameter (ParameterPtr parameter)
 Delete input parameter from this function.
 
void deleteOutputParameter (ParameterPtr parameter)
 Delete output parameter from this function.
 
FunctionAtomInstanceListgetAtomInstances ()
 Return list of atom instances composing this function.
 
const FunctionAtomInstanceListgetAtomInstances () const
 Return list of atom instances composing this function.
 
const StringgetDescription () const
 Get the description of this function.
 
FunctionType getFunctionType () const
 get function type.
 
const ShaderParameterListgetInputParameters () const
 Return a list of input parameters.
 
const ShaderParameterListgetLocalParameters () const
 Return a list of local parameters.
 
const StringgetName () const
 Get the name of this function.
 
const ShaderParameterListgetOutputParameters () const
 Return a list of output parameters.
 
ParameterPtr getParameterByContent (const ShaderParameterList &parameterList, const Parameter::Content content, GpuConstantType type)
 Get parameter by a given content and type from the given parameter list.
 
void operator delete (void *ptr)
 
void operator delete (void *ptr, const char *, int, const char *)
 
void operator delete (void *ptr, void *)
 
void operator delete[] (void *ptr)
 
void operator delete[] (void *ptr, const char *, int, const char *)
 
voidoperator new (size_t sz)
 
voidoperator new (size_t sz, const char *file, int line, const char *func)
 operator new, with debug line info
 
voidoperator new (size_t sz, void *ptr)
 placement operator new
 
voidoperator new[] (size_t sz)
 
voidoperator new[] (size_t sz, const char *file, int line, const char *func)
 array operator new, with debug line info
 
ParameterPtr resolveInputParameter (Parameter::Semantic semantic, int index, const Parameter::Content content, GpuConstantType type)
 Resolve input parameter of this function.
 
ParameterPtr resolveLocalParameter (Parameter::Semantic semantic, int index, const Parameter::Content content, GpuConstantType type)
 Resolve local parameter of this function

 
ParameterPtr resolveLocalParameter (Parameter::Semantic semantic, int index, const String &name, GpuConstantType type)
 Resolve local parameter of this function

 
ParameterPtr resolveOutputParameter (Parameter::Semantic semantic, int index, const Parameter::Content content, GpuConstantType type)
 Resolve output parameter of this function.
 
void sortAtomInstances ()
 Sort all atom instances of this function.
 

Static Public Member Functions

static ParameterPtr getParameterByName (const ShaderParameterList &parameterList, const String &name)
 Get parameter by a given name from the given parameter list.
 
static ParameterPtr getParameterBySemantic (const ShaderParameterList &parameterList, const Parameter::Semantic semantic, int index)
 Get parameter by a given semantic and index from the given parameter list.
 

Friends

class Program
 

Detailed Description

A class that represents a shader based program function.

Member Enumeration Documentation

◆ FunctionType

Enumerator
FFT_INTERNAL 
FFT_VS_MAIN 
FFT_PS_MAIN 

Member Function Documentation

◆ addAtomInstance()

void Ogre::RTShader::Function::addAtomInstance ( FunctionAtom atomInstance)

Add a function atom instance to this function.

Parameters
atomInstanceThe atom instance to add.

◆ addInputParameter()

void Ogre::RTShader::Function::addInputParameter ( ParameterPtr  parameter)

Add input parameter to this function.

◆ addOutputParameter()

void Ogre::RTShader::Function::addOutputParameter ( ParameterPtr  parameter)

Add output parameter to this function.

◆ deleteAllInputParameters()

void Ogre::RTShader::Function::deleteAllInputParameters ( )

Delete all input parameters from this function.

◆ deleteAllOutputParameters()

void Ogre::RTShader::Function::deleteAllOutputParameters ( )

Delete all output parameters from this function.

◆ deleteAtomInstance()

bool Ogre::RTShader::Function::deleteAtomInstance ( FunctionAtom atomInstance)

Delete a function atom instance from this function.

Parameters
atomInstanceThe atom instance to OGRE_DELETE.

◆ deleteInputParameter()

void Ogre::RTShader::Function::deleteInputParameter ( ParameterPtr  parameter)

Delete input parameter from this function.

◆ deleteOutputParameter()

void Ogre::RTShader::Function::deleteOutputParameter ( ParameterPtr  parameter)

Delete output parameter from this function.

◆ getAtomInstances() [1/2]

FunctionAtomInstanceList & Ogre::RTShader::Function::getAtomInstances ( )
inline

Return list of atom instances composing this function.

◆ getAtomInstances() [2/2]

const FunctionAtomInstanceList & Ogre::RTShader::Function::getAtomInstances ( ) const
inline

Return list of atom instances composing this function.

(Const version)

◆ getDescription()

const String & Ogre::RTShader::Function::getDescription ( ) const
inline

Get the description of this function.

◆ getFunctionType()

FunctionType Ogre::RTShader::Function::getFunctionType ( ) const

get function type.

◆ getInputParameters()

const ShaderParameterList & Ogre::RTShader::Function::getInputParameters ( ) const
inline

Return a list of input parameters.

◆ getLocalParameters()

const ShaderParameterList & Ogre::RTShader::Function::getLocalParameters ( ) const
inline

Return a list of local parameters.

◆ getName()

const String & Ogre::RTShader::Function::getName ( ) const
inline

Get the name of this function.

◆ getOutputParameters()

const ShaderParameterList & Ogre::RTShader::Function::getOutputParameters ( ) const
inline

Return a list of output parameters.

◆ getParameterByContent()

ParameterPtr Ogre::RTShader::Function::getParameterByContent ( const ShaderParameterList parameterList,
const Parameter::Content  content,
GpuConstantType  type 
)

Get parameter by a given content and type from the given parameter list.

Parameters
parameterListThe parameters list to look in.
contentThe content of the parameter to search in the list.
typeThe type of the parameter to search in the list.
Remarks
Return NULL if no matching parameter found.

◆ getParameterByName()

static ParameterPtr Ogre::RTShader::Function::getParameterByName ( const ShaderParameterList parameterList,
const String name 
)
static

Get parameter by a given name from the given parameter list.

Parameters
parameterListThe parameters list to look in.
nameThe name of the parameter to search in the list.
Remarks
Return NULL if no matching parameter found.

◆ getParameterBySemantic()

static ParameterPtr Ogre::RTShader::Function::getParameterBySemantic ( const ShaderParameterList parameterList,
const Parameter::Semantic  semantic,
int  index 
)
static

Get parameter by a given semantic and index from the given parameter list.

Parameters
parameterListThe parameters list to look in.
semanticThe semantic of the parameter to search in the list.
indexThe index of the parameter to search in the list.
Remarks
Return NULL if no matching parameter found.

◆ operator delete() [1/3]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete ( void ptr)
inlineinherited

◆ operator delete() [2/3]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete ( void ptr,
const char ,
int  ,
const char  
)
inlineinherited

◆ operator delete() [3/3]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete ( void ptr,
void  
)
inlineinherited

◆ operator delete[]() [1/2]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete[] ( void ptr)
inlineinherited

◆ operator delete[]() [2/2]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete[] ( void ptr,
const char ,
int  ,
const char  
)
inlineinherited

◆ operator new() [1/3]

template<class Alloc >
void * Ogre::AllocatedObject< Alloc >::operator new ( size_t  sz)
inlineinherited

◆ operator new() [2/3]

template<class Alloc >
void * Ogre::AllocatedObject< Alloc >::operator new ( size_t  sz,
const char file,
int  line,
const char func 
)
inlineinherited

operator new, with debug line info

◆ operator new() [3/3]

template<class Alloc >
void * Ogre::AllocatedObject< Alloc >::operator new ( size_t  sz,
void ptr 
)
inlineinherited

placement operator new

◆ operator new[]() [1/2]

template<class Alloc >
void * Ogre::AllocatedObject< Alloc >::operator new[] ( size_t  sz)
inlineinherited

◆ operator new[]() [2/2]

template<class Alloc >
void * Ogre::AllocatedObject< Alloc >::operator new[] ( size_t  sz,
const char file,
int  line,
const char func 
)
inlineinherited

array operator new, with debug line info

◆ resolveInputParameter()

ParameterPtr Ogre::RTShader::Function::resolveInputParameter ( Parameter::Semantic  semantic,
int  index,
const Parameter::Content  content,
GpuConstantType  type 
)

Resolve input parameter of this function.

Parameters
semanticThe desired parameter semantic.
indexThe index of the desired parameter.
contentThe content of the parameter.
typeThe type of the desired parameter. Return parameter instance in case of that resolve operation succeeded.
Remarks
Pass -1 as index parameter to create a new parameter with the desired semantic and type.

◆ resolveLocalParameter() [1/2]

ParameterPtr Ogre::RTShader::Function::resolveLocalParameter ( Parameter::Semantic  semantic,
int  index,
const Parameter::Content  content,
GpuConstantType  type 
)

Resolve local parameter of this function

Parameters
semanticThe desired parameter semantic.
indexThe index of the desired parameter.
contentThe content of the parameter.
typeThe type of the desired parameter.
Return parameter instance in case of that resolve operation succeeded.

◆ resolveLocalParameter() [2/2]

ParameterPtr Ogre::RTShader::Function::resolveLocalParameter ( Parameter::Semantic  semantic,
int  index,
const String name,
GpuConstantType  type 
)

Resolve local parameter of this function

Parameters
semanticThe desired parameter semantic.
indexThe index of the desired parameter.
nameThe name of the parameter.
typeThe type of the desired parameter.
Return parameter instance in case of that resolve operation succeeded.

◆ resolveOutputParameter()

ParameterPtr Ogre::RTShader::Function::resolveOutputParameter ( Parameter::Semantic  semantic,
int  index,
const Parameter::Content  content,
GpuConstantType  type 
)

Resolve output parameter of this function.

Parameters
semanticThe desired parameter semantic.
indexThe index of the desired parameter.
contentThe content of the parameter.
typeThe type of the desired parameter. Return parameter instance in case of that resolve operation succeeded.
Remarks
Pass -1 as index parameter to create a new parameter with the desired semantic and type.

◆ sortAtomInstances()

void Ogre::RTShader::Function::sortAtomInstances ( )

Sort all atom instances of this function.

Friends And Related Symbol Documentation

◆ Program


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