Skip to main content

vec2

Type Alias vec2 

Source
pub type vec2<T> = (T, T);

Trait Implementations§

Source§

impl<T: Copy> Cast<&[T]> for vec2<T>

Source§

fn to(v: &[T]) -> Self

Source§

impl<T, A> Cast<[A; 2]> for vec2<T>
where T: Cast<A>,

Source§

fn to(v: [A; 2]) -> Self

Source§

impl<T> Cast<(T, T, T)> for vec2<T>

Source§

fn to((v1, v2, _): vec3<T>) -> Self

Source§

impl<T> Cast<(T, T, T, T)> for vec2<T>

Source§

fn to((v1, v2): vec4<T>) -> Self

Source§

impl Cast<Matrix<f16, Const<2>, Const<1>, ArrayStorage<f16, 2, 1>>> for vec2<f16>

Source§

fn to(v: Vector2<f16>) -> Self

Source§

impl Cast<Matrix<f32, Const<2>, Const<1>, ArrayStorage<f32, 2, 1>>> for vec2<f32>

Source§

fn to(v: Vector2<f32>) -> Self

Source§

impl Cast<Matrix<f64, Const<2>, Const<1>, ArrayStorage<f64, 2, 1>>> for vec2<f64>

Source§

fn to(v: Vector2<f64>) -> Self

Source§

impl Cast<Matrix<i128, Const<2>, Const<1>, ArrayStorage<i128, 2, 1>>> for vec2<i128>

Source§

fn to(v: Vector2<i128>) -> Self

Source§

impl Cast<Matrix<i16, Const<2>, Const<1>, ArrayStorage<i16, 2, 1>>> for vec2<i16>

Source§

fn to(v: Vector2<i16>) -> Self

Source§

impl Cast<Matrix<i32, Const<2>, Const<1>, ArrayStorage<i32, 2, 1>>> for vec2<i32>

Source§

fn to(v: Vector2<i32>) -> Self

Source§

impl Cast<Matrix<i64, Const<2>, Const<1>, ArrayStorage<i64, 2, 1>>> for vec2<i64>

Source§

fn to(v: Vector2<i64>) -> Self

Source§

impl Cast<Matrix<i8, Const<2>, Const<1>, ArrayStorage<i8, 2, 1>>> for vec2<i8>

Source§

fn to(v: Vector2<i8>) -> Self

Source§

impl Cast<Matrix<u128, Const<2>, Const<1>, ArrayStorage<u128, 2, 1>>> for vec2<u128>

Source§

fn to(v: Vector2<u128>) -> Self

Source§

impl Cast<Matrix<u16, Const<2>, Const<1>, ArrayStorage<u16, 2, 1>>> for vec2<u16>

Source§

fn to(v: Vector2<u16>) -> Self

Source§

impl Cast<Matrix<u32, Const<2>, Const<1>, ArrayStorage<u32, 2, 1>>> for vec2<u32>

Source§

fn to(v: Vector2<u32>) -> Self

Source§

impl Cast<Matrix<u64, Const<2>, Const<1>, ArrayStorage<u64, 2, 1>>> for vec2<u64>

Source§

fn to(v: Vector2<u64>) -> Self

Source§

impl Cast<Matrix<u8, Const<2>, Const<1>, ArrayStorage<u8, 2, 1>>> for vec2<u8>

Source§

fn to(v: Vector2<u8>) -> Self

Source§

impl Cast<OPoint<f16, Const<2>>> for vec2<f16>

Source§

fn to(v: Point2<f16>) -> Self

Source§

impl Cast<OPoint<f32, Const<2>>> for vec2<f32>

Source§

fn to(v: Point2<f32>) -> Self

Source§

impl Cast<OPoint<f64, Const<2>>> for vec2<f64>

Source§

fn to(v: Point2<f64>) -> Self

Source§

impl Cast<OPoint<i128, Const<2>>> for vec2<i128>

Source§

fn to(v: Point2<i128>) -> Self

Source§

impl Cast<OPoint<i16, Const<2>>> for vec2<i16>

Source§

fn to(v: Point2<i16>) -> Self

Source§

impl Cast<OPoint<i32, Const<2>>> for vec2<i32>

Source§

fn to(v: Point2<i32>) -> Self

Source§

impl Cast<OPoint<i64, Const<2>>> for vec2<i64>

Source§

fn to(v: Point2<i64>) -> Self

Source§

impl Cast<OPoint<i8, Const<2>>> for vec2<i8>

Source§

fn to(v: Point2<i8>) -> Self

Source§

impl Cast<OPoint<u128, Const<2>>> for vec2<u128>

Source§

fn to(v: Point2<u128>) -> Self

Source§

impl Cast<OPoint<u16, Const<2>>> for vec2<u16>

Source§

fn to(v: Point2<u16>) -> Self

Source§

impl Cast<OPoint<u32, Const<2>>> for vec2<u32>

Source§

fn to(v: Point2<u32>) -> Self

Source§

impl Cast<OPoint<u64, Const<2>>> for vec2<u64>

Source§

fn to(v: Point2<u64>) -> Self

Source§

impl Cast<OPoint<u8, Const<2>>> for vec2<u8>

Source§

fn to(v: Point2<u8>) -> Self

Source§

impl<T: Copy> FlattenCast<T> for vec2<T>

Source§

fn flatten(self) -> Vec<T>

Source§

impl<N: Copy, T: FlattenCast<N>> FlattenCastMat<N> for vec2<T>

Source§

fn flatten_all(self) -> Vec<N>

Source§

impl<T: ToZero> TupleIdentity for vec2<T>

Source§

fn one() -> Self

Source§

fn zero() -> Self