Estella 0.113.0
A fast 2D and 3D game engine powered by WebAssembly and ECS
Loading...
Searching...
No Matches
SpringBoneSystem.hpp File Reference

Per-App secondary motion: runs every SpringBone chain after the animation has posed the skeleton and before the frame is drawn. More...

#include "../core/Types.hpp"
#include "../math/Math.hpp"
#include "../ecs/Registry.hpp"
#include "../ecs/TransformSystem.hpp"
#include "SpringBoneSolver.hpp"
#include <unordered_map>
#include <vector>
Include dependency graph for SpringBoneSystem.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  esengine::springbone::SpringBoneSystem

Namespaces

namespace  esengine
namespace  esengine::springbone

Detailed Description

Per-App secondary motion: runs every SpringBone chain after the animation has posed the skeleton and before the frame is drawn.

The runtime state (each chain's simulated points) lives HERE, keyed by the chain's root entity, not on the component — the split TrailSystem and ParticleSystem make, so the component stays configuration and serialization never sees the transient state.

Per chain, per frame: read the pose the animation gave the bones (world transforms composed from their local ones), step the simulation toward it, then write back, for each bone, the local rotation that aims it at where its child has got to. Positions of bones are never written, so a bone cannot leave its parent; only rotations change, which is what skinning needs.

Definition in file SpringBoneSystem.hpp.