Making a humanoid model look up and down

Started by
6 comments, last by dpadam450 7 years, 7 months ago

I'm looking for an easy approach is to making a humanoid skeleton model bend over and upwards.

I did some research and found that Quake 3 split their models into 3 pieces: the legs, torso, and head. They positioned each one in the "correct" location using "tags" in engine. They then independently bent the torso and head forwards or backwards depending upon if the player looked up or down.

What are some "easy" approaches using one model with a skeleton?

A secondary question is whats an easy way to animate the legs and upper body individually?

Thanks.

Advertisement

What program/engine are you looking to use? UE4 does things different than Unity and Blender is different (in the finer points) to both.

Developer with a bit of Kickstarter and business experience.

YouTube Channel: Hostile Viking Studio
Twitter: @Precursors_Dawn

I did some research and found that Quake 3 split their models into 3 pieces: the legs, torso, and head. They positioned each one in the "correct" location using "tags" in engine. They then independently bent the torso and head forwards or backwards depending upon if the player looked up or down.

This was a long time ago, when 3D rigs where simple things.

You could still do it this way, however you will have lots of limits on what you can achieve with such a simple rig. The advantage would be the performance you can get from it.

Search "3D character animation" "3D rigs for game animation"

http://iamzimmer.blogspot.co.za/2013/01/game-character-rig-skeleton.html

This is a example of a more modern rig I found on the net, one of the first images Google provided.

This appears to be a complex all purpose rig, before exporting the helper bones would have to be deleted.

In general most rigs have 42 bones on export.

Note: This is for the most used rigs(humanoid enemies in shooter games) and after exports, the rigs used to create the animations is as large as the animator needs.

Head, Neck, Eye guide, Cervical, Thoracic, Lumbar, R/L Arm, R/L ForeArm, R/L Hand, Pelvis, R/L UpperLeg, R/L LowerLeg, R/L Foot, R/L Toes.

The Hands are: Palm, Thumb(3 joints), Index Finger(3 joints), MiddleFinger(2 joints) and the RingFinger and Pinky both share one bone.

I have seen some developers creating bones for each finger with 3 joints each, that is 15 bones for one hand, combined with the toes you would need over a 100 bones for such a complex rig.

The other downside is that each bone, if they are animated or not, will have a impact on performance. So using a 15 bone hand on a character that only has to pull a trigger is just a waste.

What program/engine are you looking to use? UE4 does things different than Unity and Blender is different (in the finer points) to both.

Custom.

I did some research and found that Quake 3 split their models into 3 pieces: the legs, torso, and head. They positioned each one in the "correct" location using "tags" in engine. They then independently bent the torso and head forwards or backwards depending upon if the player looked up or down.

This was a long time ago, when 3D rigs where simple things.

You could still do it this way, however you will have lots of limits on what you can achieve with such a simple rig. The advantage would be the performance you can get from it.

Search "3D character animation" "3D rigs for game animation"

http://iamzimmer.blogspot.co.za/2013/01/game-character-rig-skeleton.html

This is a example of a more modern rig I found on the net, one of the first images Google provided.

This appears to be a complex all purpose rig, before exporting the helper bones would have to be deleted.

In general most rigs have 42 bones on export.

Note: This is for the most used rigs(humanoid enemies in shooter games) and after exports, the rigs used to create the animations is as large as the animator needs.

Head, Neck, Eye guide, Cervical, Thoracic, Lumbar, R/L Arm, R/L ForeArm, R/L Hand, Pelvis, R/L UpperLeg, R/L LowerLeg, R/L Foot, R/L Toes.

The Hands are: Palm, Thumb(3 joints), Index Finger(3 joints), MiddleFinger(2 joints) and the RingFinger and Pinky both share one bone.

I have seen some developers creating bones for each finger with 3 joints each, that is 15 bones for one hand, combined with the toes you would need over a 100 bones for such a complex rig.

The other downside is that each bone, if they are animated or not, will have a impact on performance. So using a 15 bone hand on a character that only has to pull a trigger is just a waste.

Is it the engines responsibility to animate the humanoid forwards and backwards or is it the artists?

If you rotated a torso around a pelvic bone, then the triangles from the upper body will clip into the triangles from the pelvic area. The vertices must be compressed nicely in order to create a smooth look, like in these screenshots [1] and [2].

[1] https://doi.ieeecomputersociety.org/cms/Computer.org/dl/mags/cg/2008/03/figures/mcg20080300484.gif

[2] https://62e528761d0685343e1c-f3d1b99a743ffa4142d9d7f1978d9686.ssl.cf2.rackcdn.com/files/111482/width668/image-20160215-22596-1xdjfyg.png

This bending needs to happen from the bottom of the torso and up to the neck (so the back bends nicely).

My question is:

#1. Whose responsible for the bending, the engine or the artist?

#2. If its the engine, then what algorithms are used for this? Do vertex weights set by the artist come in to play or does the engine just use "special" bones (maybe based off there name) to do rotation/weighting? I'm asking how this works in general.

There is no only "engine" or only "artist". Artist does the rigging/skinning and makes animation clips which are then used by the engine to process further. There may be IK solver work done on engine side, clip blending, attaching objects to bones, adding restrictions, ragdolling and so on.

Look for "inverse kinematics lookat" to find some read about this topic. Just to confirm I understand what you're trying to achieve correctly, you want to do something like this:

?


Where are we and when are we and who are we?
How many people in how many places at how many times?

Just to confirm I understand what you're trying to achieve correctly, you want to do something like this:


Yes, thats what I'm trying to solve however, I only need looking up and down as opposed to all around you like in the video. Is IK the easiest way to achieve this?

Here are some other techniques I've considered, but I'm not sure about there feasibility:

  • Have the artist create the up/down bend and then blend it with another upper body animation like saluting and leg animation.
  • Take the Quake 3 route and make the head, torso, and legs separate pieces assembled in engine.
  • Create a skeleton that the engine "understands" and the artist builds around. The bones of the skeleton would be understood by the engine so it knows how to create a bend. Is this how its normally done?

Additionally, is there a popular IK library (in C or C++) that could be leveraged?

Thanks so much for your help. Its difficult to describe a problem when you don't know the terminology.

I've worked a couple of games were we did this splitting... in both cases we had the engine know what bone would be used to split an animation from...

For example, your artist could create a running animation, a shooting animation independently....this way we set to use the pelvis as the spliting bone... so you could run the shooting animation from the pelvis upwards (ignoring it from the pelvis downwards), and the running animation from the pelvis downwards (ignoring the upper part of the animation).... and you would get a "running and shooting" animation....

The same could be done with the head, we could specify the neckbone for splitting animations, so that we could rotate the head depending on where the user was looking at (not animated by the arstist), and everything below would be animated accordingly depending on the current action by the player (running, shooting, standing still, etc).

"lots of shoulddas, coulddas, woulddas in the air, thinking about things they shouldda couldda wouldda donne, however all those shoulddas coulddas woulddas ran away when they saw the little did to come"

Weights and bones in maya/blender/max will be exported and read as is in your custom engine. Same data. Same outcome. The only difference between the two is it is your job to deal with game engine stuff, like IK and blending of multiple animations together.

As for your original question, you basically can hi-jack your bones after they are done with your animation code. You can directly set your spines matrix as well as your head if you want head tracking.

NBA2K, Madden, Maneater, Killing Floor, Sims http://www.pawlowskipinball.com/pinballeternal

This topic is closed to new replies.

Advertisement