pub struct MatrixUtils;Expand description
Helpers computing the transform of a composition visual.
Implementations§
Source§impl MatrixUtils
impl MatrixUtils
Sourcepub fn compute_transform(
size: Vector,
anchor_point: Vector,
center_point: Vector3D,
transform_matrix: Matrix,
scale: Vector3D,
rotation_angle: f32,
orientation: Quaternion,
offset: Vector3D,
) -> Option<Matrix>
pub fn compute_transform( size: Vector, anchor_point: Vector, center_point: Vector3D, transform_matrix: Matrix, scale: Vector3D, rotation_angle: f32, orientation: Quaternion, offset: Vector3D, ) -> Option<Matrix>
Computes the transform of a visual from its transform properties.
Returns None when the transform is the identity.
Sourcepub fn to_matrix4x4(matrix: Matrix) -> Matrix4x4
pub fn to_matrix4x4(matrix: Matrix) -> Matrix4x4
Converts a 3x3 matrix to the 4x4 matrix that leaves Z unchanged.
Auto Trait Implementations§
impl Freeze for MatrixUtils
impl RefUnwindSafe for MatrixUtils
impl Send for MatrixUtils
impl Sync for MatrixUtils
impl Unpin for MatrixUtils
impl UnsafeUnpin for MatrixUtils
impl UnwindSafe for MatrixUtils
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> ClassDefaults for Twhere
T: ?Sized,
impl<T> ClassDefaults for Twhere
T: ?Sized,
Source§fn static_constructor()
fn static_constructor()
The static constructor of a type: work done once per thread, after
the properties of the type are registered and before its first
instance exists (class handlers,
affects_render, metadata
overrides). Read more