Bug 488714 - Interface flickering under Wayland with any OpenGL acceleration enabled
Summary: Interface flickering under Wayland with any OpenGL acceleration enabled
Status: CLOSED DOWNSTREAM
Alias: None
Product: krita
Classification: Applications
Component: OpenGL Canvas (show other bugs)
Version: 5.2.2
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-06-19 07:57 UTC by Loque
Modified: 2024-06-26 09:03 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Loque 2024-06-19 07:57:13 UTC
SUMMARY
When using Krita under Wayland the interface is flickering severely when interacting with an open canvas.

STEPS TO REPRODUCE
1. Start KDE Plasma 6 under Wayland
2. Enable OpenGL Acceleration
3. Move Cursor anywhere onto the Canvas and draw

OBSERVED RESULT
The interface around the Canvas is constantly flickering with every move you make inside the applications.

EXPECTED RESULT
Drawing on the canvas without flickering.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: endeavouros, 6.9.5-arch1-1 Kernel
(available in About System)
KDE Plasma Version: 6.0.5
KDE Frameworks Version: 6.3.0
Qt Version: 6.7.1

ADDITIONAL INFORMATION
GPU: NVIDIA GeForce RTX 3060 Ti/PCIe/SSE2
Nvidia Driver version: 550.90.07

Crosstesting has been made with PopOs on a system with a 3060 Mobile, Wayland enabled, no driver tweaks, there was no flickering.

The video in this post describes what the flickering looks like:
https://www.reddit.com/r/hyprland/comments/1cvpttm/krita_flickering/
Comment 1 Halla Rempt 2024-06-19 09:34:50 UTC
I cannot reproduce this on KDE Neon in a wayland session with the appimage. Please also check with the appimage.
Comment 2 Loque 2024-06-19 10:29:51 UTC
(In reply to Halla Rempt from comment #1)
> I cannot reproduce this on KDE Neon in a wayland session with the appimage.
> Please also check with the appimage.

Tested it in appimage, pacman and flatpak. The issue persists across the Krita versions. I'm on Plasma 6 on EndavourOS which is Arch-based though.
Comment 3 Halla Rempt 2024-06-19 12:09:41 UTC
That very much looks like an nvidia driver bug. I don't have access to systems with an nvidia card, though... Could switching to nouveau help?
Comment 4 Loque 2024-06-19 12:43:46 UTC
(In reply to Halla Rempt from comment #3)
> That very much looks like an nvidia driver bug. I don't have access to
> systems with an nvidia card, though... Could switching to nouveau help?

I've switched to nouveau but the framerate was terribly low, about 1 fps. Switched back to the prop. drivers. 
Good point, I might dig into options of the prop. driver though. Or maybe find out what is tweaked in endeavourOS that might have caused the issue
Comment 5 Loque 2024-06-19 12:49:42 UTC
(In reply to Loque from comment #4)
> (In reply to Halla Rempt from comment #3)
> > That very much looks like an nvidia driver bug. I don't have access to
> > systems with an nvidia card, though... Could switching to nouveau help?
> 
> I've switched to nouveau but the framerate was terribly low, about 1 fps.
> Switched back to the prop. drivers. 
> Good point, I might dig into options of the prop. driver though. Or maybe
> find out what is tweaked in endeavourOS that might have caused the issue

Small update: Open-dkms drivers run OK but also show the issue with Krita. I'll see what I can dig up further.
Comment 6 Halla Rempt 2024-06-19 12:56:02 UTC
Thanks for investigating!
Comment 7 Loque 2024-06-19 20:36:56 UTC
(In reply to Halla Rempt from comment #6)
> Thanks for investigating!

You're welcome, so I've done some research on it and it's most probably a problem with explicit sync.
Tested it on KDE Neon live boot which already has 6.1 while arch is on 6.0.5, on KDE Neon Krita worked pretty well (It seems to run at 30fps but I can live with that)
I think explicit sync is fully implemented only in 6.1 from what I've read on the web. Should this bug report be kept open until Plasma 6.1 for arch is out of testing and it can be confirmed it's caused by missing explicit sync? (I'm not going to use the testing repo which already has 6.1)
Comment 8 Bug Janitor Service 2024-06-20 03:47:18 UTC
Thanks for your comment!

Automatically switching the status of this bug to REPORTED so that the KDE team
knows that the bug is ready to get confirmed.

In the future you may also do this yourself when providing needed information.
Comment 9 Halla Rempt 2024-06-26 08:55:37 UTC
I think we can close it; it's not something we can fix in Krita.
Comment 10 Loque 2024-06-26 09:03:41 UTC
(In reply to Halla Rempt from comment #9)
> I think we can close it; it's not something we can fix in Krita.

Yes, I think so as well. Tested it under vanilla arch, it wasn't flickering with the nouveau driver plasma 6 is shipped with and performance was okay. Under EOS there was probably some driver blacklisting I've missed to remove to make nouveau work but I digress. So yeah I think it's not caused by Krita itself but rather by the proprietary driver, I'm closing it.