Trait geo_nd::Geometry2D

source ·
pub trait Geometry2D<Scalar: Float> {
    type Vec2: Vector<Scalar, 2>;
    type Mat2: SqMatrix<Self::Vec2, Scalar, 2, 4>;
}
Expand description

This is an experimental trait - it bundles together a Vec2 and a Mat2.

The Geometry2D trait supplies a framework for implementing 2D vector and matrix operations.

Required Associated Types§

source

type Vec2: Vector<Scalar, 2>

The type of a 2D vector

source

type Mat2: SqMatrix<Self::Vec2, Scalar, 2, 4>

The type of a 2D matrix that can transform a Vec2

Implementations on Foreign Types§

source§

impl Geometry2D<f64> for f64

§

type Vec2 = FArray<f64, 2>

§

type Mat2 = FArray2<f64, 2, 4>

source§

impl Geometry2D<f32> for f32

§

type Vec2 = FArray<f32, 2>

§

type Mat2 = FArray2<f32, 2, 4>

Implementors§