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

Editor sub-windows are slow to respond when displayed in "tabbed" mode in Sway (Wayland) #100611

Open
pk-tset opened this issue Dec 19, 2024 · 2 comments

Comments

@pk-tset
Copy link

pk-tset commented Dec 19, 2024

Tested versions

Experienced in v4.3.stable.arch_linux.

System information

Godot v4.3.stable unknown - Arch Linux #1 ZEN SMP PREEMPT_DYNAMIC Mon, 09 Dec 2024 14:30:31 +0000 - Wayland - Vulkan (Forward+) - integrated Intel(R) Iris(R) Xe Graphics (ADL GT2) - 12th Gen Intel(R) Core(TM) i5-1235U (12 Threads)

Issue description

Sub-windows - such as the "Create New Node" dialog - displayed in Sway's "tabbed" mode respond slowly. It's unclear whether this is a slow response to input (applying both for mouse input and keyboard input), or just a laggy interface in general resulting in high latency. The issue does not occur in "split" modes.

This video demonstrates both cases:
https://github.com/user-attachments/assets/73df318b-7311-4f8c-92db-63a9158d9778

Steps to reproduce

Open any sub-window in tabbed mode while using the Sway Wayland compositor. Attempt to make inputs. This can be performed in a fresh project.

Minimal reproduction project (MRP)

N/A

@Riteo
Copy link
Contributor

Riteo commented Dec 19, 2024

Hi, thank for your report!

You're using XWayland, an X11-to-Wayland compatibility layer, which is known to have various issues. See #78581.

I suppose that when the main window is occluded, it throttles its framerate to 1 FPS, which seems consistent with the lag you're seeing. You could confirm this by running the editor with --print-fps from the command line.

As a workaround you can enable single-window mode in the editor settings or enable the experimental native Wayland backend.

The editor setting for single window mode is located at interface/editor/single_window_mode while the Wayland setting is located at run/platforms/linuxbsd/prefer_wayland.

Note that the Wayland backend does not (yet, WIP) support multiple native windows and that this will not set the running game backend, as it has a separate entry in the project settings.

@pk-tset
Copy link
Author

pk-tset commented Dec 19, 2024

Ah, I see. I hadn't considered that XWayland might be in use here. Thank you for flagging that up!

Indeed, your hypothesis about the framerate throttling seems to be correct. It's 1 FPS when tabbed out of the main window, and returns to a normal framerate when tabbing back in (even if the sub-window is still open).

The workarounds do both work, although of course they don't provide the same tabbing behavior. It is better than having to press the shortcut to switch to tiling each time, at least, so that is an improvement.

Perhaps the framerate throttling is something that can be disabled/adjusted? I assume that is a Sway/Wayland/XWayland thing, rather than a Godot thing, so I'll do some research on my own to see if that is possible.

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

No branches or pull requests

2 participants