Information Technology Reference
In-Depth Information
project the features of the round original onto a flat surface. There are a number of different ways of projecting
maps, and all of them must by definition produce distortion. The effect of this distortion is that distances measured
near the extremities of the map appear further than they actually are. Another effect is that great circle routes (the
shortest or longest path between two places on a planet) appear curved on a projected map. The type of projection
used is usually printed somewhere on the map, a very common system being that due to Mercator. Clearly the
process of mapping involves some three-dimensional geometry in order to simulate the paths of light rays from the
map so that they appear to have come from the curved surface. Video effects machines work in exactly the same
way. It is an interesting demonstration of the evolving power of microelectronics that the circuitry developed for
DVEs costing hundreds of thousands of dollars in the 1980s is now just part of an MPEG-4 decoder chip.
The distortion of maps means that things are not where they seem. In timesharing computers, every user appears
to have his own identical address space in which his program resides, despite the fact that many different
programs are simultaneously in the memory. In order to resolve this contradiction, memory management units are
constructed which add a constant value to the address which the user thinks he has (the virtual address ) in order to
produce the physical address . As long as the unit gives each user a different constant, they can all program in the
same virtual address space without one corrupting another's programs. Because the program is no longer where it
seems to be, the term mapping was introduced. The address space of a computer is one-dimensional, but a video
frame expressed as rows and columns of pixels can be considered to have a two-dimensional address as in Figure
3.30 . Video manipulators work by mapping the pixel addresses in two dimensions.
Figure 3.30: The entire TV picture can be broken down into uniquely addressable pixels.
Every pixel in the frame array has an address. The address is twodimensional, because in order to uniquely specify
one pixel, the column address and the row address must be supplied. It is possible to transform a picture by
simultaneously addressing in rows and columns. It was discovered some time ago in connection with computer
graphics that the two-dimensional problem can sometimes be converted into two onedimensional problems. [ 12 ]
Essentially if a horizontal transform affecting whole rows of pixels independently of other rows is performed on the
array, followed by or preceded by a vertical transform which affects entire columns independently of other columns,
the effect will be the same as if a two-dimensional transform had been performed. This is the principle of
separability.
There are many different manipulations needed in warping, and the approach here will be to begin with the
simplest, which require the least processing, and to graduate to the most complex, introducing the necessary
processes at each stage. Initially the examples given will be one-dimensional. Figure 3.31 shows a single row of
pixels which are held in a buffer where each can be addressed individually and transferred to another. If a constant
is added to the read address, the selected pixel will be to the right of the place where it will be put. This has the
effect of moving the picture to the left. If the buffer represented a column of pixels, the picture would be moved
vertically. As these two transforms can be controlled independently, the picture could be moved diagonally.
If the read address is multiplied by a constant, say 2, the effect is to bring samples from the input closer together on
the output, so that the picture size is reduced. Again independent control of the horizontal and vertical transforms is
possible, so that the aspect ratio of the picture can be modified. Clearly the secret of these manipulations is in the
constants fed to the address generators. The added constant represents displacement, and the multiplied constant
represents magnification. A multiplier constant of less than one will result in the picture getting larger. Figure 3.31
also shows, however, that there is a problem. If a constant of 0.5 is used, to make the picture twice as large, half of
the addresses generated are not integers. A memory does not understand an address of two and a half! If an
arbitrary magnification is used, nearly all the addresses generated are non-integer. A similar problem crops up if a
constant of less than one is added to the address in an attempt to move the picture less than the pixel spacing. The
solution to the problem is to use the interpolation techniques described earlier in this chapter. Because the input
Search WWH ::




Custom Search