Allow simultaneous controller, mouse, and keyboard input during streaming#143
Open
Jayian1890 wants to merge 22 commits intoOpenCloudGaming:devfrom
Open
Allow simultaneous controller, mouse, and keyboard input during streaming#143Jayian1890 wants to merge 22 commits intoOpenCloudGaming:devfrom
Jayian1890 wants to merge 22 commits intoOpenCloudGaming:devfrom
Conversation
…s, and update pointer lock handling
…rmat subscription info
…nd management in StreamView
…djust related functionality
- Introduced `requestKeyframe` method in GfnSignalingClient to send keyframe requests with reason, backlog frames, and attempt count. - Added IPC handler for keyframe requests in the main process. - Updated preload API to include `requestKeyframe` method. - Enhanced StreamView component to manage sidebar tabs for preferences and shortcuts. - Implemented decoder pressure detection and recovery mechanisms in GfnWebRtcClient, including bitrate reduction and keyframe requests. - Updated diagnostics to track decoder pressure state and recovery attempts. - Styled sidebar tabs for better user experience.
…hot shortcut error handling
- Introduced new settings for recording shortcuts in settings.ts and App.tsx. - Implemented recording API methods in preload/index.ts for starting, stopping, and managing recordings. - Enhanced StreamView component to handle recording state, display recording controls, and show recordings in a sidebar. - Added CSS styles for recording indicators and recording cards in styles.css. - Updated IPC channels in ipc.ts to support recording operations. - Defined new types for recording requests and entries in gfn.ts.
…ming Remove exclusive input mode switching that prevented concurrent use of different input methods. Previously, when a controller was active, mouse and keyboard input would be suppressed, and vice versa. Changes: - Remove activeInputMode property and mode switching logic - Remove input mode checks from mouse/keyboard event handlers - Modify gamepad keepalive to work continuously instead of mode-dependent - Allow all input types (controller, mouse, keyboard) to work simultaneously This enables users to use controllers for gameplay while still having access to mouse/keyboard for UI navigation and other inputs.
feat(streamview-sidebar): add streamview sidebar
feat(stream-recording): add stream recording support
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
When a controller was connected and in use during a stream, mouse and keyboard input would be locked out (suppressed). Similarly, controller input would be blocked when mouse/keyboard was active. This made it impossible to use multiple input methods simultaneously.
Root Cause
The
GfnWebRtcClienthad an exclusiveactiveInputModeproperty that toggled between"mkb"(mouse+keyboard) and"gamepad"modes. When mode switched to"gamepad", all keyboard, mouse movement, mouse button, and mouse wheel events were silently dropped. A 3-second lockout (GAMEPAD_MODE_LOCKOUT_MS) prevented switching back to"mkb"even after putting down the controller.Solution
Remove the exclusive input mode switching system entirely and allow all input types to operate concurrently:
activeInputModeproperty andGAMEPAD_MODE_LOCKOUT_MSconstantensureKeyboardInputMode()methodonKeyDown,onKeyUp,onMouseDown,onMouseUp,onWheel,queueMouseMovement, and the mouse flush timer"gamepad"mode)Result
All input methods — controller, mouse, and keyboard — now work simultaneously during active streaming sessions.