Trait sif_rtree::Object

source ·
pub trait Object {
    type Point: Point;

    // Required method
    fn aabb(&self) -> (Self::Point, Self::Point);
}
Expand description

Defines the objects which can be organized in an RTree by specifying their extent in the vector space defined via the Point trait

Required Associated Types§

source

type Point: Point

The Point implementation used to represent the axis-aligned bounding boxes (AABB) of these objects.

Required Methods§

source

fn aabb(&self) -> (Self::Point, Self::Point)

Return the axis-aligned bounding box (AABB) associated with this object.

Note that this method is called repeatedly during construction and querying. Hence it might be necessary to cache the value internally to avoid the cost of computing it repeatedly.

Implementors§