InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType > Class Template Reference
The complete Policy template for initializing particles, used by the ParticleSystem class.
More...
#include <Graphics/ParticleSystem.h>
List of all members.
Detailed Description
template<class PositionPolicy, class VelocityPolicy, class AnglePolicy, class SizePolicy, class ColorPolicy, class AgePolicy, class UserPolicy = NullInitPolicy<Particle>, class ParticleType = Particle>
class InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType >
The complete Policy template for initializing particles, used by the ParticleSystem class.
- Template Parameters:
-
| PositionPolicy | the policy for updating particle position, expected to have the same methods as the Policy template. |
| VelocityPolicy | the policy for updating particle velocity, expected to have the same methods as the Policy template. |
| AnglePolicy | the policy for updating particle angle and angular velocity, expected to have the same methods as the Policy template. |
| SizePolicy | the policy for updating particle size, expected to have the same methods as the Policy template. |
| ColorPolicy | the policy for updating particle color, expected to have the same methods as the Policy template. |
| AgePolicy | the policy for updating particle age, expected to have the same methods as the Policy template. |
| UserPolict | an extra policy that can do whatever the user wants. Defaults to the NullPolicy. |
| ParticleType | the type of particle to use in the particle system. The ParticleType is expected to inheret from the Particle class (or at least have duplicate members). |
Member Function Documentation
template<class PositionPolicy , class VelocityPolicy , class AnglePolicy , class SizePolicy , class ColorPolicy , class AgePolicy , class UserPolicy = NullInitPolicy<Particle>, class ParticleType = Particle>
void InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType >::InitParticle |
( |
ParticleType & |
p |
) |
[inline] |
Called once on each new particle that is emitted.
- Parameters:
-
[in] | p | the particle to initialize. |
template<class PositionPolicy , class VelocityPolicy , class AnglePolicy , class SizePolicy , class ColorPolicy , class AgePolicy , class UserPolicy = NullInitPolicy<Particle>, class ParticleType = Particle>
void InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType >::PreEmit |
( |
const Point2f & |
pos, |
|
|
uint |
amount | |
|
) |
| | [inline] |
Called once before new particles are emitted.
- Parameters:
-
[in] | pos | the requested position to emit the particles. |
[in] | amount | the number of particles that will be emitted. |
Member Data Documentation
template<class PositionPolicy , class VelocityPolicy , class AnglePolicy , class SizePolicy , class ColorPolicy , class AgePolicy , class UserPolicy = NullInitPolicy<Particle>, class ParticleType = Particle>
AgePolicy InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType >::agePolicy |
template<class PositionPolicy , class VelocityPolicy , class AnglePolicy , class SizePolicy , class ColorPolicy , class AgePolicy , class UserPolicy = NullInitPolicy<Particle>, class ParticleType = Particle>
AnglePolicy InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType >::anglePolicy |
The angle and agular velocity policy
template<class PositionPolicy , class VelocityPolicy , class AnglePolicy , class SizePolicy , class ColorPolicy , class AgePolicy , class UserPolicy = NullInitPolicy<Particle>, class ParticleType = Particle>
ColorPolicy InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType >::colorPolicy |
template<class PositionPolicy , class VelocityPolicy , class AnglePolicy , class SizePolicy , class ColorPolicy , class AgePolicy , class UserPolicy = NullInitPolicy<Particle>, class ParticleType = Particle>
PositionPolicy InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType >::positionPolicy |
template<class PositionPolicy , class VelocityPolicy , class AnglePolicy , class SizePolicy , class ColorPolicy , class AgePolicy , class UserPolicy = NullInitPolicy<Particle>, class ParticleType = Particle>
SizePolicy InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType >::sizePolicy |
template<class PositionPolicy , class VelocityPolicy , class AnglePolicy , class SizePolicy , class ColorPolicy , class AgePolicy , class UserPolicy = NullInitPolicy<Particle>, class ParticleType = Particle>
UserPolicy InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType >::userPolicy |
template<class PositionPolicy , class VelocityPolicy , class AnglePolicy , class SizePolicy , class ColorPolicy , class AgePolicy , class UserPolicy = NullInitPolicy<Particle>, class ParticleType = Particle>
VelocityPolicy InitPolicy< PositionPolicy, VelocityPolicy, AnglePolicy, SizePolicy, ColorPolicy, AgePolicy, UserPolicy, ParticleType >::velocityPolicy |
The documentation for this class was generated from the following file: