aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/api/Transform.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/crepe/api/Transform.h')
-rw-r--r--src/crepe/api/Transform.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/crepe/api/Transform.h b/src/crepe/api/Transform.h
new file mode 100644
index 0000000..c17ae34
--- /dev/null
+++ b/src/crepe/api/Transform.h
@@ -0,0 +1,26 @@
+#pragma once
+
+#include <cstdint>
+
+#include "api/Point.h"
+
+#include "Component.h"
+
+namespace crepe::api {
+
+class Transform : public Component {
+ // FIXME: What's the difference between the `Point` and `Position`
+ // classes/structs? How about we replace both with a universal `Vec2` that
+ // works similar (or the same) as those found in GLSL?
+public:
+ Transform(uint32_t id, Point &, double, double);
+ ~Transform();
+ //! Translation (shift)
+ Point position;
+ //! Rotation, in radians
+ double rotation;
+ //! Multiplication factor
+ double scale;
+};
+
+} // namespace crepe::api