Computer Animation
Algorithms and Techniques
Rick Parent
Ohio State University
T hird Edit io n
Table of Contents
Title page
Copyright
Dedication
Preface
Overview
Organization of the Book
Acknowledgments
About the Author
Chapter 1. Introduction
1.1 Motion perception
1.2 The heritage of animation
1.3 Animation production
1.4 Computer animation production
1.5 A brief history of computer animation
1.6 Summary
References
Chapter 2. Technical Background
2.1 Spaces and transformations
2.2 Orientation representation
2.3 Summary
References
Chapter 3. Interpolating Values
3.1 Interpolation
3.2 Controlling the motion of a point along a curve
3.3 Interpolation of orientations
3.4 Working with paths
3.5 Chapter summary
References
Chapter 4. Interpolation-Based Animation
4.1 Key-frame systems
4.2 Animation languages
4.3 Deforming objects
4.4 Three-dimensional shape interpolation
4.5 Morphing (two-dimensional)
4.6 Chapter summary
References
Chapter 5. Kinematic Linkages
5.1 Hierarchical modeling
5.2 Forward kinematics
5.3 Inverse kinematics
5.4 Chapter summary
References
Chapter 6. Motion Capture
6.1 Motion capture technologies
6.2 Processing the images
6.3 Camera calibration
6.4 Three-dimensional position reconstruction
6.5 Fitting to the skeleton
6.6 Output from motion capture systems
6.7 Manipulating motion capture data
6.8 Chapter summary
References
Chapter 7. Physically Based Animation
7.1 Basic physics—a review
7.2 Spring animation examples
7.3 Particle systems
7.4 Rigid body simulation
7.5 Cloth
7.6 Enforcing soft and hard constraints
7.7 Chapter summary
References
Chapter 8. Fluids: Liquids and Gases
8.1 Specific fluid models
8.2 Computational fluid dynamics
8.3 Chapter summary
References
Chapter 9. Modeling and Animating Human Figures
9.1 Overview of virtual human representation
9.2 Reaching and grasping
9.3 Walking
9.4 Coverings
9.5 Chapter summary
References
Chapter 10. Facial Animation
10.1 The human face
10.2 Facial models
10.3 Animating the face
10.4 Lip-sync animation
10.5 Chapter summary
References
Chapter 11. Behavioral Animation
11.1 Primitive behaviors
11.2 Knowledge of the environment
11.3 Modeling intelligent behavior
11.4 Crowds
11.6 Chapter summary
References
Chapter 12. Special Models for Animation
12.1 Implicit surfaces
12.2 Plants
12.3 Subdivision surfaces
12.4 Chapter summary
References
APPENDIX A: Rendering Issues
APPENDIX B: Background Information and Techniques
B.1 Vectors and matrices
B.2 Geometric computations
B.3 Transformations
B.4 Denevit and Hartenberg representation for linked appendages
B.5 Interpolating and approximating curves
B.6 Randomness
B.7 Physics primer
B.8 Numerical integration techniques
B.9 Optimization
B.10 Standards for moving pictures
B.11 Camera calibration
Index
Copyright
Acquiring Edit o r: St even Ellio t
Develo pment  Edit o r: Ro byn Day
Pro ject  Manager: Paul Go t t ehrer
Designer: Jo anne Blank
Morgan Kaufmann is an imprint of Elsevier
225 Wyman Street, Waltham, MA 02451, USA
©  2012 Elsevier Inc. All rights reserved.
No part of this publication may be reproduced or transmitted in any form or by any means, electronic or mechanical,
including photocopying, recording, or any information storage and retrieval system, without permission in writing from the
publisher. Details on how to seek permission, further information about the Publisher’s permissions policies and our
arrangements with organizations such as the Copyright Clearance Center and the Copyright Licensing Agency, can be
found at our website: www.elsevier.com/permissions.
This book and the individual contributions contained in it are protected under copyright by the Publisher (other than as
may be noted herein).
Notices
Knowledge and best practice in this field are constantly changing. As new research and experience broaden our
understanding, changes in research methods or professional practices, may become necessary. Practitioners and
researchers must always rely on their own experience and knowledge in evaluating and using any information or
methods described herein. In using such information or methods they should be mindful of their own safety and the
safety of others, including parties for whom they have a professional responsibility.
To the fullest extent of the law, neither the Publisher nor the authors, contributors, or editors, assume any liability for any
injury and/or damage to persons or property as a matter of products liability, negligence or otherwise, or from any use or
operation of any methods, products, instructions, or ideas contained in the material herein.
Library o f Co ngress Cat alo ging-in-Publicat io n Dat a
Application submitted
Brit ish Library Cat alo guing-in-Publicat io n Dat a
A catalogue record for this book is available from the British Library.
ISBN: 978-0-12-415842-9
Printed in the United States of America
12 13 14 16 16  10 9 8 7 6 5 4 3 2 1
For information on all MK publications visit our website at http://store.elsevier.com
Dedication
To Kim and John, for teaching me to keep things in perspective.
And to my wife, Arlene, for her attention-to-detail approach to life, especially when juxtaposed
to my ‘big picture’ way of doing things.
Preface
It  should  come  as  no  surprise  to  anyone  reading  this  book  that  activity  in  Computer
Animation has exploded in recent years - as a research area, as an academic field of study, as
a  career,  and  even  as  a  hobby.  Feature  length  films  are  now  often  stored  digitally  and
incorporate  digital  special  effects  (often  referred  to  as computer  generated  imagery  and
abbreviated CGI). As listed by the Internet Movie Database (imdb.com) [1] as of March 2012, all
of the top 10 U.S. films (All-Time U.S. Box Office) depend on extensive use of CGI. Computer
animated  films  have  become  top  box  office  attractions  -  according  to  the  same  movie
database, 2 of the top 10 feature length films are computer animations (Shrek 2 and Toy Story
3) with a third having a significant computer animation component (Avatar). Recent Technical
Achievement and Scientific and Engineering awards from the Motion Picture Academy of Arts
and  Sciences  have  been  for  digital  image  technology  including  render  queue  management,
facial motion retargeting, tools to review digital effects, and efficient rendering of volumetric
effects, just to name a few [2]. And, of course, the computer game industry has exploded. The
Entertainment Software Association estimate that, in 2010, consumers spent $25.1 billion on
video games, hardware and accessories [3].
Computer  animation  is  more  accessible  that  ever.  Desktop,  high-quality,  computer
animation is now possible because of sophisticated off-the-shelf animation software, cheap
CPU cycles, and cheap storage coupled with digital video recording. Many technical programs
and  computer  science  departments  now  offer  courses  in  computer  animation  and  the
proliferating artistic programs train digital artists in the use of off-the-shelf animation software.
There  are  now  major  technical  conferences  and  journals  that  archive  developments  in
computer animation and video game algorithms and techniques.
This  book  addresses  practical  issues,  provides  accessible  techniques,  and  offers
straightforward implementations. Purely theoretical discussions have been avoided except to
point out avenues of current and future research. In some cases, programming examples are
complete working code segments—in C, which can be copied, compiled, and run to produce
basic  examples  of  the  algorithms  discussed;  other  programming  examples  are  C-like
pseudocode  that  can  be  translated  into  working  code.  C  was  chosen  because  it  forms  the
common basis for languages such as C++ and Java, and it lends itself to illustrating the step-
by-step nature of algorithms. The Appendixes cover basic material that the reader may find
useful as a refresher as well as specific algorithms for use in implementations.
Overview
This  book  surveys  computer  algorithms  and  programming  techniques  for  specifying  and
generating motion for graphical objects, that is, computer animation. It is primarily concerned
with 
is  advanced
undergraduate  or  beginning  graduate  students  in  Computer  Science.  Computer  graphics
programmers who want to learn the basics of computer animation programming and artists
who use software packages to generate computer animation (digital animators) who want to
better understand the underlying computational issues of animation software will also benefit
from this book.
three-dimensional  (3D)  computer  animation.  The  main  audience 
This text is not intended for animators using off-the-shelf animation software (except to
the  extent  that  it  might  help  in  understanding  the  underlying  computations  required  for  a
particular technique). It does not attempt to cover the theory of computer animation, address
the  aesthetics  of  computer  animation,  or  discuss  the  artistic  issues  involved  in  designing
animations.  It  does  not  detail  the  production  issues  in  the  actual  commercial  enterprise  of
producing a finished piece of animation. And, finally, it does not address the issue of computer-
assisted  animation,  which,  for  our  purposes,  is  taken  to  mean  the  computerization  of
conventional hand-drawn techniques; for the most part, that area has its own set of separate
issues [4] [5].  The  book  does  concentrate  on  full  3D  computer  animation  and  identifies  the
useful algorithms and techniques that animators and programmers can use to move objects in
interesting ways. While 3D techniques are the emphasis, 2D is not completely ignored.
The  fundamental  objective  of  computer  animation  programming  is  to  select  techniques
and design tools that are expressive enough for animators to specify what they intend, yet at
the same time are powerful enough to relieve animators from specifying any details they are
not  interested  in.  Obviously,  no  one  tool  is  going  to  be  right  for  every  animator,  for  every
animation, or even for every scene in a single animation. The appropriateness of a particular
animation  tool  depends  on  the  effect  desired  and  the  control  required  by  the  animator. An
artistic  piece  of  animation  will  usually  require  tools  different  from  those  required  by  an
animation that simulates reality or educates a patient. In this spirit, alternative approaches are
presented whenever possible.