Skip to content

Manikin

Manikin

"Make your own motion reference"

In this tutorial, we will setup a human-like character for use as reference or constraint target to your rig. You will be able to pose and position this Manikin like you would a real Manikin, and drop it from various heights and onto various obstacles to produce realistic poses as it falls.

Something the animator can import and throw around for reference on how it would look like.

Version 1.0 - Up to date

Written for Ragdoll 2021.08.06 and above, but should still apply for 2021.06 and newer.

Estimated Time

  • 🕐 30 minutes

You will learn

  • ✔️ How to limit limbs to realistic angles
  • ✔️ How to pose a dynamic character
  • ✔️ How to apply forces to a specific rigid

Where to find help

If you find or run into any issues with this tutorials, here's what you can do.

Spelling

There's two ways to spell "Manikin", this tutorial is based on this term here.


Bring Your Own Rig

Follow this tutorial either using our provided Manikin rig, or your own character. It can have any number of limbs.


Motivation

Why should we even bother simulating a character?

Finding motion reference is one of the most important activities for any animator. And yet I can safely challenge you to find reference for perhaps the most common motion in all blockbuster movies today, something that is either impossible or dangerous for actors or animators alike.

Or how about reference of someone simply falling over, perhaps from heat stroke or staring into the sun.

This is, after all, one of the major reasons for pursuing computer graphics in storytelling rather than real people.

Animators bring life to characters, but of equal challenge is that of lifelessness. Of natural and realistic motion without someone behind the wheel. Be it getting hit or shot, blasted or thrown, animating lifelessnes is a enough to challenge even the most senior of animators.

As you will find, there is a lot more we can do once our motion reference is in 3D, on our actual character rig witin Maya and infinitely customisable. As opposed to some video on the internet.


Setup

Create a new reference of your chosen character rig or download this Manikin rig to get started.

Play around with the controls to get a feel for what we're working with. This character is entirely FK which will make simulating it straightforward.

What about IK?

We can achieve IK through physics, using the Soft Pin and Hard Pin controls.


Dynamics

The stage is set, now let's apply physics.


Torso

If you experimented with the pose earlier, reset all controls to 0 before proceeding.

Do I have to?

No, only for the sake of this tutorial.

Ragdoll will use the starting pose as a template for how to generate rigid bodies and constraints. The character can be in any pose, it can even be animated before applying any physics.

  1. Select hip_ctl
  2. Shift select torso_ctl
  3. Shift select head_ctl
  4. Run Active Chain

This will produce our first Active Chain, which is a set of Active Rigid with a Socket Constraint in between them.


Left Arm

Next we will continue from the torso_ctl and out into the arms.

  1. Select the torso_ctl
  2. Shift select L_clavicle_ctl
  3. Shift select L_upperArm_ctl
  4. Shift select L_lowerArm_ctl
  5. Shift select L_hand_ctl
  6. Run Active Chain
Is the order important?

Yes, the order in which you select will determine how the rigids are connected.

Your first selection is extra important, as it determines whether to start a new chain, like for the hip_ctl, or to continue from an existing chain, like the torso_ctl.

In this case, we would very much like our arm to be connected to the torso.

Can I skip the clavicles?

Yes, if you have extra controls - such as twist or bend - you do not have to include these. So long as there is a natural parent/child relationship between your controls, Ragdoll should behave just fine.

Simply skip over them as you select, from torso_ctl directly to L_upperarm_ctl.

In this tutorial however, we will use the clavicles to demonstrate a physical aspect of the Manikin which allows the arm to rotate in a very specific way.


Right Arm

Now repeat the above process for the other arm.

Oh no! What happened! 😨

Turns out, the clavicles of this character are so close to each other that they intersect. Intersections can be ok, so long as there is nothing holding the intersection together, which in this case is our torso.

One way of solving this is to simply disable collisions between the two clavicles.

Why can the clavicles not intersect?

Intersections aren't always a problem. When two rigids intersect, Ragdoll will typically push them apart once, and leave them apart.

The reason it isn't working for our clavicles is because the clavicles are intersecting whilst also being held together by the torso_ctl. Only one of these can be true, so we must either fix the intersection or remove the connection to the torso.

Is there an alternative?

Yes, you can also play with the Shape Length and Shape Radius parameters to avoid any overlap, or you can use an Ignore Contarct Constraint to only disable contacts between these exact two rigids.

Notice how the upper and lower arms intersect with each other. This is OK, because they are neighbours. Neighbours should intersect, that is a good thing and in many case mandatory.


Legs

Now let's continue down the hips and into the legs.

  1. Select the hip_ctl
  2. Shift select L_thigh_ctl
  3. Shift select L_knee_ctl
  4. Shift select L_foot_ctl
  5. Run Active Chain

Notice that we skipped the hip_ctl since we do not need it, and since the legs are far-enough apart there was no overlap between them. Great!


Drop Test

That's enough setup, let's drop him!

  1. Select hip_ctl
  2. Run Active Rigid

The default behaviour for Active Chain is to turn the first selection - the Root - into a Passive Rigid. That's how why he doesn't fall over as we run the simulation.

Calling Active Rigid on something that is already dynamic will convert a rigid from Passive to Active, which is exactly what we want.

But he's too stiff. Let's reduce the Global Strength and turn him more into a classic "ragdoll".


Tuning

Yikes! What a mess. Let's see if we can turn spaghetti into an anatomically plausible character.


Volumes

A good first step is usually to ensure our collision shapes do a good job capturing the character. They represent not only how and where to collide against the environment, but also how they should behave; their center of gravity and angular mass.

The arms and legs are fine, let's address the torso.

  1. Select hip_ctl
  2. Edit Shape Radius and Shape Length to fit the model
  3. Repeat for torso_ctl and head_ctl

That's more like it.

Before

After


Clavicles

We're not out of the woods yet. Half-way through the fall, we can spot a few of the worst offending limbs.

  1. Clavicles are dropping
  2. Feet are bending too far
  3. Knees are bending too far

image

Let's address the clavicles first.

image

Here's what we want, the spherical little wooden thing can rotate, but only around one axis. The arm is then attached to this sphere, and is only able to rotate around one other axis.

  1. Select L_clavicle_ctl
  2. Set Rotate Limit X = 60 under the rPoseConstraint node
  3. Set Rotate Limit Y = -1
  4. Set Rotate Limit Z = -1
  5. Repeat this process for R_clavicle_ctl

Now they stick to the sides of the torso, whilst still being able to spin around their length axis.


Feet Geometry

Next let's have a look at those feet.

They intersect the ground, so let's address that first.

  1. Select L_foot_geoShape
  2. Shift select the rRigid shape of L_foot_ctl
  3. Run Replace Geometry
  4. Repeat this process for the other foot
Why is it so complicated

Yes, you are right.

It's because the mesh is under the same parent as the rigid body, so we need to explicitly select the mesh geometry and rdRigid nodes in order to not confuse Ragdoll.

Normally, you would select the mesh from the viewport instead.

There we go, feet that perfectly align with the ground.


Feet Limits

The feet are still bending too far, let's address that.

  1. Select both L_foot_ctl and R_foot_ctl
  2. Set Rotate Limit XYZ to 35.0

But there's a problem. We want the Limit Rotate X axis aligned with our primary rotate axis.

What's special about X?

The X axis of a limit - also known as Twist - is ideal for limbs with only 1 moving axis, like this foot.

  1. Select both L_foot_ctl and R_foot_ctl
  2. Run Edit Constraint Pivots
  3. Using the rotate manipulator in Object mode, rotate 90 degrees along Z
  4. Rotate 90 degrees along Y

Everything allright?

How do I reset my constraint?

Editing pivots can be tricky, and if you make a mistake you can reset a constraint like this.

  1. Remove any existing parentFrame and childFrame handles
  2. Select the rPoseConstraint node
  3. Run Socket Constraint

By re-running a constraint command on an existing constraint, we reset its attributes and pivots to their default values so you can try again.

How do I rotate it?

Make sure that when you rotate, you use the Object or World rotate gizmo and that you include both pivots called parentFrame and childFrame.

Something else happened

Sorry to hear that! Please let me know in the chat or on the forums and I'll try and fix this as soon as possible.

Finally, now we can, lock the Y and Z axes.


Lower Leg Pivots

Let's carry on with the knees.

The knees are special in that they should be able to bend in one direction but not the other, like a typical healthy human knee.

  1. Select L_knee_ctl and R_knee_ctl
  2. Set Rotate Limit X = 40 to see the axis
  3. Run Edit Pivots from the Constraints submenu
  4. Rotate 90 degrees around Z
  5. Rotate 90 degrees around Y


Lower Leg Frames

Now we've got a problem. The knee is able to bend in the wrong direction.

We could try and reduce the range, but that just moves the problem to the other side.

So what we need to do is rotate this limit. For this I'd like to introduce the parent and child frames.

Parent Frame
Child Frame

Here's how to do it.

  1. Select L_knee_ctl and R_knee_ctl
  2. Find these in the Outliner
  3. Select both parentFrame handles
  4. Rotate both parentFrame such that it lines up with the thigh_ctl

Now the knee will only ever bend back, but not forwards. To finish this off, let's lock the Rotate Limit Y and Z axes.

Test it out, by dropping the Manikin from a few different angles. With the legs complete, they should not be able to form an unnatural pose. If they do, you now know how to tune the limits!


Upper Legs

Unlike knees, the upper legs are free to rotate around all 3 axis, X, Y and Z.

  1. Select L_thigh_ctl and R_thigh_ctl
  2. Set Rotate Limit XYZ to 40.0

Let's now use what we've learnt about the parentFrame to tune the range of motion of the thighs.

  1. Select L_thigh_ctl and R_thigh_ctl
  2. Run Edit Pivots under the Constraints submenu
  3. Find and edit both parentFrame nodes


Finalise

You now know enough to construct any character of any anatomy!

You have learnt

  • ✔️ How to limit the motion between two rigids
  • ✔️ How to manipulate the pivot of a constraint
  • ✔️ How to edit the range of motion using the parent frame

With these lessons in mind, try your hand at the remaining parts of the character, namely the Head, Shoulders, Elbows and Hands.

As you tune, try dropping the Manikin from different heights and angles. Put an obstacle underneath for more detail and to catch more edge cases. Once you are unable to produce an unnatural pose, you are done!

Download Completed Scene

For your reference, here is the completed scene with the Manikin file referenced.


Soft Limits

Let's enhance the realism of our character with soft limits

  1. Run Constraints from the Select submenu
  2. Reduce Limit Strength to 0.1

A default value of 1.0 means "very stiff" whereas a value of 0.1 means "less stiff". Depending on the number of limbs your character has, and its physical size and Mass, this value may need to be greater or smaller.

There are two kinds of softness in the world; springy and damped. The defaults values are a little too springy for my taste, so I'll increase the Rotate Limit Damping by adding another 0.

With yet another 0 added, we get some nice subtle "relaxing" of a pose as he's coming to rest on the ground. This is not unlike what you would see if you were to try and relax into a position near your own physical limits.


Practical Examples

So now that we have an anatomically correct character, what can we do with it?

  • We can pose it for motion reference
  • We can transfer the simulation onto another rig
  • We can transition from animation to simulation
  • We can double or triple the amount of characters
  • We can free it from gravity and achieve weightlessness
  • ...


Motion Reference

What would it look like to get shot in this pose, from this specific angle, with this specific force?

  1. Pose the character
  2. Select head_ctl
  3. Run Push Force from the Forces submenu
  4. Give it a high value, such as 20000
  5. Give it a low Max Distance, such as 7.5

By having the head selected, the force is applied onto onto the head.

Use the force visualiser (a.k.a. "Slice") to visualise the force in 3D.

Experiment

This example assigned a force to the head and didn't change the strength of that force. What if you..

  • Assigned a force to the torso, or thigh?
  • Assigned one to the whole body, like an explosion?
  • Increased or decreased the force?
  • ...


Transfer Simulation

Given that we ran our simulation on the actual character rig, exporting the simulation is identical to exporting regular animation. Which means we can use regular animation export tools to transfer this between rigs and characters.

Here's an example using Studio Library; a popular tool for transferring animation between characters and shots in both games and film pipelines.

  1. Bake
  2. Export
  3. Undo

By undoing the bake, we get to keep our simulation after export.

Bake Simulation

Studio Library only deals with keyframes, so we first need to convert our simulation into keyframes.

Export Animation

Next, select all controls and export it like you normally would using Studio Library. After export, you can undo the Bake we did earlier, to restore our physics settings and export produce more results.

Import Animation

In a new scene, with a clean rig - completely unrelated to Ragdoll - import the animation back onto the rig.


Transition From Animation

With access to our reference in full 3D space, with controls similar or identical to our animation rig, why not pass the torch to simulation once we're happy with our animation?

This chapter is in development


Multiple Manikins

Having gone through the trouble of setting this whole thing up, it would be a waste not to multiply our efforts onto more characters!

This chapter is in development


Life

There's no reason our Manikin cannot be alive and well as it drops, using the Mimic along with Soft and Hard Pin controls we can shape the simulation to our will.

This chapter is in development


Space

In an environment without gravity, animation takes on a whole different level of difficulty. We humans are surprisingly good at spotting when weightlessness isn't weightless; you'll know this from watching any space movies like Life or 2001.

With our newfound knowledge and understanding of how to use Mimic and Pins to bring life into a character, let's explore a world beyond earth and head into space.

This chapter is in development


Initial Velocity

So far our Manikin has started out still and either fallen or gotten hit by a force. But what about if our Manikin is in the middle of some motion? We can use a Mimic to give our Manikin some starting velocity.

This chapter is also in development


Last update: 2021-08-27