Trait rin::prelude::NodeRef[][src]

pub trait NodeRef {
Show methods pub fn node(&self) -> &Node; pub fn position(&self) -> Point<f32, U3> { ... }
pub fn orientation(&self) -> Unit<Quaternion<f32>> { ... }
pub fn rotation(&self) -> Rotation<f32, U3> { ... }
pub fn scale(
        &self
    ) -> Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer> { ... }
pub fn local_x_axis(
        &self
    ) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>> { ... }
pub fn local_y_axis(
        &self
    ) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>> { ... }
pub fn local_z_axis(
        &self
    ) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>> { ... }
pub fn global_x_axis(
        &self
    ) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>> { ... }
pub fn global_y_axis(
        &self
    ) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>> { ... }
pub fn global_z_axis(
        &self
    ) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>> { ... }
pub fn local_transformation(
        &self
    ) -> Matrix<f32, U4, U4, <DefaultAllocator as Allocator<f32, U4, U4>>::Buffer> { ... }
pub fn global_transformation(
        &self
    ) -> Matrix<f32, U4, U4, <DefaultAllocator as Allocator<f32, U4, U4>>::Buffer> { ... }
pub fn global_position(&self) -> Point<f32, U3> { ... }
pub fn global_orientation(&self) -> Unit<Quaternion<f32>> { ... }
pub fn global_scale(
        &self
    ) -> Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer> { ... }
pub fn inv_local_transformation(
        &self
    ) -> Matrix<f32, U4, U4, <DefaultAllocator as Allocator<f32, U4, U4>>::Buffer> { ... }
pub fn inv_global_transformation(
        &self
    ) -> Matrix<f32, U4, U4, <DefaultAllocator as Allocator<f32, U4, U4>>::Buffer> { ... }
}

Trait to implement by objects that conatain a node and want to expose it’s same api

NodeRef only exposes the non mutable api for a node

Required methods

pub fn node(&self) -> &Node[src]

Returns this object’s Node

Loading content...

Provided methods

pub fn position(&self) -> Point<f32, U3>[src]

Returns the local position of this node

pub fn orientation(&self) -> Unit<Quaternion<f32>>[src]

Returns the orientation of this node as a quaternion which is how it’s stored internally

pub fn rotation(&self) -> Rotation<f32, U3>[src]

Returns the orientation of this node as a Rotation3.

This method converts the internal quaternion into a Rotation3

pub fn scale(
    &self
) -> Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>
[src]

Returns the current local scale

pub fn local_x_axis(
    &self
) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>>
[src]

The node orientation x axis

pub fn local_y_axis(
    &self
) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>>
[src]

The node orientation y axis

pub fn local_z_axis(
    &self
) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>>
[src]

The node orientation z axis

pub fn global_x_axis(
    &self
) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>>
[src]

The node orientation x axis

pub fn global_y_axis(
    &self
) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>>
[src]

The node orientation y axis

pub fn global_z_axis(
    &self
) -> Unit<Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>>
[src]

The node orientation z axis

pub fn local_transformation(
    &self
) -> Matrix<f32, U4, U4, <DefaultAllocator as Allocator<f32, U4, U4>>::Buffer>
[src]

Local transformation matrix

pub fn global_transformation(
    &self
) -> Matrix<f32, U4, U4, <DefaultAllocator as Allocator<f32, U4, U4>>::Buffer>
[src]

Global transformation matrix

pub fn global_position(&self) -> Point<f32, U3>[src]

Global position of this node

pub fn global_orientation(&self) -> Unit<Quaternion<f32>>[src]

Global orientation of this node

pub fn global_scale(
    &self
) -> Matrix<f32, U3, U1, <DefaultAllocator as Allocator<f32, U3, U1>>::Buffer>
[src]

Global scale of this node

pub fn inv_local_transformation(
    &self
) -> Matrix<f32, U4, U4, <DefaultAllocator as Allocator<f32, U4, U4>>::Buffer>
[src]

Inverse local transformation of this node

This is cacheed internally and uses the fastest version posible to calculate the inverse so it’s usually faster than calling local_transformation().try_inverse()

pub fn inv_global_transformation(
    &self
) -> Matrix<f32, U4, U4, <DefaultAllocator as Allocator<f32, U4, U4>>::Buffer>
[src]

Inverse global transformation of this node

This is cacheed internally and uses the fastest version posible to calculate the inverse so it’s usually faster than calling global_transformation().try_inverse()

Loading content...

Implementors

impl NodeRef for rin::graphics::Camera[src]

impl NodeRef for Node[src]

impl NodeRef for OrthoCamera[src]

impl<C> NodeRef for ArcballCamera<C> where
    C: NodeRef
[src]

impl<C> NodeRef for rin::scene::Camera<C> where
    C: NodeRef
[src]

impl<G> NodeRef for Object<G>[src]

Loading content...