commit fee757a5adb2ee6561899cb40b3424a6d23c80f3
parent e97acfd1850cef926cccb0a5f582ce5431699f2f
Author: Yoann <yoann.b87@voila.fr>
Date: Wed, 30 Nov 2011 08:46:56 +0100
Ajout de la déclaration de la class caméra dans le fichier view.cpp.
Définition et intégration de la classe prochainement.
Diffstat:
1 file changed, 18 insertions(+), 0 deletions(-)
diff --git a/view.hh b/view.hh
@@ -9,6 +9,8 @@
// Calcul correct des normales dans triangle.cpp
// Prendre en compte tous les évènements X en attente avant de relancer le rendu.
+class Camera;
+
class View {
private:
Chose* root;
@@ -37,4 +39,20 @@ class View {
void setLight();
};
+class Camera {
+ private:
+ Vertex cameraCenter;
+ Vertex cameraSight;
+ float xAngle;
+ float yAngle;
+ int moveDist;
+ float mouseSensitivity;
+
+ public:
+ Camera(Vertex pos, float xA, float yA, int moveSensitivity, float mouseSensitivity);
+ void setCamera() const;
+ void mouseMotion(const SDL_MouseMotionEvent &event);
+ void keyboard(const SDL_KeyboardEvent &event);
+ void animation() const;
+};
#endif