Module effects

Expand description

Original bounded simulation and shared low-poly GPU effect rendering.

Modules§

presets
Original procedural templates. Units are meters/seconds; scale the authored velocity, acceleration and size for pixel-coordinate games.

Structs§

BeamDesc
BeamPool
BeamView
BillboardView
BurstAdmission
Read-only burst admission at the pool’s current occupancy.
DirectionCone
DrawReport
EffectStats
EffectStyle
EmissionStats
Emitter
Particle position/velocity and spawn shapes are emitter-local; acceleration remains world-space so rotating a nozzle does not rotate gravity. Counter-seeded emission: dropped work still advances the sequence without iterating it, so pool capacity/quality cannot perturb a gameplay RNG or the random values assigned to later requested particles. No per-frame allocation.
EmitterDesc
EmitterTransform
ParticleDesc
ParticleMotion
ParticlePool
ParticleRenderer
Scratch is allocated once. Alpha 3D particles sort by camera depth with an allocation-free unstable sort and explicit tie order. Oversized pools are truncated to this renderer’s capacity, independently of the geometry budget.
ParticleStyle
ParticleView
RibbonPath
RibbonPoint
RibbonTriangle
RibbonTriangles
Triangle iterator with bounded miters and explicit breaks; no allocation.
RibbonVertex
Trail
Fixed ring, distance resampling and a current head. Capacity bounds the visible point count (including that head); one extra head value is stored separately. Stops and teleports create breaks; old segments fade naturally without bridges. Use Self::break_segment or Self::teleport for explicit discontinuities, including short respawn jumps, and Self::clear to reset all trail history.
TrailConfig
TrailSample
TrailStats

Enums§

BeamError
EffectBlend
EffectError
OverflowPolicy
ParticleError
ParticleShape
RibbonError
RibbonFacing
SpawnShape
TrailError

Constants§

MAX_BEAMS
MAX_EFFECT_LIFETIME
MAX_EMISSION_PER_UPDATE
MAX_PARTICLES
MAX_RIBBON_POINTS
MAX_RIBBON_WIDTH
Largest accepted full ribbon width, in world units.
MAX_TRAIL_POINTS

Traits§

RibbonSource

Functions§

draw_beams
draw_ribbon
draw_triangles
Record unlit, normalized RGBA triangles with the current camera. This color stream is shared with ordinary geometry; flags preserve blend/depth/HUD order. At most 65,536 triangles are examined per frame, including malformed input.
effect_stats
particle_triangles
CPU reference geometry for software hosts and GPU comparison tests.