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

Applies a rotational acceleration to particles over time. More...

Inheritance diagram for thor::TorqueAffector:
Inheritance graph

List of all members.

Public Types

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

Static Public Member Functions

static Ptr Create (float angularAcceleration)
 Creates an affector that applies an angular acceleration to particles.

Public Member Functions

 TorqueAffector (float angularAcceleration)
 Constructor.
virtual void Affect (Particle &particle, float dt)
 Affects particles.
void SetAngularAcceleration (float angularAcceleration)
 Sets the angular acceleration applied to the particles (in degrees).
float GetAngularAcceleration () const
 Returns the angular acceleration applied to the particles (in degrees).

Detailed Description

Applies a rotational acceleration to particles over time.

Affector class that applies a scalar angular acceleration value to each particle.


Constructor & Destructor Documentation

thor::TorqueAffector::TorqueAffector ( float  angularAcceleration) [explicit]

Constructor.

Parameters:
angularAccelerationThe angular acceleration, in degrees. The particle's rotation speed changes by this value each second.

Member Function Documentation

virtual void thor::TorqueAffector::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::TorqueAffector::Create ( float  angularAcceleration) [static]

Creates an affector that applies an angular acceleration to particles.

Parameters:
angularAccelerationThe angular acceleration, in degrees. The particle's rotation speed changes by this value each second.


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