public class CoverKt
| Modifier and Type | Method and Description |
|---|---|
static <D> void |
cover(Quadtree<D> $receiver,
double x,
double y)
Expands the quadtree to cover the specified point ⟨x,y⟩.
If the quadtree’s extent already covers the specified point, this method does nothing.
If the quadtree has an extent, the extent is repeatedly doubled to cover the specified point, wrapping the
root node as necessary; if the quadtree is empty, the extent is initialized to the extent (⌊x⌋, ⌊y⌋, ⌈x⌉, ⌈y⌉).
(Rounding is necessary such that if the extent is later doubled, the boundaries of existing quadrants do
not change due to floating point error.)
|
public static <D> void cover(Quadtree<D> $receiver, double x, double y)
Expands the quadtree to cover the specified point ⟨x,y⟩. If the quadtree’s extent already covers the specified point, this method does nothing. If the quadtree has an extent, the extent is repeatedly doubled to cover the specified point, wrapping the root node as necessary; if the quadtree is empty, the extent is initialized to the extent (⌊x⌋, ⌊y⌋, ⌈x⌉, ⌈y⌉). (Rounding is necessary such that if the extent is later doubled, the boundaries of existing quadrants do not change due to floating point error.)