Rescaling Keyframes

General Moho topics.

Moderators: Víctor Paredes, Belgarath, slowtiger

Post Reply
User avatar
ZeroAbility
Posts: 27
Joined: Thu Mar 20, 2014 10:15 pm
Location: Dublin, Ireland

Rescaling Keyframes

Post by ZeroAbility »

I stupidly set up a project at 12fps and need to change it to 30fps.
Ideally you would just change the frame rate in Project Settings and all keyframes would adjust appropriately, but apparently they don't.

However, the Rescale Keyframes option is also not really an option as it moves Frame 1 keyframes away from Frame 1 for some reason.
e.g. Rescaling f1-f17 to f1-f43, shifts all frame 1 keyframes to frame 3.

Also, why on earth can't you rescale layer-based keyframes?
User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: Rescaling Keyframes

Post by Greenlaw »

Normally, I would use Rescale Frames, but, as you have discovered, there appears to be a bug in this feature. When scaling up, it will offset frame 1's keyframes, even when you enter frame 1 as the start frame for both the source and new range. When 1 is entered in both fields, those keyframes should remain locked in place, and only the following keys should be affected.

I did a quick test scaling the keys from 1-12 using to 48 frames, and it appears only frame 1 was moved incorrectly. Frame 6 was properly moved to frame 24 and frame 12 was properly moved to 48, but frame 1 was moved to frame 4 when it should have stayed at frame 1. To correct this, I just grabbed the keys at frame 4 and dragged them back to 1. It's not ideal but at least the result is correct. (When frame 1 is entered as the start frame, I think Moho is using frame 0. I'll let the devs know about this issue.)

Another way is to reveal all the keys in your animation, making sure there is a freeze at frame 1, and then select and Alt-drag the keys in the timeline to the duration you want. This is similar to how it's done in After Effects, and it's what I typically do in Moho, but be aware that it only works with keyframes that are visible in the timeline.
User avatar
SimplSam
Posts: 1048
Joined: Thu Mar 13, 2014 5:09 pm
Location: London, UK
Contact:

Re: Rescaling Keyframes

Post by SimplSam »

You can try using 0 as the new start frame. I have done a quick test and it seems to work - as it should with 1.
Moho 14.1 » Win 11 Pro 64GB » NVIDIA GTX 1080ti 11GB
Moho 14.1 » Mac mini 2012 8GB » macOS 10.15 Catalina
Tube: SimplSam


Sam
User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: Rescaling Keyframes

Post by Greenlaw »

Here's a video from my test...

Image
User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: Rescaling Keyframes

Post by Greenlaw »

SimplSam wrote: Mon Dec 18, 2023 3:11 am You can try using 0 as the new start frame. I have done a quick test and it seems to work - as it should with 1.
Hi SimplSam,

I tried that in an earlier test, but it didn't work...frame 1 still got offset. I also tried entering 0 as the start frame, and still got the incorrect result for frame 1. Entering 0 in both fields, doesn't work either. Just tried it again after seeing your message, and yeah, same failure.

I also tried entering frame 2 as the start, hoping to get Moho to skip frame 1. That works for frame 1, but then the following frames are not exactly where they should be.

The only solution I found that was accurate is what I described above.
User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: Rescaling Keyframes

Post by Greenlaw »

Hmm...I'm looking at my own example above, and now I'm unsure about the accuracy of the Alt-Drag method. Even though frame 1 is pinned, it looks like some of the other frames may be off. I guess I never questioned the results before because, practically speaking, the end result looked fine to me.

I'll still ask the devs about it though, because I may be misinterpreting the result.
User avatar
SimplSam
Posts: 1048
Joined: Thu Mar 13, 2014 5:09 pm
Location: London, UK
Contact:

Re: Rescaling Keyframes

Post by SimplSam »

Yeah. My bad. It is not reliable to use 0.

But strictly speaking, rescale may actually be doing the right thing. It merely factors the keyframe positions. So that the scaled transition between the former frame 1 and former next frame is accurate.

This has the side effect of 'creating/breaking' former frame 0 to former 1.

In order for it to work as we desire - it would probably need to move former frame 1, but also keep a duplicate copy on frame 1.
Moho 14.1 » Win 11 Pro 64GB » NVIDIA GTX 1080ti 11GB
Moho 14.1 » Mac mini 2012 8GB » macOS 10.15 Catalina
Tube: SimplSam


Sam
User avatar
ZeroAbility
Posts: 27
Joined: Thu Mar 20, 2014 10:15 pm
Location: Dublin, Ireland

Re: Rescaling Keyframes

Post by ZeroAbility »

Greenlaw wrote: Mon Dec 18, 2023 2:55 am Normally, I would use Rescale Frames, but, as you have discovered, there appears to be a bug in this feature. When scaling up, it will offset frame 1's keyframes, even when you enter frame 1 as the start frame for both the source and new range. When 1 is entered in both fields, those keyframes should remain locked in place, and only the following keys should be affected.

I did a quick test scaling the keys from 1-12 using to 48 frames, and it appears only frame 1 was moved incorrectly. Frame 6 was properly moved to frame 24 and frame 12 was properly moved to 48, but frame 1 was moved to frame 4 when it should have stayed at frame 1. To correct this, I just grabbed the keys at frame 4 and dragged them back to 1. It's not ideal but at least the result is correct. (When frame 1 is entered as the start frame, I think Moho is using frame 0. I'll let the devs know about this issue.)

Another way is to reveal all the keys in your animation, making sure there is a freeze at frame 1, and then select and Alt-drag the keys in the timeline to the duration you want. This is similar to how it's done in After Effects, and it's what I typically do in Moho, but be aware that it only works with keyframes that are visible in the timeline.
Thanks for that, Greenlaw. I noticed that Cycle keyframes also don't point to the correct frame after rescaling.
User avatar
ZeroAbility
Posts: 27
Joined: Thu Mar 20, 2014 10:15 pm
Location: Dublin, Ireland

Re: Rescaling Keyframes

Post by ZeroAbility »

SimplSam wrote: Mon Dec 18, 2023 3:11 am You can try using 0 as the new start frame. I have done a quick test and it seems to work - as it should with 1.
Ah, I get you, thanks. I did try putting zero for both start frames and it just gave an error beep.
Post Reply