Monday, February 26, 2007

Breaking splines not strangulating Ring Masters

I completed the run in and bow video sequence this weekend which moves the flea film project a little closer to it's objective. The sequence starts with an announcement, the character runs in from the left of the screen and then bows to the audience. In the process I learnt a little about tweening with spline curves.

Basically my character was running in, thanks to Poser's walk designer and stopping and bending down. However when I added the moves to make him go back up, all sorts of strange things started happening. The poor little guy started strangling himself, his legs wrapped around themselves and his thumbs tied themselves in knots.

Thanks to an answer from PhilC on Renderosity, I discovered that the problem was my use of spline for the tweening which are the default and most natural looking tweeners available in Poser.

To see what's going on and why a future point might affect a historic point, I put together a simple experiment in excel. You can see in the left graph that the trendline (3rd order polynomial) is a simple straight line. However when I add new points to the right it causes the curve on the left to overshoot. The problem is that the curve fitting algorithm does not understand what I am attempting to achieve and in fact, I could not find any algorithm in excel that would sort this issue.

Luckily Poser does have an answer to this which is to "break spline". Rather than having the whole animation as only long spline curve you break it up into a series of shorter curves which are easier to manage and importantly don't interact with each other in this way. So in my example from excel I would need to break the spline at 4 and 6 and then add a couple of new key frames to smooth the curve between the two points.

So you need to ensure is if you have any animated poses that you start and finish them with a key frame with a break in the spline so that they don't interact with others. Once you've done this you can simply apply the pose from the library and it will blend seamlessly into the rest of the sequence.

You can find Phil's tutorial on this and other poser tips at his website.

No comments: