Header only 3D Particle Emitter in C99
This library computes 3d particles in pure C99.
The example uses raylib as a render engine.
This library follows single-file C/C++ public domain libraries rules.
Include the header file and the definition to include the implementation code in just one of the includes.
#define PARTICLE_EMITTER_IMPLEMENTATION
#include "particle_emitter.h"
Refer the examples to see the library usage.
Creates the emitter
EmitConfiguration configuration;
configuration.particlesPerSecond = 30;
(...)
Emitter emitter = particle_emitter_create(configuration);
Update the particles
particle_emitter_update(&emitter, dt);
Destroys the emitter
particle_emitter_destroy(&emitter);
- General forces (gravity, wind)
- Attraction / Repulsion vortices
- Friction
- Particle attributes
- rotation
- scale
- color
- Implement an editor
- Load and save presets
- Support more attributes