nalgebra::base

Type Alias UnitVector2

Source
pub type UnitVector2<T> = Unit<Matrix<T, U2, U1, ArrayStorage<T, 2, 1>>>;
Expand description

A stack-allocated, 2-dimensional unit vector.

Aliased Type§

struct UnitVector2<T> { /* private fields */ }

Trait Implementations§

Source§

impl TryFrom<DVec2> for UnitVector2<f64>

Source§

type Error = &'static str

The type returned in the event of a conversion error.
Source§

fn try_from(e: DVec2) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<Vec2> for UnitVector2<f32>

Source§

type Error = &'static str

The type returned in the event of a conversion error.
Source§

fn try_from(e: Vec2) -> Result<Self, Self::Error>

Performs the conversion.