summaryrefslogtreecommitdiff
path: root/src/render/OpenGL.cpp
diff options
context:
space:
mode:
authorzacoons <73414084+zacoons@users.noreply.github.com>2025-06-22 03:03:28 +1000
committerGitHub <noreply@github.com>2025-06-21 19:03:28 +0200
commit8b1d5560cf1ca2c4c2624914de284d315502a092 (patch)
tree5a056cb66c14b9e8a9004586daf93f02d764ea25 /src/render/OpenGL.cpp
parent238887473866a63c0fd70ead614f37ac86333e28 (diff)
renderer: add wrapping options to renderTextureWithBlur method (#10807)
Diffstat (limited to 'src/render/OpenGL.cpp')
-rw-r--r--src/render/OpenGL.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/render/OpenGL.cpp b/src/render/OpenGL.cpp
index a253e3ff..30680497 100644
--- a/src/render/OpenGL.cpp
+++ b/src/render/OpenGL.cpp
@@ -2133,7 +2133,7 @@ bool CHyprOpenGLImpl::shouldUseNewBlurOptimizations(PHLLS pLayer, PHLWINDOW pWin
}
void CHyprOpenGLImpl::renderTextureWithBlur(SP<CTexture> tex, const CBox& box, float a, SP<CWLSurfaceResource> pSurface, int round, float roundingPower, bool blockBlurOptimization,
- float blurA, float overallA) {
+ float blurA, float overallA, GLenum wrapX, GLenum wrapY) {
RASSERT(m_renderData.pMonitor, "Tried to render texture with blur without begin()!");
TRACY_GPU_ZONE("RenderTextureWithBlur");
@@ -2161,7 +2161,7 @@ void CHyprOpenGLImpl::renderTextureWithBlur(SP<CTexture> tex, const CBox& box, f
inverseOpaque.invert(&surfbox).intersect(0, 0, pSurface->m_current.size.x * pSurface->m_current.scale, pSurface->m_current.size.y * pSurface->m_current.scale);
if (inverseOpaque.empty()) {
- renderTexture(tex, box, a, round, roundingPower, false, true);
+ renderTexture(tex, box, a, round, roundingPower, false, true, wrapX, wrapY);
return;
}
} else
@@ -2197,7 +2197,7 @@ void CHyprOpenGLImpl::renderTextureWithBlur(SP<CTexture> tex, const CBox& box, f
if (USENEWOPTIMIZE && !(m_renderData.discardMode & DISCARD_ALPHA))
renderRect(box, CHyprColor(0, 0, 0, 0), round, roundingPower);
else
- renderTexture(tex, box, a, round, roundingPower, true, true); // discard opaque
+ renderTexture(tex, box, a, round, roundingPower, true, true, wrapX, wrapY); // discard opaque
glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE);
glStencilFunc(GL_EQUAL, 1, 0xFF);
@@ -2223,7 +2223,8 @@ void CHyprOpenGLImpl::renderTextureWithBlur(SP<CTexture> tex, const CBox& box, f
pushMonitorTransformEnabled(true);
if (!USENEWOPTIMIZE)
setRenderModifEnabled(false);
- renderTextureInternalWithDamage(POUTFB->getTexture(), box, (*PBLURIGNOREOPACITY ? blurA : a * blurA) * overallA, texDamage, round, roundingPower, false, false, true);
+ renderTextureInternalWithDamage(POUTFB->getTexture(), box, (*PBLURIGNOREOPACITY ? blurA : a * blurA) * overallA, texDamage, round, roundingPower, false, false, true, wrapX,
+ wrapY);
if (!USENEWOPTIMIZE)
setRenderModifEnabled(true);
popMonitorTransformEnabled();
@@ -2237,7 +2238,7 @@ void CHyprOpenGLImpl::renderTextureWithBlur(SP<CTexture> tex, const CBox& box, f
// draw window
glDisable(GL_STENCIL_TEST);
- renderTextureInternalWithDamage(tex, box, a * overallA, texDamage, round, roundingPower, false, false, true, true);
+ renderTextureInternalWithDamage(tex, box, a * overallA, texDamage, round, roundingPower, false, false, true, true, wrapX, wrapY);
glStencilMask(0xFF);
glStencilFunc(GL_ALWAYS, 1, 0xFF);