Bug 469299

Summary: Compositing does not disable for full-screen games on Wayland
Product: [Plasma] kwin Reporter: adr.fantini
Component: compositingAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED INTENTIONAL    
Severity: normal CC: kde
Priority: NOR    
Version First Reported In: 5.27.4   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description adr.fantini 2023-05-03 08:33:03 UTC
# SUMMARY
I just performed a new install from scratch on a new system, using Wayland.

When I started playing games, I noticed that compositing and desktop effects were not automatically disabled during the game, as was the case in my previous system (same KDE version, but on Xorg + Nvidia). This makes gaming on KDE+Wayland very unpleasant, since things like screen edges and desktop effects are still active.

This is linked to the fact that the configuration option "Allow applications to block compositing" is missing on Wayland.
My old and new compositor settings can be seen here: https://www.reddit.com/r/kde/comments/135z1bz/

# STEPS TO REPRODUCE
1. Fresh KDE install
2. Setup screen edges effects (e.g. show desktop in a corner)
3. Open a fullscreen game which should block compositing and effects (this works in Xorg)
4. See that effects are still active (e.g.: show desktop is still active)

# OBSERVED RESULT
On Wayland, compositing and effects are active during full-screen gaming, even if the game provides an hint to disable compositing.
This interferes with gaming, introducing performance degradation and causing interruptions during the game.

Notifications also seem not to be blocked (again, this was not an issue on Xorg).

# EXPECTED RESULT
Compositing and effects are inactive and do not interfere during full-screen gaming, if the game provides a hint to disable compositing.

# SOFTWARE/OS VERSIONS
Operating System: Arch Linux
KDE Plasma Version: 5.27.4
KDE Frameworks Version: 5.105.0
Qt Version: 5.15.9
Kernel Version: 6.2.13-arch1-1 (64-bit)
Graphics Platform: Wayland
ADDITIONAL INFORMATION

Output of `qdbus org.kde.KWin /KWin org.kde.KWin.supportInformation`: https://pastebin.com/P1CwVEAA
Comment 1 David Edmundson 2023-05-03 09:10:56 UTC
We no longer need to disable compositing for performance. We have direct scan-out which is even faster.

The impact of screen edges is open as another bug somewhere. But disabling compositing is not part of this
Comment 2 adr.fantini 2023-05-03 09:15:22 UTC
(In reply to David Edmundson from comment #1)
> We no longer need to disable compositing for performance. We have direct
> scan-out which is even faster.
> 
> The impact of screen edges is open as another bug somewhere. But disabling
> compositing is not part of this

Got it, thank you. This one, maybe?
https://bugs.kde.org/show_bug.cgi?id=441464