Manages a set of individual ParticleSystem objects, so that each individual one doesn't have to be updated and rendered every frame See Also : particleSystemManager.cxx. More...
#include "particleSystemManager.h"
Public Member Functions | |
ParticleSystemManager (int every_nth_frame=1) | |
default constructor More... | |
virtual | ~ParticleSystemManager () |
Destructor. More... | |
void | attach_particlesystem (ParticleSystem *ps) |
void | clear () |
void | do_particles (PN_stdfloat dt) |
does an update and render for each ps in the list. More... | |
void | do_particles (PN_stdfloat dt, ParticleSystem *ps, bool do_render=true) |
does an update and an optional render for a specific ps. More... | |
int | get_frame_stepping () const |
virtual void | output (std::ostream &out) const |
Write a string representation of this instance to <out>. More... | |
void | remove_particlesystem (ParticleSystem *ps) |
removes a ps from the maintenance list More... | |
void | set_frame_stepping (int every_nth_frame) |
virtual void | write (std::ostream &out, int indent=0) const |
Write a string representation of this instance to <out>. More... | |
virtual void | write_ps_list (std::ostream &out, int indent=0) const |
Write a string representation of this instance to <out>. More... | |
Manages a set of individual ParticleSystem objects, so that each individual one doesn't have to be updated and rendered every frame See Also : particleSystemManager.cxx.
Definition at line 27 of file particleSystemManager.h.
|
explicit |
default constructor
Definition at line 30 of file particleSystemManager.cxx.
|
virtual |
Destructor.
Definition at line 38 of file particleSystemManager.cxx.
void ParticleSystemManager::do_particles | ( | PN_stdfloat | dt | ) |
does an update and render for each ps in the list.
this is probably the one you want to use. Rendering is the expensive operation, and particles REALLY should at least be updated every frame, so nth_frame stepping applies only to rendering.
Definition at line 64 of file particleSystemManager.cxx.
void ParticleSystemManager::do_particles | ( | PN_stdfloat | dt, |
ParticleSystem * | ps, | ||
bool | do_render = true |
||
) |
does an update and an optional render for a specific ps.
Since rendering is the expensive operation, multiple updates could be applied before calling the final render.
Definition at line 128 of file particleSystemManager.cxx.
References ParticleSystem::render(), and ParticleSystem::update().
|
virtual |
Write a string representation of this instance to <out>.
Definition at line 148 of file particleSystemManager.cxx.
void ParticleSystemManager::remove_particlesystem | ( | ParticleSystem * | ps | ) |
removes a ps from the maintenance list
Definition at line 45 of file particleSystemManager.cxx.
|
virtual |
Write a string representation of this instance to <out>.
Definition at line 174 of file particleSystemManager.cxx.
References indent(), and write_ps_list().
|
virtual |
Write a string representation of this instance to <out>.
Definition at line 158 of file particleSystemManager.cxx.
References indent().
Referenced by write().