From 7b020ffa84e64d0734709b2489e1da5463689e61 Mon Sep 17 00:00:00 2001 From: vaxerski Date: Thu, 1 Dec 2022 13:36:07 +0000 Subject: Added screen shaders --- src/render/OpenGL.hpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/render/OpenGL.hpp') diff --git a/src/render/OpenGL.hpp b/src/render/OpenGL.hpp index e54b76aa..fabd3666 100644 --- a/src/render/OpenGL.hpp +++ b/src/render/OpenGL.hpp @@ -111,11 +111,15 @@ public: void onWindowResizeStart(CWindow*); void onWindowResizeEnd(CWindow*); + void applyScreenShader(const std::string& path); + SCurrentRenderData m_RenderData; GLint m_iCurrentOutputFb = 0; GLint m_iWLROutputFb = 0; + bool m_bReloadScreenShader = true; // at launch it can be set + CWindow* m_pCurrentWindow = nullptr; // hack to get the current rendered window pixman_region32_t m_rOriginalDamageRegion; // used for storing the pre-expanded region @@ -134,9 +138,12 @@ private: bool m_bFakeFrame = false; bool m_bEndFrame = false; + bool m_bApplyFinalShader = false; + + CShader m_sFinalScreenShader; - GLuint createProgram(const std::string&, const std::string&); - GLuint compileShader(const GLuint&, std::string); + GLuint createProgram(const std::string&, const std::string&, bool dynamic = false); + GLuint compileShader(const GLuint&, std::string, bool dynamic = false); void createBGTextureForMonitor(CMonitor*); void initShaders(); -- cgit v1.2.3