Repository navigation
GameInput: XCL_PRESS_HOLD holds scripted presses longer - #609
pablogonz12 wants to merge 1 commit into
Conversation
XCL_PRESS_AT / XCL_PRESS_A_AT hold each button for 200 ms. A title that draws a frame every few seconds (a retail title under Wine here: about one frame in 4 s at the start) reads its pad as seldom and misses such a press. XCL_PRESS_HOLD=s holds each press for s seconds instead; the default stays 200 ms.
|
Tested on an RTX 5080, release build: pass, 686 passed, 0 failed.
Not tested
AI use: Claude Code (Claude Opus 5.5, Claude Fable 5.2) |
|
Mac/Wine verification of this head as filed (a second host for the counts, not a review of the design). Tested
What this host can and cannot say about the motivation With #541 applied, this bench's port run presents ~24 fps and reads the pad continuously, and its own Related: I have just filed #893 ( Not tested
AI use
|
|
I tested
The fixture uses synthetic input only. AI use — OpenAI Codex (GPT-6) wrote and ran the test and drafted this report. |
Empirical test report (1178e8a)Hardware / environment
Commands and results
Observed behavior The diff adds one unit test, Not tested The full GPU workspace suite and game smoke runs were omitted. Runtime parsing of AI use Verified with T3 Code / Codex (gpt-6.2-sol, reasoningEffort: high). Coordinator #2 (T3 Code / Antigravity, gemini-4-neon) verified counts against pr609-focused.log and published. |
|
Verification on RTX 3060 Ti (Windows 11), branch merged with current
Thanks! |
XCL_PRESS_AT/XCL_PRESS_A_AThold each scripted button for 200 ms. A title that draws a frame every few seconds reads its pad about as seldom and misses such a press: a retail title under Wine here (about one frame in 4 s while its first screens load) never saw a scripted A; with the press held for 8 s it logsGameInput: gamepad buttons 0x4 pressed for the first time.XCL_PRESS_HOLD=sholds each press forsseconds; without it nothing changes.What is in it
crates/xcl/src/hle/gameinput.rs:XCL_PRESS_HOLD(seconds, > 0; default 0.2), read once; the test of a press moves intoheld(presses, t, hold); the module andparse_pressesdocs name the variable.a_press_is_held_for_its_hold_time.Tested
cargo xwin test --workspace --release --locked --target x86_64-pc-windows-msvc --no-run, then each of the 15 test binaries from its package folder under Wine (GE-Proton11-14, Mesa 26.3.1, DXC 1.9.2609.5, Rust 1.100.0, static CRT) with--test-threads=4; no filters, 0SKIPPEDlines on the head, 0 on the base:1178e8a): 679 passed, 7 failed, 41 ignored;main(cb868b2): 678 passed, 7 failed, 41 ignored.disk_free_space_ex_reports_pls_quota,gpu::recomp::tests::gpu_f64_math_random,gpu::recomp::tests::gpu_f64_roots,gpu::recomp::tests::gpu_nonfused_mad_and_mac_prevent_fma_contraction,hle::xaudio2::tests::xma2_source_voice_decodes_and_manages_lifetime,set_predication_buffer_state_and_kickoff,test_title_runs_and_game_folder_is_untouched.XCL_PRESS_AT=60:A,90:A,…withXCL_PRESS_HOLD=8: the A press is logged at 61 s; with the default 200 ms no press was logged in a 240 s run with presses every 10 s.Regression run
Both blocks are the output of each commit's own unmodified
scripts/smoke.ps1, written to a file by PowerShell and pasted as is. It ran in Windows PowerShell 7.7.0 (pwsh.exe) under Wine (GE-Proton11-14, Linux), not on native Windows, with MinGit 2.56.1 forgit;xcl.exeis an MSVC release build (cargo xwin, static CRT), passed with-Xcl. Host workarounds outside the script: a pseudo-terminal,DOTNET_SYSTEM_GLOBALIZATION_USENLS=1, and importing PowerShell's Utility and Management modules before calling it.mainis this PR's base commit; no scripted input in either run, so this is a regression check, not a run ofXCL_PRESS_HOLD. These replace the earlier blocks from a bash script. Frame counts at this speed are small and vary between runs. Each commit was run once. Note that this title can end in a device removal on this host even onmain(seen in repeat runs of another base commit, see #464).main:This PR's head:
Not tested
XCL_PRESS_HOLDwith the test title's e2e tests (they keep the default).AI use