tildearrow / kwin-lowlatency

archived - X11 full-screen unredirection and lots'a settings for KWin
373 stars 10 forks source link

Disabling composition for full-screen applications #110

Open es20490446e opened 3 years ago

es20490446e commented 3 years ago

I figured out another way of disabling composition for full-screen applications.

The trick is simple: instantly disabling composition on full screen, and if the full-screen application loses focus just waiting 10 seconds before re-enabling composition. That prevents 95% of glitches.

Better than that: no need to constantly poll the current window to see if it is full-screen, wasting computer resources. It only checks full-screen status on a window change.

Here you have the algorithms, in case you find that useful.

es20490446e commented 3 years ago

By the way I have figured out an even better algorithm to do this. Now:

The trick was simple: only re-test for full-screen if the last known full-screen window is no longer full-screen.

Everything is done in memory for maximum performance, and only iterated on window focus change.

es20490446e commented 3 years ago

@tildearrow Ported to kwinscript on the KDE Store.

tildearrow commented 2 years ago

Full-screen unredirection now available with the latest KWin-lowlatency release I just pushed a bit ago.