OGRE-Next  2.3
Object-Oriented Graphics Rendering Engine
Ogre::RTShader::SubRenderState Class Referenceabstract

This class is the base interface of sub part from a shader based rendering pipeline. More...

#include <OgreShaderSubRenderState.h>

+ Inheritance diagram for Ogre::RTShader::SubRenderState:

Public Member Functions

 SubRenderState ()
 Class default constructor. More...
 
virtual ~SubRenderState ()
 Class destructor. More...
 
virtual void copyFrom (const SubRenderState &rhs)=0
 Copy details from a given sub render state to this one. More...
 
virtual bool createCpuSubPrograms (ProgramSet *programSet)
 Create sub programs that represents this sub render state as part of a program set. More...
 
SubRenderStateAccessorPtr getAccessor ()
 Return the accessor object to this sub render state. More...
 
SubRenderStateAccessorPtr getAccessor () const
 Return the accessor object to this sub render state. More...
 
virtual int getExecutionOrder () const =0
 Get the execution order of this sub render state. More...
 
virtual const StringgetType () const =0
 Get the type of this sub render state. More...
 
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 *)
 
void * operator new (size_t sz)
 
void * operator new (size_t sz, const char *file, int line, const char *func)
 operator new, with debug line info More...
 
void * operator new (size_t sz, void *ptr)
 placement operator new More...
 
void * operator new[] (size_t sz)
 
void * operator new[] (size_t sz, const char *file, int line, const char *func)
 array operator new, with debug line info More...
 
SubRenderStateoperator= (const SubRenderState &rhs)
 Operator = declaration. More...
 
virtual bool preAddToRenderState (const RenderState *renderState, Pass *srcPass, Pass *dstPass)
 Called before adding this sub render state to the given render state. More...
 
virtual void updateGpuProgramsParams (Renderable *rend, Pass *pass, const AutoParamDataSource *source, const LightList *pLightList)
 Update GPU programs parameters before a rendering operation occurs. More...
 

Detailed Description

This class is the base interface of sub part from a shader based rendering pipeline.

All sub parts implementations should derive from it and implement the needed methods. A simple example of sub class of this interface will be the transform sub state of the fixed pipeline.

Constructor & Destructor Documentation

◆ SubRenderState()

Ogre::RTShader::SubRenderState::SubRenderState ( )

Class default constructor.

◆ ~SubRenderState()

virtual Ogre::RTShader::SubRenderState::~SubRenderState ( )
virtual

Class destructor.

Member Function Documentation

◆ copyFrom()

◆ createCpuSubPrograms()

virtual bool Ogre::RTShader::SubRenderState::createCpuSubPrograms ( ProgramSet programSet)
virtual

Create sub programs that represents this sub render state as part of a program set.

The given program set contains CPU programs that represents a vertex shader and pixel shader. One should use these program class API to create a representation of the sub state he wished to implement.

Parameters
programSetcontainer class of CPU and GPU programs that this sub state will affect on.

Reimplemented in Ogre::RTShader::FFPTransform.

◆ getAccessor() [1/2]

SubRenderStateAccessorPtr Ogre::RTShader::SubRenderState::getAccessor ( )

Return the accessor object to this sub render state.

See also
SubRenderStateAccessor.

◆ getAccessor() [2/2]

SubRenderStateAccessorPtr Ogre::RTShader::SubRenderState::getAccessor ( ) const

Return the accessor object to this sub render state.

See also
SubRenderStateAccessor.

◆ getExecutionOrder()

virtual int Ogre::RTShader::SubRenderState::getExecutionOrder ( ) const
pure virtual

◆ getType()

◆ 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

◆ operator=()

SubRenderState& Ogre::RTShader::SubRenderState::operator= ( const SubRenderState rhs)

Operator = declaration.

Assign the given source sub state to this sub state.

Parameters
rhsthe source sub state to copy from.

◆ preAddToRenderState()

virtual bool Ogre::RTShader::SubRenderState::preAddToRenderState ( const RenderState renderState,
Pass srcPass,
Pass dstPass 
)
inlinevirtual

Called before adding this sub render state to the given render state.

Allows this sub render state class to configure specific parameters depending on source pass or parent render state. Return of false value will cause canceling the add operation.

Parameters
renderStateThe target render state container this sub render state is about to be added.
srcPassThe source pass.
dstPassThe destination pass.

Reimplemented in Ogre::RTShader::FFPTexturing, Ogre::RTShader::FFPLighting, Ogre::RTShader::FFPFog, Ogre::RTShader::FFPColour, Ogre::RTShader::FFPAlphaTest, Ogre::RTShader::TriplanarTexturing, Ogre::RTShader::TextureAtlasSampler, Ogre::RTShader::PerPixelLighting, Ogre::RTShader::NormalMapLighting, Ogre::RTShader::IntegratedPSSM3, and Ogre::RTShader::HardwareSkinning.

◆ updateGpuProgramsParams()

virtual void Ogre::RTShader::SubRenderState::updateGpuProgramsParams ( Renderable rend,
Pass pass,
const AutoParamDataSource source,
const LightList pLightList 
)
inlinevirtual

Update GPU programs parameters before a rendering operation occurs.

This method is called in the context of SceneManager::renderSingle object via the RenderObjectListener interface and lets this sub render state instance opportunity to update custom GPU program parameters before the rendering action occurs.

See also
RenderObjectListener::notifyRenderSingleObject.
Parameters
rendThe renderable that is about to be rendered.
passThe pass that used for this rendering.
sourceThe auto parameter source.
pLightListThe light list used in the current rendering context.

Reimplemented in Ogre::RTShader::FFPTexturing, Ogre::RTShader::FFPLighting, Ogre::RTShader::FFPFog, Ogre::RTShader::FFPAlphaTest, Ogre::RTShader::TriplanarTexturing, Ogre::RTShader::TextureAtlasSampler, Ogre::RTShader::PerPixelLighting, Ogre::RTShader::NormalMapLighting, and Ogre::RTShader::IntegratedPSSM3.


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