1 #ifndef MSP_GL_SCENE_H_
2 #define MSP_GL_SCENE_H_
5 #include <msp/datafile/objectloader.h>
7 #include "renderable.h"
14 Scenes are containers for other Renderables. This is a base class that can't
15 be instantiated. Examples of available Scene types are SimpleScene,
16 InstancedScene and OrderedScene.
18 class Scene: public Renderable
21 class Loader: public DataFile::CollectionObjectLoader<Scene>
24 Loader(Scene &, Collection &);
27 void object(const std::string &);
31 std::list<Renderable *> owned_data;
32 mutable Matrix culling_matrix;
33 mutable Vector4 frustum_edges[6];
38 Scene &operator=(const Scene &);
42 virtual void add(const Renderable &) = 0;
43 virtual void remove(const Renderable &) = 0;
45 using Renderable::render;
46 virtual void render(const Tag & = Tag()) const;
49 bool setup_frustum(const Renderer &) const;
50 bool frustum_cull(const Renderable &) const;