A ParticleLayer to add random 3D coordinates to a particle. More...
#include <RandomParticleLayer.h>
Classes | |
struct | RandomParticle |
Layer specific particle data for managing random particles. More... | |
Public Member Functions | |
RandomParticleLayer (box3f bounds) | |
Creates a new RandomParticleLayer. | |
virtual | ~RandomParticleLayer () |
Deletes this RandomParticleLayer. | |
RandomParticle * | getRandomParticle (ParticleStorage::Particle *p) |
Returns the random specific data of the given particle. | |
virtual void | addNewParticles () |
Adds new particles. | |
Protected Member Functions | |
RandomParticleLayer () | |
Creates an uninitialized RandomParticleLayer. | |
void | init (box3f bounds) |
Initializes this RandomParticleLayer. | |
virtual void | initParticle (ParticleStorage::Particle *p) |
Initializes the random position of the given particle. | |
Private Attributes | |
box3f | bounds |
The bounds of the random positions. |
A ParticleLayer to add random 3D coordinates to a particle.
This class provides particle data to store a position for each particle.
proland::RandomParticleLayer::RandomParticleLayer | ( | box3f | bounds | ) |
Creates a new RandomParticleLayer.
bounds | the bounds of the random positions. |
virtual proland::RandomParticleLayer::~RandomParticleLayer | ( | ) | [virtual] |
Deletes this RandomParticleLayer.
proland::RandomParticleLayer::RandomParticleLayer | ( | ) | [protected] |
Creates an uninitialized RandomParticleLayer.
virtual void proland::RandomParticleLayer::addNewParticles | ( | ) | [virtual] |
Adds new particles.
The default implementation of this method does nothing.
Reimplemented from proland::ParticleLayer.
RandomParticle* proland::RandomParticleLayer::getRandomParticle | ( | ParticleStorage::Particle * | p | ) | [inline] |
Returns the random specific data of the given particle.
p | a particle. |
void proland::RandomParticleLayer::init | ( | box3f | bounds | ) | [protected] |
Initializes this RandomParticleLayer.
See RandomParticleLayer.
virtual void proland::RandomParticleLayer::initParticle | ( | ParticleStorage::Particle * | p | ) | [protected, virtual] |
Initializes the random position of the given particle.
Reimplemented from proland::ParticleLayer.
box3f proland::RandomParticleLayer::bounds [private] |
The bounds of the random positions.