#include <glm/glm.hpp>
-#include "model.hpp"
-
namespace blank {
-class Camera
-: public Model {
+class Camera {
public:
Camera();
- ~Camera();
-
- Camera(const Camera &) = delete;
- Camera &operator =(const Camera &) = delete;
-
- glm::mat4 MakeMVP(const glm::mat4 &m) const { return vp * m; }
void Viewport(int width, int height);
void Viewport(int x, int y, int width, int height);
+ /// FOV in radians
void FOV(float f);
void Aspect(float r);
void Aspect(float w, float h);
void Clip(float near, float far);
- void Update(int dt);
+ const glm::mat4 &Projection() { return projection; }
private:
void UpdateProjection();
float far_clip;
glm::mat4 projection;
- glm::mat4 vp;
};