|
Estella 0.113.0
A fast 2D and 3D game engine powered by WebAssembly and ECS
|
#include <Particle.hpp>
Public Member Functions | |
| ParticlePool (u32 capacity) | |
| Particle * | allocate () |
| void | deallocate (Particle *particle) |
| void | clear () |
| u32 | capacity () const |
| u32 | aliveCount () const |
| std::vector< Particle > & | particles () |
| const std::vector< Particle > & | particles () const |
| template<typename Fn> | |
| void | forEachAlive (Fn &&fn) |
| template<typename Fn> | |
| void | forEachAlive (Fn &&fn) const |
| void | deallocateByIndex (u32 index) |
| Deallocate a particle by its pool index. | |
Definition at line 39 of file Particle.hpp.
|
explicit |
Definition at line 7 of file Particle.cpp.
References capacity().
|
inline |
Definition at line 48 of file Particle.hpp.
Referenced by esengine::particle::ParticleSystem::emitAt(), and esengine::particle::ParticleSystem::update().
| Particle * esengine::particle::ParticlePool::allocate | ( | ) |
Definition at line 15 of file Particle.cpp.
References esengine::particle::Particle::alive.
|
inline |
Definition at line 47 of file Particle.hpp.
Referenced by ParticlePool().
| void esengine::particle::ParticlePool::clear | ( | ) |
Definition at line 39 of file Particle.cpp.
| void esengine::particle::ParticlePool::deallocate | ( | Particle * | particle | ) |
Definition at line 29 of file Particle.cpp.
| void esengine::particle::ParticlePool::deallocateByIndex | ( | u32 | index | ) |
Deallocate a particle by its pool index.
Definition at line 50 of file Particle.cpp.
Referenced by esengine::particle::ParticleSystem::resolveCollisions().
|
inline |
Definition at line 53 of file Particle.hpp.
|
inline |
Definition at line 60 of file Particle.hpp.
|
inline |
Definition at line 49 of file Particle.hpp.
Referenced by esengine::particle::ParticleSystem::resolveCollisions().
|
inline |
Definition at line 50 of file Particle.hpp.