ProtoTracer  1.0
Real-time 3D rendering and animation engine
Loading...
Searching...
No Matches
EulerAngles Class Reference

Encapsulates a 3D rotation using Euler angles and a specific order of application. More...

#include <EulerAngles.h>

Collaboration diagram for EulerAngles:

Public Member Functions

 EulerAngles ()
 Default constructor that initializes angles to zero and order to a default value.
 
 EulerAngles (Vector3D angles, EulerOrder order)
 Constructs an EulerAngles object with specified angles and order.
 
String ToString ()
 Converts the EulerAngles object to a string representation.
 

Public Attributes

Vector3D Angles
 The three rotation angles (pitch, yaw, roll) in degrees (or radians based on usage).
 
EulerOrder Order
 The order in which the angles are applied (e.g., XYZ, ZYX, etc.).
 

Detailed Description

Encapsulates a 3D rotation using Euler angles and a specific order of application.

Euler angles are commonly used to represent rotations in 3D space by specifying three angles applied in a specific sequence. The sequence is defined by the EulerOrder.

Definition at line 25 of file EulerAngles.h.

Constructor & Destructor Documentation

◆ EulerAngles() [1/2]

Default constructor that initializes angles to zero and order to a default value.

Definition at line 5 of file EulerAngles.cpp.

◆ EulerAngles() [2/2]

EulerAngles ( Vector3D  angles,
EulerOrder  order 
)

Constructs an EulerAngles object with specified angles and order.

Parameters
anglesThe rotation angles as a Vector3D (e.g., pitch, yaw, roll).
orderThe order in which the angles are applied, represented by EulerOrder.

Definition at line 9 of file EulerAngles.cpp.

Member Function Documentation

◆ ToString()

String ToString ( )

Converts the EulerAngles object to a string representation.

Useful for debugging and visualizing the rotation angles and order.

Returns
A string representing the EulerAngles in the format "(angles: [X, Y, Z], order: XYZ)".

Definition at line 13 of file EulerAngles.cpp.

References Angles, Order, EulerOrder::ToString(), and Vector3D::ToString().

Member Data Documentation

◆ Angles

Vector3D Angles

The three rotation angles (pitch, yaw, roll) in degrees (or radians based on usage).

Definition at line 27 of file EulerAngles.h.

Referenced by ToString(), and Transform::ToString().

◆ Order

EulerOrder Order

The order in which the angles are applied (e.g., XYZ, ZYX, etc.).

Definition at line 28 of file EulerAngles.h.

Referenced by ToString().


The documentation for this class was generated from the following files: