Trait rust_3d::traits::HasDistanceTo [] [src]

pub trait HasDistanceTo<T> {
    fn sqr_distance(&self, other: &T) -> NonNegative;

    fn distance(&self, other: &T) -> NonNegative { ... }
}

HasDistanceTo trait used for types which have a defined distance towards another T. Implementing HasDistanceTo for U also implements HasDistanceTo for T

Required Methods

Should return the sqr distance to other

Provided Methods

The distance to other

Implementors