X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fgraphics%2FCamera.hpp;h=924b5b4bd320396ab28dbdb2dd3c710c28cdf91c;hb=be3a81656b8493010d2329fa00da617e24293438;hp=2fabfc6a66a9e77dd1d8c9458d277ef8f811aeb0;hpb=b7d09e1e35ef90282c97509e0020b20db3c7ea9f;p=blank.git diff --git a/src/graphics/Camera.hpp b/src/graphics/Camera.hpp index 2fabfc6..924b5b4 100644 --- a/src/graphics/Camera.hpp +++ b/src/graphics/Camera.hpp @@ -11,16 +11,15 @@ class Camera { public: Camera() noexcept; - void Viewport(int width, int height) noexcept; - void Viewport(int x, int y, int width, int height) noexcept; - /// FOV in radians void FOV(float f) noexcept; void Aspect(float r) noexcept; void Aspect(float w, float h) noexcept; void Clip(float near, float far) noexcept; - const glm::mat4 &Projection() noexcept { return projection; } + const glm::mat4 &Projection() const noexcept { return projection; } + const glm::mat4 &View() const noexcept { return view; } + void View(const glm::mat4 &v) noexcept { view = v; } private: void UpdateProjection() noexcept; @@ -28,10 +27,11 @@ private: private: float fov; float aspect; - float near_clip; - float far_clip; + float near; + float far; glm::mat4 projection; + glm::mat4 view; };