Skip to content

Posts tagged ‘Character’

Rules on modeling for games, and deformation.

October 7, 2008

Charles

As I’m currently in the process of skinning many meshes for the current game I’m working on here are some rules I’ve learnt on the way:

  • Don’t attempt to skin spherical deformation without having bones for deformation or quaternion based skinning methods. Key places where this must happen is the shoulders, thighs, elbows, knees, wrists and ankles.
  • You don’t need lots of twist bones, three including the actual bone is enough e.g shoulder *deformer bone, main twist (100% to upper arm with a direction pointing to the deformer bone), 50% twist bone, 0% twist (100% to the upper arm)

*By deformer bone i mean a tweak bone/point, etc  has average deformations between the  shoulder and upper arm. Similar to elbow or wrist deformer bones.

  • Don’t model the wrist/hand attached to the sleeve, tuck it inside and treat it as an element. The same applies to the ankle/foot and trouser leg.
  • If you don’t see the underside of a mesh, don’t model it, cap it off. A good example of this is a skirt.
  • The deformation of the wrist is not the same as the elbow or shoulder; the shoulder can be considered a one dimensional quaternion – in this i mean its twist is dictated by its direction.  The wrist could be considered two dimension as the first quaternions direction dictates the rotation space (one plane) for the second quaternion to ride on.  The wrist bone dictating the direction for the hand to ride on, as oppose to the upper arm bones direction dictating the entire deformation of the shoulder.
I’ll discuss more on the differences of the wrist compared to the shoulder in later posts.

Using tangent direction to dictate quaternions.

June 23, 2008

Charles

Just a quick theoretical idea – I’ve been thinking that a rotation is basically the reflection or product of a direction indirectly or directly controlled by its spin.  This seems simple to understand in theory but in practice its more complex. Im coming to terms that rotation is really an illusion of a direction or a side product.

Thinking about this more in my notes, we can hypothesize that if a rotation is really just a direction, then we can seperate it into two parts: the direction and the spin and more importantly have direction controlled by anything, namely the tangent of a spline or curve. This seems amazingly simple now, the curviture of a spline dictating the direction of a quaternion about a hemisphere. But detaching yourself to thinking this way is really hard.

In this way we can treat the wrist and spine articulation the same – the spin (or twist in the conventional sence) is just used to dictate the direction of the system, with a spine you’d use the tangent of the curve itself,  with the wrist the hand  is the direction.

Simple dynamics and clickability!

October 9, 2007

Charles

I tend to think in small chunks – I break down an idea, work out each part and then put it back together hopefully. I’m trying to use this approach with dynamics – I’m looking into a simple system to handle a variety of situations. Currently I’m thinking of simple spherical detection. This method use just a diameter from a point – its a simple system, but it might be scalable for more complexity.

Dynamics I find very hard to get to grips with, I have to take it very very slowly. Just understanding derivatives is hard, as its the function of the equation. Its also very fragile as a system – finite tweaks make big changes, especially in complex systems. My aim is to build simple systems that can be ‘bolted’ together right across the board from dynamics, to transformation stuff. Its sort of the middle man of rigging. I’m not the string or the parts of the puppet, im the knots that tie the string to the parts.

Rigging retrospective (part one)

August 20, 2007

Charles

So Ive been away on vacation over the past two weeks in beautiful Montreal (an amazing city). I had time to think about rigging, ways to break it up and what it is at its heart: intergrating systems.

Rigging can be regarded as modular in one sence and choatic in another. It can also be though of a group of systems that interact with each other in simple and hybrid types of ways. There are three main ‘Driven Systems’ at its heart:

Kinematic – the animator drives the rig with keyframes, purely controlling the puppet and f-curves

Procedural – the animator drives values which adds automatic driven motion, the wave if you will doesnt however have to be procedural and handmade in a fourier synthetic way.

Dynamic – the animator drives controls in which there ‘children’ act in a physically based way. The controls themselves could also act dynamic.

Theses are the bases, but many hybrid versions of these can be combined, waves driving dynamics for instance. A rig should only support this if its really really neccesary – we need to understand what a rig needs. At its heart is what the animator wants, especially interms of control. But we can also make our own assumptions and give some basic rules in constructing a rig:

1. A rig is a series of systems.

This can be a hard idea to understand, but if we treat a part of a rig as a system than a series of joints (more of an outwardly looking in analysis), we can work out what we need. A good example is a tentacle – because were are treating this entirely as a system – e.g. a splineIK base with a layer of FK controls. The tentacle is treated as a whole unit and this is how we should look at it when rigging. Lets break it down:

A tentacle that needs to be fk, dynamic, driven and procedural – we’ll first off we can pair these together fk/procedural and dynamic/driven as a system. By doing this we can see that the fk/procedural can ‘ride’ the dynamic driven system. And this dynamic driven system itself can be treated as one: A dynamic chain solution that rides a bezier spline based on tension, and a fk procedural system that rides this in tern.

A tentacle is essentially an easy example as we regard it as unit, but can this be the same for a wing, leg or even spine? A spine or torso can be summed up as three independant units that are glued together either or additionally by a positon or a main control. It can be regarded as a system. A wing is essentially an arm, that feathers ride along and intern have dynamics (air resistance etc)

Modular continuity

July 31, 2007

Charles

Im looking into areas that can essentially be shared  – modular continuity between arms/legs etc on biped and quadrapedal rigs (even bird rigs). Its opened up some interesting ideas namely to first break the lower arm in half and some oddities in the foot.

Breaking the lower arm in half basically allows for a front arm to act like a front leg of a quadrapedal – why is this important well for one thing it allows a quadraped to act like a biped and vice versa. It doesnt mean you would nessesarily use it in a biped rig, but its a simple additional that allows for the control.

For the foot rig – ive seemed to find a stumbling block namely where the control of the foot goes? In human locomotion the pivot exists at the heel, but when its on the ground its at the ball. The problem is even more compounded in that we both swivel and hinge about the heel – hinging is a simple heel<>ball setup, but swivel is more of a problem. Do we change the transform space of the main control if its at the ball or add an additional layered control?

The problem is exactly the same and virtually opposite if the main control is the ankle, you get heel and swivel control but ball of foot swivel is lost.  Its not truely lost, you could drive its z rotation of the roll controls z rotation but, as where dealing with ik system our trigonometry plane space would freak out and the foot as a whole would twist – the old gimbal problem looming as two rotations overlap each other.

The art of rigging: relativity & reference

July 24, 2007

Charles

Probably the most important aspect of rigging, infact what we can sum rigging up is relativity – everything relies on. If its the mesh its relative to a skin, the to the bones and the bones to a rig. And even at the finite level the controls of the rig are relative to a other controls – they exist in a space of there own but are relative to something else even if this is the world.

Rigging is relativity and reference – its a bold statement but is the basis for everything needed. Everytime you parent or constrain an object to another you set its relativity and its reference. The key to rigging is a system where both dont fight but work hand in hand with one another. A good example is the spine – the animator wants control of the hip, chest and head. But also wants control of the torso (everything) – they also dont want counterotation and the ability to hold a pose.

 Its a lot of systems but if we boil it down to relativity and reference its relatively (pardon the pun) straight forward. The hips are parented to the torso – so we have defined a refence: the torso and a relavity (torso-hip) to work in. The chest is parented to the torso, the same applies here. But the head is different the neck is really a part of the spine and really moves with the chest, but the problem comes in that we want it to move with the head when needed.

So we define 2 references – firstly we set the heads position relative to the chest, but its rotation to the torso. This means when we rotate the chest the head moves with it but crucial stays pointing at a target. But additional if we move the head the neck will follow – this is via an ik system or lookat/pole vector – simple stuff.

So when building a rig really understand whats relative to what, and understand the methods and math of space.

Rigging ground rules.

June 8, 2006

Charles

A lot of people ask me what goes into a rig? – This really isnt a question you should be asking but rather what does the character need to do?. There are however a certain set of key features most rigs have and need, bar all the stretch and even twist setups:

  1. A method to control the entire torso.
  2. A method to control the upper torso.
  3. A method to rotate/move the hips independent of the torso.
  4. A method to rotate/move the chest independent of the hips and head.
  5. Shoulder controls
  6. FK/IK arms and legs
  7. FK foot controls
  8. A method to rotate the foot at the heel, ball and toe.*

Extras:

  1. Animatable pivots
  2. Curl controls on fingers, pose tool etc.

 *I generally have an expression that drives the entire foot roll – its an important feature to have, as for quick lifts etc it’s neccesary. Eg walking up a ladder. I also introduce ‘Natural Foot’ which allows the foot to ‘peel’ off its controls, if it reaches to far.

From developing  40 or so rigs for my last company, we came up with a pretty solid rig splitting the torso into two parts: ‘Torso’ and ‘Upper Torso’ – Torso essential drives everything from the pelvis up. With Upper Torso driving the head, neck arms and chest.

The need to lock the head either by a target or just its orientation is crucial too – personally I still like to be able to move/rotate the head with the torso and upper torso controls, including a  blend to lock the head when needed.

With skinning you need to introduce twist bones, these essentially can be as many bones as you want. Valve with HL2 introduced ‘interpolator’ bones at elbows, shoulders, knees etc, to aid skinning.