Camera.h 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #ifndef CAMERA3D_H
  2. #define CAMERA3D_H
  3. #include "client/math/Vector.h"
  4. class Camera final {
  5. public:
  6. Camera();
  7. const Vector& getFront() const;
  8. const Vector& getBack() const;
  9. const Vector& getRight() const;
  10. const Vector& getLeft() const;
  11. const Vector& getUp() const;
  12. const Vector& getDown() const;
  13. const Vector& getFlatFront() const;
  14. const Vector& getFlatBack() const;
  15. const Vector& getFlatRight() const;
  16. const Vector& getFlatLeft() const;
  17. const Vector& getFlatUp() const;
  18. const Vector& getFlatDown() const;
  19. const Vector& getPosition() const;
  20. void storePosition();
  21. void setPosition(const Vector& pos, float length, float width);
  22. void update(float lag);
  23. private:
  24. Vector oldPosition;
  25. Vector position;
  26. float oldLengthAngle;
  27. float lengthAngle;
  28. float oldWidthAngle;
  29. float widthAngle;
  30. Vector interPosition;
  31. Vector front;
  32. Vector back;
  33. Vector right;
  34. Vector left;
  35. Vector up;
  36. Vector down;
  37. Vector flatFront;
  38. Vector flatBack;
  39. Vector flatRight;
  40. Vector flatLeft;
  41. Vector flatUp;
  42. Vector flatDown;
  43. };
  44. #endif