Input: read PlayStation and generic HID pads XInput does not list #50
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/lobomfz--VIctory-xmem!50
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-50"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@delacor on GitHub · 2026-11-30 23:10 UTC · original
delacor:hid-gamepad-pads→main· +1044 −4 · 3 files · 1 commits · merged 2026-12-01 20:55 UTCOnly XInput pads reached the title: a DualSense, a DualShock 4 or any other
pad without an XInput driver did nothing unless something like Steam Input
turned it into an XInput pad. Pads XInput does not list are now read over the
HID API and fill the XInput slots it leaves empty:
report layouts, with rumble through their output reports;
Rx/Ry right stick, the hat as the D-pad, buttons in the usual DirectInput
order, VICTORY_PAD_BUTTONS for other orders.
XInput's own HID devices are skipped. An XInput pad keeps its slot; a HID pad
in a slot XInput takes moves to a free one. Host::pad reads XInput first and
falls back to a HID pad in the same slot; Host::rumble reaches the HID pad's
output reports. The focus gating (VICTORY_PAD_FOCUS) and the scripted key
overlay now cover HID pads too. victory-hle gains the
Win32_Devices_DeviceAndDriverInstallation and
Win32_Devices_HumanInterfaceDevice windows-sys features.
Ported from delacor/VIctory commit a9553ae72 (author marquezini) and its hid
module, which is carried over unchanged; the gameinput.rs integration is
adapted to this tree's host pad path. The source fork checked it with a
DualSense on USB: every button, the triggers and both sticks over their whole
range, and the rumble.
Verified on this branch: cargo check --tests (msvc target) is clean; clippy
has no warnings in the touched files; the hid module's unit tests pass under
Wine (10 passed, 1 ignored - the one needs a real pad).
Note: the xtask policy test
repository_passes_policyalready fails on main(crates/victory-shader/src/emit/lower.rs is 910329 bytes against the
655360-byte limit); this branch adds no new violation.