X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fgraphics%2FViewport.hpp;h=0bd6e89018d1ff6ed2d46b719a9131d086edda51;hb=50f35affb16c78bd3d0b420f5ba37d74fcac391f;hp=d64e580e56676bcc9024ce302c01bc07f8528885;hpb=1bc6f085c53cdeaa08e2c00e821d4e2e25cae1c8;p=blank.git diff --git a/src/graphics/Viewport.hpp b/src/graphics/Viewport.hpp index d64e580..0bd6e89 100644 --- a/src/graphics/Viewport.hpp +++ b/src/graphics/Viewport.hpp @@ -1,6 +1,7 @@ #ifndef BLANK_GRAPHICS_VIEWPORT_HPP_ #define BLANK_GRAPHICS_VIEWPORT_HPP_ +#include "align.hpp" #include "BlendedSprite.hpp" #include "BlockLighting.hpp" #include "Camera.hpp" @@ -8,7 +9,6 @@ #include "DirectionalLighting.hpp" #include -#include namespace blank { @@ -41,6 +41,11 @@ public: void Clear() noexcept; void ClearDepth() noexcept; + void SetCursor(const glm::vec3 &); + void SetCursor(const glm::vec3 &, Gravity = Gravity::NORTH_WEST); + void MoveCursor(const glm::vec3 &); + const glm::mat4 &Cursor() const noexcept { return cursor; } + BlockLighting &ChunkProgram() noexcept; DirectionalLighting &EntityProgram() noexcept; DirectionalLighting &HUDProgram() noexcept; @@ -50,14 +55,12 @@ public: const glm::mat4 &Perspective() const noexcept { return cam.Projection(); } const glm::mat4 &Ortho() const noexcept { return canv.Projection(); } - const glm::mat4 &CenterTransform() const noexcept { return center; } private: - SDL_GLContext ctx; Camera cam; Canvas canv; - glm::mat4 center; + glm::mat4 cursor; BlockLighting chunk_prog; DirectionalLighting entity_prog;