diff options
Diffstat (limited to 'src/opengl/renderer.hpp')
| -rw-r--r-- | src/opengl/renderer.hpp | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/opengl/renderer.hpp b/src/opengl/renderer.hpp index 5cb7b3d..35650ec 100644 --- a/src/opengl/renderer.hpp +++ b/src/opengl/renderer.hpp @@ -1,5 +1,4 @@ #pragma once -#include <GL/glew.h> #include "shaders.hpp" #include <glm/glm.hpp> #include <chrono> @@ -7,6 +6,8 @@ using namespace std::chrono; +struct GLFW_CONTEXT; + /** * Bind this fonction with the following for debugging: * glEnable ( GL_DEBUG_OUTPUT ); @@ -45,13 +46,13 @@ private: steady_clock::time_point ClockCurrent; /// @brief Current loaded shader name std::string CurrentShader; - /** * Compile send CurrentShader to the graphics card */ void LoadShader(); - + GLFW_CONTEXT *Context; public: + Renderer(short width,short height,std::string shader_name); ~Renderer(); /** @@ -73,4 +74,9 @@ public: * Refresh CurrentShader code (recompile it etc..) */ void RefreshShader(); + void RefreshHUD(); + void SetGLFWContext(GLFW_CONTEXT *context){ + Context=context; + RefreshHUD(); + } }; |
