Notes for Wednesday April 21 -- animation

In general, there are two major components to animation. One component is the subtlety of individual movement. The other is the sequence of what happens next. This week we look at each of these in turn.

Ease curves

First, let us consider individual movement. The most important thing to consider is that in nature, we rarely see things move at a constant velocity. Rather, objects tend to accelerate from rest and then decelerate again to rest when they are done with their movement. Animators know all about this, and integrate it into their workflow through the concept of ease curves. In its essence, an ease curve is an s-shaped curve that starts out with a velocity of zero, accelerates to a steady state velocity, and then at the end decelerates back to a velocity of zero. It is also sometimes called an "S curve", because of its shape. One simple example of an ease curve is the cubic equation 3t2 - 2t3, which has a value and derivative of 0.0 at its start and a value of 1.0 and derivative 0.0 at its end. In practice animators describe the different components of character movement, particularly rotation of limbs, as various overlapping ease curves. A good animator will overlap ease curves that describe, for example, head movement and the movement of various parts of the arms and legs, in such a way that those movements do not start and stop at the same time. Beginning animators will animate all of these things at the same time, whereas the really good animators will artfully begin and end those component ease curves at different times so that the character always seems alive and always seems to be in motion.

Sequencing

The second part of animation is sequencing, the idea that this happens then that happens then another thing happens. This is the basic component of storytelling. One way of effecting this through programming, which we briefly noted last week, is to design all of the animations around a sequence of onset curves, each of which is an ease curve. Any given action can be described by a variable which remains at zero until the onset of that action, then rises via and ease curve to a value of 1.0 over some period of time, and then remains at 1.0 for the duration of the animated narrative.

Once you have such a sequence of control parameters, then you can use those control parameters to tell a story by using various mathematical expressions of those control parameters. In class we showed how you can build a narrative in this way.

Rather than do this completely manually, it is useful to have a data structure and a way of specifying input to that data structure that makes it easy to describe when various events start and other events and in such a way that the animator does not need to worry too much about details of implementation, and rather can focus on the timing.

On top of such a data structure we can build a user interface so that the animator can work visually, just adjusting timing parameters to control the with fine precision exactly when various movements start and stop. In this way we can allow visual designers to work visually while, as programmers who are taking on the scripting portion of an animation, we can work behind the scenes to help make things happen.

In animation that is created by teams, this kind of workflow is very common. You will have at least one person who is an animator who works visually, and then at least one other person who is a programmer or scripter who builds the control mechanisms that the animator is controlling. In a sense this becomes like the computer graphic equivalent of puppetry, where you have some people who build puppets and other people who move those puppets around to create life like movement. In this case we, the programmers, are the makers of the puppets, and the animators are the puppeteers.

In class we created a simple version of all this, which you can build on for your homework.

Then we showed this video:

The Centrifuge Brain Project
Finally, we briefly discussed modeling shapes via implicit surfaces and the Marching Cubes algorithm. We will discuss that in more detail next week.

Homework, due before the start of class on Wednesday April 28

Starting with the code we developed in class, which you can find in hw9.zip, create your own animated scene. Try to tell a visual story of some sort as a visual sequence of events.

Also, make some use of buttons and sliders to allow the person watching your animation to vary things about your animation. For example, you can change the rate that something spins or moves, or change the color of somebody's clothes, or vary how many leaves are on a tree, or change the size of various objects in your scene.

See if you can use the various kinds of shapes that you have learned how to make -- cubes, spheres, cylinders, tori or surfaces of revolution.

Try to think in terms of narrative. Here are a few ideas among the very many possibilities:

  • A tree changes over time. Eg: grows branches and leaves and fruit.
  • Show a sorting algorithm in action.
  • Show how to traverse a maze.
  • Tell a story with characters who enter a room, interact, then leave.
  • Show, step by step, how to assemble a [fill in the blank].
  • Show somebody playing a musical instrument.
  • Show people playing a sport.
  • Show a big dog scaring off a little dog.
  • Show how protons and electrons combine to make hydrogen atoms.
The important thing is to be creative, have fun with it, show something that is of interest to you, convey an interesting story.