Bromeon
Public Types | Static Public Member Functions | Public Member Functions
thor::FadeInAffector Class Reference

Fades particles out over time. More...

Inheritance diagram for thor::FadeInAffector:
Inheritance graph

List of all members.

Public Types

typedef std::tr1::shared_ptr
< FadeInAffector
Ptr
 Shared pointer type referring to FadeInAffector objects.

Static Public Member Functions

static Ptr Create (float timeRatio=1.f)
 Creates an affector that increases the alpha value at the beginning of the particle lifetime.

Public Member Functions

 FadeInAffector (float timeRatio=1.f)
 Constructor.
virtual void Affect (Particle &particle, float dt)
 Affects particles.
void SetTimeRatio (float timeRatio)
 Sets the time ratio (how long the fade-out time is compared to the particle lifetime).
float GetTimeRatio () const
 Returns the time ratio (how long the fade-out time is compared to the particle lifetime).

Detailed Description

Fades particles out over time.

Affector class that constantly decreases the alpha color value of a particle.


Constructor & Destructor Documentation

thor::FadeInAffector::FadeInAffector ( float  timeRatio = 1.f) [explicit]

Constructor.

Parameters:
timeRatioHow long the fade-in time is in comparison to the total particle lifetime. For example, 1.f means over the whole lifetime, and 0.25f means to fade in the particle only in the first quarter.

Member Function Documentation

virtual void thor::FadeInAffector::Affect ( Particle particle,
float  dt 
) [virtual]

Affects particles.

Parameters:
particleThe particle currently being affected.
dtTime interval during which particles are affected.

Implements thor::Affector.

static Ptr thor::FadeInAffector::Create ( float  timeRatio = 1.f) [static]

Creates an affector that increases the alpha value at the beginning of the particle lifetime.

Parameters:
timeRatioHow long the fade-in time is in comparison to the total particle lifetime. For example, 1.f means over the whole lifetime, and 0.25f means to fade in the particle only in the first quarter.


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