23 lines
1.1 KiB
Diff
23 lines
1.1 KiB
Diff
|
|
--- a/src/backend/drm/impl/Legacy.cpp
|
||
|
|
+++ b/src/backend/drm/impl/Legacy.cpp
|
||
|
|
@@ -18,6 +18,10 @@
|
||
|
|
if (!connector->output->cursorVisible || !connector->output->state->state().enabled || !connector->crtc || !connector->crtc->cursor)
|
||
|
|
return true;
|
||
|
|
|
||
|
|
+ // move the cursor plane immediately via the legacy ioctl instead of
|
||
|
|
+ // waiting for the next vblank-bound commit
|
||
|
|
+ drmModeMoveCursor(connector->backend->gpu->fd, connector->crtc->id, (int)connector->output->cursorPos.x, (int)connector->output->cursorPos.y);
|
||
|
|
+
|
||
|
|
if (!skipSchedule)
|
||
|
|
connector->output->scheduleFrame(IOutput::AQ_SCHEDULE_CURSOR_MOVE);
|
||
|
|
|
||
|
|
@@ -123,7 +127,7 @@
|
||
|
|
connector->backend->backend->log(AQ_LOG_ERROR, std::format("legacy drm: cursor drmIoctl failed: {}", strerror(errno)));
|
||
|
|
return false;
|
||
|
|
}
|
||
|
|
- } else if (drmModeSetCursor(connector->backend->gpu->fd, connector->crtc->id, 0, 0, 0))
|
||
|
|
+ } else if (!connector->output->cursorVisible && drmModeSetCursor(connector->backend->gpu->fd, connector->crtc->id, 0, 0, 0))
|
||
|
|
connector->backend->backend->log(AQ_LOG_ERROR, "legacy drm: cursor null failed");
|
||
|
|
|
||
|
|
if (!enable)
|