|
Clutter Engine 0.0.1
|
Represents a 3D transformation including translation, rotation, and scale. More...
#include <Transform.h>
Public Member Functions | |
| Transform () | |
| Default constructor. Initializes to identity transform. | |
| Transform (Vector3 pLocation, Vector3 pScale, Quaternion pRotation) | |
| Constructs a transform with specified location, scale, and rotation. | |
| Vector3 | Right () const |
| Gets the right direction vector in world space. | |
| Vector3 | Up () const |
| Gets the up direction vector in world space. | |
| Vector3 | Forward () const |
| Gets the forward direction vector in world space. | |
| Vector3 | TransformPosition (const Vector3 &localPosition) const |
| Transforms a local position to world space. | |
| Vector3 | InverseTransformPosition (const Vector3 &worldPosition) const |
| Transforms a world position to local space. | |
| void | SetLocation (Vector3 newLocation) |
| Sets the location of the transform. | |
| void | SetLocation (Vector2 newLocation) |
| Sets the location of the transform using a Vector2. | |
| void | SetRotation (Quaternion newRotation) |
| Sets the rotation of the transform. | |
| void | SetRotation (Vector3 newRotation) |
| Sets the rotation of the transform using Euler angles. | |
| void | AddRotation (Vector3 newRotation) |
| Adds a rotation to the current rotation using Euler angles. | |
| void | SetRotation (float newRotation) |
| Sets the rotation of the transform using a float (implementation dependent). | |
| void | SetScale (Vector3 newScale) |
| Sets the scale of the transform. | |
| void | SetScale (Vector2 newScale) |
| Sets the scale of the transform using a Vector2. | |
| Transform | operator+ (const Transform &q) const |
| Combines this transform with another. | |
| Vector3 | Location () const |
| Gets the location of the transform. | |
| Vector3 | Scale () const |
| Gets the scale of the transform. | |
| Quaternion | Rotation () const |
| Gets the rotation of the transform as a quaternion. | |
| Vector3 | EulerRotation () const |
| Gets the rotation of the transform as Euler angles. | |
| Matrix4Row | GetMat4Transform () |
| Gets the 4x4 transformation matrix. | |
| void | ComputeWorldTransform () |
| Computes the world transformation matrix from location, rotation, and scale. | |
Represents a 3D transformation including translation, rotation, and scale.
Provides methods for manipulating and querying the transform, as well as converting between local and world space.
|
inline |
Constructs a transform with specified location, scale, and rotation.
| pLocation | The position. |
| pScale | The scale. |
| pRotation | The rotation as a quaternion. |
|
inline |
Adds a rotation to the current rotation using Euler angles.
| newRotation | The rotation to add as Euler angles. |
|
inline |
Gets the rotation of the transform as Euler angles.
|
inline |
Gets the forward direction vector in world space.
|
inline |
Gets the 4x4 transformation matrix.
Transforms a world position to local space.
| worldPosition | The world position. |
|
inline |
Gets the location of the transform.
Combines this transform with another.
| q | The other transform. |
|
inline |
Gets the right direction vector in world space.
|
inline |
Gets the rotation of the transform as a quaternion.
|
inline |
Gets the scale of the transform.
|
inline |
Sets the location of the transform using a Vector2.
| newLocation | The new location. |
|
inline |
Sets the location of the transform.
| newLocation | The new location. |
|
inline |
Sets the rotation of the transform using a float (implementation dependent).
| newRotation | The new rotation. |
|
inline |
Sets the rotation of the transform.
| newRotation | The new rotation as a quaternion. |
|
inline |
Sets the rotation of the transform using Euler angles.
| newRotation | The new rotation as Euler angles. |
|
inline |
Sets the scale of the transform using a Vector2.
| newScale | The new scale. |
|
inline |
Sets the scale of the transform.
| newScale | The new scale. |
Transforms a local position to world space.
| localPosition | The local position. |
|
inline |
Gets the up direction vector in world space.