Call for testing from Artists - Krita's stroke and cursor lag.

@dkazakov has made some changes to Krita’s openGL canvas portion such that the canvas updates in patches when a portion of a canvas changes. It should increase rendering speed, especially on 4K displays. The main effect of the change is reducing the lag between the brush outline and hardware cursor when hovering over the canvas.

Example demonstrating the lag

You can see that the cursor is ahead of the actual stroke that is appearing on the canvas.

See this bug for more details: https://bugs.kde.org/show_bug.cgi?id=413504

Testing Packages

Test Plan

  1. Test speed:
    1. Activate both, brush outline and hardware cursor in Krita settings.
    2. Compare the lag between hardware cursor and brush outline when hovering the stylus over the canvas without painting with Krita 4.3.0.
    3. Compare the same lag when painting. Preferably using some brush with complex outline and “drawing angle” sensor active.
  2. Shape Selection Tool
    1. Manipulating shapes on the canvas should not leave any traces of handles and decorations on the canvas
    2. Don’t forget about extra actions available via Tool Options docker!
    3. Undo/Redo of actions should update decorations correctly and should not generate any artifacts
    4. Test snapping (use Shift+S to activate it)
  3. Bezier Path Tool
    1. Creating a path in any mode (dragging, Alt and Shift modifier) should not generate any artifacts
    2. It should be possible to start/end(?) a path on an existing path.
    3. Test snapping (use Shift+S to activate it)
  4. Path Editing Tool
    1. Manipulating shapes on the canvas should not leave any traces of handles and decorations on the canvas
    2. Don’t forget about extra actions available via Tool Options docker!
    3. Undo/Redo of actions should update decorations correctly and should not generate any artifacts
    4. Test snapping (use Shift+S to activate it)
  5. Test manipulating reference images

Our community members are requested to test this and let us know if there is improvement or if there is any observation.

4 Likes

Can i help if i don’t have a 4k device?

Yes if you have a device with resolution bigger than 1080p it would be okay. Generally test it everywhere. the lag is much noticeable on bigger resolution that is all.

1 Like

And any Mac user should try the dmg build because it might help with performance on macOS with canvas acceleration enabled.

:upside_down_face:

after a quick test: it seems I’m not very affected by the lag as I do have a similar result and I don’t feel it’s a problem. The thing that is obvious though is the segmented lines. I wished they would have gone in this version but doesn’t seem so.

1 Like

Windows 10, Wacom Cintiq 13HD 1920 x 1080

1 - Everything went smoothly!
I also tried this one on my 2560 x 1440 monitor, and it performed just as good!

2 - Everything went smoothly!

3 -

  1. No artifacts
  2. Worked correctly
  3. Works, but can’t make a new point that snaps to a guide without selecting and moving the guide

4 - Went good
There was one visual weirdness one time, but I can’t seem to recreate it. Where the red pointy dot was far from the mouse when snapping

I also noticed this on step 3 and 4 of the test plan:
Snapping works, but if Pixel snap is enabled, that overwrites most other snapping. For instance, I can’t snap to guides when I have pixel snapping on. This might be intentional, but it feels a tad weird.

5 - Mostly works, but in the Tool Options the Opacity and Saturation did not update when undoing and redoing. Deselecting and selecting the image will show the correct numbers on the sliders

I can see any difference :open_mouth: so i don’t know how to say.
I read the thread and following steps, and i get stuck in the first point. I can record a video if you think this would be helpful. :thinking:

is there any plan to optimize the zoom performance? because the brush work smooth enough, but when I zoom canvas I can feel the lag and stick.

1 Like

Hi, @K-Pax!

Most probably you have a Canvas Graphics Accelerations disabled. Go to Preferences->Display and enable it.

no,i have choice opengl or d3d.and enable canvas acceleration. sometimes opengl work better than
d3d, but still feel the lag.

That seem to be something local on your system, I have no lags when zooming.

You can try to make a screen recording of the lag so I could understand that better, but please make a separate thread for it.

ok,sure. Thanks

I just tested it on my computer at 4K and didn’t notice any significant improvement, the brush lag and reference performance appear to be the same or very similar.

Windows 10
R7 2700X
Vega 64

I compared this version to krita-5.0.0-prealpha-d239357 (can’t run 4.3)
and the lag is just as bad except the brush strokes are producing weird artifacts:
krita_screen

4K monitor
geforce 1080
Kubuntu 20.04

can you double-check if your graphics acceleration is turned on in the settings? It can turn off when Krita crashes due to opengl crashing, and that cursor looks like the non-graphics accelerated version…

Yes, CGA is enabled.

With it off the lag that I can notice manifests as the brush cursor faithfully following the stroke I made, which is much preferable to CGA on, as when it lags it randomly cuts corners and the cursor jumps from place to place.

Another issue I noticed in all the 4.4.0 versions, when I try to scale image to new size or resize canvas the window doesn’t show, Krita just turns darker and I have to press Esc to cancel the adjustment. When I point to the ‘screen edge’ the scale settings window appears among the rest of running apps, but I can’t get it to show active on the screen.

Hi, @Rakurri!

Thank you for extensive testing! The red dot is indeed a bug in the snapping algorithm (they appear with some offset to the target destination), but that is also a problem in 4.3.0. I’ll make a report.

UPD: I’ve added a report https://bugs.kde.org/show_bug.cgi?id=426514

1 Like

Hi, @half!

Can you please confirm two things:

  1. Do these artifacts on the canvas disappear when you hover over them with the mouse/stylus without painting? Or them disappear only after you paint over them?
  2. Do you have Instant Preview enabled?

UPD:
3) What display scaling value you have set for your display?

Hi @dkazakov

Tried to upload screen recording, but couldn’t as a new user.

Those artifacts tend to disappear on their own after couple of seconds.

Instant Preview on or off doesn’t seem to make noticeable difference in performance nor probably in the frequency artifacts get produced. Also the size of the canvas doesn’t seem to affect performance, at least up to 6000x5000 I haven’t noticed change in performance.

If you mean Global scale under Display Configuration, its set to 125%. I did play with it and didn’t notice difference in Krita’s performance.