From 1c221240d0c6c352cea203b51a918b906a8d340f Mon Sep 17 00:00:00 2001 From: Vaxry Date: Tue, 30 Jul 2024 15:46:35 +0200 Subject: output: submit damage to kms --- src/helpers/Monitor.cpp | 2 ++ src/render/Renderer.cpp | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/helpers/Monitor.cpp b/src/helpers/Monitor.cpp index 9d282090..787b790f 100644 --- a/src/helpers/Monitor.cpp +++ b/src/helpers/Monitor.cpp @@ -822,6 +822,8 @@ bool CMonitor::attemptDirectScanout() { Debug::log(TRACE, "presentFeedback for DS"); PSURFACE->presentFeedback(&now, this, true); + output->state->addDamage(CBox{{}, vecPixelSize}); + if (state.commit()) { if (lastScanout.expired()) { lastScanout = PCANDIDATE; diff --git a/src/render/Renderer.cpp b/src/render/Renderer.cpp index 0bf4c9f3..df0c6af5 100644 --- a/src/render/Renderer.cpp +++ b/src/render/Renderer.cpp @@ -1371,6 +1371,8 @@ void CHyprRenderer::renderMonitor(CMonitor* pMonitor) { frameDamage.add(damage); g_pHyprRenderer->damageMirrorsWith(pMonitor, frameDamage); + + pMonitor->output->state->addDamage(frameDamage); } pMonitor->renderingActive = false; -- cgit v1.2.3