X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?p=laserbrain_demo;a=blobdiff_plain;f=src%2Fsnode.h;h=5af02f41fc0d99ed03f42902d40e3a169f48f44a;hp=11651c6636c320e0e367854ea3c5bb460d232625;hb=dbcb9345c23c5c027d808915962843e7db2d14aa;hpb=72b941af07bbf2673539ad4eea073e68d3bcbbfc diff --git a/src/snode.h b/src/snode.h index 11651c6..5af02f4 100644 --- a/src/snode.h +++ b/src/snode.h @@ -5,6 +5,8 @@ #include "object.h" #include "gmath/gmath.h" +class Scene; + class SceneNode { private: char *name; @@ -22,6 +24,7 @@ private: Mat4 inv_xform; public: + Scene *scene; // scene to which this node belongs Mat4 dbg_xform; SceneNode(); @@ -63,6 +66,8 @@ public: void update_node(float dt = 0.0f); void update(float dt = 0.0f); + void apply_xform(); + bool intersect(const Ray &ray, HitPoint *hit) const; };