[][src]Struct gdnative::Basis

#[repr(C)]
pub struct Basis {
    pub elements: [Vector3D<f32, UnknownUnit>; 3],
}

A 3x3 matrix.

Fields

elements: [Vector3D<f32, UnknownUnit>; 3]

Methods

impl Basis[src]

pub fn identity() -> Basis[src]

pub fn from_diagonal(p_diag: Vector3D<f32, UnknownUnit>) -> Basis[src]

pub fn from_transform(
    transform: &Transform3D<f32, UnknownUnit, UnknownUnit>
) -> Basis
[src]

Creates a Basis from the rotation and scaling of the provided transform.

pub fn from_typed_transform<Src, Dst>(
    transform: &Transform3D<f32, Src, Dst>
) -> Basis
[src]

Creates a Basis from the rotation and scaling of the provided transform, in Dst space.

pub fn tdotx(&self, v: Vector3D<f32, UnknownUnit>) -> f32[src]

Transposed dot product with the x axis of the matrix.

pub fn tdoty(&self, v: Vector3D<f32, UnknownUnit>) -> f32[src]

Transposed dot product with the y axis of the matrix.

pub fn tdotz(&self, v: Vector3D<f32, UnknownUnit>) -> f32[src]

Transposed dot product with the z axis of the matrix.

Trait Implementations

impl Clone for Basis[src]

impl Copy for Basis[src]

impl Debug for Basis[src]

impl Export for Basis[src]

type Hint = ()

A type-specific hint type that is valid for the type being exported.

impl<'l> From<&'l Basis> for Variant[src]

impl FromVariant for Basis[src]

impl PartialEq<Basis> for Basis[src]

impl StructuralPartialEq for Basis[src]

impl ToVariant for Basis[src]

Auto Trait Implementations

impl RefUnwindSafe for Basis

impl Send for Basis

impl Sync for Basis

impl Unpin for Basis

impl UnwindSafe for Basis

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> Export for T where
    T: GodotObject + ToVariant
[src]

type Hint = ()

A type-specific hint type that is valid for the type being exported.

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.