Graphics Reference
In-Depth Information
2 4 6 8 1012 14 16 18 20 22 24 26 28 30 32
frames
Fig. 5.2. A function curve relating brightness to frame number.
in computer animation to control the movement of objects, lights and the
virtual camera. But instead of depicting the relationship between x and y , the
graphs show the relationship between an activity such as movement, rotation,
size, brightness, colour, etc., with time. Figure 5.2 shows an example where
the horizontal axis marks the progress of time in animation frames, and the
vertical axis records the corresponding brightness of a virtual light source.
Such a function forms part of the animator's user interface, and communicates
in a very intuitive manner the brightness of the light source for every frame
of animation. The animator can then make changes to the function with the
aid of interactive software tools.
5.1.2 Geometric Shapes
Computer graphics requires that 2D shapes and 3D objects have a numerical
description of some sort. Shapes can include polygons, circles, arbitrary curves,
mathematical functions, fractals, etc., and objects can be faceted, smooth,
bumpy, furry, gaseous, etc. For the moment, though, we will only consider 2D
shapes.
5.1.3 Polygonal Shapes
A polygon is constructed from a sequence of vertices (points) as shown in
Figure 5.3. A straight line is assumed to link each pair of neighbouring ver-
tices; intermediate points on the line are not explicitly stored. There is no
convention for starting a chain of vertices, but software will often dictate
whether polygons have a clockwise or anti-clockwise vertex sequence. If the
vertices in Figure 5.3 had been created in an anti-clockwise sequence, they
could be represented in a tabular form as shown, where the starting vertex is
(1, 1), but this is arbitrary.
Search WWH ::




Custom Search