Destroy frees the nodes if the Quadtree uses the node pool
()
| 114 | |
| 115 | // Destroy frees the nodes if the Quadtree uses the node pool |
| 116 | func (qt *Quadtree) Destroy() { |
| 117 | qt.freeQuadtreeNode(qt.root) |
| 118 | qt.root = nil |
| 119 | } |
| 120 | |
| 121 | func (qt *Quadtree) newNode(bounds AABB, level int) (node *quadtreeNode) { |
| 122 | if qt.usePool { |
no test coverage detected