Summary: | Animation cache not updated correctly | ||
---|---|---|---|
Product: | [Applications] krita | Reporter: | David Garcia <thedahu.dragon> |
Component: | Animation | Assignee: | Eoin O'Neill <eoinoneill1991> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | ahab.greybeard, eoinoneill1991 |
Priority: | NOR | Keywords: | regression |
Version: | 5.0.0-beta2 | ||
Target Milestone: | --- | ||
Platform: | Microsoft Windows | ||
OS: | Microsoft Windows | ||
Latest Commit: | https://invent.kde.org/graphics/krita/commit/f7bd2832f3414f4222f1f0e8812dbf8919b4579b | Version Fixed In: | |
Sentry Crash Report: | |||
Attachments: | Animation cache not refresh/updated demonstration |
I can confirm this for the Nov 10 5.1.0-prealpha (git 17a3a4c) appimage on Debian 10. It does not happen with the 4.4.8 appimage. The second/middle frame content is removed from the cache and does not appear anywhere when moving the timeline cursor manually at the top of the Timeline docker. When the cursor is first moved forward, past the new second frame position, the contents of the second frame are displayed as they used to be. After the cursor is moved back before the new second frame position, the second frame is not displayed anywhere. However, if the timeline cursor is manually scrubbed over the range a few times, the correct content appears. Also, selecting the frame by clicking on it makes the correct content appear. Git commit 014f33b517fe4b8b83e518dbd7445bf1e9cf7e4c by Eoin O'Neill. Committed on 11/11/2021 at 03:51. Pushed by eoinoneill into branch 'master'. Fix caching bug when scrubbing from cached to uncached frame. An optimization to prevent unnecessary refreshes was causing a regression. Since scrubbing on cached frames doesn't trigger a time change, but uncached frames do, an optimization where we check if the last frame and the current frame exist within the same "timeframe" would lock users out from seeing the uncached frames properly when scrubbing. We now force at least one time switch call when switching from uncached to cached frames to prevent this issue. Now, it will properly recognize that the last frame and the 'current frame' are different and refresh their contents. M +23 -6 plugins/dockers/animation/KisTimeBasedItemModel.cpp M +1 -0 plugins/dockers/animation/KisTimeBasedItemModel.h https://invent.kde.org/graphics/krita/commit/014f33b517fe4b8b83e518dbd7445bf1e9cf7e4c Git commit f7bd2832f3414f4222f1f0e8812dbf8919b4579b by Eoin O'Neill. Committed on 11/11/2021 at 03:58. Pushed by eoinoneill into branch 'krita/5.0'. Fix caching bug when scrubbing from cached to uncached frame. An optimization to prevent unnecessary refreshes was causing a regression. Since scrubbing on cached frames doesn't trigger a time change, but uncached frames do, an optimization where we check if the last frame and the current frame exist within the same "timeframe" would lock users out from seeing the uncached frames properly when scrubbing. We now force at least one time switch call when switching from uncached to cached frames to prevent this issue. Now, it will properly recognize that the last frame and the 'current frame' are different and refresh their contents. (cherry picked from commit 014f33b517fe4b8b83e518dbd7445bf1e9cf7e4c) M +23 -6 plugins/dockers/animation/KisTimeBasedItemModel.cpp M +1 -0 plugins/dockers/animation/KisTimeBasedItemModel.h https://invent.kde.org/graphics/krita/commit/f7bd2832f3414f4222f1f0e8812dbf8919b4579b |
Created attachment 143400 [details] Animation cache not refresh/updated demonstration SUMMARY The animation cache is sometimes not updated when moving a frame, then moving the timeline cursor with the mouse: The canvas is not update/refresh and it can cause weird effect when painting on it (well, it updates only a "brush size" rectangle on the canvas, have a look on the video attached). STEPS TO REPRODUCE 1. Create three spaced frames on timeline (should be same layer) 2. Make sure the middle frame looks different from the two other to highlight the bug 3. Move the middle frame on the timeline 4. Move the timeline cursor with your mouse and stop between the second and last frame OBSERVED RESULT The canvas is not updated and shows the first frame, painting on it refresh only where we paint. EXPECTED RESULT The canvas shows the second frame content SOFTWARE/OS VERSIONS Windows: Windows 10.0.19042 Linux/KDE Plasma: Linux Mint 21