[][src]Struct micromath::vector::I8x2

pub struct I8x2 {
    pub x: i8,
    pub y: i8,

2-dimensional XY vector of i8 values


x: i8

X component

y: i8

Y component


impl I8x2[src]

pub fn new(x: i8, y: i8) -> Self[src]

Instantiate from X and Y components

Trait Implementations

impl Vector for I8x2[src]

type Component = i8

Type representing measured acceleration for a particular axis

type Axes = U2

Number of axes

impl From<(i8, i8)> for I8x2[src]

impl From<I8x2> for F32x2[src]

impl Debug for I8x2[src]

impl PartialEq<I8x2> for I8x2[src]

impl MulAssign<f32> for I8x2[src]

impl MulAssign<i8> for I8x2[src]

impl Index<usize> for I8x2[src]

type Output = i8

The returned type after indexing.

impl Copy for I8x2[src]

impl StructuralPartialEq for I8x2[src]

impl Clone for I8x2[src]

impl Default for I8x2[src]

Auto Trait Implementations

impl Unpin for I8x2

impl Send for I8x2

impl Sync for I8x2

Blanket Implementations

impl<V, A, C> VectorExt for V where
    A: ArrayLength<C>,
    C: Component + Into<f32>,
    V: Vector<Axes = A, Component = C> + MulAssign<f32>, 

fn distance(Self, V) -> f32[src]

Compute the distance between two vectors

fn magnitude(Self) -> f32[src]

Compute the magnitude of a vector

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> Into<U> for T where
    U: From<T>, 

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized

impl<T> BorrowMut<T> for T where
    T: ?Sized

impl<T> Any for T where
    T: 'static + ?Sized

impl<T> Same<T> for T

type Output = T

Should always be Self