Just out of curiosity, why did you make a "spheretree" system? I can't think of a reason not to use R-trees because you need to use the rectilinear bounding box of the given polygon in order to do the initial culling efficiently. With a sphere-based system, you need to calculate a vector normal for every single test, which, I would think, would bog you down considerably.
|