Go to the documentation of this file.
27 #ifndef _ShaderProgramFunction_
28 #define _ShaderProgramFunction_
FunctionAtomInstanceList & getAtomInstances()
Return list of atom instances composing this function.
ParameterPtr resolveLocalParameter(Parameter::Semantic semantic, int index, const Parameter::Content content, GpuConstantType type)
Resolve local parameter of this function
Superclass for all objects that wish to use custom memory allocators when their new / delete operator...
FunctionType mFunctionType
const String & getName() const
Get the name of this function.
void deleteParameter(ShaderParameterList ¶meterList, ParameterPtr parameter)
Delete parameter from a given list.
void deleteInputParameter(ParameterPtr parameter)
Delete input parameter from this function.
ShaderFunctionList::iterator ShaderFunctionIterator
FunctionAtomInstanceList mAtomInstances
FunctionType getFunctionType() const
get function type.
~Function()
Class destructor.
const ShaderParameterList & getOutputParameters() const
Return a list of output parameters.
ParameterPtr getParameterByContent(const ShaderParameterList ¶meterList, const Parameter::Content content, GpuConstantType type)
Get parameter by a given content and type from the given parameter list.
void addParameter(ShaderParameterList ¶meterList, ParameterPtr parameter)
Add parameter to given list.
vector< Function * >::type ShaderFunctionList
const ShaderParameterList & getLocalParameters() const
Return a list of local parameters.
void deleteOutputParameter(ParameterPtr parameter)
Delete output parameter from this function.
ParameterPtr resolveOutputParameter(Parameter::Semantic semantic, int index, const Parameter::Content content, GpuConstantType type)
Resolve output parameter of this function.
vector< ParameterPtr >::type ShaderParameterList
void deleteAllOutputParameters()
Delete all output parameters from this function.
const FunctionAtomInstanceList & getAtomInstances() const
Return list of atom instances composing this function.
void addAtomInstance(FunctionAtom *atomInstance)
Add a function atom instance to this function.
A class that represents a shader based program.
A class that represents an atomic code section of shader based program function.
static ParameterPtr getParameterByName(const ShaderParameterList ¶meterList, const String &name)
Get parameter by a given name from the given parameter list.
void sortAtomInstances()
Sort all atom instances of this function.
ShaderParameterList mOutputParameters
ParameterPtr resolveInputParameter(Parameter::Semantic semantic, int index, const Parameter::Content content, GpuConstantType type)
Resolve input parameter of this function.
static ParameterPtr getParameterBySemantic(const ShaderParameterList ¶meterList, const Parameter::Semantic semantic, int index)
Get parameter by a given semantic and index from the given parameter list.
ShaderParameterList mInputParameters
ParameterPtr resolveLocalParameter(Parameter::Semantic semantic, int index, const String &name, GpuConstantType type)
Resolve local parameter of this function
void deleteAllInputParameters()
Delete all input parameters from this function.
GpuConstantType
Enumeration of the types of constant we may encounter in programs.
bool deleteAtomInstance(FunctionAtom *atomInstance)
Delete a function atom instance from this function.
const String & getDescription() const
Get the description of this function.
ShaderFunctionList::const_iterator ShaderFunctionConstIterator
const ShaderParameterList & getInputParameters() const
Return a list of input parameters.
ShaderParameterList mLocalParameters
Function(const String &name, const String &desc, const FunctionType functionType)
Class constructor.
vector< FunctionAtom * >::type FunctionAtomInstanceList
void addInputParameter(ParameterPtr parameter)
Add input parameter to this function.
A class that represents a shader based program function.
void addOutputParameter(ParameterPtr parameter)
Add output parameter to this function.
Copyright © 2012 Torus Knot Software Ltd

This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.