Animation - Frame Cycles

Hello, I have looked around for information on this feature and while I have seen a few people discuss it, most of the responses to the suggestion have been concerningly negative if not ignored. I do feel like this would be a very useful and basic feature that helps greatly enhance the workflow of animation as there are situations where you would want to test repeating animation as a backdrop while a more complex animation happens in the foreground. This feature is seen in “RoughAnimator” for the Smartphone and I think I have an idea of how to build something like that into Krita.

I am a software engineer and have programming knowledge so I would be more than happy to volunteer to build the feature in myself, but would need to see how to pick up the project’s source and what the protocol is for creating feature branches (Blender has a similar document detailing how to pull the source code, develop a feature and set up a pull request).

As an artist, I see a lot of potential in this software that was formerly untapped, and as a software developer, I can’t stand the phrase “It can’t be done because it’s too complicated” without at least giving it a try. If there’s any direction I can be pointed, I’ll happily develop this feature myself for everyone.

The basic plan I have is creating a “Loop Frame” that copies the frame range and automatically duplicates them for the duration of the Loop frame. The frames will repeat until the loop frame terminates, and as I saw suggestions for, the order of the loop could be forward, reverse, or ping-pong. I can imagine it should be a matter of taking those frames in the array that stores the loop and copying them by referencing the position and repeating those layers on playback (so it acts more like a pointer to the array position).

I have seen that the codebase itself could make this difficult, but hopefully I can take a crack at it.

2 Likes

There’s already been work on clone and cycle frames. Last time I used it, it was too buggy to merge, but since then it has been ported to 4.3. It might be best to ask @emmetpdx what the state of affairs is here.

UPDATE: I found the location that may be what you’re referencing. I’m not entirely sure if what was done is what I am talking about, but it looks like it’s a good start (code that automatically duplicates keyframes, I guess it’s called “autokey”?). A method that clones the frames would be the foundation, but there just needs to be a UI that allows you to select the range of cloned frames and the repeat length. And the goal would be that when you update the “original” frames, the “cloned” frames are automatically updated. Still this is good I found the location. With @emmetpdx 's assistance and just clarification on what was done, I can fill in the blanks. My day job is a UX developer so building a UI for this shouldn’t be too difficult for me.

This is the branch you’re talking about right?


Ah thanks for the direction. Yes i would love to take a look at the branch and see what i can do to help. Good to know there is a start on it at least. I’ll look out for that branch and see what i can do to assist.

My concern was that there seems to be no documentation on how to do it and the UI doesn’t show any way to do it as of the latest version, but it could be that the UI hasn’t been updated to allow for it. Still I can only guess until @emmetpdx responds. Hopefully they can link me to the branch so I can look at the code, and the forum where we can discuss what’s up. This feature would be tremendously useful for many projects I am planning.

No, it’s this MR, but this MR is old. There’s a new branch for it somewhere, but that still has problems.

Autoframe mode is a workflow feature, it has nothing to do with repeating frames. Please carefully read the commit to understand what it does do.

Ah, forgive me. It’s not that I didn’t understand what the commit does as much as there were many branches to look through and I wanted to make sure I was looking at the correct branch (though in retrospect, I should’ve spent more time looking at the MRs. I just woke up to your response. I’m sorry). I can see Auto framing creates new keys when you draw on a blank frame (which is useful in its own right as it allows you to skip having to manually create new keyframes), but I guess I was getting a bit excited there.

Still I appreciate the link. I’ll look through this code and see if there’s anything I can do. I appreciate the direction.

It looks like the issue seems to primarily be how the code is organized and a discussion on ways to make it more consistent. This was discussed a month ago and the most recent commit was last October. I’ll post a message on the commit asking what the status of development is for this branch. I’ll be happy to pick it up and do what needs to be done to get it merged in and make sure I fully understand what’s holding it back at the moment.