[pr-feature][input] DualSense: the PS5 build's adaptive triggers read as its handler reads them, its light bar, and its haptics (DARNER_DS_HAPTICS) #185
Loading…
Reference in a new issue
No description provided.
Delete branch "ItsYusei99/Darner:ds-ps5-effects"
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?
Contributor role (optional)
What it changes
With
DARNER_DS_TRIGGERS=1, R2 was stiff all the time and the title's real trigger effects never reached the pad. Three causes, all ingameinput/playstation.rs:ps5_trigger.rsdecodes and encodes them as xmem PR 273 does.capturecleared both triggers on every call without one. An effect now stays until the title sends another one or releases it.It also adds:
[0, 0, 64]. Used whenDARNER_DS_LIGHTBARis unset, withDARNER_DS_TRIGGERS=1.DARNER_DS_HAPTICS=1, off by default).haptics.rsis xmem PR 273's port: it hooks the mixer's per-group output step and plays thePadHapticsgroup on channels 3 and 4 of the DualSense's USB audio endpoint through WASAPI. Env names areDARNER_*;DARNER_HAPTICS_GAIN_DB(default 8) andDARNER_HAPTICS_LOG. It needsWin32_UI_Shell_PropertiesSystemindarner-hle'swindowsfeatures.adaptive triggers: first effect of this kind for this target), which is how the mapping above was checked in game.DARNER_DS_LIGHTBARnow says what it does when unset.Credit: the offsets, the effect layout and the haptics player are from VIctory-xmem PR 273 by k-qno1.
How it was tested
maindc332e0;cargo testandclippyran there. The game test ran onbd0de0cwith the same files.cargo test --locked -p darner-hle: 497 passed, 0 failed, 15 ignored (the gameinput ones need a pad). New tests:trigger_encodings(from xmem PR 273),title_kinds_decode, and xmem PR 273's three haptics tests.cargo clippy -p darner-hle --all-targets --locked -- -D warnings: clean.haptics: playing on the controller's channels 3 and 4in the log.Checklist
main.docs/asset-policy.md.Checked for overlap
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.