NormalEmitter Class Reference

An Emitter that emits particles following a Zone normals. More...

Inheritance diagram for NormalEmitter:
Emitter Registerable Transformable

List of all members.

Public Member Functions

 NormalEmitter (Zone *normalZone=NULL, bool inverted=false)
 Constructor of NormalEmitter.
void setInverted (bool inverted)
 Sets whether normals are inverted or not.
void setNormalZone (Zone *zone)
 the Zone used to compute normals
bool isInverted () const
 Tells whether normals are inverted for this NormalEmitter.
ZonegetNormalZone () const
 Gets the normal Zone of this NormalEmitter.
virtual RegisterablefindByName (const std::string &name)
 Finds a registerable with its name recursively from this registerable.

Static Public Member Functions

static NormalEmittercreate (Zone *normalZone=NULL, bool inverted=false)
 Creates and registers a new NormalEmitter.

Protected Member Functions

virtual void registerChildren (bool registerAll)
 Registers the children of this Registerable.
virtual void destroyChildren (bool keepChildren)
 Destroys the children of this Registerable.

Detailed Description

An Emitter that emits particles following a Zone normals.

The Zone used to derive the direction of emission can either be the Emitter Zone or another Zone that can be set with setNormalZone(Zone*).
If the normal zone is NULL the emitter Zone is used.

Since:
1.02.00

Definition at line 41 of file SPK_NormalEmitter.h.


Constructor & Destructor Documentation

NormalEmitter ( Zone normalZone = NULL,
bool  inverted = false 
)

Constructor of NormalEmitter.

Parameters:
normalZone : the Zone used to compute normals (NULL to used the Emitter Zone)
inverted : true to invert the normals, false otherwise

Member Function Documentation

NormalEmitter * create ( Zone normalZone = NULL,
bool  inverted = false 
) [static]

Creates and registers a new NormalEmitter.

Parameters:
normalZone : the Zone used to compute normals (NULL to used the Emitter Zone)
inverted : true to invert the normals, false otherwise
Returns:
A new registered NormalEmitter
Since:
1.04.00

Definition at line 123 of file SPK_NormalEmitter.h.

virtual void destroyChildren ( bool  keepChildren  )  [protected, virtual]

Destroys the children of this Registerable.

This method has to be implemented in derived classes of Registerable which hold pointers or references of Registerable children.
The destroyChild(Registerable*,bool) has to be called within it for each child to destroy.
The keepChildren parameter of destroyChild is simply the keepChildren parameter of destroyChildren.

Parameters:
keepChildren : true to keep the children (used when destroying all registered Registerable)

Reimplemented from Emitter.

virtual Registerable* findByName ( const std::string &  name  )  [virtual]

Finds a registerable with its name recursively from this registerable.

If the name is not found, NULL is returned.
If the several objects with the same name exists, only the first one is returned.

Note that the name of the registerable itself is already tested.

Parameters:
name : the name of the registerable to find
Returns:
: the first registerable with that name within this registerable or NULL if none is found
Since:
1.05.00

Reimplemented from Emitter.

Zone * getNormalZone (  )  const

Gets the normal Zone of this NormalEmitter.

Returns:
the normal Zone of this NormalEmitter

Definition at line 140 of file SPK_NormalEmitter.h.

bool isInverted (  )  const

Tells whether normals are inverted for this NormalEmitter.

Returns:
true if normals are inverted, false if not

Definition at line 135 of file SPK_NormalEmitter.h.

virtual void registerChildren ( bool  registerAll  )  [protected, virtual]

Registers the children of this Registerable.

This method has to be implemented in derived classes of Registerable which hold pointers or references of Registerable children.
The registerChild(Registerable*,bool) has to be called within it for each child to copy from object.
The registerAll parameter of registerChild is simply the registerAll parameter of registerChildren.

Parameters:
registerAll : true to register unregistered children, false to only increment ref counts of already registered children
Since:
1.04.00

Reimplemented from Emitter.

void setInverted ( bool  inverted  ) 

Sets whether normals are inverted or not.

Parameters:
inverted true to use inverted normals, false not to

Definition at line 130 of file SPK_NormalEmitter.h.

void setNormalZone ( Zone zone  ) 

the Zone used to compute normals

Note that if the normal zone is NULL, the Emitter Zone is used.

Parameters:
zone : the Zone used to compute normals (NULL to used the Emitter Zone)

Generated on Wed Apr 27 21:09:26 2011 for SPARK Particle Engine by  doxygen 1.6.1