Commit graph

53 commits

Author SHA1 Message Date
kalaposfos13
b8aac357cb
Fix SDL gyro and acceleration sensor handling (#2532)
* Fix sensor handling if they are enabled but an error was thrown regardless

* Initialise orientation to a default value + clang
2025-02-24 22:38:06 +02:00
jarred wilson
bc85357235
move display mode and hdr to graphics tab (#2485)
* move display mode and hdr to graphics tab

* add left margin to display settings box

* merge display combo box and fullscreen checkbox

* remove commented out checkbox

* Rename borderless to windowed

* rename graphics box and mode

* Rename window modes and map

* fix formatting

* fix: xml formatting

* Rename borderless windowed

* change resolution input layout

* rename resolution to window size

* change window size layout oriention

* add true fullscreen mode

* fix duplicate label name

* set fullscreen on true fullscreen or borderless

* remove commented out ref

* rearrange settings config for new schema

* move HDR config to GPU section
2025-02-23 17:01:09 +02:00
Dmugetsu
2af20b0d83
Now lightbar overwrite works on dualsense while using it on bluetooth (#2481) 2025-02-20 10:15:54 +02:00
kalaposfos13
1cc9e0d37f
Initial implementation of controller color config (#2411) 2025-02-14 12:30:49 +02:00
kalaposfos13
c4bfaa6031
Added keyboard and mouse input remapping, mouse movement to joystick logic, GUI and more (#1356)
* added support for loading keyboard config from file

* final minor update before pull request

* fix messing up the merge

* fix waitEvent to correctly handle mouse inputs

* add license

* Applied coding style fixes

* clang-format fucked up the .ini file

* actually fix clang changing ini syntax
use relative path for the ini file

* remove big commented out code blocks,
and fixed platform-dependent code

* fix windows hating me

* added mouse config option

* added toggle for mouse movement input (f7)

* fix license and style

* add numpad support i accidentally left out

* added support for mouse wheel (to buttons only)

* if keyboard config doesn't exist, autogenerate it

* added keybinds for "walk mode"

* Mouse movement input is now off by default

* code cleanup and misc fixes

* delete config file since it is now autogenerated

* F6 = F7 + F9

* added better mouse handling with config options

* Added capslock support

* fix clang-format

* Added support for mod key toggle key

* F6 and F7 are removed, F9 captures and enables the mouse

* Encapsulated globals and new classes in a new namespace

* Added mouse side button support

* Added per-game config

* relocated input parser to the new namespace

* changed parser parameters to make it possible to use it from the gui

* added home, end, pgup and pgdown

* Resolved merge conflict and refactored code

* Updated default keybindings

* Changed input handling to be single-threaded

* General code cleanup

* Start working on new backend

* Mouse polling, CMakeLists, and basic framework

* Output update handling, and reworked file creating, reading and parsing

* Parsing works now

* Single key button inputs work now

* Axis outputs work now

* Wheel works now (for me), l2/r2 handling improvements, and misc bugfixes

* Downgraded prints to log_debug, and implemented input hierarchy

* Implemented key toggle

* Added mouse parameter parsing

* clang-format

* Fixed clang and added a const keyword for mac

* Fix input hierarchy

* Fixed joysick halfmodes, and possibly the last update on input hierarchy

* clang-format

* Rewrote the default config to reflect new changes

* clang

* Update code style

* Updated sorting to accomodate for that one specific edge case

* Fix default config and the latest bug with input hiearchy

* Fix typo

* Temporarily added my GUI

* Update cmakelists

* Possible fix for Gravity Rush

* Update Help text, default config, and clang

* Updated README with the new keybind info

* okay so maybe the gravity rush fix might have slightly broken the joystick halfmode and key toggle

* Fixed mistakenly overwriting the last opened config with the default one if the GUI is opened multiple times in a session

* Updated Help descriptions and fixed mouse movement default parameters

* Fix crash if the Help dialog was opened a second time
If it's closed with the top right close button instead of clicking the Help button again, a required flag wasn't reset, making the next click on Help try to close a nonexistent window and segfault

* Added closing the config also closing the Help window, and fixed more segfaults due to mismatched flags

* Initial controller support

* clang and debug print cleanup

* Initial axis-to-button logic

* Updated Help text

* Added 'Reset to Default' button in GUI

* Minor text and description updates + fixed an issue with Help text box rendering

* Fix button-to-touchpad logic and l2/r2 handling, as they are both axes and buttons
The touchpad's button state was correctly handled, so games that use that were fine, but the touchDown flag was always set to true, so games that use this flag had problems, like Gravity Rush

* Fix merge conflict

* Clang

* Added back back button to touchpad binding

* Added touchpad button handling

* Added end-of-line comments and fixed some crashes happening with the VS debugger

* Apply recent changes from kbm-only

* Deadzone + initial directional axis-to-button mapping

* Added that one missing space in the README. Are you all happy now?

* Fixups from making everything use SDL

* Revert directional joystick code and fix a memory leak

* Change config directory name again to conform to project standards

* Clang

* Revert the old deeadzone code and properly add the new one

* Clang
2025-01-31 16:36:14 +02:00
squidbus
0b50e2e270
sdl_window: Allow alternate face button keys on any system. (#2275)
* sdl_window: Allow alternate face button keys on any system.

* readme: Fix typo
2025-01-30 10:09:11 +02:00
Quang Ngô
90b04e8cc0
input: Don't use old input state in GameController::ReadState() (#2170) 2025-01-18 09:59:38 +03:00
squidbus
4719d32295
sdl: Respect text input main thread requirements. (#2138) 2025-01-12 22:44:42 +02:00
kalaposfos13
4df0d9c035
Add support for true fullscreen (#2016)
* Support for true fullscreen

* clang

* Re-add mistakenly deleted line

* Size

I adjusted the size of the entire screen.
trophies font size and added a margin so it wouldn't be so spaced out.

---------

Co-authored-by: DanielSvoboda <daniel.svoboda@hotmail.com>
2025-01-07 15:30:05 +02:00
kalaposfos13
15c9bb0e83
Motion controls (#1984)
* Initial motion controls

* Store sensor polling rate, and add more logging

* Revert commented out logging for testing purposes

* Code cleanup & clang

* New orientation handling

* clang
2025-01-01 20:05:22 +02:00
Quang Ngô
ab7e794f23
sdl: Limit minimum window size (#1966) 2024-12-29 12:35:52 +02:00
Connor Garey
af26c945b1
Fix for "shadPS4" not being given on Linux volume mixers (#1789) 2024-12-14 23:30:17 +01:00
Vinicius Rangel
f1b23c616e
Devtools - Shader editing (#1705)
* devtools: shader editing and compiling

* devtools: patch shader at runtime

* devtools: shader editing load patch even with config disabled
2024-12-09 21:11:11 +01:00
TheTurtle
5b6e0ab238
core: Library cleanup (#1631)
* core: Split error codes into separate files

* Reduces build times and is cleaner

* core: Bring structs and enums to codebase style

* core: More style changes
2024-11-30 22:37:36 +02:00
Vladislav Mikhalin
c38e3f77f9
Add poll interval to libScePad (#1415) 2024-10-19 15:57:01 +03:00
Exhigh
f139762c64
imgui/renderer: Hide Cursor on Idle Implementation (#1266)
Implement hide cursor on idle w/ idle timeout duration (configurable via GUI). While at it add always and never to hide the cursor options as well.

* Revert commit #1211 as to not interfere with the cursor states.
* Make hide cursor on idle as the default setting w/ timeout duration of 5 seconds to hide.
* Add an input tab in the settings page to add the hide cursor setting, with hiding the idle timeout box with respect to the cursor hide option.

Co-authored-by: georgemoralis <giorgosmrls@gmail.com>
2024-10-08 09:47:42 +03:00
fireph
ce53c41205
Add support to click touchpad using back button on non PS4/5 controllers (#1258)
* Working touchpad support

Tested on PS5 controller plugged in via USB.

* fix lint

* Add support to click touchpad using back button on other controllers

Takes the back button and allows the user to change the behavior of how it clicks the touchpad. The current options are left, right, center, and none.

* add description text

* make more generic so translations can be supported in combobox

* fix lint

* linter again

* support back button to touchpad for spacebar as well

* linter at it again
2024-10-08 09:15:30 +03:00
tGecko
ec6579cb4f
Hide cursor on key/button press (#1211) 2024-10-04 08:49:18 +02:00
squidbus
398019867b
sdl: Fix use of functions that now return SDL_bool (#1160) 2024-09-30 06:47:55 +03:00
Lander Gallastegi
a984d44fd3
Swapchain recreation and window resizing (#933)
* Always present acquired swapchain images

Always present acquired swapchain images in order to be able to acquire them again.

fix #865

* Recreate swapchain if window is resized

* Respect aspect ratio when blitting to frame

* Make SDL window resizable

* clang-format

* designator order (building with gcc)

Fix /shadPS4/src/video_core/renderer_vulkan/vk_instance.cpp:314:9: error: designator order for field ‘vk::PhysicalDeviceVulkan12Features::samplerMirrorClampToEdge’ does not match declaration order in ‘vk::PhysicalDeviceVulkan12Features’

* Clear frame before blitting

* clang-format

* Revert "designator order (building with gcc)"

There already is a PR opened for this.

This reverts commit 7f8ccf4b1e.
2024-09-25 12:43:08 +03:00
georgemoralis
dd61c2a0d1 Revert "Add UI to configure keyboard-to-controller mapping (#308)"
This reverts commit fdb13a3b90.
2024-09-11 12:56:27 +03:00
Vasyl_Baran
fdb13a3b90
Add UI to configure keyboard-to-controller mapping (#308)
* Add UI to configure keyboard-to-controller mapping

* Add an optional "---fix" argument to format-checking script

* clang fix

---------

Co-authored-by: georgemoralis <giorgosmrls@gmail.com>
2024-09-11 08:51:18 +03:00
Vinicius Rangel
035cb3eeaa
Dear ImGui Implementation (#598)
* added imgui as dependency

* imgui renderer/basic input implementation

* imgui: add layers system

Add video info layer to show fps. Press F10 to toggle it.

* imgui: add custom imgui config

* imgui: gamepad capture, stopping propagation

* imgui: changed config & log file path to use portable dir

* videoout: render blank frame when video output is closed

required to render imgui even when game has no video output

- fixed merge compile-error
2024-09-08 22:50:32 +03:00
Daniel R.
ffd0f7b53a
core/libraries/save_data: Implement wildcard searches on sceSaveDataDirNameSearch (#817)
* libraries/save_data: Implement wildcards and params

* clang-format
2024-09-07 00:01:00 +03:00
counter185
4e6e90dfb9 add touchpad support, auto reconnect 2024-08-28 13:48:50 +02:00
SolidStateDj
7ecc1d3be0 Add a toggle fullscreen button
Assigns F11 as the key for toggling fullscreen.
2024-08-26 18:27:31 -04:00
georgemoralis
3e8d7c2040 possible R2/L2 fix 2024-08-22 19:43:45 +03:00
counter185
bb159eafb9
Basic gamepad support through SDL (#407)
* Add basic gamepad support through SDL

* lightbar, vibration, code style changes

* okay fine

* one day clang format will finally pass
2024-08-13 12:54:08 +03:00
georgemoralis
4ffb812e94 more linux fix? 2024-08-09 00:02:25 +03:00
georgemoralis
13331cdda9 linux fix? 2024-08-09 00:02:25 +03:00
georgemoralis
5a68224a13 update submodules , fixed sdl update , rewrote config with new toml11 v4 2024-08-09 00:02:24 +03:00
georgemoralis
bd48e24c32 print git info to log as well 2024-08-01 01:11:58 +03:00
georgemoralis
62e501f31f print git info in windows title 2024-08-01 00:56:10 +03:00
TheTurtle
0d6edaa0a0
Move presentation to separate thread/improve sync (#303)
* video_out: Move presentation to separate thread

* liverpool: Better sync for CPU flips

* driver: Make flip blocking

* videoout: Proper flip rate and vblank management

* config: Add vblank divider option

* clang format

* videoout: added `sceVideoOutWaitVblank`

* clang format

* vk_scheduler: Silly merge conflict

* externals: Add renderdoc API

* clang format

* reuse

* rdoc: manual capture trigger

* clang fmt

---------

Co-authored-by: psucien <168137814+psucien@users.noreply.github.com>
2024-07-28 15:54:09 +02:00
raziel1000
a11ac5a687 ... 2024-07-26 07:59:55 +03:00
raziel1000
fa76a723ad Applied feedback from @raphaelthegreat 2024-07-26 07:59:35 +03:00
raziel1000
f35518d527 sdl window: Added game title (serial, title and app_ver) 2024-07-26 07:53:18 +03:00
squidbus
cf03743631 Restore old keybindings for Windows and Linux. 2024-07-21 22:36:12 +03:00
squidbus
a4fd0d6386 Remap SDL face buttons to be usable without a keypad. 2024-07-21 22:36:12 +03:00
squidbus
66fa29059c Add initial macOS support. 2024-07-21 22:36:12 +03:00
georgemoralis
134541bdcd submodules updates 2024-07-05 15:08:33 +03:00
georgemoralis
0ada442cbc
Stabilization8 (#218)
* disable configured flexible memory size (caused issues in some games)

* fixed case S_OR_B64 for blazing chrome

* submodules updates and fixes for latest SDL

* stubbed _sigprocmask (not handled and spams too much)

* added ReplaceOp case in Stencilop

* dummy ajm module added
2024-06-27 16:37:17 +03:00
georgemoralis
7519d4610c added missing buttons and analog buttons to keyboard 2024-06-21 14:37:49 +03:00
georgemoralis
49601f58ed initial dents support 2024-06-20 18:09:40 +03:00
georgemoralis
b17a57cb3d analog sticks works better now 2024-06-17 14:33:03 +03:00
georgemoralis
91e6d35e89 analog support via keyboard 2024-06-17 13:42:39 +03:00
georgemoralis
48d6ccd9bb partially added analog controls 2024-06-17 12:52:25 +03:00
georgemoralis
0aa29428e1 new pad module structured using modulegenerator , added common pad structures and function signatures 2024-06-17 09:02:06 +03:00
TheTurtle
31bd502764
core: Fixup linux support (#195)
* tls: Implement for linux

* core: Implement memory manager for linux
2024-06-14 00:58:57 +03:00
georgemoralis
81a1cbf6b1 more clang fix 2024-06-10 15:24:34 +03:00