[MUSIC] The human body is a single complex object, but one whose individual parts move in different ways. My hands and head are all part of my body and tightly linked, but I can move them all pretty independently. Like most 3D graphics objects, human bodies are represented as a polygon mesh. But unlike other object it isn't enough to simply move the whole thing around with a single transform. We need to move our limbs. We could create a compound object with separate objects for our hands, lower arm, and upper arm, and this is what the early computer games and computer graphics did, but it isn't very realistic. My lower arm and upper arm are not separate objects, even though they move relative to each other. They form a single smooth surface. So now a days we do something a bit more clever. While the body is complex, and it's outward appearance has many features, the majority of the movement actually comes down to the movement of the skeleton. The skeleton consists of a number of rigid bones linked together by rotational joints. When we move, our joints rotate. And so rotate our bones relative to each other. In 3D character animation, we have a single, probably very complex mesh to represent the body. But we also separately represent the skeleton. The skeleton is a series of rigid links with bones, with rotational transforms, the joints. We animate the character by rotating those joints. These rotations are then mapped onto the mesh using a process called smooth skinning. Which is done automatically in the GPU. This results in a realistically moving mesh. But we don't have to think of the individual movements of all the vertices, we only have to animate the joints. This makes our animation data relatively simple. It's just the number of key frames to the rotations of the joint. Setting up this kind of skeleton animation can be quite complex as we need to create a realistic mesh and also a skeleton, which consists of a number of transforms. These transforms are hierarchical. That means that each transform has transforms attached as children and these children themselves have children. So my shoulder has my upper arm as a child, which has my lower arm, which has my hand, my hand is very complex with a child for each finger. This skeleton needs to be attached to the mesh, which means that we need to say which bone each vertex is attached to, a process called rigging. To achieve smooth movement, vertices can be attached to several bones. This whole process is pretty hard work. Most animation packages will partially automate it, but it rarely works perfectly. Luckily, as usual, the asset store comes to our rescue and contains a number of excellent pre-rigged characters. Skeletal animation works in a process called forward kinematics or FK. I rotate a joint, for example, my shoulder. That moves my whole arm. I then rotate my elbow, which moves my lower arm and my wrist which moves my hand. The position of my hand is worked out by starting at the top joint, my shoulder, and applying its rotation and then going down each joint in turn applying that rotation, until we reach the hand itself. FK is just handled automatically by the way transforms work. And you really don't have to think about it at all. The only reason I mentioned it is because we need to know about its opposite, inverse kinematics, or IK. Forward kinematics can be quite complex to animate with. Often we just want the hand to be in a particular position, maybe to pick something up. Doing that with FFK is very fiddly. I will take my shoulder to where I think it should be. Then my elbow. Then my wrist. It's kind of there but not quite or it doesn't look right. So it has to go back to tweak my shoulder and it all continues. That's why inverse kinematics was invented. IK is an algorithm which takes the position where you want the hand, and does a load of calculations to work out what the rotations of all the joints should be, to get your hand in the right position. It's very useful for animation, and it's included as standard in most 3D animation packages, like Myer, 3D Studio, Max or Blender. But it's also useful for doing real time interaction. For example, getting characters to pick up objects. Or even doing a fist bump with you. It isn't just for arms either. We'll see in a future video how we can use it to get cowards to look at things. Skeletal animation is a very powerful and flexible technique for human body animation. And we'll see in future videos that it underlies all the more complex things that we'll want to do with body language. [MUSIC]