1 #ifndef R2C2_3D_LAYOUT_H_
2 #define R2C2_3D_LAYOUT_H_
4 #include <sigc++/trackable.h>
5 #include <msp/gl/instancescene.h>
6 #include <msp/gl/light.h>
7 #include <msp/gl/lighting.h>
8 #include <msp/gl/simplescene.h>
9 #include "libr2c2/layout.h"
10 #include "catalogue.h"
16 class Layout3D: public sigc::trackable
19 typedef std::map<Object *, Object3D *> ObjectMap;
23 Catalogue3D catalogue;
25 Msp::GL::InstanceScene scene;
26 Msp::GL::SimpleScene ep_scene;
27 Msp::GL::InstanceScene path_scene;
29 Msp::GL::Lighting lighting;
35 Layout &get_layout() const { return layout; }
36 const Catalogue3D &get_catalogue() const { return catalogue; }
37 void get_bounds(Vector &, Vector &) const;
40 Object3D &get(Object &) const;
41 const ObjectMap &get_all() const { return objects; }
42 void remove(Object3D &);
45 T &get(Object &o) const
46 { return dynamic_cast<T &>(get(o)); }
48 Msp::GL::Scene &get_scene() { return scene; }
49 Msp::GL::Scene &get_endpoint_scene() { return ep_scene; }
50 Msp::GL::Scene &get_path_scene() { return path_scene; }
51 const Msp::GL::Lighting &get_lighting() const { return lighting; }
54 void object_added(Object &);
55 void object_removed(Object &);