summaryrefslogtreecommitdiff
path: root/src/extend/transform.h
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2019-12-04 00:07:32 +0800
committerchai <chaifix@163.com>2019-12-04 00:07:32 +0800
commit2e82e2ddd0852b8063a3d6645366f53ee844e273 (patch)
tree41ec10760f2d2c9f1f782a918f48e1287da2a4b4 /src/extend/transform.h
+init
Diffstat (limited to 'src/extend/transform.h')
-rw-r--r--src/extend/transform.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/extend/transform.h b/src/extend/transform.h
new file mode 100644
index 0000000..b366305
--- /dev/null
+++ b/src/extend/transform.h
@@ -0,0 +1,14 @@
+#include "../math/math.h"
+
+/*
+** TransformҪעÒâ°´ scale -> rotation -> position ˳Ðò¼ÆËã
+*/
+typedef struct Transform {
+ Vec3 position;
+ Vec3 scale;
+ Quat rotation;
+} Transform;
+
+void transformtranslate(Transform* trans, Vec4* v, Vec4* out);
+
+Vec4 transform_translate(Transform* trans, Vec4* v);