]> git.tdb.fi Git - libs/gl.git/blob - source/scene.h
Require mspgbase now that Image was moved there
[libs/gl.git] / source / scene.h
1 /* $Id$
2
3 This file is part of libmspgl
4 Copyright © 2007  Mikko Rasa, Mikkosoft Productions
5 Distributed under the LGPL
6 */
7
8 #ifndef MSP_GL_SCENE_H_
9 #define MSP_GL_SCENE_H_
10
11 #include <map>
12 #include <set>
13 #include "renderable.h"
14
15 namespace Msp {
16 namespace GL {
17
18 class Object;
19 class ObjectInstance;
20
21 class Scene: public Renderable
22 {
23 private:
24         std::map<const Object *, std::set<const ObjectInstance *> > objects;
25         std::set<const Renderable *> renderables;
26
27 public:
28         void add(const Renderable &);
29         void remove(const Renderable &);
30
31         virtual bool has_pass(const Tag &) const { return true; }
32         virtual void render(const Tag &tag=Tag()) const;
33 };
34
35 } // namespace GL
36 } // namespace Msp
37
38 #endif