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

Input from Ipad and Android is wrong #3409

Open
2 tasks done
lublak opened this issue Nov 18, 2024 · 2 comments
Open
2 tasks done

Input from Ipad and Android is wrong #3409

lublak opened this issue Nov 18, 2024 · 2 comments

Comments

@lublak
Copy link

lublak commented Nov 18, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Is your issue described in the documentation?

  • I have read the documentation

Is your issue present in the latest beta/pre-release?

This issue is present in the latest pre-release

Describe the Bug

I use the Touchscreen Input Mode (not the Trackpad mode)
The Trackpad Mode works fine.

I have 3 Monitors
grafik

First of all:
The input is always on the "left" monitor. The Mirroring is set to the monitor in the center.
But there is more than one issue:
If i touch on the right side of my Ipad/Android it shows goes to the centered monitor (can it comes from the 125% scaling in kde, but if i set it to 100% the right side of my Ipad/Android is also not the right side of the monitor, its like at 90% of the width of the monitor)
If I see in the logs: logical size width is off.
The last Issue i: The pen input is ony 30% of the screen width.
(height works fine on screen input and pen input)

Expected Behavior

Input should be on the screen based on the Display Number:
grafik
If the monitor is upscaled (here 125%) it should be calculated correctly (also manual setting would be fine).
The Pen Input is completely of, currently i don't really know where the issue is.
I just noticed that the mouse is also flickering around. Maybe they are interfering with each other? Precisely because the position is not right?

Additional Context

No response

Host Operating System

Linux

Operating System Version

EndeavourOS

Architecture

amd64/x86_64

Sunshine commit or version

v2024.1115.143556

Package

Linux - LizardByte/pacman-repo

GPU Type

Nvidia

GPU Model

RTX $090

GPU Driver/Mesa Version

565.57.01

Capture Method

KMX (Linux)

Config

output_name = 1

Apps

{
  "env": {
    "PATH": "$(PATH):$(HOME)/.local/bin"
  },
  "apps": [
    {
      "name": "Desktop",
      "image-path": "desktop.png"
    },
    {
      "name": "Low Res Desktop",
      "image-path": "desktop.png",
      "prep-cmd": [
        {
          "do": "xrandr --output HDMI-1 --mode 1920x1080",
          "undo": "xrandr --output HDMI-1 --mode 1920x1200"
        }
      ]
    },
    {
      "name": "Steam Big Picture",
      "detached": [
        "setsid steam steam://open/bigpicture"
      ],
      "image-path": "steam.png"
    }
  ]
}

Relevant log output

Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.871]: Info: Found H.264 encoder: h264_nvenc [nvenc]
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.871]: Info: Found HEVC encoder: hevc_nvenc [nvenc]
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.871]: Info: Found AV1 encoder: av1_nvenc [nvenc]
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.937]: Info: New streaming session started [active sessions: 1]
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.960]: Info: CLIENT CONNECTED
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.961]: Info: /dev/dri/card0 -> nvidia-drm
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.961]: Info: /dev/dri/card1 -> i915
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.961]: Info: Found display [wayland-0]
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Found interface: zxdg_output_manager_v1(31) version 3
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Found interface: wl_output(67) version 4
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Found interface: wl_output(68) version 4
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Found interface: wl_output(69) version 4
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Resolution: 2560x1440
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Resolution: 2560x1440
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Resolution: 2560x1440
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Offset: 4096x0
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Logical size: 2048x1152
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Name: HDMI-A-1
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Found monitor: Microstep MAG274QRF-QD/CA8A281600323
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Offset: 0x0
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Logical size: 2048x1152
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Name: DP-3
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Found monitor: Microstep MAG274QRF-QD/CA8A281600327
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Offset: 2048x0
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Logical size: 2048x1152
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Name: DP-2
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Found monitor: Microstep MAG274QRF-QD/CA8A281600309
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: -------- Start of KMS monitor list --------
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Monitor 0 is HDMI-A-1: Microstep MAG274QRF-QD/CA8A281600323
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Monitor 2 is DP-3: Microstep MAG274QRF-QD/CA8A281600327
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Monitor 1 is DP-2: Microstep MAG274QRF-QD/CA8A281600309
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: --------- End of KMS monitor list ---------
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Screencasting with KMS
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: /dev/dri/card0 -> nvidia-drm
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Found monitor for DRM screencasting
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Found connector ID [110]
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Found cursor plane [66]
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Creating encoder [hevc_nvenc]
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Color coding: SDR (Rec. 601)
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Color depth: 8-bit
Nov 18 23:51:49 system sunshine[8518]: [2024-11-18 23:51:49.965]: Info: Color range: MPEG
Nov 18 23:51:50 system sunshine[8518]: [2024-11-18 23:51:50.460]: Info: Found default monitor by name: alsa_output.pci-0000_00_1f.3.pro-output-3.monitor
Nov 18 23:51:50 system sunshine[8518]: [2024-11-18 23:51:50.475]: Info: Opus initialized: 48 kHz, 2 channels, 512 kbps (total), LOWDELAY
@LizardByte-bot
Copy link
Member

It seems this issue hasn't had any activity in the past 90 days. If it's still something you'd like addressed, please let us know by leaving a comment. Otherwise, to help keep our backlog tidy, we'll be closing this issue in 10 days. Thanks!

@DeadCowboy
Copy link

DeadCowboy commented Feb 18, 2025

Hello, I feel like I am having the same Issue. I have a dual 4K Monitor setup and have just tried streaming it to my android tablet for notetaking. I have the same effect where, when streaming the left screen, the mouseposition is about halfway of the position I am touching with the drawing pen. On the left most screen edge the positions match. When using touch, so using fingers, the condition is reversed, where the mouse extends about 10% more to the right than it should.
Changing screen resolution on either the host or client, including matching resolution, had no impact for me.

I found this to be caused by the multiple monitors. When disabling all but one monitor before starting the stream, the issue is fixed and everything works fine. Sunshine seem to compute touchscreen positions relative to the entire available screen area on the host.
This idea is supported by the fact that (when disabling UI Scaling) the right most edge of my tablet brings the cursor to what very much looks like the middle of my screen. When using scaling it is about 2/3rds of the way, though not proportional. Using 200% scaling seems to create more or less the same offset as using 125%.

Temporary (sort of) fix:
When disabling one screen, starting a stream, and then within the stream re-enabling the other monitor the issue is fixed for pen input. The mouse the is positioned correctly on whatever monitor it was placed on. So when moving the cursor over with the mouse of the host machine, the peninput moves the mouse on the other screen that is not shared, but also correctly scaled. Touchinput is still offset and seems to not switch monitors when the mouse is moved over on the host machine. Alternatively disable all but one monitor.

Hope this sheds some light on the issue
Kind regards,
DC

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

No branches or pull requests

3 participants