Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(input): Removed batching of move events of PEN_PACKET #3477

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

aceradryd
Copy link

@aceradryd aceradryd commented Dec 22, 2024

Description

The changes ensure that move events from pens are no longer batched.
This is necessary when Sunshine is used to work with graphics programs.

Issues Fixed

moonlight-stream/moonlight-android#1427

Associated pull requests

moonlight-stream/moonlight-common-c#99

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Dependency update (updates to dependencies)
  • Documentation update (changes to documentation)
  • Repository update (changes to repository files, e.g. .github/...)

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated the in code docstring/documentation-blocks for new or existing methods/components

@aceradryd aceradryd changed the title Removed batching of move events of PEN_PACKET fix(input): Removed batching of move events of PEN_PACKET Dec 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot wasn't able to review any files in this pull request.

Files not reviewed (1)
  • src/input.cpp: Language not supported
@cgutman
Copy link
Collaborator

cgutman commented Dec 31, 2024

When I was testing the the pen support on Windows during initial implementation, I encountered some cases where injecting pen input would take a non-trivial amount of time per event and lead to a massive backlog of input events that caused input latency. Unfortunately, it's not always easy to reproduce (perhaps it depends on the window message processing latency of the focused application). We should probably have some batching to ensure we aren't sending pen events at a completely insane rate that the OS can't keep up with.

@Douvahkiin
Copy link

Douvahkiin commented Jan 2, 2025

@cgutman Is it possible to make it an option? Users can choose whether to have batching or not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants