|
group2 0.1.0
CSE 125 Group 2
|
Dynamic AABB tree for O(log n) overlap queries. More...
#include "ecs/physics/SweptCollision.hpp"#include <cstdint>#include <entt/entt.hpp>#include <functional>#include <glm/vec3.hpp>#include <vector>Go to the source code of this file.
Classes | |
| struct | physics::broadphase::Proxy |
| Stable handle to a tree leaf. More... | |
| class | physics::broadphase::Tree |
| Dynamic AABB tree. More... | |
| struct | physics::broadphase::Tree::Node |
Namespaces | |
| namespace | physics |
| Pure physics math — no ECS types, no registry. | |
| namespace | physics::broadphase |
Dynamic AABB tree for O(log n) overlap queries.
Box2D-style b2DynamicTree: a binary tree of "fat" AABBs (padded by a margin so small movements don't require re-insertion). Each leaf stores a stable Proxy handle plus user data (an entt::entity). Internal nodes track the union AABB of their children.
Operations.
Determinism. Tree topology depends on insertion order; for reproducible behaviour, callers insert proxies in stable entity-id order (see Phase 15 audit checklist).
Memory. Nodes are stored in a pool indexed by 32-bit ids; the free list reuses slots so capacity stays bounded.