Wayland clients never receive wl_touch.frame, so Qt ignores all touch input
Is there an existing issue for this?
- [x] I have searched the existing issues
Are you using any gamescope patches or a forked version of gamescope?
- [x] The issue occurs on upstream gamescope without any modifications
(Observed with the gamescope package SteamOS ships on the Steam Frame; the missing call is also absent from src/wlserver.cpp on upstream master, see below.)
Current Behavior
When a client is connected to gamescope's own Wayland socket (WAYLAND_DISPLAY=gamescope-0) and gamescope delivers touch input, it sends wl_touch.down, wl_touch.motion and wl_touch.up but never wl_touch.frame. The protocol requires a frame event to terminate each group of touch events, and Qt's Wayland platform plugin only processes touch points when the frame arrives. The result is that taps do nothing in Qt apps.
On the Steam Frame this is how VR controller trigger "clicks" on a flat window are delivered, so a Qt app on the gamescope Wayland socket renders fine but cannot be clicked at all.
Expected: After each batch of touch events gamescope calls wlr_seat_touch_notify_frame( wlserver.wlr.seat ), so clients receive wl_touch.frame.
Impact: Qt apps (and any toolkit that follows the protocol and waits for the frame) cannot be operated by touch on gamescope's Wayland socket. On SteamOS this blocks running Qt flatpaks natively on Wayland in Game Mode, which would otherwise avoid X11-only rendering problems (see https://github.com/ValveSoftware/SteamOS/issues/3074).
Steps To Reproduce
- In a gamescope session with touch input, start a Qt 6 app with
WAYLAND_DISPLAY=gamescope-0 QT_QPA_PLATFORM=wayland WAYLAND_DEBUG=client. - Tap inside the window.
- The trace shows
wl_touch.down/upwith nowl_touch.frame, and the app does not react to the tap.
Hardware information
- Distro: SteamOS 0.5.8 (build 20261106.6144341, variant
vr), Steam Frame - CPU: Qualcomm SM8650 (aarch64)
- GPU: Adreno 750
- Driver Version: Mesa 26.3.0-devel (turnip / zink)
Software information
- Desktop environment: gamescope-session (Steam Game Mode)
- Session type: x11 (
XDG_SESSION_TYPEin the session); the affected client connects to gamescope's Wayland socketgamescope-0 - Gamescope version: gamescope version 3.16.30 (gcc 15.2.1), package 3.16.30-4
- Gamescope launch command(s):
gamescope --allow-deferred-backend --backend openvr --default-touch-mode 4 ...(started by the SteamOS session)
Which gamescope backends have the issue you are reporting?
- [ ] Wayland (default for nested gamescope)
- [ ] DRM (default for embedded gamescope, i.e. gamescope-session)
- [ ] SDL
- [x] OpenVR
Logging, screenshots, or anything else
Client: Jellyfin Desktop 2.0.0 flatpak (Qt 6.11, QT_QPA_PLATFORM=wayland). Input: VR controller trigger on the app's window, which gamescope delivers as touch.
WAYLAND_DEBUG=client trace of the app while tapping its window 21 times. Event counts for the seat's touch and pointer objects:
21 wl_touch#12.down
309 wl_touch#12.motion
21 wl_touch#12.up
3785 wl_pointer#11.frame
3424 wl_pointer#11.motion
There is no wl_touch.frame line at all in the trace.
Excerpt around one tap. Each touch event is followed by a wl_pointer.frame instead of a wl_touch.frame:
[3709041.920] wl_pointer#11.motion(53927, 889.69531250, 207.52343750)
[3709042.005] wl_pointer#11.frame()
[3709052.577] wl_touch#12.down(2066, 53928, wl_surface#17, 0, 889.69531250, 207.52343750)
[3709052.743] wl_touch#12.motion(53929, 0, 889.69531250, 207.52343750)
[3709052.759] wl_pointer#11.frame()
[3709063.982] wl_touch#12.motion(53930, 0, 889.69531250, 207.52343750)
[3709064.007] wl_pointer#11.frame()
...
[3709219.378] wl_touch#12.up(2067, 53944, 0)
The seat advertises capabilities(7) (pointer, keyboard, touch) and the client binds wl_touch.
This matches the source. In src/wlserver.cpp on current master, wlserver_touchdown(), wlserver_touchmotion() and wlserver_touchup() call wlr_seat_touch_notify_down/motion/up() and then wlr_seat_pointer_notify_frame(). There is no call to wlr_seat_touch_notify_frame() anywhere in the file.