O'Reilly logo

Python 2.6 Graphics Cookbook by Mike Ohlson de Fine

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 4. Animation Principles

In this chapter, we will cover:

  • Static shifting of a ball
  • Timed shifting of a ball
  • Animation timed draw-and-erase cycles
  • Two balls moving unimpeded
  • A ball that bounces
  • Bouncing in a gravitational field
  • Colliding balls with tracer trails
  • Elastic ball against ball collisions
  • Dynamic debugging
  • Trajectory tracing
  • Rotating a line and vital trigonometry
  • Rotating lines which rotate lines
  • A digital flower

Introduction

Animation is about making graphic objects move smoothly around a screen. The method to create the sensation of smooth dynamic action is simple:

  1. First present a picture to the viewer's eye.
  2. Allow the image to stay in view for about one-twentieth of a second.
  3. With a minimum of delay, present another picture where objects have ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required