Trait FromIntoPointLike

Source
pub trait FromIntoPointLike<T>: Sized {
    // Required methods
    fn from_point_like(t: T) -> Self;
    fn into_point_like(self) -> T;
}
Expand description

A point-like type that can be converted to and from [F; 2].

Any third component is assumed to be zero.

Required Methods§

Source

fn from_point_like(t: T) -> Self

Source

fn into_point_like(self) -> T

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<F> FromIntoPointLike<[F; 2]> for [F; 2]
where F: Float,

Source§

impl<F> FromIntoPointLike<[F; 2]> for [F; 3]
where F: Float,

Source§

impl<F> FromIntoPointLike<[F; 2]> for (F, F)
where F: Float,

Source§

impl<F> FromIntoPointLike<[F; 2]> for (F, F, F)
where F: Float,

Implementors§