Gamepad
Usually connected gamepads are not always configured properly. This UI needs to support the ability to remap the plugged-in gamepad to a "standard" gamepad (a Xbox gamepad).
Also the raw names reported by the drivers are not always correct, we need to allow someway to remap this to a user-friendly name which can then be shown to the user when say assigning a gamepad to a user in a game.
Goals
- Allow to chose the gamepad to remap.
- Set the name for a gamepad (many gamepads raw names are badly reported).
- Remap a gamepad to a standard gamepad.
- In this we may have to alert the user from mapping the same key to a button
- There must also be a way to say that no such button/axis exists for this standard-gamepad-button/axis in this gamepad
- Allow some way to review the mapping, for example by letting the user press the gamepad button and see which standard gamepad button corresponds to it.
- Allow to remap some of the buttons of the gamepad
- An easy interface to map all the buttons of a unknown/wrongly-mapped gamepad
Relevant Art
OpenEMU
https://www.youtube.com/watch?v=bA6PxHKloNg
Discussion
https://wiki.gnome.org/Design/Playground/Games/Inputs
Experimental Guidelines
It can be a step-wise process:
- Choose a gamepad
- Prompt for name with the current name filled in
- Show a dialog whether to remap the gamepad afresh or to review the current binding (AFRESH/REVIEW)
- Show a window with an image of the Standard Gamepad
- AFRESH Mode
- Highlight "sequentially" each button/axis of the standard gamepad in the image and ask the user to press the corresponding button on his gamepad
- Dialog asking Done/Review
- REVIEW Mode
- Highlight the correspondingly mapped standard button in the image when a gamepad button is pressed
- If he clicked on a button in the image.. that part is highlighted and the user can assign a new key to it
- Common to both Modes
- He may chose to press some keyboard key to switch to the next button telling that no such key exists on my gamepad
- AFRESH Mode