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

Qt/Input: Introduce profiles #3978

Merged
merged 1 commit into from Jan 9, 2018

Conversation

Projects
None yet
7 participants
@Megamouse
Copy link
Contributor

Megamouse commented Dec 23, 2017

This also fixes a XInput connection issue, where a disconnected device would incapacitate all following devices.

You can now add profiles by just putting them into the correct folder or creating them yourselves with the corresponding button.
please test this like bosses minna

confirmations:

  • keyboard
  • Xinput
  • DS4
  • MMJOY
  • evdev

@Megamouse Megamouse force-pushed the Megamouse:profiles branch 3 times, most recently from 7890b5c to d161f2d Dec 23, 2017

@Asinin3

This comment has been minimized.

Copy link
Contributor

Asinin3 commented Dec 25, 2017

If i chose a profile e.g profile 4 for my pad1. after hitting "ok" and closing the pad window it resets back to profile 0. Making it impossible to use more than one profile.

@Megamouse Megamouse force-pushed the Megamouse:profiles branch from d161f2d to 16cc32d Dec 25, 2017

@Megamouse

This comment has been minimized.

Copy link
Contributor

Megamouse commented Dec 25, 2017

@Asinin3 it should work now

@toccata10

This comment has been minimized.

Copy link
Contributor

toccata10 commented Dec 26, 2017

A welcomed functionality. About the ergonomy: I would prefer these 2 things:

  1. display the evdev number next (before or after) to the controller name on the gamepad settings panel
  2. be able to load/save a file instead of a profile number as I can give more explicit names. This probably means duplicate the file selection on the "configure evdev" panel and add a "load" button on it.

@Megamouse Megamouse force-pushed the Megamouse:profiles branch from 16cc32d to aac95a5 Dec 26, 2017

@MSuih

This comment has been minimized.

Copy link
Contributor

MSuih commented Dec 27, 2017

Woudn't it be better to store the profiles as a vector rather than a fixed-lenght array? That way you could arrange them more freely and delete unneeded profiles from the middle of the list. You'd have to add profile naming though, else it would get confusing really fast. Some kind of dynamic loading would be worth looking into as well to avoid clogging up the system if users create large amounts of profiles.

Saving the profiles as individual files and then f.ex. loading a whole /profiles folder into the UI would be an neat feature as well, but I'd imagine it woudn't be easy to implement since you'd have to work through the OS and it's file system.

@HerrHulaHoop

This comment has been minimized.

Copy link

HerrHulaHoop commented Dec 27, 2017

Profiles on keyboard work. Tested with Catherine Co-op using different profiles for each player on the same keyboard.
If I had 2 keyboards connected, I imagine binding separate profiles to different keyboards shouldn't be an issue either.

@Megamouse Megamouse force-pushed the Megamouse:profiles branch 3 times, most recently from 2379d64 to a123b26 Dec 27, 2017

@Megamouse

This comment has been minimized.

Copy link
Contributor

Megamouse commented Dec 27, 2017

reworked to use custom profiles, each an own file in /InputConfigs/<handler>/<profile>.yml

should also have an experimental evdev event nr. (no idea if that works)

@Megamouse Megamouse force-pushed the Megamouse:profiles branch 2 times, most recently from 0dc6891 to cdaa922 Dec 27, 2017

@Megamouse

This comment has been minimized.

Copy link
Contributor

Megamouse commented Dec 27, 2017

@toccata10 can you please test this with evdev again?

@Megamouse Megamouse force-pushed the Megamouse:profiles branch 3 times, most recently from d037416 to d212539 Dec 27, 2017

@toccata10

This comment has been minimized.

Copy link
Contributor

toccata10 commented Dec 30, 2017

It works nicely with evdev.

  1. Now, I wonder why "evdev_positive_axis" is a separate file: shouldn't the parameters be included at the end of the yml profile file ? I wondered why after changing ABS_X and ABS_Y to true, it works fine with my dragonrise and xbox360 sticks (I predicted it shouldn't work with xbox360, but it works).
  2. the evdev event number works fine. That's good: it's easier to distinguish same brand controllers.
  3. I suggest adding a "Delete profile" button: it'll be easier for everyone, instead of having to digg in the subfolders.
  4. I should get my hands on a DS4 controller soon, so I'll can test that.
    Very cool feature being able to remap and mix different controllers.
@Megamouse

This comment has been minimized.

Copy link
Contributor

Megamouse commented Dec 30, 2017

Thank you for testing!

  1. this PR doesn't handle the positive axis for multiple controllers yet.
  2. Good to know, I was just changing two lines of code without thinking. I'm kinda surprised that it worked.
  3. The delete profile button will not be part of this PR (yet)
  4. yeah.. DS4 would be nice, but don't buy it just for this purpose.. unless you wanted to have one anyway
@toccata10

This comment has been minimized.

Copy link
Contributor

toccata10 commented Dec 30, 2017

The DS4 was on its way (you know, Christmas time...), but sadly it segfaults as soon as I select it (and closes rpcs3):
selection_057
On master, it works fine (even the gyros)

@Megamouse

This comment has been minimized.

Copy link
Contributor

Megamouse commented Dec 30, 2017

could you try to find the reason?

@toccata10

This comment has been minimized.

Copy link
Contributor

toccata10 commented Dec 30, 2017

That seems way beyond my skills. I'll see if I can create a backtrace.

@toccata10

This comment has been minimized.

Copy link
Contributor

toccata10 commented Dec 30, 2017

My backtrace:
https://pastebin.com/m3pMkeLQ
Doesn't to like this: "ds4_pad_handler::SendVibrateData"

@Megamouse Megamouse force-pushed the Megamouse:profiles branch from d212539 to 53e0652 Dec 30, 2017

@Megamouse

This comment has been minimized.

Copy link
Contributor

Megamouse commented Dec 30, 2017

I changed sth.
could you please test again?
and if it works: please try the vibration tests in the pad-dialog

edit: fixed the stupid compile error

@Megamouse Megamouse force-pushed the Megamouse:profiles branch from 53e0652 to 674c4ea Dec 30, 2017

@toccata10

This comment has been minimized.

Copy link
Contributor

toccata10 commented Dec 31, 2017

ds4 is working fine now. I tried the switch in the pad-dialog: works fine. In game vibrations: working.
So: this profile stuff is working fine on my side. Another nice addition.
On Super Street Fighter Turbo 2 HD (and 1942 joint strike), the buttons are not responding but I suppose it's in your other PR #3989

@@ -314,6 +359,8 @@ struct pad_config : cfg::node
}
};

static input_config input_cfg;

This comment has been minimized.

@Nekotekina

Nekotekina Jan 4, 2018

Member

What is this? Don't declare such variables in headers.

@Megamouse Megamouse force-pushed the Megamouse:profiles branch from 674c4ea to f1d70bb Jan 4, 2018

@AniLeo AniLeo requested a review from Nekotekina Jan 6, 2018

@Megamouse Megamouse force-pushed the Megamouse:profiles branch 2 times, most recently from 188a4f1 to 7dd1b81 Jan 8, 2018

@Megamouse Megamouse force-pushed the Megamouse:profiles branch from 7dd1b81 to 0358fab Jan 9, 2018

@Nekotekina Nekotekina merged commit 51a2b43 into RPCS3:master Jan 9, 2018

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@Megamouse Megamouse deleted the Megamouse:profiles branch Jan 14, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment