Octree based on triangles. Allows for fast collision-detection with a set of triangles. Each triangle is a TTriangle structure, that keeps triangle geometry in 3D space, and links to parent VRML Shapes and such.
By keeping a list of triangles here, and only keeping indexes to this table in leafs (in ItemsIndices) we conserve a lot of memory. This also allows to use mailboxes and fast TriangleToIgnore (because every triangle has a unique index, and a pointer too, shared even if this triangle is placed in multiple leaves).
Methods
function StatisticsBonus( const LeavesCount, ItemsCount, NonLeafNodesCount: Int64): string; override;
Add a single triangle. Automatically checks whether IsValidTriangle. Before adding a lot of triangles, it's suggested to increase Triangles.AllowedCapacityCount.