Information Technology Reference
In-Depth Information
the image in pixels and by the number of bits per pixel. For color images, each
pixel needs to hold a minimum of three numbers - to specify the intensity of
the three red, green, and blue components. Raster graphics images cannot be
scaled up in size because the image will appear pixelated - that is, the individual
rectangular pixels making up the image will become visible.
An alternative way of representing images in a computer program is to use
vector graphics . This technique uses simple geometrical shapes such as points,
lines, curves, and rectangles to represent images. Thus a square would be rep-
resented by just four points, one for each corner. Each of these points has infor-
mation that tells the computer how to connect the points - with straight lines
in the case of a square - and what color to use to fill in the enclosed shape.
Vector graphics images can be resized with no loss of detail - the vector points
are just spread out or shrunk as required and the computer can easily redraw
the image. However, for printing, vector graphics images need to be converted
to a bitmap/raster format. The SAGE air defense system was one of the first to
use vector graphics displays.
In the early 1980s, the computer graphics technology used by game design-
ers for the 8-bit microprocessor personal computers of the time was quite prim-
itive compared to the state of the art in computer graphics research. Nowadays,
the hardware technology in game platforms has advanced so much that com-
puter game companies are now some of the leaders in graphics research. We
illustrate some of the early techniques used by game developers for personal
computers by looking at how games were implemented on the Atari 800 and
the Commodore 64.
One of the standard devices for platform video games such as Mario was
side scrolling, in which the characters move across a background screen. Many
of these 8-bit microprocessor-based computers offered hardware support for
scrolling and for sprites , small graphic elements of fixed width and height that
can be positioned independently on the main screen (see Fig. 9.8 ). Atari's 2600
video game console had hardware support for up to five sprites that could be
moved independently of the game background. The Atari 800 home computer
had a similar hardware capability and supported four sprites eight pixels wide
to represent characters and one sprite eight pixels wide that could optionally
be split into four two-pixel wide sprites to represent missiles. The characters
could be moved horizontally and vertically, and the software specified prior-
ities - that is, which image would be visible - whenever two sprites ran into
each other. The computer hardware also supported scrolling the background
by up to fifteen pixels in the horizontal and vertical directions. Larger scroll-
ing movements required shifting the start of the screen display in memory.
The Commodore 64 had similar graphics capabilities and provided hardware
support for scrolling and for eight sprites. Both the Atari and the Commodore
supported a palette of sixteen colors, and the Atari also provided eight lumi-
nance settings. Luminance specifies the amount of light emitted from a given
area and is an indicator of how bright the surface will appear.
By the 1990s, as predicted by Moore's law, microprocessors had become
cheaper and more powerful, and the two-dimensional tricks of these early video
games gave way to true three-dimensional models. Instead of two-dimensional
shapes like circles and rectangles, three-dimensional models allow a wireframe
Horizontal
position
Player
Fig. 9.8. Sprites were graphics devices
used to represent characters or missiles
in early computer games. This figure
shows the Player/Missile sprite for the
Atari 800 home computer.
Search WWH ::




Custom Search