Struct adi::screen::Matrix

source ·
pub struct Matrix {
Show 16 fields pub m00: f32, pub m01: f32, pub m02: f32, pub m03: f32, pub m10: f32, pub m11: f32, pub m12: f32, pub m13: f32, pub m20: f32, pub m21: f32, pub m22: f32, pub m23: f32, pub m30: f32, pub m31: f32, pub m32: f32, pub m33: f32,
}
Expand description

4x4 Matrix.

Fields

m00: f32m01: f32m02: f32m03: f32m10: f32m11: f32m12: f32m13: f32m20: f32m21: f32m22: f32m23: f32m30: f32m31: f32m32: f32m33: f32

Implementations

Scale, then rotate Quaternion (axis, angle), then translate.

Rotate Quaternion (axis, angle), then translate.

Scale, then translate.

Translate.

Scale.

Rotate Quaternion (axis, angle).

Multiply by a custom matrix

Full constructor.

Diagonal constructor.

Tri-diagonal constructor.

Orthographic projection matrix constructor.

Finite perspective projection matrix constructor.

Computes the matrix determinant.

Computes the matrix trace.

Computes the matrix inverse.

Panics

Panics if the matrix has no inverse (i.e. has zero determinant).

Returns the matrix transpose.

Attempts to compute the matrix inverse, returning None if the matrix is non-invertible (i.e. has zero determinant).

Trait Implementations

The resulting type after applying the + operator.
Performs the + operation. Read more
Converts this type into a shared reference of the (usually inferred) input type.
Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Returns the “default value” for a type. Read more
Formats the value using the given formatter. Read more
Converts to this type from the input type.
Converts to this type from the input type.
Converts this type into the (usually inferred) input type.
Converts this type into the (usually inferred) input type.
The resulting type after applying the * operator.
Performs the * operation. Read more
The resulting type after applying the * operator.
Performs the * operation. Read more
The resulting type after applying the * operator.
Performs the * operation. Read more
The resulting type after applying the * operator.
Performs the * operation. Read more
This method tests for self and other values to be equal, and is used by ==. Read more
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason. Read more
The resulting type after applying the - operator.
Performs the - operation. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
Converts the given value to a String. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.