diff options
| author | vaxerski <vaxry@vaxry.net> | 2023-01-31 12:29:23 +0000 |
|---|---|---|
| committer | vaxerski <vaxry@vaxry.net> | 2023-01-31 12:29:23 +0000 |
| commit | 85c07c2fe0427ab5603addcef0e6b7cc211e1af7 (patch) | |
| tree | bdeb599295a7af78f64018d1fef205eed1148943 /src/render/OpenGL.cpp | |
| parent | eaf0fb14c933e49342afb0ae421e992dd84df8b9 (diff) | |
scale the opaque region in blurring
Diffstat (limited to 'src/render/OpenGL.cpp')
| -rw-r--r-- | src/render/OpenGL.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/render/OpenGL.cpp b/src/render/OpenGL.cpp index a02b8dba..e427e4c2 100644 --- a/src/render/OpenGL.cpp +++ b/src/render/OpenGL.cpp @@ -857,6 +857,8 @@ void CHyprOpenGLImpl::renderTextureWithBlur(const CTexture& tex, wlr_box* pBox, pixman_region32_init_rect(&inverseOpaque, 0, 0, pBox->width, pBox->height); } + wlr_region_scale(&inverseOpaque, &inverseOpaque, m_RenderData.pMonitor->scale); + // vvv TODO: layered blur fbs? const bool USENEWOPTIMIZE = (*PBLURNEWOPTIMIZE && !blockBlurOptimization && ((m_pCurrentWindow && !m_pCurrentWindow->m_bIsFloating) || *PBLURXRAY) && @@ -864,12 +866,6 @@ void CHyprOpenGLImpl::renderTextureWithBlur(const CTexture& tex, wlr_box* pBox, CFramebuffer* POUTFB = nullptr; if (!USENEWOPTIMIZE) { - if (pSurface->current.scale != 1) { - // wlroots prohibits shrinking a region - // TODO: just shrink - pixman_region32_union_rect(&inverseOpaque, &inverseOpaque, 0, 0, pBox->width, pBox->height); - } - pixman_region32_translate(&inverseOpaque, pBox->x, pBox->y); pixman_region32_intersect(&inverseOpaque, &inverseOpaque, &damage); |
