screencopy: support hw cursors while sharing with cursor

This commit is contained in:
Vaxry
2025-04-28 20:18:02 +01:00
parent f5c5cfa960
commit c505eb55ff
4 changed files with 10 additions and 31 deletions

View File

@@ -591,13 +591,13 @@ SP<Aquamarine::IBuffer> CPointerManager::renderHWCursorBuffer(SP<CPointerManager
return buf;
}
void CPointerManager::renderSoftwareCursorsFor(PHLMONITOR pMonitor, const Time::steady_tp& now, CRegion& damage, std::optional<Vector2D> overridePos) {
void CPointerManager::renderSoftwareCursorsFor(PHLMONITOR pMonitor, const Time::steady_tp& now, CRegion& damage, std::optional<Vector2D> overridePos, bool forceRender) {
if (!hasCursor())
return;
auto state = stateFor(pMonitor);
if ((!state->hardwareFailed && state->softwareLocks == 0)) {
if (!state->hardwareFailed && state->softwareLocks == 0 && !forceRender) {
if (currentCursorImage.surface)
currentCursorImage.surface->resource()->frame(now);
return;