diff options
| author | Vaxry <vaxry@vaxry.net> | 2023-11-25 19:40:15 +0000 |
|---|---|---|
| committer | Vaxry <vaxry@vaxry.net> | 2023-11-25 19:44:34 +0000 |
| commit | ad3f6886484e9adbab532de125e69a70c54fa13e (patch) | |
| tree | fa312f0e365cda57983d8bd8a8017df53f94b3b2 /src/render/OpenGL.cpp | |
| parent | 98c7ba4782476c10e5854a7e520c47bb10353607 (diff) | |
opengl: check for introspection on special_blur
Diffstat (limited to 'src/render/OpenGL.cpp')
| -rw-r--r-- | src/render/OpenGL.cpp | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/src/render/OpenGL.cpp b/src/render/OpenGL.cpp index f2028aaf..f2cec5df 100644 --- a/src/render/OpenGL.cpp +++ b/src/render/OpenGL.cpp @@ -118,9 +118,10 @@ GLuint CHyprOpenGLImpl::compileShader(const GLuint& type, std::string src, bool bool CHyprOpenGLImpl::passRequiresIntrospection(CMonitor* pMonitor) { // passes requiring introspection are the ones that need to render blur. - static auto* const PBLUR = &g_pConfigManager->getConfigValuePtr("decoration:blur:enabled")->intValue; - static auto* const PXRAY = &g_pConfigManager->getConfigValuePtr("decoration:blur:xray")->intValue; - static auto* const POPTIM = &g_pConfigManager->getConfigValuePtr("decoration:blur:new_optimizations")->intValue; + static auto* const PBLUR = &g_pConfigManager->getConfigValuePtr("decoration:blur:enabled")->intValue; + static auto* const PXRAY = &g_pConfigManager->getConfigValuePtr("decoration:blur:xray")->intValue; + static auto* const POPTIM = &g_pConfigManager->getConfigValuePtr("decoration:blur:new_optimizations")->intValue; + static auto* const PBLURSPECIAL = &g_pConfigManager->getConfigValuePtr("decoration:blur:special")->intValue; if (*PBLUR == 0) return false; @@ -143,6 +144,18 @@ bool CHyprOpenGLImpl::passRequiresIntrospection(CMonitor* pMonitor) { return true; } + if (*PBLURSPECIAL) { + for (auto& ws : g_pCompositor->m_vWorkspaces) { + if (!ws->m_bIsSpecialWorkspace || ws->m_iMonitorID != pMonitor->ID) + continue; + + if (ws->m_fAlpha.fl() == 0) + continue; + + return true; + } + } + if (*PXRAY) return false; |
