Trait ccgeom::Geometry[][src]

pub trait Geometry<T: Scalar = f64>: Clone + 'static {
    type Pos: Clone;
    type Dir: Clone;
    type Map: Map<Self::Pos, Self::Dir>;
    fn origin() -> Self::Pos;
fn default_dir() -> Self::Dir;
fn length(a: Self::Pos) -> T;
fn distance(a: Self::Pos, b: Self::Pos) -> T; }
Expand description

N-dimensional geometry.

Associated Types

type Pos: Clone[src]

type Dir: Clone[src]

type Map: Map<Self::Pos, Self::Dir>[src]

Required methods

fn origin() -> Self::Pos[src]

Point of origin.

fn default_dir() -> Self::Dir[src]

Default direction at the point of origin.

fn length(a: Self::Pos) -> T[src]

fn distance(a: Self::Pos, b: Self::Pos) -> T[src]

Implementors

impl<T: Scalar> Geometry<T> for Euclidean3<T>[src]

type Pos = Vector<T, 3>

type Dir = Vector<T, 3>

type Map = Homogenous3<T>

fn origin() -> Self::Pos[src]

fn default_dir() -> Self::Dir[src]

fn length(a: Self::Pos) -> T[src]

fn distance(a: Self::Pos, b: Self::Pos) -> T[src]

impl<T: Scalar> Geometry<T> for Hyperbolic3<T>[src]

type Pos = Quaternion<T>

type Dir = Quaternion<T>

type Map = Moebius<Complex<T>>

fn origin() -> Self::Pos[src]

fn default_dir() -> Self::Dir[src]

fn length(a: Self::Pos) -> T[src]

fn distance(a: Self::Pos, b: Self::Pos) -> T[src]