godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
88.99k stars 20.18k forks source link

Editor splash screen is massive on Wayland compared to X11 #87749

Open Calinou opened 7 months ago

Calinou commented 7 months ago

Tested versions

System information

Godot v4.3.dev (cae759949) - Fedora Linux 39 (KDE Plasma) - Wayland - GLES3 (Compatibility) - NVIDIA GeForce RTX 4090 (nvidia; 545.29.06) - 13th Gen Intel(R) Core(TM) i9-13900K (32 Threads)

Issue description

The splash screen is rescaled to match the window size, which makes it look massive on a 4K display:

Screenshot_20240130_185217

This doesn't occur on X11 where the splash screen remains pixel-perfect. My Wayland display scale is 100%, and so is the editor scale.

Ideally, we should scale the splash screen according to the OS scale factor (or the editor scale factor) on both X11 and Wayland.

Steps to reproduce

Use a Wayland session, enable the Prefer Wayland editor setting then restart the editor.

Minimal reproduction project (MRP)

N/A

Riteo commented 7 months ago

So, this is a fun one.

Basically, if the wp_viewport extension is available, it turns it on to allow for fractional scaling.

That has the fun (and intended) side effect of removing the explicit bond between buffers and windows, stretching the poor little splash to a full-screen window.

With the extension disabled/missing, you'd see the lil' buffer in a huge window.

IMO, the fix would be to properly (re?)render the splash on resize, somehow.

(BTW, there is a hack to force a proper window resize before rendering, but that wouldn't change the fact that a resize would squishy squash the buffer)