Repository navigation
fix(cursor): keep the zoomed view on a game-drawn cursor (#443) - #444
Merged
Merged
Conversation
Games that hide the pointer and draw their own cursor (Cyberpunk 2077 menus) show it about a display frame late, while DWM centring shows the newest pointer, so the cursor wobbled in the zoomed view. While a covering app hides the pointer, Wind writes the view itself and follows the pointer gameCursorLagMs late (default one display frame). Measured at 6.5x: rms 53 -> 15-23 px at 1000 px/s, 29 -> 6 px at 400 px/s. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_011zPmivSAQeivGUdBjTsaMu
Maxaubert
added a commit
that referenced
this pull request
Oct 11, 2026
…443) (#447) Review of #444/#446: - The game-drawn cursor mode switched on for any covering window that hides the pointer (a video player's idle hide, hiding while typing), handing the view to Wind and moving it by DWM's pixel. It now switches on only while the hidden pointer moves (GameCursorStep). - Warm pulses follow who writes the view (!dc.freeCursor), so they run with a game-drawn cursor and in the hold after Inspect. - The pointer history is cleared at session start. - The pan_glide.h include comment had moved onto game_cursor.h. Claude-Session: https://claude.ai/code/session_011zPmivSAQeivGUdBjTsaMu Co-authored-by: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #443.
What. Games that hide the Windows pointer and draw their own cursor (Cyberpunk 2077 menus) showed that cursor wobbling in the zoomed view. While a foreground app that covers the monitor hides the pointer, Wind now turns DWM centring off and follows the pointer one display frame late (
gameCursorLagMs, -1 = one frame, 0 = off, ini only). The pointer itself is never moved. Locked mouselook and normal windows are unchanged.Why. Measured on this PC: the game draws its cursor 1-2 display frames behind the pointer. DWM centring shows the newest pointer, so at 6.5x the game cursor swung 40-70 px behind each movement and flipped side on each change of direction. Wind's own write without a delay measured the same as DWM centring, so the delay is what helps.
Measured (Cyberpunk main menu, 6.5x, 144 fps capture, pointer sweeps; rms offset of the game cursor from its rest point on screen):
gameCursorLagMs=0)What remains (sd 8-10 px at 1000 px/s) is the game's own frame timing.
Tests.
build.bat test: 617 passed, 0 failed (newtests/test_game_cursor.cpp, config clamp test).build.bat checkclean apart from the existing fopen warnings. No UI change. Signed UIAccess build deployed and measured on this PC.Version 0.29.0 -> 0.29.1 (fix). Unsigned in CI as usual.
🤖 Generated with Claude Code
https://claude.ai/code/session_011zPmivSAQeivGUdBjTsaMu