Particle Universe  1.2
ParticleUniverse::Randomiser Class Reference

#include <ParticleUniverseRandomiser.h>

Inheritance diagram for ParticleUniverse::Randomiser:

Public Member Functions

 Randomiser (void)
 
virtual ~Randomiser (void)
 
Real getMaxDeviationX (void) const
 
void setMaxDeviationX (const Real maxDeviationX)
 
Real getMaxDeviationY (void) const
 
void setMaxDeviationY (const Real maxDeviationZ)
 
Real getMaxDeviationZ (void) const
 
void setMaxDeviationZ (const Real maxDeviationZ)
 
Real getTimeStep (void) const
 
void setTimeStep (const Real timeStep)
 
bool isRandomDirection (void) const
 
void setRandomDirection (bool randomDirection)
 
virtual void _preProcessParticles (ParticleTechnique *particleTechnique, Real timeElapsed)
 
virtual void _affect (ParticleTechnique *particleTechnique, Particle *particle, Real timeElapsed)
 
virtual void _postProcessParticles (ParticleTechnique *technique, Real timeElapsed)
 
virtual void copyAttributesTo (ParticleAffector *affector)
 
- Public Member Functions inherited from ParticleUniverse::ParticleAffector
 ParticleAffector (void)
 
virtual ~ParticleAffector (void)
 
const AffectSpecialisationgetAffectSpecialisation (void) const
 
void setAffectSpecialisation (const AffectSpecialisation &affectSpecialisation)
 
const StringgetAffectorType (void) const
 
void setAffectorType (const String &affectorType)
 
const StringgetName (void) const
 
void setName (const String &name)
 
ParticleTechniquegetParentTechnique (void) const
 
void setParentTechnique (ParticleTechnique *parentTechnique)
 
virtual void _prepare (ParticleTechnique *particleTechnique)
 
virtual void _unprepare (ParticleTechnique *particleTechnique)
 
virtual void _notifyStart (void)
 
virtual void _notifyStop (void)
 
virtual void _notifyPause (void)
 
virtual void _notifyResume (void)
 
virtual void _notifyRescaled (const Vector3 &scale)
 
virtual void _firstParticle (ParticleTechnique *particleTechnique, Particle *particle, Real timeElapsed)
 
virtual void _initForEmission (void)
 
virtual void _initForExpiration (ParticleTechnique *technique, Real timeElapsed)
 
virtual void _initParticleForEmission (Particle *particle)
 
void _processParticle (ParticleTechnique *particleTechnique, Particle *particle, Real timeElapsed, bool firstParticle)
 
void addEmitterToExclude (const String &emitterName)
 
void removeEmitterToExclude (const String &emitterName)
 
void removeAllEmittersToExclude (void)
 
const list< String > & getEmittersToExclude (void) const
 
bool hasEmitterToExclude (const String &emitterName)
 
virtual void copyParentAttributesTo (ParticleAffector *affector)
 
const Vector3getDerivedPosition (void)
 
Real _calculateAffectSpecialisationFactor (const Particle *particle)
 
- Public Member Functions inherited from ParticleUniverse::Particle
 Particle (void)
 
virtual ~Particle (void)
 
bool _isMarkedForEmission (void) const
 
void _setMarkedForEmission (bool markedForEmission)
 
virtual bool isEnabled (void) const
 
virtual void setEnabled (bool enabled)
 
void _setOriginalEnabled (bool originalEnabled)
 
bool _getOriginalEnabled (void) const
 
bool isFreezed (void) const
 
void setFreezed (bool freezed)
 
void setEventFlags (uint32 flags)
 
void addEventFlags (uint32 flags)
 
void removeEventFlags (uint32 flags)
 
uint32 getEventFlags (void) const
 
bool hasEventFlags (uint32 flags) const
 
void copyBehaviours (ParticleBehaviourList &behaviours)
 
virtual void _process (ParticleTechnique *technique, Real timeElapsed)
 
ParticleBehaviourgetBehaviour (const String &behaviourType)
 
Real calculateVelocity (void) const
 
virtual void copyAttributesTo (Particle *particle)
 
- Public Member Functions inherited from ParticleUniverse::IAlias
 IAlias (void)
 
virtual ~IAlias (void)
 
const StringgetAliasName (void) const
 
void setAliasName (String aliasName)
 
const AliasType getAliasType (void) const
 
void setAliasType (AliasType aliasType)
 
- Public Member Functions inherited from ParticleUniverse::IElement
 IElement (void)
 
virtual ~IElement (void)
 

Static Public Attributes

static const Vector3 DEFAULT_MAX_DEVIATION
 
static const Real DEFAULT_TIME_STEP
 
static const bool DEFAULT_RANDOM_DIRECTION
 
- Static Public Attributes inherited from ParticleUniverse::ParticleAffector
static const bool DEFAULT_ENABLED
 
static const Vector3 DEFAULT_POSITION
 
static const AffectSpecialisation DEFAULT_SPECIALISATION
 
- Static Public Attributes inherited from ParticleUniverse::Particle
static Real DEFAULT_TTL
 
static Real DEFAULT_MASS
 

Protected Attributes

Real mMaxDeviationX
 
Real mMaxDeviationY
 
Real mMaxDeviationZ
 
Real mTimeSinceLastUpdate
 
Real mTimeStep
 
bool mRandomDirection
 
bool mUpdate
 
- Protected Attributes inherited from ParticleUniverse::ParticleAffector
ParticleTechniquemParentTechnique
 
String mAffectorType
 
String mName
 
AffectSpecialisation mAffectSpecialisation
 
list< StringmExcludedEmitters
 
Vector3 _mAffectorScale
 
- Protected Attributes inherited from ParticleUniverse::Particle
uint32 mEventFlags
 
bool mMarkedForEmission
 
bool mEnabled
 
bool mFreezed
 
bool mOriginalEnabled
 
bool mOriginalEnabledSet
 
Vector3 mDerivedPosition
 
ParticleBehaviourList mBehaviours
 
- Protected Attributes inherited from ParticleUniverse::IAlias
String mAliasName
 
AliasType mAliasType
 

Additional Inherited Members

- Public Types inherited from ParticleUniverse::ParticleAffector
enum  AffectSpecialisation { AFSP_DEFAULT, AFSP_TTL_INCREASE, AFSP_TTL_DECREASE }
 
- Public Types inherited from ParticleUniverse::Particle
enum  ParticleType {
  PT_VISUAL, PT_TECHNIQUE, PT_EMITTER, PT_AFFECTOR,
  PT_SYSTEM
}
 
enum  ReservedParticleEventFlags { PEF_EXPIRED = 1<<0, PEF_EMITTED = 1<<1, PEF_COLLIDED = 1<<2 }
 
typedef vector< ParticleBehaviour * > ParticleBehaviourList
 
typedef ParticleBehaviourList::const_iterator ParticleBehaviourIterator
 
- Public Types inherited from ParticleUniverse::IAlias
enum  AliasType {
  AT_UNDEFINED, AT_TECHNIQUE, AT_RENDERER, AT_EMITTER,
  AT_AFFECTOR, AT_OBSERVER, AT_EXTERN, AT_HANDLER,
  AT_BEHAVIOUR
}
 
- Public Attributes inherited from ParticleUniverse::Particle
ParticleEmitterparentEmitter
 
Vector3 position
 
Vector3 direction
 
Real mass
 
Real timeToLive
 
Real totalTimeToLive
 
Real timeFraction
 
ParticleType particleType
 
Any mUserDefinedObject
 
PhysicsActorphysicsActor
 
IVisualDatavisualData
 
Vector3 originalPosition
 
Vector3 originalDirection
 
Real originalVelocity
 
Real originalDirectionLength
 
Real originalScaledDirectionLength
 
Vector3 latestPosition
 

Detailed Description

Randomises the position or the direction of a particle.

Constructor & Destructor Documentation

ParticleUniverse::Randomiser::Randomiser ( void  )
virtual ParticleUniverse::Randomiser::~Randomiser ( void  )
inlinevirtual

Member Function Documentation

virtual void ParticleUniverse::Randomiser::_affect ( ParticleTechnique particleTechnique,
Particle particle,
Real  timeElapsed 
)
virtual

Affect a particle.

Parameters
particlePointer to a ParticleTechnique to which the particle belongs.
particlePointer to a Particle.
timeElapsedThe number of seconds which have elapsed since the last call.

Implements ParticleUniverse::ParticleAffector.

virtual void ParticleUniverse::Randomiser::_postProcessParticles ( ParticleTechnique technique,
Real  timeElapsed 
)
virtual

Perform activities after the individual particles are processed.

Remarks
This function is called after the ParticleTechnique update-loop where all particles are traversed.

Reimplemented from ParticleUniverse::ParticleAffector.

virtual void ParticleUniverse::Randomiser::_preProcessParticles ( ParticleTechnique particleTechnique,
Real  timeElapsed 
)
virtual

Perform activities before the individual particles are processed.

Remarks
This function is called before the ParticleTechnique update-loop where all particles are traversed. the preProcess is typically used to perform calculations where the result must be used in processing each individual particle.

Reimplemented from ParticleUniverse::ParticleAffector.

virtual void ParticleUniverse::Randomiser::copyAttributesTo ( ParticleAffector affector)
virtual

Copy attributes to another affector.

Reimplemented from ParticleUniverse::ParticleAffector.

Real ParticleUniverse::Randomiser::getMaxDeviationX ( void  ) const
Real ParticleUniverse::Randomiser::getMaxDeviationY ( void  ) const
Real ParticleUniverse::Randomiser::getMaxDeviationZ ( void  ) const
Real ParticleUniverse::Randomiser::getTimeStep ( void  ) const
bool ParticleUniverse::Randomiser::isRandomDirection ( void  ) const
void ParticleUniverse::Randomiser::setMaxDeviationX ( const Real  maxDeviationX)
void ParticleUniverse::Randomiser::setMaxDeviationY ( const Real  maxDeviationZ)
void ParticleUniverse::Randomiser::setMaxDeviationZ ( const Real  maxDeviationZ)
void ParticleUniverse::Randomiser::setRandomDirection ( bool  randomDirection)
void ParticleUniverse::Randomiser::setTimeStep ( const Real  timeStep)

Member Data Documentation

const Vector3 ParticleUniverse::Randomiser::DEFAULT_MAX_DEVIATION
static
const bool ParticleUniverse::Randomiser::DEFAULT_RANDOM_DIRECTION
static
const Real ParticleUniverse::Randomiser::DEFAULT_TIME_STEP
static
Real ParticleUniverse::Randomiser::mMaxDeviationX
protected
Real ParticleUniverse::Randomiser::mMaxDeviationY
protected
Real ParticleUniverse::Randomiser::mMaxDeviationZ
protected
bool ParticleUniverse::Randomiser::mRandomDirection
protected
Real ParticleUniverse::Randomiser::mTimeSinceLastUpdate
protected
Real ParticleUniverse::Randomiser::mTimeStep
protected
bool ParticleUniverse::Randomiser::mUpdate
protected

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