X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?p=laserbrain_demo;a=blobdiff_plain;f=src%2Fmetascene.h;h=6987f007e5ba5b10ba9b771185a40dc5b55c3607;hp=00960cae54f5d9a3d877726327dbc162db8d6ddb;hb=844f36f03073c5db86a8acd2cf7cd1a89e1a16b9;hpb=b30241a8a51be904b22459a1d0cc3322e0a505d9 diff --git a/src/metascene.h b/src/metascene.h index 00960ca..6987f00 100644 --- a/src/metascene.h +++ b/src/metascene.h @@ -1,15 +1,27 @@ #ifndef METASCENE_H_ #define METASCENE_H_ +#include #include #include "scene.h" #include "mesh.h" +#include "geom.h" +#include "audio/ovstream.h" #include "datamap.h" + +struct FlatMirror { + Plane plane; + float reflect; + std::vector objects; + SceneNode *node; + + FlatMirror *next; +}; + + class MetaScene { public: - SceneSet *sceneman; - TextureSet *texman; DataMap datamap; std::vector scenes; @@ -20,8 +32,12 @@ public: std::map scndata; + FlatMirror *mirrors; + std::map objmirror; - MetaScene(SceneSet *sman, TextureSet *tman); + AudioStream *music; + + MetaScene(); ~MetaScene(); bool load(const char *fname); @@ -29,6 +45,17 @@ public: void update(float dt); void draw() const; + + /* helper functions which end up calling the corresponding Scene functions + * for every scene + */ + SceneNode *find_node(const char *name) const; + SceneNode *match_node(const char *qstr) const; + std::list match_nodes(const char *qstr) const; + + Scene *extract_nodes(const char *qstr); + + int calc_mirror_planes(); }; #endif // METASCENE_H_