As stupid as it might sound, I forgot how the subtrees are indexed in
spatially. Therefore it might make sense to simply document even the
trivial things in the header file to avoid future confusion.
Signed-off-by: Timo Kokkonen <kaapeli@itanic.dy.fi>
struct quadtree {
struct vector pos;
+
+ /*
+ * Each node divide the sub-tree in following quadtrants:
+ *
+ * up left (0) | up right (1)
+ * -----------------------------
+ * down left (2) | down right (3)
+ */
struct quadtree *child[4];
struct quadtree *parent;