Bug 430572

Summary: Krita is unuseable when airplay is active
Product: [Applications] krita Reporter: Manga Tengu <mangatengu>
Component: OpenGL CanvasAssignee: Krita Bugs <krita-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: ghevan, halla
Priority: NOR    
Version: 4.4.1   
Target Milestone: ---   
Platform: macOS (DMG)   
OS: macOS   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Manga Tengu 2020-12-19 10:44:57 UTC
SUMMARY
I airplay youtube on a 4k tv. At the same time, I try to draw on my macbook's screen. It makes the segmented lines issue so bad that medium sized circles are simplified into 4 sides polygons to give you a rough idea.
Krita has something to do with it because if you get a trial photoshop (or even a paid one you cancel within 7 days) you will have a very smooth experience (except the horrible, nearly impossible to customize shortcuts).
I hope this hints at something about the segmented lines problem that has yet to be solved.

STEPS TO REPRODUCE
1. Launch krita on a macOS cputer.
2. Airplay a youtube video (one of mine if you want :D) on a 4k tv
3. try to use krita

OBSERVED RESULT
the soft is really unuseavle

EXPECTED RESULT
Something smooth as usual, as I said I tested with other software without a problem.

SOFTWARE/OS VERSIONS
macOS: big sur

ADDITIONAL INFORMATION
it rains here
Comment 1 Manga Tengu 2020-12-19 11:02:26 UTC
krita keeps lagging after turning off airplay until I close and restart it.
Comment 2 Halla Rempt 2020-12-19 11:28:59 UTC
I guess the problem also goes away if you disable canvas acceleration in Krita? I would think that it's just the mac that's running out of GPU oomph -- and Photoshop these days disables their opengl acceleration on macOS since macOS support for opengl is so bad.

I cannot test it in any case since while I do have two macs I don't have a tv, let alone a 4k tv.
Comment 3 Manga Tengu 2020-12-19 11:45:30 UTC
spot on.
Interestingly disabling OpenGL acceleration only solves the segmentation due to airplay's enabling. It doesn't solve the usual curve segmentation. So maybe it's not due to openGL but something different
Comment 4 Bug Janitor Service 2020-12-20 04:34:38 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 5 vanyossi 2020-12-21 17:26:12 UTC
The first case is exactly as halla said. Current openGL rendering on macos is intense and we loose some tablet events due to that.

However, Do you get segmentation without openGL canvas rendering?? and wnat mac hardware are you testing this on?
Comment 6 Manga Tengu 2020-12-21 18:11:26 UTC
Yes, I do get the usual segmentation with openGL disabled.
Working on a MacBook pro 2018 15'
Comment 7 Bug Janitor Service 2020-12-22 04:35:04 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 8 Halla Rempt 2022-04-07 09:16:15 UTC
Is this issue still present with Krita 5 with the macos opengl workaround?
Comment 9 Manga Tengu 2022-04-07 09:50:40 UTC
I need to try again. Also now I also have the new m1 blabla laptop so I'll try it with both and come back to you.
Comment 10 Bug Janitor Service 2022-04-08 04:35:00 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 11 Halla Rempt 2022-05-10 13:36:09 UTC
Setting to needinfo
Comment 12 vanyossi 2022-05-20 23:48:34 UTC
This was an issue in krita before the openGL optimization patch. The problem is in that your are sending processing a 4k feed before sending it through airplay causing the bottle neck and due to our non optimized code, the choppy lines.

Tested on krita 4.4.1
airplay from mbp 13 intel early 2015 -> M1,  slight performance decrease painting barely affected 
airplay from mbp 13 intel early 2015 -> 4k TV,  performance hit, no painting possible, no chopy feed (this intel chip might not be able to process 4k)

The same tests on krita 5.0.6 did not affect painting much even when outputing a 4k feed. some performace is lost but this is system wide.
The same tests from the M1 to the 4KTV did not affect painting and 4k feed was smooth.

Im marking this bug as fixed