Ogre::MaterialSerializer::Listener Class Reference

Class that allows listening in on the various stages of material serialization process. More...

`#include <OgreMaterialSerializer.h>`

Inheritance diagram for Ogre::MaterialSerializer::Listener:
[legend]

## Public Member Functions

virtual | ~Listener ()
void | gpuProgramRefEventRaised (MaterialSerializer *ser, SerializeEvent event, bool &skip, const String &attrib, const GpuProgramPtr &program, const GpuProgramParametersSharedPtr &params, GpuProgramParameters *defaultParams)
| Called when GPU program reference section event raised. More...
virtual void | materialEventRaised (MaterialSerializer *ser, SerializeEvent event, bool &skip, const Material *mat)
| Called when material section event raised. More...
virtual void | passEventRaised (MaterialSerializer *ser, SerializeEvent event, bool &skip, const Pass *pass)
| Called when pass section event raised. More...
virtual void | techniqueEventRaised (MaterialSerializer *ser, SerializeEvent event, bool &skip, const Technique *tech)
| Called when technique section event raised. More...
virtual void | textureUnitStateEventRaised (MaterialSerializer *ser, SerializeEvent event, bool &skip, const TextureUnitState *textureUnit)
| Called when texture unit state section event raised. More...

## Detailed Description

Class that allows listening in on the various stages of material serialization process.

Sub-classing it enable extending the attribute set of any part in the material.

Definition at line 122 of file OgreMaterialSerializer.h.

## Constructor & Destructor Documentation

## ~Listener()

virtual Ogre::MaterialSerializer::Listener::~Listener | ( |  | ) |

virtual

Definition at line 125 of file OgreMaterialSerializer.h.

## Member Function Documentation

## gpuProgramRefEventRaised()

void Ogre::MaterialSerializer::Listener::gpuProgramRefEventRaised | ( | MaterialSerializer * | ser,
|  | SerializeEvent | event,
|  | bool & | skip,
|  | const String & | attrib,
|  | const GpuProgramPtr & | program,
|  | const GpuProgramParametersSharedPtr & | params,
|  | GpuProgramParameters * | defaultParams
| ) |  |

Called when GPU program reference section event raised.

Parameters

  ser | The MaterialSerializer instance that writes the given material.
  event | The current section writing stage.
  skip | May set to true by sub-class instances in order to skip the following section write. This parameter relevant only when stage equals MSE_PRE_WRITE.
  attrib | The GPU program reference description (vertex_program_ref, fragment_program_ref, etc).
  program | The program being written.
  params | The program parameters.
  defaultParams | The default program parameters.

Definition at line 170 of file OgreMaterialSerializer.h.

## materialEventRaised()

virtual void Ogre::MaterialSerializer::Listener::materialEventRaised | ( | MaterialSerializer * | ser,
|  | SerializeEvent | event,
|  | bool & | skip,
|  | const Material * | mat
| ) |  |

virtual

Called when material section event raised.

Parameters

  ser | The MaterialSerializer instance that writes the given material.
  event | The current section writing stage.
  skip | May set to true by sub-class instances in order to skip the following section write. This parameter relevant only when stage equals MSE_PRE_WRITE.
  mat | The material that is being written.

Reimplemented in Ogre::RTShader::SGMaterialSerializerListener.

Definition at line 134 of file OgreMaterialSerializer.h.

## passEventRaised()

virtual void Ogre::MaterialSerializer::Listener::passEventRaised | ( | MaterialSerializer * | ser,
|  | SerializeEvent | event,
|  | bool & | skip,
|  | const Pass * | pass
| ) |  |

virtual

Called when pass section event raised.

Parameters

  ser | The MaterialSerializer instance that writes the given material.
  event | The current section writing stage.
  skip | May set to true by sub-class instances in order to skip the following section write. This parameter relevant only when stage equals MSE_PRE_WRITE.
  pass | The pass that is being written.

Reimplemented in Ogre::RTShader::SGMaterialSerializerListener.

Definition at line 156 of file OgreMaterialSerializer.h.

## techniqueEventRaised()

virtual void Ogre::MaterialSerializer::Listener::techniqueEventRaised | ( | MaterialSerializer * | ser,
|  | SerializeEvent | event,
|  | bool & | skip,
|  | const Technique * | tech
| ) |  |

virtual

Called when technique section event raised.

Parameters

  ser | The MaterialSerializer instance that writes the given material.
  event | The current section writing stage.
  skip | May set to true by sub-class instances in order to skip the following section write. This parameter relevant only when stage equals MSE_PRE_WRITE.
  tech | The technique that is being written.

Reimplemented in Ogre::RTShader::SGMaterialSerializerListener.

Definition at line 145 of file OgreMaterialSerializer.h.

## textureUnitStateEventRaised()

virtual void Ogre::MaterialSerializer::Listener::textureUnitStateEventRaised | ( | MaterialSerializer * | ser,
|  | SerializeEvent | event,
|  | bool & | skip,
|  | const TextureUnitState * | textureUnit
| ) |  |

virtual

Called when texture unit state section event raised.

Parameters

  ser | The MaterialSerializer instance that writes the given material.
  event | The current section writing stage.
  skip | May set to true by sub-class instances in order to skip the following section write. This parameter relevant only when stage equals MSE_PRE_WRITE.
  textureUnit | The texture unit state that is being written.

Reimplemented in Ogre::RTShader::SGMaterialSerializerListener.

Definition at line 193 of file OgreMaterialSerializer.h.

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

- OgreMaterialSerializer.h

Copyright © 2012 Torus Knot Software Ltd
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.