summaryrefslogtreecommitdiff
path: root/demo
diff options
context:
space:
mode:
authorsanine-a <sanine.not@pm.me>2020-12-02 01:42:21 -0600
committersanine-a <sanine.not@pm.me>2020-12-02 01:42:21 -0600
commitf417d2b047369cac234c471ef37ab8281181d69f (patch)
tree3b21174fc4efcd5643b1f4d1e8a202020f85cede /demo
parentbe49795636e5a9ede3742d077701f48e9316e121 (diff)
create basic scene tree node
Diffstat (limited to 'demo')
-rw-r--r--demo/main.lua14
1 files changed, 12 insertions, 2 deletions
diff --git a/demo/main.lua b/demo/main.lua
index 3fabe00..ec0bac1 100644
--- a/demo/main.lua
+++ b/demo/main.lua
@@ -1,9 +1,19 @@
+local root = honey.node(nil,
+ honey.glm.vec3{0,0,0},
+ honey.glm.vec3{0,0,0},
+ honey.glm.vec3{1,1,1})
+
+local child = honey.node(root,
+ honey.glm.vec3{0,0,0},
+ honey.glm.vec3{0,0,0},
+ honey.glm.vec3{1,1,1})
+
local v = honey.glm.vec3{1, 2, 3}
-local M = honey.glm.mat3()
+local M = honey.glm.mat4()
M:set(1,3, 1)
-print(M:mulv(v))
+print(M:mul(M))
print(v)
print(honey.glm.vec3{2, 0.001, 0})