]> git.tdb.fi Git - r2c2.git/blob - source/designer/cameracontroller.h
Halt all trains in various unexpected situations
[r2c2.git] / source / designer / cameracontroller.h
1 /* $Id$
2
3 This file is part of the MSP Märklin suite
4 Copyright © 2010 Mikkosoft Productions, Mikko Rasa
5 Distributed under the GPL
6 */
7
8 #ifndef CAMERACONTROLLER_H_
9 #define CAMERACONTROLLER_H_
10
11 #include <msp/gbase/window.h>
12 #include <msp/gl/camera.h>
13
14 class CameraController
15 {
16 private:
17         Msp::Graphics::Window &window;
18         Msp::GL::Camera &camera;
19         int move_x;
20         int move_y;
21         int zoom;
22         int rotate;
23         int pitch;
24
25 public:
26         CameraController(Msp::Graphics::Window &, Msp::GL::Camera &);
27
28         void tick(float);
29 private:
30         void key_press(unsigned, unsigned, wchar_t);
31         void key_release(unsigned, unsigned);
32 };
33
34 #endif