From 2eaa4d80a0ecb56fc16c8ad4077b1b1a7d28281f Mon Sep 17 00:00:00 2001 From: vaxerski Date: Thu, 26 Dec 2024 00:16:42 +0100 Subject: [PATCH] debug: fix overlay not rendering --- src/debug/HyprDebugOverlay.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/debug/HyprDebugOverlay.cpp b/src/debug/HyprDebugOverlay.cpp index 0df46086..d72e2144 100644 --- a/src/debug/HyprDebugOverlay.cpp +++ b/src/debug/HyprDebugOverlay.cpp @@ -2,6 +2,8 @@ #include "HyprDebugOverlay.hpp" #include "config/ConfigValue.hpp" #include "../Compositor.hpp" +#include "../render/pass/TexPassElement.hpp" +#include "../render/Renderer.hpp" CHyprDebugOverlay::CHyprDebugOverlay() { m_pTexture = makeShared(); @@ -268,6 +270,8 @@ void CHyprDebugOverlay::draw() { glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, PMONITOR->vecPixelSize.x, PMONITOR->vecPixelSize.y, 0, GL_RGBA, GL_UNSIGNED_BYTE, DATA); - CBox pMonBox = {0, 0, PMONITOR->vecPixelSize.x, PMONITOR->vecPixelSize.y}; - g_pHyprOpenGL->renderTexture(m_pTexture, &pMonBox, 1.f); + CTexPassElement::SRenderData data; + data.tex = m_pTexture; + data.box = {0, 0, PMONITOR->vecPixelSize.x, PMONITOR->vecPixelSize.y}; + g_pHyprRenderer->m_sRenderPass.add(makeShared(data)); }