Graphics Reference
In-Depth Information
The composite operation on the left side of the equation refers to compositing the two rendered
images; the merge operation on the right side of the equation refers to combining the geometries of
the two scenes into one. The render function represents the process of rendering an image based on
the input scene geometries. In the case in which the composite operator is used, the render function
must tag pixels not covered by the scene as transparent. The equality will hold if the scenes are disjoint
in depth from the observer and the composite operator gives precedence to the image closer to the
observer. The visibility between elements from the different scenes can be accurately represented
in two-and-a-half dimensional compositing. The visibility between disjoint planes can be accurately
resolved by assigning a single visibility priority to all elements within a single plane.
The image-based over operator places one image on top of the other. In order for over to operate,
there must be some assumption or some additional information indicating which part of the closer
image (also referred to as the overlay plane or foreground image ) occludes the image behind it (the
background image ). In the simplest case, all of the foreground image occludes the background image.
This is useful for the restricted situation in which the foreground image is smaller than the background
image. In this case, the smaller foreground image is often referred to as a sprite . There are usually
two-dimensional coordinates associated with the sprite that locate it relative to the background image
(see Figure A.3 ) .
However, for most cases, additional information in the form of an occlusion mask (also referred to
as a matte or key ) is provided along with the overlay image. A one-bit matte can be used to indicate
which pixels of the foreground image should occlude the background during the compositing process
(see Figure A.4 ) . In frame buffer displays, this technique is often used to overlay text or a cursor on top
of an image.
Compositing is a binary operation, combining two images into a single image. However, any num-
ber of images can be composited to form a final image. The images must be ordered by depth and are
Scene 1
Scene 2
Image 2
Image 2
“over”
Sprite positioning
FIGURE A.3
Two-and-a-half dimensional compositing without transparency.
 
Search WWH ::




Custom Search