The Roll
method of the Rotation
struct returns the roll component of the rotation. The roll is the rotation around the forward axis, which is typically the Z-axis in a right-handed coordinate system.
The Roll
method of the Rotation
struct returns the roll component of the rotation. The roll is the rotation around the forward axis, which is typically the Z-axis in a right-handed coordinate system.
To retrieve the roll component of a Rotation
instance, simply call the Roll
method on the instance. This method does not take any parameters and returns a float
representing the roll in degrees.
// Example of using the Roll method Rotation rotation = Rotation.From(30.0f, 45.0f, 60.0f); float roll = rotation.Roll(); // roll now contains the value 60.0f, which is the roll component of the rotation