tree_d_3d.quad
The square cells of the quadtrees.
Classes
| Name | Description |
|---|---|
Quad | Represents a quadrant in the quadtree. |
Quadclass#
class Quad(x_mid: float, y_mid: float, half_size: float)Represents a quadrant in the quadtree.
halfattributeinstance attribute#
half: float = half_sizexmidattributeinstance attribute#
xmid: float = x_midymidattributeinstance attribute#
ymid: float = y_midcontainsmethod#
def contains(x: float, y: float) -> boolCheck if point is within this quadrant.
northeastmethod#
def northeast() -> QuadCreate northeast child quadrant.
northwestmethod#
def northwest() -> QuadCreate northwest child quadrant.
southeastmethod#
def southeast() -> QuadCreate southeast child quadrant.
southwestmethod#
def southwest() -> QuadCreate southwest child quadrant.