-
-
Notifications
You must be signed in to change notification settings - Fork 961
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(input/linux): add support for more virtual input devices #2606
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #2606 +/- ##
=========================================
- Coverage 9.88% 8.70% -1.19%
=========================================
Files 88 94 +6
Lines 18070 17366 -704
Branches 8605 8251 -354
=========================================
- Hits 1787 1512 -275
+ Misses 13374 12994 -380
+ Partials 2909 2860 -49
Flags with carried forward coverage won't be shown. Click here to find out more.
|
23df8b9
to
2898ae8
Compare
@ABeltramo any idea how to solve these errors on Fedora 40? https://github.com/LizardByte/Sunshine/actions/runs/9295282809/job/25581974710?pr=2606#step:10:3266 We're using gcc-14 on that distro, I'm guessing that's part of the problem. |
I've quickly skimmed thru the logs:
sounds like it's missing |
@ABeltramo Seems to work! But now it needs the same fix in |
I was testing this PR in my setup, and found some problems of the virtual motion sensor. Sunshine ad93e89 After setup uhid, on the server side (sunshine), I have:
on the client side (moonlight), I have:
But in the game tested, the motion sensor is unreasonablely fast to use. After compare the output of So, I run On the server side:
On the client side:
Edit
The 2 plots represent the same movement of the dualsense controller, the server side seems wrong to me. |
This is probably the most in-depth bug report I've ever received, thanks @azuwis ! |
My bad, I've added that too! |
@azuwis thanks for your report! @ABeltramo I'm splitting in smaller parts the upper input layer too, so it will be easier to understand, here is the PR #2594 if you want to use it And the (hopefully) last changes missing to build on all platforms: games-on-whales/inputtino#4 |
@Hazer I've pushed a fix for Gyro and Acceleration, it should now be very close to the original: gyro_capture.mp4You have to update inputtino to the latest and change the following (I'm afraid I can't push to this PR, right?):
to: std::get<inputtino::PS5Joypad>(*gamepad->joypad).set_motion(inputtino::PS5Joypad::GYROSCOPE, deg2rad(motion.x), deg2rad(motion.y), deg2rad(motion.z)); (add the It would be great if @azuwis can give it another go after this change is in! |
@ABeltramo sent you an invite for my fork, if you want to change directly. Updated with latest ps5 changes, can you give it another go @azuwis? |
Damn you Fedora! I'm going to install it in a VM to quickly test this compilation issues.. |
@ABeltramo a few developers VS a hat, who would win? I don't know, maybe it's because it's on mobile. I've updated now to games-on-whales/inputtino@99c9840, so I guess everything should be there. PS: Fedora is building with latest release. So far. |
Sunshine: azuwis@4855e09, not the version in this PR, have to apply the patch @ABeltramo mentioned:
Gnuplot of
Great work! 👍 |
Thanks @azuwis for confirming! @Hazer I've pushed the missing bit to your branch, I think there are only a few things left for this PR:
Anything else missing? |
For your third checklist, I don't know that it's worth it. I don't think we'll be keeping both code paths for long. |
That sounds good to me! Shall we clean it up then? I mean, it's always going to be present in git history if anyone ever is going to need it.. |
I'm fine with that, or handling it in a separate PR right after the next stable release. I'm just a little worried about a big change like this with so few testers. |
That's a valid concern; whilst the DualSense stuff is definitely experimental and lightly tested users can always force an xbox joypad from the config page and that's been in use for more than a year in Wolf. I'd assume that any big issue would have been reported by now.. |
(I know, C++ is dumb)
7cf2d1c
to
920cca6
Compare
@ABeltramo it looks like the percentage we give is divided by 10. Is that the issue? https://github.com/games-on-whales/inputtino/blob/2739465690c7bbd1a27cb4e285ff08f486a208e3/src/uhid/joypad_ps5.cpp#L383 |
I'll have to do more investigation, I've been primarily testing using a modded Switch running a Moonlight client. I have tried with other proper controllers, however, and I do believe that those also presented the "low battery" message. I'll double-check in a bit. When I received those errors, the Switch was most certainly on somewhere around 80-90%, or more. |
SDL2 doesn't have proper pen support, so you'd need to test on Android or iOS using a stylus. Those should support all of the fancy pen features (pressure, tilt, hover, buttons) assuming your hardware has them. |
…Byte#2606) Co-authored-by: ABeltramo <[email protected]> Co-authored-by: ReenigneArcher <[email protected]>
Description
This is a direct continuation of #2315 @ABeltramo 's amazing work.
inputtino.cpp
into namespaces by kindinput.cpp
tolegacy_input.cpp
Issues Fixed or Closed
Might help with #1720
Type of Change
.github/...
)Checklist
Branch Updates
LizardByte requires that branches be up-to-date before merging. This means that after any PR is merged, this branch
must be updated before it can be merged. You must also
Allow edits from maintainers.