Main Page Namespace List Class Hierarchy Alphabetical List Compound List File List Namespace Members Compound Members File Members Related Pages

# Ogre::ParticleEmitterFactory Class Reference

Abstract class defining the interface to be implemented by creators of ParticleEmitter subclasses. More...

`#include <OgreParticleEmitterFactory.h>`

Inheritance diagram for Ogre::ParticleEmitterFactory:

[legend]
List of all members.

## Public Methods

| ParticleEmitterFactory ()
virtual | ~ParticleEmitterFactory ()
virtual String | getName () const=0
| Returns the name of the factory, the name which identifies the particle emitter type this factory creates.
virtual ParticleEmitter * | createEmitter (void)=0
| Creates a new emitter instance.
virtual void | destroyEmitter (ParticleEmitter *e)
| Destroys the emitter pointed to by the parameter (for early clean up if reauired).

## Protected Attributes

std::vector< ParticleEmitter * > | mEmitters

## Detailed Description

Abstract class defining the interface to be implemented by creators of ParticleEmitter subclasses.

Remarks:
  Plugins or 3rd party applications can add new types of particle emitters to Ogre by creating subclasses of the ParticleEmitter class. Because multiple instances of these emitters may be required, a factory class to manage the instances is also required.

  ParticleEmitterFactory subclasses must allow the creation and destruction of ParticleEmitter subclasses. They must also be registered with the ParticleSystemManager. All factories have a name which identifies them, examples might be 'point', 'cone', or 'box', and these can be also be used from particle system scripts.

Definition at line 46 of file OgreParticleEmitterFactory.h.

## Constructor & Destructor Documentation

Ogre::ParticleEmitterFactory::ParticleEmitterFactory | ( |  | ) |

| Definition at line 51 of file OgreParticleEmitterFactory.h.

virtual Ogre::ParticleEmitterFactory::~ParticleEmitterFactory | ( |  | ) | `[virtual]`

| Definition at line 52 of file OgreParticleEmitterFactory.h.

## Member Function Documentation

virtual ParticleEmitter* Ogre::ParticleEmitterFactory::createEmitter | ( | void |  | ) | `[pure virtual]`

Creates a new emitter instance.

Remarks:
  The subclass MUST add a pointer to the created instance to mEmitters.

Implemented in Ogre::BoxEmitterFactory, Ogre::CylinderEmitterFactory, Ogre::EllipsoidEmitterFactory, Ogre::HollowEllipsoidEmitterFactory, Ogre::PointEmitterFactory, and Ogre::RingEmitterFactory.

virtual void Ogre::ParticleEmitterFactory::destroyEmitter | ( | ParticleEmitter * | e | ) | `[virtual]`

| Destroys the emitter pointed to by the parameter (for early clean up if reauired). Definition at line 75 of file OgreParticleEmitterFactory.h.

virtual String Ogre::ParticleEmitterFactory::getName | ( |  | ) | const`[pure virtual]`

| Returns the name of the factory, the name which identifies the particle emitter type this factory creates. Implemented in Ogre::BoxEmitterFactory, Ogre::CylinderEmitterFactory, Ogre::EllipsoidEmitterFactory, Ogre::HollowEllipsoidEmitterFactory, Ogre::PointEmitterFactory, and Ogre::RingEmitterFactory. Referenced by Ogre::ParticleSystemManager::addEmitterFactory().

## Member Data Documentation

std::vector<ParticleEmitter*> Ogre::ParticleEmitterFactory::mEmitters`[protected]`

| Definition at line 49 of file OgreParticleEmitterFactory.h.

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

- OgreParticleEmitterFactory.h

Copyright © 2002-2003 by The OGRE Team
Last modified Sun Nov 28 19:51:21 2004