Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/camera.h')
-rw-r--r--src/client/camera.h40
1 files changed, 21 insertions, 19 deletions
diff --git a/src/client/camera.h b/src/client/camera.h
index 2e20c1b..7e189b3 100644
--- a/src/client/camera.h
+++ b/src/client/camera.h
@@ -18,47 +18,49 @@ for the camera eye location. The camera always looks at (0,0,0)
class Camera
{
public:
+ Camera();
+ ~Camera();
+
/// enum indicating the camera mode
enum Mode {Free, Track};
/// draw the OpenGL camera transformation
- static void draw(float elapsed);
+ void draw(float elapsed);
/// rotate the camera left
- static void rotate_left();
+ void rotate_left();
/// rotate the camera right
- static void rotate_right();
+ void rotate_right();
/// rotate the camera up
- static void rotate_up();
+ void rotate_up();
/// rotate the camera down
- static void rotate_down();
+ void rotate_down();
/// switch to next camera mode
- static void nextmode();
+ void nextmode();
/// camera target
/** The location the camera is looking at */
- static gl::Vector3f target;
+ gl::Vector3f target;
/// target yaw, angle in XZ plane, positive is looking left
- static float yaw_target;
+ float yaw_target;
/// target pitch, angle in XZ plane, positive is looking left
- static float pitch_target;
+ float pitch_target;
/// distance from the camera to the target
- static float distance;
+ float distance;
+ /// current camera mode
+ Mode mode;
protected:
- /// default tracking pitch
- static const float track_pitch;
- /// default offset increment
- static const float offset_inc;
-
/// current yaw, angle in XZ plane, positive is looking left
- static float yaw;
+ float yaw ;
/// current pitch, angle in XY, positive is looking up
- static float pitch;
-
- static Mode mode;
+ float pitch;
+ /// default tracking pitch
+ float pitch_track;
+ /// default offset increment
+ float offset_inc;
};
} // namespace client