mirror of
https://github.com/hyprwm/Hyprland.git
synced 2025-08-04 06:01:56 -07:00
compositor: ignore setting surface scanout if DS is disabled
This commit is contained in:
@@ -2285,6 +2285,8 @@ void CCompositor::updateFullscreenFadeOnWorkspace(PHLWORKSPACE pWorkspace) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void CCompositor::setWindowFullscreen(PHLWINDOW pWindow, bool on, eFullscreenMode mode) {
|
void CCompositor::setWindowFullscreen(PHLWINDOW pWindow, bool on, eFullscreenMode mode) {
|
||||||
|
static auto PNODIRECTSCANOUT = CConfigValue<Hyprlang::INT>("misc:no_direct_scanout");
|
||||||
|
|
||||||
if (!validMapped(pWindow) || g_pCompositor->m_bUnsafeState)
|
if (!validMapped(pWindow) || g_pCompositor->m_bUnsafeState)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@@ -2333,7 +2335,9 @@ void CCompositor::setWindowFullscreen(PHLWINDOW pWindow, bool on, eFullscreenMod
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
// send a scanout tranche if we are entering fullscreen, and send a regular one if we aren't.
|
// send a scanout tranche if we are entering fullscreen, and send a regular one if we aren't.
|
||||||
g_pHyprRenderer->setSurfaceScanoutMode(pWindow->m_pWLSurface->resource(), on ? PMONITOR->self.lock() : nullptr);
|
// ignore if DS is disabled.
|
||||||
|
if (!*PNODIRECTSCANOUT)
|
||||||
|
g_pHyprRenderer->setSurfaceScanoutMode(pWindow->m_pWLSurface->resource(), on ? PMONITOR->self.lock() : nullptr);
|
||||||
|
|
||||||
g_pConfigManager->ensureVRR(PMONITOR);
|
g_pConfigManager->ensureVRR(PMONITOR);
|
||||||
}
|
}
|
||||||
|
@@ -236,7 +236,7 @@ static void renderSurface(SP<CWLSurfaceResource> surface, int x, int y, void* da
|
|||||||
g_pHyprOpenGL->renderTexture(TEXTURE, &windowBox, ALPHA, rounding, false, true);
|
g_pHyprOpenGL->renderTexture(TEXTURE, &windowBox, ALPHA, rounding, false, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!g_pHyprRenderer->m_bBlockSurfaceFeedback)
|
if (!g_pHyprRenderer->m_bBlockSurfaceFeedback)
|
||||||
surface->presentFeedback(RDATA->when, RDATA->pMonitor);
|
surface->presentFeedback(RDATA->when, RDATA->pMonitor);
|
||||||
|
|
||||||
g_pHyprOpenGL->blend(true);
|
g_pHyprOpenGL->blend(true);
|
||||||
|
Reference in New Issue
Block a user