www.jpct.net

jPCT - a 3d engine for Java => Support => Topic started by: AGP on December 31, 2010, 12:31:21 am

Title: Animation.crossFade
Post by: AGP on December 31, 2010, 12:31:21 am
Sorry for yet another (no doubt annoying) suggestion: object3d.getAnimation().crossFade(int currentSequence, int newSequence). Also very important to be able to cross fade between any two animations.
Title: Re: Animation.crossFade
Post by: EgonOlsen on December 31, 2010, 01:51:28 pm
How is that supposed to work? If you have no keyframes between the mesh states of the two sequences, the result would look like crap. And if you have those keyframes, they simply define a new sequence of its own.
Title: Re: Animation.crossFade
Post by: AGP on December 31, 2010, 05:04:39 pm
It looks perfect in Unity. I can look up an algorithm, but why wouldn't it just be linear interpolation? I'm sure we can think of something (I'm much more comfortable tackling something like this than that camera issue).
Title: Re: Animation.crossFade
Post by: EgonOlsen on December 31, 2010, 05:11:06 pm
I don't see how this should work in a generic way when using keyframe animations. It might work better with skeletal animation, but with pure keyframes...if that would work, you wouldn't need keyframes at all.
Title: Re: Animation.crossFade
Post by: AGP on December 31, 2010, 05:16:43 pm
You're right, it would need skeletal animation to not look awful. Maybe I'll try adding it to raft's bones and report my results.