Bug 427628 - Black window flashes after restarting compositing
Summary: Black window flashes after restarting compositing
Status: RESOLVED UNMAINTAINED
Alias: None
Product: kwin
Classification: Plasma
Component: compositing (show other bugs)
Version: 5.18.5
Platform: Kubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-10-13 10:34 UTC by Lastique
Modified: 2023-09-06 10:38 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
KWin config file (~/.config/kwinrc) (3.71 KB, text/plain)
2020-10-13 10:34 UTC, Lastique
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lastique 2020-10-13 10:34:32 UTC
Created attachment 132317 [details]
KWin config file (~/.config/kwinrc)

SUMMARY

After restarting compositing in KWin (for example, due to a Nvidia driver crash or via a hotkey or VT switch), contents of some windows begin flashing black upon certain activities. For example, when "Open/Save File" dialog window opens, Firefox window in the background momentarily turns black and then back to normal.

This is not tied to any particular applications or GUI toolkits. I've seen black flashes with both GTK and Qt applications. This is also not reliably reproducible and may not show right away after restarting compositing.

STEPS TO REPRODUCE

1. Restart KWin compositing.
2. Try interacting with desktop, like open or close windows, resize windows, etc.

OBSERVED RESULT

Some windows begin flashing black.

EXPECTED RESULT

No black flashing is expected.

SOFTWARE/OS VERSIONS
Linux: Kubuntu 20.04 x86_64, X11
KDE Plasma Version: 5.18.5
KDE Frameworks Version: 5.68.0
Qt Version: 5.12.8
Nvidia driver: 455.26.1 (also reproducible with other versions)

ADDITIONAL INFORMATION

In my /etc/environment I have:

KWIN_TRIPLE_BUFFER=1
KWIN_USE_BUFFER_AGE=0
KWIN_PERSISTENT_VBO=1
__GL_YIELD="USLEEP"
__GL_SYNC_TO_VBLANK=1

KWin is started with the command line `__GL_THREADED_OPTIMIZATIONS=0 kwin_x11 "$@"`. The __GL_THREADED_OPTIMIZATIONS env variable has no effect on the issue, it is just used to reduce CPU consumption by kwin_x11.

The usual workaround is to restart KWin by running `kwin_x11 --replace` from krunner.
Comment 1 David Edmundson 2023-09-06 10:38:44 UTC
This bug was reported against an outdated version of KWin. We have made many changes since the. 
If the issue persists in newer versions can you reopen the bug report updating the version number.