Nu/Nu.Math/Matrix3x3.cs
/// <summary>
/// Builds a rotation matrix for a rotation around the z-axis.
/// </summary>
/// <param name="angle">The counter-clockwise angle in radians.</param>
/// <param name="result">The resulting Matrix3 instance.</param>
Builds a rotation matrix for a rotation around the z-axis.
Builds a rotation matrix for a rotation around the z - axis .
public static void CreateRotationZ(float angle, out Matrix3x3 result)
        {
            float cos = (float)System.Math.Cos(angle);
            float sin = (float)System.Math.Sin(angle);
            result = Identity;
            result.Row0.X = cos;
            result.Row0.Y = sin;
            result.Row1.X = -sin;
            result.Row1.Y = cos;
        }
public static void CreateRotationZ ( float angle , out Matrix3x3 result ) { float cos = ( float ) System . Math . Cos ( angle ) ; float sin = ( float ) System . Math . Sin ( angle ) ; result = Identity ; result . Row0 . X = cos ; result . Row0 . Y = sin ; result . Row1 . X = - sin ; result . Row1 . Y = cos ; }
Builds a rotation matrix for a rotation around the z-axis.
Builds a rotation matrix for a rotation around the z - axis .
angle
float
The counter-clockwise angle in radians.
The counter - clockwise angle in radians .
Matrix3x3
out
result
The resulting Matrix3 instance.
The resulting Matrix3 instance .