How to insert a new pose into existing animation

Hello!
There is a common situation, especially in game animation pipeline, when you need to make all animations starting with one and the same pose. Sometimes you need to correct the starting pose in all existing animations. And sometimes the pose correction is quite huge. While existing animations are baked “key per frame”.
So in base layer you have to manually adjust all bones, all curves, all axes. This is painful.:spin:
I tried to use NLA editor, inserting a new pose into the beginning of animation. But I do not need either Replace, or Add or Multiply mode. I somehow need an “Offset” mode :slight_smile: How could I solve this situation?
Could you please share your ideas!
Thanks!

It doesn’t sound that common to me. Usually you would have a rest pose (the default rig pose with all transforms reset) and for each animation you would have a different starting point depending on the loop and then blend between these. Or actually you would probably have idle animations and blend between the idle and the next animation. You should make sure the rig is finished (and tested) before even starting animating.

You could try using the pose library (https://www.blender.org/manual/rigging/posing/pose_library.html) to save the corrected pose, then copy it to the unbaked versions of the animations, then rebaking them.

Thanks for the answer.
I see your point but that’s not what I am looking for.
I will reformulate my question.
This “insert a pose” idea could be useful when you work with MOCAP, for example. Or when you start with some ready animations and try to change them according to your new task. You have a baked animation and there is no return to unbaked keys :slight_smile: And you have to insert initial pose, then insert final pose. Then you have to insert this very initial pose to all other animations and it should be exactly the same.
I would compare this to working with layers, but in Blender you have NLA instead of them. However NLA seems not to work with this particular case.
Perhaps there is some mysterious way to cope with this? :slight_smile:

Right. Keyframing doesn’t work that way. You are correct.

To make sure I understand you, let me lay out this scenario: Forget the full rig, That complicates thing. Make a simple one bone rig. Turn on autokey and move it on the X. Move ahead ten frames in the timeline and do it again. Move ahead ten frames and move it again.

When you play that you have the bone moving in a straight line. Great. Now go back to the first keyframe and move it on the y Axis. Logically, you would assume that the bone would now move on a straight line again, just over from where it was before. But that’s not what happens. Instead it moves back to the original Y axis position on the second keyframe and the animation continues along as it did before. This is the behavior that is frustrating you, yes?

However, “baked” is the wrong term. The thing is the key frames are interpolated – or calculated. And it is always simply calculating between two key frames. So, when you change keyframe 1, it re-interpolates the motion between Keyframe one and keyframe 2, but it has no need to change anything between keyframe 2 and keyframe 3, since nothing changed there.

There are simple ways to fix this if you are just worrying about the general placement of the armature – you simply have a root bone and you can set it to position based on a null offset. Then it is easy to move the whole rig around. But tweaking each individual bones action based on making a change to the base action is tedious stuff.

I suppose a script could be written to do the corrections, and probably has, but that’s some kind of math to do.

General advice: Work like a traditional animator does… always work in large movements, getting the main poses right. That’s where the term “Key Frame” comes from… Ub Iwerks, Disney’s lead animator drew all of the major poses, and then other artists known as “tweeners” – because they did the frames in between filled in the rest. The computer is your tweener. You may find that turning auto key off helps, as it makes you be very intentional about your keyframes. Save poses into a pose library so they can be recalled easily. One of the easy ways to do this is to save them at the “negative frames” of your timeline. You can go back to them when needed, select copy, then move to where you need it and select paste.

EDIT: I saw your post about MOCAP. This is a huge problem with using MOCAP, and why products like MotionBuilder exist. MOCAP keyframes on every frame. This destroys the ability to easily change it. Cleaning up MOCAP data – especially some of the free stuff like the famous CMU labs – will take you more time than just animating it yourself.

That’s it!
What I mean is working with MOCAP data and with other raw animations, where keys are (for this reason or other) baked key per frame on most (not necessarily all) bones.
The thing is that I often have to work with MOCAP data or correct other animations that are already baked.
The only thing that would make work in Blender easy with that, is adding a traditional “animation layer” :slight_smile: . That would be superb :yes:
Until then one has to correct all curves manually, I feel.
Or write a script… A “layer script” :evilgrin:

Can’t you already do that with the mocap tools in blender though? You can read about it here: http://wiki.blender.org/index.php/User:Benjycook/GSOC/Manual
Or maybe you’re not retargeting at all?

And there’s a picture to illustrate my question. An example of my animation curves, where I have to correct initial and final pose:


This is a rat, dashing forward to make a bite. And return back to its (new now!) pose. It used to stand on its four in the beginning. Now it has to sit on hind legs, holding front legs, like arms. Here I’ll have to change front legs to FK until they touch the floor. Perhaps later rebake them from IK to FK and backwards several times to make animations better and more natural-like:))
And what is worse, I’ll have to apply a new starting pose to seven other animations of this rat :mad:
What I am doing now - is pasting a new pose from pose library (or pose buffer) and correcting every curve on every bone, that has changed, manually, so that there was no jerk at the following keyframe of any bone… I feel really silly ;)…

Thanks for the link, I will examine it!
I do not have problems with retargeting from MOCAP data and correcting offsets. The problem would stand with further editing, I would say…
But perhaps the answer to my question will be there, I’ll read the whole article. Thanks.

Cinema 4D had a thing where it would take an animation and “normalize” it by analyzing the curves. It looked through the curves and kept enough points to make it the same, while eliminating a lot of redundant points. I really think it just looked at the high points of the curves and then kept those and just enough points to hold the curves shape. It did a decent job. I think it was a pure algorithmic approach. I’m positive it could be done in Blender via Python, but that math is beyond me.

Yea, likewise MotionBuilder has KeyReducing filter, where you can set a threshold.
But sometimes, when action is very prompt, like in attacks, deaths and damages, it’s better not to use key reducing :)) Almost all the keys are needed where they are.

If I understand your problem correctly, you may want to try the “propagate pose” tool in the 3D view. This tool was created specifically for the problem that after animating a shot, you realise that you want/need to modify some poses, but those changes will affect some other poses nearby which either hold the same pose (in its entirety or partially). While it was only really intended for use while you’re still in the blocking stage, it is probably still usable when you’ve gone through doing a bit more polish too.

Usage:
Once you’ve created the new initial pose for an action (but before inserting any new keyframes), try using the “propagate pose” tool. There are several modes to choose from, some of which sound like they may help (if you’re using 2.76+, have a look at the triangle-dropdown beside “Propagate” in the toolbar).

For example:

  1. “To Last Keyframe (Make Cyclic)” sounds like something that will definitely be of interest to you, as it will ensure that the pose on the first frame is copied to the last frame.

  2. The default mode sounds like it may help with the other situations, specifically on controls which stay the same as the initial pose for several consecutive keyframes. To do its magic, it requires that you don’t insert any new keyframes yet once you’ve modified the starting pose, as it will use the old pose to tell if the next keyframes are the “same” and thus need updating.

You won’t need to insert any keyframes for the initial pose, as the tool will do this as part of its operations.

Hopefully this is closer to what you were looking for :slight_smile:

Thank you! I have already tried this tool and have come across your BlogSpot article :slight_smile: Sometimes it helps. Do I understand correctly, that it doesn’t much help with MOCAP and baked bone animations?

I attach my file with rat animation. It’s rat’s idle. I
I’ll explain, why there can be too many keys all over some limbs:
The rat is on the FK bone system now. I sometimes use IKs for legs, tail, chest and head. In difficult animations (this Idle is not a difficult animation, just an example) I need to rebake IK to FK and backwards several times. Or I use some older library animations in my files, that are already baked.

I need to change starting and final pose. New pose is in the pose library. In case with classical layer work I would just paste a new pose to a new layer and that would be it, no further editing :slight_smile: It would create some sort of Offset for all the bones, and gradually reduce its influence until a zero key, if there is one.
Here I insert a new pose to first frame and last frame (or do it with Propagate menu:)))) and manually correct all the other curves in-betweens.

PS: to Cyaoeu: I remember about “Motion Capture Addon”, just haven’t finished examining the article :eek:

Attachments

rat_posetest.blend (2.17 MB)

I’m a little confused by some of the terminology. You say “baked” animation – but what I understand is that just means its MOCAP that has put a keyframe on virtually every frame, right? (And besides, isn’t it basically ALWAYS FK, since MOCAP is just reading sensors and moving bones accordingly?)

Secondly, you are talking about IK vs FK, and I am not understanding the distinction. The only difference between IK and FK – that I know – is how it interpolates the frames in between. In IK, the Child influences the rest of the chain (i.e. the hand influences the forearm which influences the upper arm) So by moving the hand, you also cause the rest of the chain to move and keyframes are assigns accordingly.

But, in FK, it is the opposite. My Shoulder moves my upper arm, which moves my forearm and then my hand. They are different means to strike the same pose, and the interpolation scheme i.e. how the other bones move through space, is calculated differently… But that’s the only difference, right?

Is that what you mean with IK and FK?

Because if so, I don’t understand how either method matters at all once every frame is keyframed (or baked as you call it) – which is what MOCAP basically does. Once every frame has been keyframed, it would be difficult to unpack how it got there. It seems like you would have to selectively remove all previous animation and then rework it by changing IK to FK – but maybe I am totally missing what you mean.

Is there a tool that you have used that does what you are referring to?

On a secondary note… how did you get MOCAP of a RAT? someone put sensors on a rat? Or how did it happen? That’s cool!

My terminology: by MOCAP I mean MOCAP files, shot by MOCAP system (like Vicon etc.). By baked animation I mean, e.g., an FK limb of a character, consisting of Shoulder, UpperArm, Arm and Hand, that used to be driven by FK Effector, but baked to FK (Animation-Bake Menu), so that you could edit it further in FK. When, say, you need to put a character onto the floor with its hands, and later put it again straight for some time. I know that I can animate influence of IK constraint (and keep it zeroed for the time it’s not needed), but sometimes to add some secondary animation and other peculiar strokes, I need to disable this IK constraint and work with FK system, provided all animation from IK preserved.
Why do I have to bake? To transfer animation from IK to FK, because if I just disable IK animation, there will be no animation on FK system. At least that’s how my rig (and several others that I used) works… Is it correct?

I remembered one more case, when baking from IK to FK in very useful! When you have a complicated animation with a long Spine system in FK. When animation is almost finished, some times I notice that Head is jerking. But it is very difficult to remove this jerk using only FK, for there are too many bones in the system, each rotating and, perhaps, even moving! So a simple way is to bake animation to IK (with Head an effector) and just remove this jerk on the Head Effector curve. And afterwards bake it back to FK :D. Works great with upper spine and head!

You are right here. MOCAP gives only FK keys on every single keyframe (I do not call this case “baked”:no: :)). In case of working with MOCAP I copy animation from the last limb in a chain (Foot or Hand) to IK Effector and then make an IK constraint for arms or legs (change FK to IK, not backwards :)).

That is not a MOCAP file, that is a keyframe animation :cool:
But I know people who made MOCAP of Horses and dogs :yes::yes::yes:

This thread makes me go :spin:

What’s wrong with regular old keyframed animation? It’s pretty easy and probably more fun than having to edit all your motion capture stuff. Plus you wouldn’t have to worry (much) about copying poses and stuff with a loop based workflow. Although what you said in the last post makes me think that it’s not really motion capture at all which makes me even more confused.

Anyway, you say that you’re baking IK to keyframes to disable the IK, but instead you would normally have IK bones and FK bones and then an IK/FK switch that you can keyframe to instantly switch to FK or IK without baking any keyframes at all. You could also have FK bones snap to the IK bones to make that switch more seamless, and even switches that stop the head bone (or any other bone) from rotating if you don’t want it to. That way you can have fewer keyframes and it’s much less of a pain when editing.

Maybe you should make your rig a bit more complex so you don’t have to bake stuff at all. Either by adding this switch type of functionalities or by using a crazy rig like BEPUik where you’ve got FK and IK at the same time. :eek:

sorry posting mistake

sorry posting mistake can’t delete message

Ok, let’s forget about my baking IF to FK stuff.
But I cannot avoid MOCAP :slight_smile: Client gives me MOCAP animations to edit.

The thing is that I’m trying to figure out if Blender can fit into our work pipeline.
I’m relatively new to Blender and I like almost everything about it.
For years, I used to work in other software, creating animations, while animation tools in Blender quite differ from those I got used to.
That’s why I created this thread, sorry if it makes you dizzy :spin:

Anna, I think the discussion is helpful. I’m not a Blender Developer, but discussing pipelines is important.

I come back to my long post and a question I asked that you probably missed: “Is there a 3D Tool that does this?” It might be helpful if so to focus the conversation around an existing product. Also, what does your work pipeline consist of currently?