Bug 478527 - Krita UI glitches under Wayland
Summary: Krita UI glitches under Wayland
Status: REPORTED
Alias: None
Product: krita
Classification: Applications
Component: OpenGL Canvas (show other bugs)
Version: 5.2.2
Platform: Flatpak Linux
: NOR major
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-12-14 22:34 UTC by Fonkle
Modified: 2024-04-26 22:51 UTC (History)
6 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Fonkle 2023-12-14 22:34:29 UTC
SUMMARY
***
NOTE: If you are reporting a crash, please try to attach a backtrace with debug symbols.
See https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***


STEPS TO REPRODUCE
1. Run Krita with Canvas Graphics Acceleration set to auto (OpenGL) under Wayland
2. Create a new document
3. Move the document around using MMB drag on the canvas (or SHIFT+MMB rotation or CTRL+MMB zoom)

OBSERVED RESULT
The UI outside of the canvas flickers heavily: some frames are correct and others are black.

I have uploaded a clip to Youtube showing the UI glitches:

https://www.youtube.com/watch?v=NdNfba-1m-0

EXPECTED RESULT
No flickering and no black frames.

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: Kubuntu 23.10 (with backports)
(available in About System)
KDE Plasma Version: 5.27.10
KDE Frameworks Version: 5.112.0
Qt Version: 5.15.10
Graphics Platform: Wayland
Graphics Processor: NVIDIA GeForce RTX4070 (proprietary driver 545.29.06 from PPA graphics-drivers)

ADDITIONAL INFORMATION
Comment 1 lakoisfun 2023-12-21 11:41:57 UTC
Experiencing the same issue as well. It's also on an NVIDIA GPU with Wayland.

Linux/KDE Plasma: Fedora Linux 39
KDE Plasma Version: KDE Plasma 5.27.9
KDE Frameworks Version: 5.111.0
Qt Version: QT 5.15.11
Graphics Platform: Wayland
Graphics Processor: NVIDIA GeForce GTX 1650 SUPER (545.29.06 from RPMFusion)
Comment 2 axipixel3 2023-12-23 04:51:56 UTC
I am experiencing the same issue with Krita 5.2.2 and Krita 5.1.5

There was a very similar issue last month https://bugs.kde.org/show_bug.cgi?id=477766
The past bug was able to be fixed by installing libnvidia-egl-wayland1.

I have found uninstalling this library fixes the issue for me, and the Krita UI works fine. Installing it again results in this bug again.
However, without this library most games fail to boot with the NVidia 545 driver, so this is unacceptable. 

Downgrading to the NVidia 535 driver also results in a fix to this issue. However, only the 545 driver properly supports VRR on my machine, so downgrading to 535 is unacceptable. This is likely acceptable to others experiencing this issue until a fix is found.

As far as I am aware, libnvidia-egl-wayland1 has had no changes made to its repos between this and the previous thread.

I was experiencing this issue on Plasma 5.27.8 and Framework 5.110.0, and upgraded to backports in attempt to fix it, and there was no change.

SOFTWARE/OS VERSIONS:
Linux/KDE Plasma: Kubuntu 23.10 (with backports)
KDE Plasma Version:  5.27.10
KDE Frameworks Version: 5.112.0
Qt Version: 5.15.10
Graphics platform: Wayland
Display driver: NVidia 545.29.06 (prop)
Graphics Processor: NVIDIA GeForce RTX3080Ti
Processor: Ryzen 5800X
Comment 3 Elias 2024-04-01 11:32:28 UTC
Same issue here, I'm sure it's Nvidia-Wayland related as I've had this exact problem with Kbuntu and Fedora on the 545 and 550 drivers. Not usually real important but with Wayland becoming the sole focus of more distros, this will quickly become a unusable app.
Fedora 39 Kde
Plasma 5.27.11
Frameworks 5.115.0
Qt 5.15.12
RTX 2080 550.67
Comment 4 chrismauro69 2024-04-11 00:45:59 UTC
Commenting to boost this. I just switched to Arch from Windows and thought I messed up my OS install until finding this thread. Hope it gets fixed soon.
Comment 5 Halla Rempt 2024-04-11 08:27:27 UTC
"Boosting" is not useful. Someone who uses Wayland needs to volunteer to fix this (and implement support for Wayland proper at all). We don't intend to work on this until the port to Qt6 has been finished.
Comment 6 lakoisfun 2024-04-11 10:14:44 UTC
I just want to add on that this is only appears to be an NVIDIA driver issue, as it works fine with the Nouveau driver. I also tested it on GNOME 46 with the same issues. Perhaps the recently merged Explicit Sync might have fixed the issue.
Comment 7 Rocco 2024-04-26 22:51:21 UTC
I'd like to share a workaround that worked for me with Wayland on NVIDIA 550.67:

I found that XWayland apps that use OpenGL acceleration have flickering or other graphical issues under Wayland+NVIDIA. For most of them (including Krita), the issues can be mitigated by running OpenGL over Vulkan with Zink:

__GLX_VENDOR_LIBRARY_NAME=mesa __EGL_VENDOR_LIBRARY_FILENAMES=/usr/share/glvnd/egl_vendor.d/50_mesa.json MESA_LOADER_DRIVER_OVERRIDE=zink GALLIUM_DRIVER=zink krita