summaryrefslogtreecommitdiff
path: root/src/render/OpenGL.hpp
diff options
context:
space:
mode:
authorvaxerski <vaxry@vaxry.net>2024-07-26 19:53:24 +0200
committervaxerski <vaxry@vaxry.net>2024-07-26 19:53:24 +0200
commit57371b93a058d17affb0ca92f13b8d40582b3ea0 (patch)
tree18175c67050597ab04b22c22a543e7411686ca27 /src/render/OpenGL.hpp
parent33a5c8ce325e1657ec5571b57e05c6378706f4cd (diff)
renderer: drastically optimize bg texture creation
stop loading 20MB images every time, dumbass
Diffstat (limited to 'src/render/OpenGL.hpp')
-rw-r--r--src/render/OpenGL.hpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/render/OpenGL.hpp b/src/render/OpenGL.hpp
index 5c4ee811..41e80ee5 100644
--- a/src/render/OpenGL.hpp
+++ b/src/render/OpenGL.hpp
@@ -274,6 +274,8 @@ class CHyprOpenGLImpl {
CShader m_sFinalScreenShader;
CTimer m_tGlobalTimer;
+ SP<CTexture> m_pBackgroundTexture;
+
void logShaderError(const GLuint&, bool program = false);
GLuint createProgram(const std::string&, const std::string&, bool dynamic = false);
GLuint compileShader(const GLuint&, std::string, bool dynamic = false);
@@ -282,6 +284,7 @@ class CHyprOpenGLImpl {
void initDRMFormats();
void initEGL(bool gbm);
EGLDeviceEXT eglDeviceFromDRMFD(int drmFD);
+ void createBackgroundTexture(const std::string& path);
//
std::optional<std::vector<uint64_t>> getModsForFormat(EGLint format);