]> git.tdb.fi Git - r2c2.git/blobdiff - source/designer/cameracontroller.h
Replace various map lookups with functions from maputils.h
[r2c2.git] / source / designer / cameracontroller.h
index b39b3d5a59a6d0f173e69905888d17c849514510..6d5270c1056039271c5f63d5fa9a3577b1ebd505 100644 (file)
@@ -1,17 +1,9 @@
-/* $Id$
-
-This file is part of the MSP Märklin suite
-Copyright © 2010 Mikkosoft Productions, Mikko Rasa
-Distributed under the GPL
-*/
-
 #ifndef CAMERACONTROLLER_H_
 #define CAMERACONTROLLER_H_
 
-#include <msp/gbase/window.h>
+#include <msp/graphics/window.h>
 #include <msp/gl/camera.h>
-
-class Designer;
+#include "3d/view.h"
 
 /**
 Moves the camera based on keyboard and mouse events.  Controls are as follows:
@@ -38,7 +30,7 @@ private:
                DISTANCE
        };
 
-       Designer &designer;
+       R2C2::View3D &view;
        Msp::Graphics::EventSource &event_source;
        Msp::GL::Camera &camera;
        int move_x;
@@ -48,7 +40,7 @@ private:
        DragMode drag_mode;
 
 public:
-       CameraController(Designer &, Msp::Graphics::EventSource &, Msp::GL::Camera &);
+       CameraController(R2C2::View3D &, Msp::Graphics::EventSource &);
 
        void top_down();
        void set_look_direction(const Msp::GL::Vector3 &);
@@ -67,6 +59,7 @@ private:
        void key_press(unsigned, unsigned, wchar_t);
        void key_release(unsigned, unsigned);
 
+public:
        /** Return the focus point, i.e. where the look ray intersects with ground. */
        Msp::GL::Vector3 get_focus() const;