SaturnRingLibrary 0.9.1
SGL wrapper
 
Loading...
Searching...
No Matches

◆ Scale()

Matrix33 & SRL::Math::Types::Matrix33::Scale ( const Vector3D & scale)
inlineconstexpr

Scale the matrix in-place along each axis.

Modifies the current matrix by applying non-uniform scaling along each axis. This is equivalent to multiplying each row by the corresponding scale factor.

The scaling is applied as follows: | sx*m00 sx*m01 sx*m02 | | sy*m10 sy*m11 sy*m12 | | sz*m20 sz*m21 sz*m22 |

Parameters
scaleVector containing scale factors for each axis.
Returns
Reference to this matrix after scaling.
Note
This operation affects both the orientation and scale of the transformation. For pure scaling, use CreateScale instead.
transform.Scale(Vector3D(2, 1, 0.5)); // Scale x by 2, y by 1, z by 0.5
static consteval Matrix33 Identity()
Create an identity matrix.
Definition mat33.hpp:719
constexpr Matrix33 & Scale(const Vector3D &scale)
Scale the matrix in-place along each axis.
Definition mat33.hpp:566
constexpr Matrix33()
Default constructor initializing to a zero matrix.
Definition mat33.hpp:76
A high-performance three-dimensional vector implementation optimized for Saturn hardware.
Definition vector3d.hpp:51