Engineering Inside:

2014 Issue 4
Animation

The Art of Programming in Computer Animation

December 2014

by Robin Hegg

AnimatorsWhether it’s a hand-drawn cartoon or a computer-built special effect, animation can tell us us stories we could otherwise only imagine. With the rise of 3D computer animation, these visual stories can be even more realistic and convincing than ever before, allowing the viewer to be more fully immersed in the story. Computer animation also means that there is science, math, and engineering behind the artistry of animation. Computer programmers and engineers are writing the code that determines how accurate and lifelike animated scenes and characters will be.

Computer animation software allows animators to do things they wouldn’t otherwise be able to do. They can put together complicated group shots without the need of extras, mimic complicated lighting setups, create characters that costume and makeup might not duplicate, and create convincing 3D illusions. Mathematical algorithms are used to recreate the movement of characters and other natural elements like leaves, fire, fur, hair, and groups of animals. Objects can be programmed to follow the physical laws of nature or to break them.

Laptop with reelAll animation works by using a series of quickly moving still images to trick the viewer into thinking they are seeing a smoothly moving scene. In order to cause this illusion, the individual drawings or frames, should be viewed at around 12 frames per second or faster. In computer animation, the animator creates keyframes, setting the positions of characters and objects. A process called “tweening,” fills in the movement in between the two keyframes.

Characters and other objects in 3D computer animation are modeled on the computer using modeling software. An object model is made up of individual three-dimensional shapes, which can be “sculpted” using virtual sculpting tools. Another technique, called spline-based modeling, can be used to create objects with smooth, curved lines. Objects can also be physically sculpted and then scanned with a 3D scanner to create a wireframe of the object in the modeling software. In addition to an object’s model or wireframe, objects can also be given a virtual skeleton, which allows the animator to define how and where the object moves and where different control points are positioned.


Get a behind-the-scenes look into the world of 3D animation (credit: Universal Pictures UK)

Once an object has been modeled, its surface can be shaded, and color and texture can be added. Lighting the object is one of the best ways to give it depth and realism. Modeling programs allow the animator to light the object from any angle and to adjust how the object’s surface reflects or absorbs light.

Animating a character—giving it movement—presents a new set of challenges. Viewers’ eyes are very sensitive to jerky or unnatural movements, and some everyday movements are incredibly complex. Walking, for example, requires just about every part of the body to carry out a single motion. This is where the character’s virtual skeleton and clever programming come into play.

A character’s skeleton allows the animator to move the character through space by defining animation variables or avars of different parts of the character. The character Woody in Toy Story (the first full-length 3D computer animated cartoon) contained 712 avars, with 212 of those in his face alone. These control points allow the animator to define the character’s position and orientation. The animator changes the values of the avars over time, thus creating movement from frame to frame.

Aside from the skeleton itself, virtual bones and joints are also assigned to act according to a hierarchy that mimics natural movement. If a character is going to reach for an object, the computer will take into account not just the hand moving forward, but the parts of the hand and fingers, the forearm, elbow, upper arm, and shoulder. Kinematics is the term used for the science of movement. Inverse kinematics (the use of kinematics equations to determine movement) are used to determine a character’s movements and desired position. Inverse kinematic models for walking and other common movements are often pre-loaded in animation software.

Another way to animate a 3D character is through the use of motion capture. Motion capture uses a live-action actor who performs as if they were the animated character. The actor’s movements are recorded using sensors and those movements are then applied to the animated character. The use of motion capture can be used to create smooth, natural movements.

Modeling and animating human faces so they look real is one of the greatest challenges of computer animation. Because facial expressions are so complex, computer facial animation involves a very large number of animation variables. The Facial Action Coding System (FACS) is a popular basis for many animation systems, Developed in 1976, the FACS encodes the movements of facial muscles based on changes in facial appearance. In 2001, MPEG-4 included 68 Face Animation Parameters (FAPs) that control key points on a face model to create facial expressions. Lots of developments have been made since then and facial microexpressions (small facial movements) have begun to be included in animation and programming. The PAD emotional state model, a psychological model used to study nonverbal communication, can be used to assign specific emotions to animated faces. PAD measures emotions in terms of three scales: the Pleasure-Displeasure Scale, the Arousal-Nonarousal Scale, and the Dominance-Submissiveness Scale. Animators can assign different levels of expression to faces—some to control larger movements and others to display more subtle emotional states.


See how computer technology is used to develop characters’ facial expressions (credit: Intel)

In addition to the technical difficulty of creating realistic human characters and faces, animators can also run into the problem of the “uncanny valley.” The uncanny valley refers to the tendency for audiences to react with a sense of discomfort or revulsion once human characters reach a certain point of realism. Though audiences may have positive reactions as characters look more realistic, when they get too human-looking, audiences have a very negative reaction. Theories about why this happens include the idea that as representations of humans get less distinguishable from real humans, the differences viewers pick up on take on new and unsettling significance.

Creating 3D computer animation that can fully immerse the audience in a story requires both skilled artistry and engineering. The application of hard science, research, and skillful software design all come together to create more realistic and detailed animation that can lead to more powerful stories for the audience, helping to lift the limits on what stories can be told through animation.

Related Story: Check out the winners of the 2014 IEEE Innovation through Animation Competition.

Judge’s Choice Winner: The Big Field of Small Things: Nanotechnology by Ambrose Cavalier

People’s Choice Winner: Nanotechnology Based Brain Surgery by Patrick Gabriel Negulescu

 

 

Leave a comment

TIPS AND ADVICE

Explore Computer Animation with Animation Software

If you want to give computer animation a try, there’s plenty of fun, free, and even professional quality software available online to help you get started.

Read more

IEEE SPOTLIGHT

IEEE Supporting Animation Technology

The IEEE has numerous organizations, publications, and conferences that help to support research and development in the field of animation technology.

Read more

Find a University

Search for accredited engineering degree programs throughout the world. Launch