Exact Antialiasing of Textured Terrain Models

Exact Antialiasing of Textured Terrain Models

1 Introduction Images of continuous scenes that contain arbitrarily high spatial frequencies are sample and represented in a finite set of raster pixels. Due to the discrete nature of the image raster, the image is limited to display only a finite range of frequencies. Aliasing is a phenomenon caused by high frequencies sampled at a lower rate. Spatial domain aliasing produces artifacts such as Moire patterns or jagged edges. Spatial aliasing, which can be acceptable in a still image, can cause stronger visual artifacts in a real-time animated sequence of images. An eye-irritating e¤ect caused by spatio-temporal domain aliasing is known as flickering. This is due to the display of Exact antialiasing high frequencies at falsely spatial locations that are not correlated in time, which causes sudden of textured terrain changes in pixel values. Antialiasing techniques use subpixel accuracy to models reduce or eliminate aliasing artifacts. Accurate spatial antialiasing reduces flickering due to the coherency exhibited among the images in the time Daniel Cohen-Or domain (shown in Sect. 5). Thus, real-time anima- tions of textured models must employ a very accu- Computer Science Department, School of Mathemat- rate antialiasing technique to avoid the disturbing ical Sciences, Tel-Aviv University, Ramat-Aviv 69978, Israel flickering. However, embedding accurate anti- e-mail: [email protected] aliasing into the rendering process traditionally causes a serious performance degradation, which conflicts with the real-time requirement. The anti- aliasing technique presented in this paper is We introduce a fast area-sampling anti- embedded in an algorithm that renders textured aliasing technique for textured terrain terrains. models. We scan the model in image or- The paper is structured as follows. In Sect. 2, der, averaging the pixel footprint values. a brief review of antialiasing methods of textured The technique samples all, but only, the models is presented In Sect. 3, previous works on visible parts. It improves previous texture terrain rendering are surveyed and the scheme mapping methods that ignore self- that is implemented in this work is introduced. occluded footprints. It is superior to The new antialiasing technique is introduced in super-sampling. The image quality is as- Sect 4. In Sect. 5, it is shown that, by implement- sessed in both spatial and temporal do- ing exact spatial aliasing, the technique reduces mains. The good precision of the sampling temporal aliasing artifacts. The algorithm’s cost is process in the spatial domain provides an analyzed in Sect. 6, and in Sect. 7 we show results alias-free temporal domain. The low com- from a few test cases. We end with conclusions in putational cost of the rendering technique Sect. 8. and its high-quality filtering in the spatio- temporal domain o¤er a tool for real-time rendering of discrete terrain models. Key words: Terrian visualization Ð Visual 2 Antialiasing techniques simulations Ð Voxel-based modelling Ð Antialiasing methods can be regarded as an ap- Ray casting Ð Antialiasing Ð Area samp- proximation of the convolution integral between ling Ð Supersampling the continuous image I and a filter kernel H at The Visual Computer (1997) 13:184Ð198 184 ( Springer-Verlag 1997 every output point S(i, j ) of the image: approximation of the pixel footprint over texture space. Common space-variant techniques (Watt S(i, j )":: I(i#x, j#y)H(x, y) dxdy. (1) and Watt 1992), however, do not account for subpixel visibility and convolve the entire foot- Supersampling is a common antialiasing technique print including its occluded parts. that approximates this integral. It samples the The antialiasing technique presented in this paper continuous image at N times the output image uses a space-variant filter that is exact in the sense resolution. The samples are then low-pass filtered that it computes area sampling rather than super- at the Nyquist limit of one cycle every two pixels. sampling. The pixel footprint is scanned, and only In computer graphics images, the spectrum en- its visible area is filtered (averaged). A multi- ergy does not necessarily fall o¤ with increasing resolution prefiltered pyramid is employed to re- spatial frequencies, and some aliasing may always duce the complexity of large footprints. be introduced. This is due to the fact that the filter is applied only after the image is sampled and not on the continuous space. However, if the samples 3 Rendering terrain models are positioned stochastically rather than over a regular grid, then the patterned artifacts caused Textured terrain models represented by a poly- by frequencies above the Nyquist limit are traded gonal mesh can be rendered by a standard for a noise that is less irritating to the human eye graphics pipeline that supports mip-maps texture (Cook 1986). mapping in hardware with bit-mask methods for Another antialiasing approach applies the filter- edge antialiasing (Akeley 1993). Mip-maps (Will- ing prior to sampling. The visible area seen from iams 1983) are easily implemented, but are prone an output image pixel is convolved with the kernel to low-quality antialiasing, sine the filter shape is filter in order to calculate Eq. 1 accurately. How- limited to certain squares. Better filtering, imple- ever, determining the visibility for each output mented in software, was proposed by Arganov pixel can be extremely costly (Catmull 1978). Al- and Gotsman (1995) for avisual flythrough. though the results are convolved with a simple Digital textured terrains can be rendered back- box filter whose kernel extent is limited to one wards by a ray-casting approach (Cohen and pixel, such an exact area sampling produces high- Shaked 1993; Coquillart and Gangnet 1984; Mus- quality images (see Sect. 4). Other works have grave 1991; Paglieroni and Petersen 1994). The proposed techniques that approximate the sub- image is generated by casting a ray-of-sight, pixel visibility by small discrete masks (Carpenter emanating from the viewpoint, through each of 1984; Schilling 1991). These techniques operate in the image pixels towards the terrain. The ray object order, thus partial visible subpixel data are traverses above the terrain until it ‘‘hits’’ the ter- accumulated at an image space bu¤er. Due to the rain surface. The terrain’s texture is then sampled small size (e.g., 4]4) of the masks, the dynamic and mapped back to the source pixel. If the sam- color resolution is limited. pled value is just point sampled and not filtered, The convolution operation, as defined by Eq. 1, is then the quality of the output image is very low. a space-invariant filter. Fort practical scenarios, Filtering can be applied either before sampling various shapes and sizes of filter kernels have to (prefiltering, area sampling) or after (supersamp- be applied to each output image pixel. A simple ling). Figure 1 shows two images of a terrain. The example is a textured plane viewed by a perspec- top image is point sampled, while the bottom tive transformation. where the pixel footprint gets image is supersampled at a rate of N"8 (pixels). larger towards the horizon. The pixel footprint is As can be seen, the supersampled image has defined as the object-precision visible area seen a much better quality. from the window pixel. For arbitrary complex Musgrave (1991) used bilinear interpolation, projection transformations, the pixel footprint which yields acceptable quality only when the shape can have an arbitrary complexity. However, pixel footprint is rather small. Point sampling of when a perspective viewing transformation is ap- a multiresolution prefiltered texture (Cohen and plied, the quadrilateral defined by the four projec- Shaked 1993) can better deal with variant foot- ted points of the pixel extent provides a good prints, but is still not exact enough to avoid 185 the hit point is mapped back to the source pixel. If no hit occurs, then the background color of the sky is mapped. Since the terrain is an elevation map, we can assume that the terrain model has no vertical cavities (i.e., a vertical line has only one intersection with the terrain), and thus the traver- sal can be accelerated using coherence between rays. The basic idea is that as long as the camera does not roll, a ray cast from a vertically adjacent pixel always hits the terrain at a greater distance a from the viewpoint than that of the ray below it. When the pitch angle is not equal to zero, the image lane is not perpendicular to the xy-plane, and thus the ray emanating from the upper pixel is a bit slanted, making the implementation of the vertical coherence inexact (Lee and Shin 1995, Wright and Hsieh 1992). The image pixels are generated column by col- umn, from bottom to top. A ray Ri emanating above the ray Ri~1 will always traverse distance not shorter than the distance of the ray Ri . b ~1 Thus, the ray Ri can start its traversal from a dis- tance equal to the range of the previous hit point Fig. 1. The quality of an output image using: a point sampling; of the ray Ri~1 (Fig. 3). This feature shortens the b supersampling ray’s traversal considerably. In Fig. 4 we introduce a pseudo-C code for the generation of one image column. The following notation is introduced and illustrated in Fig. 3. flickering. Better quality can be achieved by com- Denote the camera position by COP. Let i!1 bining linear interpolation and supersampling denote the current screen pixel, and Pi~1, its posi- (Cohen-Or 1996). In Sect. 7 we compare the qual- tion in world coordinates. Assumed that the ray » ity of supersampling with exact area sampling and Ri~1 is x-major, and hits a voxel k located at the show the superiority of the latter.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    15 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us