5 #include <sigc++/trackable.h>
6 #include <msp/graphics/glcontext.h>
7 #include <msp/graphics/window.h>
17 Manages the presentation of rendering results on the screen.
19 class View: public sigc::trackable
22 Graphics::Window &window;
23 Graphics::GLContext &context;
27 std::list<Camera *> synced_cameras;
30 View(Graphics::Window &, Graphics::GLContext &);
32 Graphics::Window &get_window() { return window; }
33 Graphics::GLContext &get_context() { return context; }
34 unsigned get_width() const { return window.get_width(); }
35 unsigned get_height() const { return window.get_height(); }
36 float get_aspect() const { return static_cast<float>(get_width())/get_height(); }
38 void set_camera(Camera *);
39 void set_content(Renderable *);
42 void synchronize_camera_aspect(Camera &);
47 void window_resized(unsigned, unsigned);