Commit graph

404 commits

Author SHA1 Message Date
Narr the Reg
e4492a9a82
input_common: Fix error with thread name 2021-11-29 22:03:47 -05:00
vperus
660c6bec22 Revert of b01aa72
Caused worker_thread to be stuck in Stage1Completed state until job's destruction.
2021-11-29 16:37:11 +02:00
vperus
04fa990b0c [input_common] Add completion test for CalibrationConfigurationJob 2021-11-29 16:33:12 +02:00
Narr the Reg
639402850a input_common: Fully implement UDP controllers 2021-11-26 15:46:36 -06:00
german77
746c85b560 input_common: Move button names to the frontend 2021-11-24 20:30:28 -06:00
german77
c4760489a0 input_common: Fix SDL controller with inverted axis 2021-11-24 20:30:28 -06:00
german77
42949738f2 kraken: Address comments from review
Fix compiler bug
2021-11-24 20:30:28 -06:00
german77
f4e5f89e6f core/hid: Improve accuary of mouse implementation 2021-11-24 20:30:28 -06:00
german77
654d76e79e core/hid: Fully implement native mouse 2021-11-24 20:30:28 -06:00
german77
bca299e8e0 input_common: Allow keyboard to be backwards compatible 2021-11-24 20:30:28 -06:00
german77
b673857d7d core/hid: Improve accuracy of the keyboard implementation 2021-11-24 20:30:28 -06:00
german77
c35af8d1c0 input_common: Fix motion from 3 axis 2021-11-24 20:30:27 -06:00
german77
157e0b85fd core/hid: Prevent Emulated controller from flapping with multiple inputs devices 2021-11-24 20:30:27 -06:00
german77
136eb9c4c2 core/hid: Fully emulate motion from button 2021-11-24 20:30:27 -06:00
german77
77fa4d4bf6 second commit lion review 2021-11-24 20:30:26 -06:00
german77
730f078302 settings: Fix Debug controller type options 2021-11-24 20:30:26 -06:00
german77
2b1b0c2a30 kraken: Address comments from review
start lion review
2021-11-24 20:30:26 -06:00
german77
61d9eb9f69 input_common: Revert deleted TAS functions 2021-11-24 20:30:26 -06:00
german77
d8e3f2b10b input_common: Fix GC adapter initialization
Fix GC controller
2021-11-24 20:30:26 -06:00
german77
1d71d4b874 input_common: Fix UDP uuid 2021-11-24 20:30:26 -06:00
german77
7348e205d9 input_common: Add multiple vibration curves 2021-11-24 20:30:26 -06:00
german77
064ddacf49 core/hid: Rework battery mappings 2021-11-24 20:30:26 -06:00
german77
c6c32daf40 input_common: Add manual update options to input devices 2021-11-24 20:30:26 -06:00
german77
464c4d26ac settings: Fix mouse and keyboard mappings 2021-11-24 20:30:25 -06:00
german77
b5e72de753 kraken: Address comments from review
review fixes
2021-11-24 20:30:25 -06:00
german77
85052b8662 service/hid: Fix gesture input 2021-11-24 20:30:25 -06:00
german77
af55dd1935 configuration: Migrate controller settings to emulated controller 2021-11-24 20:30:25 -06:00
german77
c3ff0a8ac0 core/hid: Fix rumble too strong at 1% 2021-11-24 20:30:24 -06:00
german77
601ac43495 core/hid: Only signal when needed 2021-11-24 20:30:24 -06:00
german77
e0da5c1bbc kraken: Fix errors from rebase and format files 2021-11-24 20:30:24 -06:00
german77
06a5ef5874 core/hid: Add output devices 2021-11-24 20:30:24 -06:00
german77
29ae42f3e2 input_common: Rewrite main and add the new drivers 2021-11-24 20:30:23 -06:00
german77
6d108f0dcb input_common: Remove obsolete files 2021-11-24 20:30:23 -06:00
german77
59b995a9e5 input_common: Rewrite SDL 2021-11-24 20:30:23 -06:00
german77
10241886dd input_common: Rewrite udp client 2021-11-24 20:30:22 -06:00
german77
dc3ab9e110 input_common: Rewrite tas input 2021-11-24 20:30:22 -06:00
german77
395e9a449d input_common: Rewrite gc_adapter 2021-11-24 20:30:22 -06:00
german77
fa8e23b842 input_common: Rewrite touch 2021-11-24 20:30:22 -06:00
german77
00834b84dd input_common: Rewrite mouse 2021-11-24 20:30:22 -06:00
german77
5a785ed794 input_common: Rewrite keyboard 2021-11-24 20:30:22 -06:00
german77
4c6f2c2547 input_common: Move touch and analog from button. Move udp protocol 2021-11-24 20:30:22 -06:00
german77
854c933716 input_common: Create input poller and mapping 2021-11-24 20:30:22 -06:00
german77
ea7b1fbc67 input_common: Create input_engine 2021-11-24 20:30:22 -06:00
Fernando S
33e92c15eb
Revert "input_common: Fix data race on GC implementation" 2021-10-23 23:32:16 +02:00
Fernando S
7461196839
Merge pull request #6515 from german77/gc_thread_safe
input_common: Fix data race on GC implementation
2021-10-23 23:28:22 +02:00
ameerj
b01aa721ff input_common: Fix VS2022 compilation errors 2021-10-20 01:21:59 -04:00
german77
8212a864ca input_common/sdl: Fix joystick range 2021-10-11 01:03:01 -05:00
bunnei
21ed944ff9
Merge pull request #6979 from german77/joycon_name
input_common: Add alternative string for joycons
2021-10-02 02:58:25 -07:00
ameerj
73666fb262 general: Update style to clang-format-12 2021-09-24 15:52:05 -04:00
german77
75d8ec1e9f UI: Relocate tas menu and add brief description 2021-09-18 23:23:03 +02:00
german77
33a1d790e8 input_common/tas: Document the main class 2021-09-18 23:22:48 +02:00
german77
e6c4bf52f0 input_common/tas: Add swap controller 2021-09-18 23:22:42 +02:00
german77
9bb6580d89 input_common/tas: overwrite file dialog 2021-09-18 23:22:42 +02:00
MonsterDruide1
f078b15565 input_common/tas: Fallback to simple update 2021-09-18 23:22:30 +02:00
german77
c01a872c8e config: Move TAS options to it's own menu 2021-09-18 23:22:30 +02:00
MonsterDruide1
4297d2fea2 core: Hacky TAS syncing & load pausing
To keep the TAS inputs synced to the game speed even through lag spikes and loading zones, deeper access is required.

First, the `TAS::UpdateThread` has to be executed exactly once per frame. This is done by connecting it to the service method the game calls to pass parameters to the GPU: `Service::VI::QueueBuffer`.

Second, the loading time of new subareas and/or kingdoms (SMO) can vary. To counteract that, the `CPU_BOOST_MODE` can be detected: In the `APM`-interface, the call to enabling/disabling the boost mode can be caught and forwarded to the TASing system, which can pause the script execution if neccessary and enabled in the settings.
2021-09-18 23:22:20 +02:00
MonsterDruide1
b42c3ce21d input_common/tas: Base playback & recording system
The base playback system supports up to 8 controllers (specified by `PLAYER_NUMBER` in `tas_input.h`), which all change their inputs simulataneously when `TAS::UpdateThread` is called.

The recording system uses the controller debugger to read the state of the first controller and forwards that data to the TASing system for recording. Currently, this process sadly is not frame-perfect and pixel-accurate.

Co-authored-by: Naii-the-Baf <sfabian200@gmail.com>
Co-authored-by: Narr-the-Reg <juangerman-13@hotmail.com>
2021-09-18 23:22:00 +02:00
german77
5798537ce4 input_common: Enable steam controllers and 8 player support 2021-09-10 00:58:12 -05:00
german77
4bc3c788f5 input_common: Add alternative string for joycons 2021-09-06 22:20:19 -05:00
german77
2a2f0bfe9e input_common: Disable sdl raw input mode 2021-08-12 13:17:07 -05:00
german77
48b6d41f1b input_common: Improve SDL joystick and hide toggle option 2021-08-07 23:11:23 -05:00
Rodrigo Locatti
d4cab35533 input_common: Fix data race on GC implementation 2021-08-07 16:46:26 -05:00
bunnei
dff438e219
Merge pull request #6654 from german77/custom_threshold
input_common: Make button threshold customizable
2021-07-21 20:31:33 -04:00
bunnei
29fb110049
Merge pull request #6649 from german77/toggle_sdl
input_common: Support SDL toggle buttons
2021-07-20 20:35:20 -04:00
Nicolas Jallamion
6573ff64b4
input/sdl_impl: fix rumble support on DualSense. (#6683)
- value return can be different 0, is not error is normal, error is only -1.
2021-07-20 04:00:07 -04:00
bunnei
ffc78ce9c1
Merge pull request #6652 from lat9nq/cmd-vulkan-fixes
yuzu-cmd: Linux Vulkan fixes
2021-07-19 20:54:03 -04:00
german77
14d5202da6 input_common: Fix mouse panning behaivour 2021-07-16 18:57:29 -05:00
lat9nq
f785933125 sdl_impl, emu_window: Remove clang ignore
Fixed upstream by
libsdl-org/SDL@25fc40b0bd
2021-07-16 15:43:12 -04:00
german77
240019feca input_common: Make button threshold customizable 2021-07-15 23:56:57 -05:00
bunnei
3cd3230295
Merge pull request #6579 from ameerj/float-settings
settings: Eliminate usage of float-point setting values
2021-07-15 18:03:11 -04:00
german77
c7478642a6 input_common: Support SDL toggle buttons 2021-07-15 14:31:58 -05:00
german77
289f59dabd input_common: Fix build with sdl disabled 2021-07-10 20:02:02 -05:00
ameerj
0ed1077763 configure_input: Use u8 for mouse sensitivity 2021-07-08 23:24:31 -04:00
Ameer J
5edc96f4a4
Merge pull request #6539 from lat9nq/default-setting
general: Move most settings' defaults and labels into their definition
2021-07-08 14:46:31 -04:00
lat9nq
a949ee0410 general: Code formatting improvements
Slight improvements to readability.

Dropped suggestions for string_view (settings.h:101), pass by value
(settings.h:82), reverting double to a float (config.cpp:316), and other
smaller ones, some out of scope.

Addresses review feedback.

Co-authored-by: Ameer J <52414509+ameerj@users.noreply.github.com>
2021-07-08 14:07:10 -04:00
Morph
ebb82b0b83 CMakeLists: Treat -Wsign-compare as an error on GCC/Clang
Treats (un)signed comparison mismatches as errors to be consistent with MSVC
2021-07-06 12:50:09 -04:00
bunnei
bf50345d4c
Merge pull request #6537 from Morph1984/warnings
general: Enforce multiple warnings in MSVC
2021-07-05 17:09:23 -07:00
german77
c19ec2edd9 input_common: Add missing modifier callback to analog from button 2021-07-05 11:39:42 -05:00
lat9nq
0e5c74bc9e core, input_common: Miscellaneous fixes
bcat: Fix settings access

telemetry_session: Fix settings accesses

So this is what I get for testing with the web service disabled.

touch_from_button: Fix settings access for clang
2021-06-28 20:56:17 -04:00
lat9nq
b91b76df4f general: Make most settings a BasicSetting
Creates a new BasicSettings class in common/settings, and forces setting
a default and label for each setting that uses it in common/settings.
Moves defaults and labels from both frontends into common settings.
Creates a helper function in each frontend to facillitate reading the
settings now with the new default and label properties.

Settings::Setting is also now a subclass of Settings::BasicSetting. Also
adds documentation for both Setting and BasicSetting.
2021-06-28 17:32:17 -04:00
Morph
954259312e input_common: Remove #pragma warning directives for external headers 2021-06-28 14:20:25 -04:00
Morph
58550cfcdc input_common: Enforce C4242 2021-06-28 14:20:25 -04:00
Chloe
f216a9432b
Add missing includes (#6521)
* Add missing includes

* Add array
2021-06-24 03:24:17 -04:00
Rodrigo Locatti
0a39163a90 input_common/mouse_input: Fix data race
Fix data race using std::jthread and std::stop_token.
2021-06-22 02:31:39 -03:00
bunnei
c1b8e59ea0
Merge pull request #6407 from lat9nq/fix-libusb-2
cmake: Use autotools for libusb linking generally on GNU, and cleanup
2021-06-10 23:35:30 -07:00
bunnei
1d1f616063
Merge pull request #6389 from german77/Analog_button_fix
input_common: Analog button, use time based position
2021-06-03 21:06:38 -07:00
lat9nq
ddc47e6df8 cmake: General improvements to libusb linking
Delegates libusb external communication to externals/CMakeLists.txt
Ensures an interface library `usb` for every pathway
input_common just links to the `usb` library now
externals/libusb/CMakeLists.txt sets variables to override SDL2's libusb
finding
Other minor cleanup
2021-06-03 03:49:35 -04:00
bunnei
348ca07e0d
Merge pull request #6318 from german77/dualJoycon
input_common: Add dual joycon support
2021-06-01 00:51:00 -07:00
german77
a323bc5af8 input_common: Analog button, use time based position instead of frequent updates 2021-05-30 00:13:51 -05:00
bunnei
aee3b57c44
Merge pull request #6312 from german77/analogMapping
input_common: Rewrite sdl analog mapping and fix controller disconnection crash
2021-05-24 12:02:37 -07:00
german77
ea4b7226a6 input_common: Add dual joycon support 2021-05-22 18:40:53 -05:00
bunnei
41b1f8d616
Merge pull request #6310 from german77/nanMotion
input_common: Sanitize motion data
2021-05-19 15:47:48 -07:00
german77
f20f4587e6 input_common: Implement SDL motion 2021-05-15 08:56:58 -05:00
german77
edd498f6e0 input_common: Fix crash when controller disconnects 2021-05-15 08:27:19 -05:00
german77
85eeae7aad input_common: Rewrite sdl analog mapping 2021-05-14 21:17:08 -05:00
german77
fd7c273fab input_common: Sanitize motion data 2021-05-13 13:41:32 -05:00
german77
6e81473574 input_common: Release mouse buttons on out of focus 2021-05-02 19:08:33 -05:00
bunnei
aab57b7975
Merge pull request #6243 from german77/GCresetOrigin
input_common: Reset GC sticks center by measuring multiple packets
2021-04-30 12:02:05 -07:00
german77
729545a946 input_common: Reset GC sticks center by measuring multiple packets 2021-04-26 18:34:00 -05:00
german77
c19ad21ae8 hid: Implement SevenSixAxis and ConsoleSixAxisSensor 2021-04-23 22:12:41 -05:00