[][src]Struct rust_3d::Matrix4Pipe

pub struct Matrix4Pipe {
    pub mtranslation: Matrix4,
    pub mrotation: Matrix4,
    pub mscale: Matrix4,
    pub mperspective: Matrix4,
    pub mcamtrans: Matrix4,
    pub mcamlook: Matrix4,
}

Matrix4Pipe, which makes it easier to pipe different matrices in a defined order

Fields

mtranslation: Matrix4mrotation: Matrix4mscale: Matrix4mperspective: Matrix4mcamtrans: Matrix4mcamlook: Matrix4

Implementations

impl Matrix4Pipe[src]

pub fn result(&self) -> Matrix4[src]

Creates a new matrix as a result of all defined operations set within the pipe

pub fn add_translation(&mut self, x: f64, y: f64, z: f64)[src]

Adds a translation to the pipe

pub fn remove_translation(&mut self)[src]

Removes any translation from the pipe

pub fn add_rotation(&mut self, x: Rad, y: Rad, z: Rad)[src]

Adds a rotation to the pipe

pub fn add_rotation_axis<N>(&mut self, axis: &N, rad: Rad) where
    N: IsNormalized3D
[src]

Adds a rotation around an axis to the pipe

pub fn remove_rotation(&mut self)[src]

Removes any rotation from the pipe

pub fn add_scale(&mut self, x: f64, y: f64, z: f64)[src]

Adds scaling to the pipe

pub fn remove_scale(&mut self)[src]

Removes any scaling from the pipe

pub fn add_perspective(&mut self, close: f64, away: f64, rad: Rad)[src]

Adds a perspective transformation to the pipe

pub fn remove_perspective(&mut self)[src]

Removes any perspective transformation from the pipe

pub fn add_camera_translation(&mut self, x: f64, y: f64, z: f64)[src]

Adds camera translation to the pipe

pub fn remove_camera_translation(&mut self)[src]

Removes any camera translation from the pipe

pub fn add_look_at<P, N>(&mut self, target: &P, up: &N) -> Result<()> where
    P: IsBuildable3D,
    N: IsNormalized3D
[src]

Adds a look at target to the pipe

pub fn remove_look_at(&mut self)[src]

Removes any look at target from the pipe

Trait Implementations

impl Clone for Matrix4Pipe[src]

impl Debug for Matrix4Pipe[src]

impl Default for Matrix4Pipe[src]

impl PartialEq<Matrix4Pipe> for Matrix4Pipe[src]

impl PartialOrd<Matrix4Pipe> for Matrix4Pipe[src]

impl StructuralPartialEq for Matrix4Pipe[src]

Auto Trait Implementations

Blanket Implementations

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

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

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

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.