X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fui%2FHUD.hpp;h=47e0fd453f635f7b048dab826d798f3a1c76cc77;hb=50f35affb16c78bd3d0b420f5ba37d74fcac391f;hp=ca6b7544a54ee9a15f7639bb2e1f6fba65376724;hpb=b7d09e1e35ef90282c97509e0020b20db3c7ea9f;p=blank.git diff --git a/src/ui/HUD.hpp b/src/ui/HUD.hpp index ca6b754..47e0fd4 100644 --- a/src/ui/HUD.hpp +++ b/src/ui/HUD.hpp @@ -1,6 +1,7 @@ #ifndef BLANK_UI_HUD_H_ #define BLANK_UI_HUD_H_ +#include "../graphics/Text.hpp" #include "../model/Model.hpp" #include "../model/OutlineModel.hpp" @@ -11,37 +12,34 @@ namespace blank { class Block; class BlockTypeRegistry; -class DirectionalLighting; +class Font; +class Viewport; class HUD { public: - explicit HUD(const BlockTypeRegistry &); + HUD(const BlockTypeRegistry &, const Font &); HUD(const HUD &) = delete; HUD &operator =(const HUD &) = delete; - void Viewport(float width, float height) noexcept; - void Viewport(float x, float y, float width, float height) noexcept; - void Display(const Block &); - void Render(DirectionalLighting &) noexcept; + void Render(Viewport &) noexcept; private: const BlockTypeRegistry &types; + const Font &font; Model block; Model::Buffer block_buf; glm::mat4 block_transform; + + Text block_label; + bool block_visible; OutlineModel crosshair; - glm::mat4 crosshair_transform; - - float near, far; - glm::mat4 projection; - glm::mat4 view; };