32 lines
696 B
Markdown
32 lines
696 B
Markdown
|
|
# GetLocalEulerAngles
|
||
|
|
|
||
|
|
Get the local rotation as Euler angles in degrees.
|
||
|
|
|
||
|
|
## Syntax
|
||
|
|
|
||
|
|
```cpp
|
||
|
|
Math::Vector3 GetLocalEulerAngles() const;
|
||
|
|
```
|
||
|
|
|
||
|
|
## Returns
|
||
|
|
|
||
|
|
Returns the local rotation as Euler angles `(x, y, z)` in degrees.
|
||
|
|
|
||
|
|
## Remarks
|
||
|
|
|
||
|
|
Converts the local quaternion rotation to Euler angles representation. The angles represent rotation around the X, Y, and Z axes respectively.
|
||
|
|
|
||
|
|
## See Also
|
||
|
|
|
||
|
|
- [SetLocalEulerAngles](set-local-euler-angles)
|
||
|
|
- [GetLocalRotation](get-local-rotation)
|
||
|
|
|
||
|
|
## Examples
|
||
|
|
|
||
|
|
```cpp
|
||
|
|
void Example(TransformComponent* transform) {
|
||
|
|
Math::Vector3 eulers = transform->GetLocalEulerAngles();
|
||
|
|
XC_LOG_INFO("Local euler angles: ({}, {}, {})", eulers.x, eulers.y, eulers.z);
|
||
|
|
}
|
||
|
|
```
|