Commit Graph

75 Commits

Author SHA1 Message Date
Cameron Gutman 377d37503f Split controller motion events onto their own channels 2023-07-04 16:18:52 -05:00
Cameron Gutman 53c29f11ba Send mouse deltas reliably for now 2023-07-04 15:48:08 -05:00
Cameron Gutman 0095141e08 Split control data into multiple channels and optimize packet flags based on type of data
This can significantly performance on lossy networks by avoiding HOL blocking.
2023-07-04 14:49:21 -05:00
Cameron Gutman 7d59c6e14e Fix motionType value in motion packets 2023-07-04 14:18:27 -05:00
Cameron Gutman 54e1556c40 Constrain the reported controller number by the max gamepad count 2023-07-04 14:16:53 -05:00
Cameron Gutman a0f8c060c0 Introduce new protocol extensions for controller RGB LEDs and battery state 2023-07-02 14:38:54 -05:00
Cameron Gutman 28d63b11dd Fix float values in pen events 2023-06-25 20:06:43 -05:00
Cameron Gutman 8c447137d6 Fix controller arrival packet to actually contain the controller that arrived 2023-06-25 14:27:43 -05:00
Cameron Gutman 44c8b95400 Pen tilt is 0..90 not -90..90 2023-06-25 00:24:55 -05:00
Cameron Gutman de0efa861a Several fixes for touch and pen APIs 2023-06-24 21:25:48 -05:00
Cameron Gutman 5cbb6f210d Fix signness of pen tilt parameters 2023-06-24 15:14:17 -05:00
Cameron Gutman 812ec0e2b7 Allow exceeding 4 controllers for Sunshine hosts 2023-06-18 16:36:34 -05:00
Cameron Gutman 689450954c Add pen and motion batching 2023-06-18 14:30:16 -05:00
Cameron Gutman 372eb94ed0 Expand button flags to support additional buttons with Sunshine 2023-06-18 14:03:29 -05:00
Cameron Gutman 7eea7a7971 Fix endianness issues for BE systems 2023-06-18 13:50:39 -05:00
Cameron Gutman 329c55d52f Send pointer IDs instead of touch indices 2023-06-18 13:48:55 -05:00
Cameron Gutman 4a48024dc8 Introduce new input extension functions for touch, pen, motion, and controller arrival 2023-06-11 19:38:22 -05:00
Cameron Gutman b77072d399 Don't use GFE modifier workaround with Sunshine 2023-02-25 13:11:54 -06:00
Cameron Gutman c88b1bcf8e Fix integer truncation warning on MSVC 2023-02-15 01:33:32 -06:00
Cameron Gutman 830187e4da Throttle mouse/controller message rate in the input send thread
This avoids clients from all having to handle this themselves independently.
2023-02-14 21:24:13 -06:00
Cameron Gutman e1a7fe84e0 Add missing return 2023-01-16 21:12:24 -06:00
Cameron Gutman c9a5cea93e Add Sunshine protocol extension to support non-normalized key codes 2023-01-16 21:05:11 -06:00
Cameron Gutman 22adeb3902 Enable high resolution scroll events on Sunshine 2023-01-16 20:58:03 -06:00
Cameron Gutman 071e595766 Implement horizontal scrolling protocol extension for Sunshine 2023-01-16 20:56:51 -06:00
Cameron Gutman af1dbfe505 Use APP_VERSION_AT_LEAST in a couple other places 2022-10-22 14:45:19 -05:00
Cameron Gutman d247873ade Add LiSendMouseMoveAsMousePositionEvent() function
This is a useful option for Android and iOS where mouse acceleration
is always enabled and mouse capture is the only feasible way to get
mouse input. It can avoid double-acceleration when being used for
remote desktop mouse mode.
2022-05-28 14:58:34 -05:00
Cameron Gutman cfe75eb569 Add workaround for keyboard and UTF-8 events interfering with each other 2022-01-17 21:56:06 -06:00
Cameron Gutman 6001ece0b8 Fix uninitialized variable 2021-12-12 16:04:58 -06:00
Cameron Gutman ac1355b922 Fix excessive high-res scroll speed on newer GFE versions 2021-12-12 12:05:20 -06:00
Cameron Gutman 257029f80d Remove redundant packet length field 2021-12-10 02:00:42 -06:00
Cameron Gutman 94d439e5c3 Fix memory corruption with UTF-8 strings over 32 bytes 2021-11-30 19:05:32 +03:00
Cameron Gutman 6a6328a355 Send each Unicode code point individually to avoid straddling packet boundaries 2021-11-30 18:28:09 +03:00
Cameron Gutman a290ec032b Fix relative mouse and controller batching after 74377a06 2021-08-05 22:14:35 -05:00
Cameron Gutman 8cac195fcf Fix compilation warnings 2021-07-30 01:32:43 -05:00
Cameron Gutman f3e37944fc Split UTF-8 strings into chunks small enough to fit in an NV_UNICODE_PACKET 2021-07-30 01:23:53 -05:00
Cameron Gutman 74377a061b Rework input packets based on new header knowledge 2021-07-30 01:02:35 -05:00
Cameron Gutman ceafe7897c Refactor input packet sending logic into a separate function 2021-07-29 23:49:58 -05:00
Mariotaku 5846a9d6aa Added unicode input event (#63)
* Added unicode input event

* Prevents strcpy overflow

* Updated according to change requests
2021-07-29 21:36:47 -05:00
Cameron Gutman ac9c4e82ac Introduce a list to cache freed input packet entries for reuse 2021-06-12 10:43:50 -05:00
Cameron Gutman ed9301f3f8 Join the input thread without interrupting first
Otherwise we'll kill it before it finishes draining
2021-05-15 22:56:44 -05:00
Cameron Gutman 431e188b07 Allow the input queue to drain before terminating the thread
This ensures any final input messages (like key ups) make it to the host
2021-05-15 22:01:50 -05:00
Cameron Gutman 1b3c14a792 Increase maximum input queue size 2021-05-14 21:07:14 -05:00
Cameron Gutman cd62147cdf Print a warning when the input queue reaches the maximum size 2021-05-14 20:36:25 -05:00
Cameron Gutman 8f371343cd Consolidate includes 2021-04-29 17:22:15 -05:00
Cameron Gutman 29d2cc6d5b Improve MbedTLS implementation of AES-CBC 2021-04-22 17:08:35 -05:00
Cameron Gutman 625ec431eb Improve AES-CBC code in preparation for audio encryption 2021-04-21 23:59:14 -05:00
Cameron Gutman 4304e597d8 Add byteswapping macros for big-endian systems 2021-04-17 21:43:13 -05:00
Cameron Gutman 98d7ceecf7 Add native MbedTLS crypto backend 2021-04-17 19:00:26 -05:00
Cameron Gutman d62ee951a0 Refactor OpenSSL usage into a platform-specific file to allow other crypto backends 2021-04-17 17:47:53 -05:00
Cameron Gutman 83431e557d Fix leak on each GFE 3.22 input packet 2021-04-09 13:47:00 -05:00