Realistic random animation

Started by
6 comments, last by Roots 18 years, 11 months ago
Well, I'm not exactly sure if this feature is used in any engine or animation system for any game, so I'll go along and put this out there. Okay, so when a character model is animated (for example, running), the wire frame model is manipulated to move in such a way, and this animation is looped. Perhaps various animations are made, and looped randomly so the character doesn't look the same, however if you look closely you can still tell the character is doing the same animations. There could be a new process the wire frame model is animated on. There is one "true" animation of the character. Running will be the example again. This animation is used as the basis for random movement generator. The animation code allows key limbs in the wire frame that are moving (for instance the arms bending up, knees bending up, feet kicking out, or the shoulders heaving) to animate slightly off path every time the animation loops is played. The give to this off path animation could be 2% to 5% or so. This means when the character model is running, the arms may bend 2% to 5% off the way they'd normally bend, as with teh legs, or the heaving shoulders, or any movements generated by running. Of course, the small percentage off would not make the character move spuraticaly and strangely; the model would only generate fluid, non-exact movements. The ending result in this process would be realistic, life-like animation for character model movements. Gone are the looped animations for each action, the cloned movement of the same character models moving next to each other. The new animation system would be a welcome addition to next generation visuals.
Advertisement
Sounds cool! My only gripe is is the additional computational cost worth it, and how much is it? The only way to know if this would work well or not would be if the end-user notices it. Deviations that are too small will go unnoticed, and deviations too large will probably look bad (unless you want your character to be clumsy). If that doesn't work, you might want to try random, periodic large motions (such as a large arm swing, or a small slip of the foot). This might actually look more "realistic" since we all trip up sometimes as we're walking/running, and also lower the computational cost. But still, your original idea sounds delicious and I'd love to see a demo in action. [grin]

Hero of Allacrost - A free, open-source 2D RPG in development.
Latest release June, 2015 - GameDev annoucement

Poser, a 3D animation program, has a "walk editor" feature in it that lets you use a set of heuristics to produce a walking animation for a model. It's designed to be used mostly with the default models, but I'm sure it can be used for other things as well. You have a number of sliders, labelled "length of stride", or "speed" or "hip sway" or "high knee" that can be set at different points along the continuum to modify the basic walking animation. You can have jack-booted marching, roguish swaggering or dainty tiptoeing by moving the bars around. I would like very much to have a game that used character stats to modify animations. A big, muscle-bound character would walk and run and jump differently than a small-framed weakling would. Everything from climbing a ladder to shouldering a backpack would be affected by character stats.

The CPU cost is quite small, as far as I can tell, and since it will be entirely client-side, no network latency would be affecting it. The aesthetic and immersive benefits far outweigh whatever cost in processor cycles it exacts.

There are problems and risks, of course. In the Poser system, it was quite possible to push the system beyond reasonable limits, putting so much arm swing into an animation that the models limbs whirl like propeller blades, or causing mesh distention with negative knee flex. Setting more reasonable boundaries could prevent this, but there are times when a specific blend of settings, even if they are all near the median default value, will compose a glitchy anim, requiring some slight adjustment to repair. Can a random system prevent this? Whatever immersive benefits are gained by convincing random animations will be totally lost when one character has an arm that teleports through his torso once every sixteen frames.
Adding a bit of noise to an animation could be done by the GPU, much like the sway added to trees and other vegetation in some games.
Exactly Iron Chef! I was thinking about it more, and the system should definately implement different body types into animation. The random offsets would be included in these too. The whole body type varition system should be as easy as typing in the body measurements of the character, be it weight, height, or whatever. A damage/injury system could be created alongside this system, where certain parts of the animation skeleton would display realistic response to injury at a specific location on the character model. Hit in the leg, realistic limp, hit in the arm, realistic limp arm swaying, or whatever. In conjunction with the whole body type system and random movements, this would be great looking!

As far as CPU cost, i feel its not even worth worrying about. Using next-gen technology, even the most CPU costly system of animation would not even remotely be a problem.
Quote:Original post by Dobbs
Adding a bit of noise to an animation could be done by the GPU, much like the sway added to trees and other vegetation in some games.


Ken Perlin did some interesting stuff with adding noise to character animations: http://mrl.nyu.edu/perlin/facedemo

[size="1"]
You know, the Source Engine that we're working with has a feature like the one you're describing called Markov groups:

"A Markov group is simply a weighted graph where the next place to go to in the graph is randomly selected from a list of options. The way this works in the FacePoser is that you can select multiple expressions that you consider of a similar enough "type" to group together and use them to create a Markov group. During playback, when the model is told to play the expression that is a Markov group, one of the underlying expressions is chosen at random."

This can be applied to walking, fighting, or any other animation you could think of. If you notice your gun in HL2, it actually is held in randomly different positions, by utilizing the Markov group system.
Interesting that you call them Markov groups, because I've always know them as Markov Models (Wikipedia). And these aren't just used in games either, I've been studying their use in microprocessor simulation and bioinformatics applications over the past few months. It's a very nice concept/model that can be applied to just about anything you can dream of. [grin]

Hero of Allacrost - A free, open-source 2D RPG in development.
Latest release June, 2015 - GameDev annoucement

This topic is closed to new replies.

Advertisement