- Home /
Animation overshoots ending keyframe during quick movements. Visual example inside. Anyone else notice this?
So basically I have an animation that works with fast sudden movements but the animations tend to overshoot their ending keyframe. Below is an example of what I mean.
As you can see in my Unity example, the lower bone goes further then pops back. If this is on a character swinging a big sword, you would notice the sudden jerk. I've tried different export options like including tangents and setting the import to use the exported tangents. It still happens. I wasn't sure if this was just a quirk of Unity or if it's just a setting.
Any help is appreciated. Thanks.
i also have an issue similar to this, unity fancies itself an animator, easing in and out our keyframes, and adding tangents :/ If i get an answer/fix on my question i'll pop over here and share it with you.
Are your animations baked to keyframes? As in, do every single one of your frames have a keyframe on it for all attributes?
I know in previous projects we did this to ensure Unity didn't interpolate differently. $$anonymous$$ight help?
@OP_toss how do you do that? sounds like it would be a good fix
In maya:
Edit->$$anonymous$$eys->Bake Simulation
In $$anonymous$$ax I'm not so sure, but a simple google search should tell you. It's a common thing every 3D application has.
Answer by Paulius-Liekis · Aug 21, 2013 at 02:43 PM
It's caused by the way Unity imports animation curves. It's supposed to improve keyframe values and tangents, instead it imports only keyframes and then simply recalculates tangents using basic smoothing of values.
There is not much you can do about it. In certain cases you could disable curve reduction and then write a script which convert tangents to linear, but that might cause other visual problems.
This explains the problem, but does nothing to solve it.. There is something you can do about it, and that is to bake the keyframes on export. This is a common practice and easy to do.
And no you shouldn't script the conversion, you should just export properly from your 3D application. $$anonymous$$UCH easier.
I accepted it because it at least explains it. I have also tried baking the keyframes and the problem persists. This answer seems closest to at least explaining why it's happening, albeit still impossible to fix.
@OP_toss: I suspect we're talking about different problems, I don't really see how baking can help you in this case. $$anonymous$$aybe it works for some software, because it fails to export to FBX correctly without baking. And there might be something $$anonymous$$ecanim specific - I'm not familiar with retargeting and stuff.
In other case baking has no effect. Baking is necessary when you want o convert I$$anonymous$$ / or some other procedural controller animation into keyframes. It does nothing for keyframes animation, only inserts more keys. For Unity amount of keys is not important. It will oversample the curve every 1/frame-rate and then it will remove unecessary keys. As I said it will ignore tangents of the curves and it will simply create new ones based on smoothed values. So if you have step, linear or broken tangents in your modeling software it might result in artifacts in Unity.
But yeah, ignore me, I worked on animation & model at Unity only for 3 years. LOL :)
@Paulius Liekis: but would it not help having the keyframes baked so that you could select them all in unity, right click, and make them flat? Would that not override unitys smoothing? *I am asking btw, i have no idea, and want to learn :3
Your answer
Follow this Question
Related Questions
Animation deformed after importing... 1 Answer
How can I export 3d model from unity3d file? 3 Answers
Linked objects not animating correctly in Unity 5 0 Answers
3Ds Max Model to Unity (No blendshapes on skinned models/ attached model) 2 Answers
Unity 3DS MAX material rotation FBX import support 0 Answers