hx3d
1
2D/3D Simple Game Framework
|
2D/3D transform. More...
#include <transform.hpp>
Public Member Functions | |
glm::mat4 | compute () |
Build the model matrix using the position, scale, size and rotation. More... | |
Transform | add (const Transform &transform) |
Add a transform to another. More... | |
glm::vec3 | realSize () |
Get the real size (size * scale). More... | |
bool | contains (glm::vec2 point) |
Check a point in the transform. More... | |
void | show () |
Show the transform information. (Debug) | |
Public Attributes | |
glm::vec3 | position |
Position. | |
glm::vec3 | scale |
Scale. | |
glm::vec3 | size |
Size. | |
glm::vec3 | rotation |
Rotation. | |
2D/3D transform.
Definition at line 35 of file transform.hpp.
Add a transform to another.
In use for parent/child transform calculation.
transform | Other transform |
Definition at line 55 of file transform.cpp.
glm::mat4 hx3d::graphics::Transform::compute | ( | ) |
Build the model matrix using the position, scale, size and rotation.
Definition at line 43 of file transform.cpp.
bool hx3d::graphics::Transform::contains | ( | glm::vec2 | point | ) |
Check a point in the transform.
point | 2D point |
Definition at line 80 of file transform.cpp.
glm::vec3 hx3d::graphics::Transform::realSize | ( | ) |