Random tidbit for those animating in MAX
Moderators: GSH, VSMIT, Red Devil, Commando
Random tidbit for those animating in MAX
If you are making an animation in 3dsMAX you are using keyframes. The program interpolates between keyframes. The problem is that BZ2 interpolates differently than MAX does, so your animations might not look how you expect.
The interpolation can be described by these two equations:
MAX: Y = (cuberoot((X/(T/2))-1)*((B-A)/2))+((B-A)/2)+A
Game: Y = (X*(B-A)/T)+A
Where A is the value of the first keyframe, and B is the value of the second, Y is the resultant value, T is the time between frames. X is the time after the first frame and Y is the resulting value of what you are interpolating.
You could probably tweak it a bit more replacing T with (SecondFrameTime - FirstFrameTime) and making X take in the global time instead of the local (right now its time since first frame). If you do would you please post it.
Long story short, plug both these into a graphic calculator and you can see the difference between how BZ2 and MAX interpolates. It matters.
The interpolation can be described by these two equations:
MAX: Y = (cuberoot((X/(T/2))-1)*((B-A)/2))+((B-A)/2)+A
Game: Y = (X*(B-A)/T)+A
Where A is the value of the first keyframe, and B is the value of the second, Y is the resultant value, T is the time between frames. X is the time after the first frame and Y is the resulting value of what you are interpolating.
You could probably tweak it a bit more replacing T with (SecondFrameTime - FirstFrameTime) and making X take in the global time instead of the local (right now its time since first frame). If you do would you please post it.
Long story short, plug both these into a graphic calculator and you can see the difference between how BZ2 and MAX interpolates. It matters.
- bigbadbogie
- Bull Dog
- Posts: 586
- Joined: Mon Feb 21, 2011 8:12 am
- Location: Ecuadorian Embassy
Re: Random tidbit for those animating in MAX
That simple is it?
- MrTwosheds
- Recycler
- Posts: 3059
- Joined: Sat Feb 19, 2011 8:37 am
- Location: Outer Space
- Contact:
Re: Random tidbit for those animating in MAX
Not quite sure I got it either.
Re: Random tidbit for those animating in MAX
I had the equations switched there.
Yea, that simple...
To understand it better...
Game is y=x
Max is y=cuberoot(x)
Not counting all the extra bits.
Yea, that simple...
To understand it better...
Game is y=x
Max is y=cuberoot(x)
Not counting all the extra bits.
Re: Random tidbit for those animating in MAX
Not to mention you can go in and change the actual interpolation in max through the curves. Only do this if you are making a movie, though, because you will shoot yourself unless 3DS is your occupation.
Re: Random tidbit for those animating in MAX
If you don't use autokey and set the keys manually, the interpolation should be ok in bz2.
Re: Random tidbit for those animating in MAX
Incorrect. This is only true if you set a keyframe on every frame, which makes it hard to maintain and edit.Apollo wrote:If you don't use autokey and set the keys manually, the interpolation should be ok in bz2.
Yes you can set max to linear, but its not a global setting, you have to do it per individual key frame pair.
Re: Random tidbit for those animating in MAX
Every frame is too much like work. 

Re: Random tidbit for those animating in MAX
Take a hybrid solution. Keep a save of pre-export for editability, which you then modify into a new iteration with keyframe on every frame.Nielk1 wrote:Incorrect. This is only true if you set a keyframe on every frame, which makes it hard to maintain and edit.Apollo wrote:If you don't use autokey and set the keys manually, the interpolation should be ok in bz2.
Yes you can set max to linear, but its not a global setting, you have to do it per individual key frame pair.
That is, this all only applies if your animation absolutely DEPENDS on the max interpolation to succeed, so your swinging door or rotating walker arms will probably be fine.
- MrTwosheds
- Recycler
- Posts: 3059
- Joined: Sat Feb 19, 2011 8:37 am
- Location: Outer Space
- Contact:
Re: Random tidbit for those animating in MAX
Hmm, seems a bit complicated to me. I just skin animated my Dalek turrets head. It was the bit where I had to make an envelope for its 247 vertex that was tricky, the actual animation to move it is really simple.
AnimationSet {
Animation anim-deploy {
{frm-hp_head}
SI_AnimationKey {
2;
2;
0; 3; 0, 0, 0;;,
30; 3; 0, -0.4, 0;;;
2 key frames -0.4 down. Animation looks great. It ducks.
AnimationSet {
Animation anim-deploy {
{frm-hp_head}
SI_AnimationKey {
2;
2;
0; 3; 0, 0, 0;;,
30; 3; 0, -0.4, 0;;;
2 key frames -0.4 down. Animation looks great. It ducks.
Re: Random tidbit for those animating in MAX
In BZ2, it moves a set distance every interpolated frame.
In MAX's default setup, it moves a different amount ever interpolated frame, sort of like it accelerates and then decelerates.
In MAX's default setup, it moves a different amount ever interpolated frame, sort of like it accelerates and then decelerates.
- bigbadbogie
- Bull Dog
- Posts: 586
- Joined: Mon Feb 21, 2011 8:12 am
- Location: Ecuadorian Embassy
Re: Random tidbit for those animating in MAX
*Slaps self*
That's what you mean!
I've just learned to imagine what the animation would actually look like in the game and ignore the way that Max does that.
I don't even think about it any more, unless I am animating walkers. Then it can actually get a bit annoying trying to stop the feet from going through the ground.
That's what you mean!
I've just learned to imagine what the animation would actually look like in the game and ignore the way that Max does that.
I don't even think about it any more, unless I am animating walkers. Then it can actually get a bit annoying trying to stop the feet from going through the ground.
- MrTwosheds
- Recycler
- Posts: 3059
- Joined: Sat Feb 19, 2011 8:37 am
- Location: Outer Space
- Contact:
Re: Random tidbit for those animating in MAX
You should be able to adjust them back to something more like the original by lightly tweaking the keyframe numbers in notepad.
Probably never going to be as smooth as they appear in Max though.
Probably never going to be as smooth as they appear in Max though.
Re: Random tidbit for those animating in MAX
No, no you can't, since the issue is in the actual movement between frames being an entire order higher or lower.MrTwosheds wrote:You should be able to adjust them back to something more like the original by lightly tweaking the keyframe numbers in notepad.
Probably never going to be as smooth as they appear in Max though.
And yes, yes it can if you put a key-frame on every frame making the interpolation relatively unneeded. It creates a sort of system like how PCs draw curves (as a series of tiny straight lines).
- MrTwosheds
- Recycler
- Posts: 3059
- Joined: Sat Feb 19, 2011 8:37 am
- Location: Outer Space
- Contact:
Re: Random tidbit for those animating in MAX
Well you can. The results may not be exactly what you wanted though.
A rotation that appeared smooth in Max, can be made to accelerate and decelerate by altering the keyframe numbers in notepad, the more frames there are the less crude the effect is, keyframe values can be tweaked to smooth it out as well.
You don't want to add a key to every frame, bz2 is smoothest with as few keyframes as possible.
If you had 30 frames, with 4 keyframes at 1 10 20 30, altering it to 1 9 21 30 or 1 11 19 30 would make it accelerate/decelerate towards 15, but not quite in the uniform manner that 3dsmax would achieve.
A rotation that appeared smooth in Max, can be made to accelerate and decelerate by altering the keyframe numbers in notepad, the more frames there are the less crude the effect is, keyframe values can be tweaked to smooth it out as well.
You don't want to add a key to every frame, bz2 is smoothest with as few keyframes as possible.
If you had 30 frames, with 4 keyframes at 1 10 20 30, altering it to 1 9 21 30 or 1 11 19 30 would make it accelerate/decelerate towards 15, but not quite in the uniform manner that 3dsmax would achieve.