## Volumetric Ray Tracing

A 3D raster ray tracing (RRT) method, developed by Yagel, Cohen, and Kaufman [84,88], produces realistic images of volumetric data using a global illumination model. The RRT algorithm is a discrete ray-tracing algorithm similar to the discrete ray-casting algorithm described in Section 4.2. Discrete primary rays are cast from the image plane, through the data to determine pixel values. Secondary rays are recursively spawned when a ray encounters a voxel belonging to an object in the data. To save time, the view-independent parts of the illumination equation can be precomputed and added to the voxel color, thereby avoiding the calculation of this quantity during the ray tracing. Also, two bits per light source per voxel can be precomputed, indicating whether the light is definitely visible, possibly visible, or definitely invisible from that voxel. Shadow rays need only be cast during the ray tracing if the bits indicate that the light is possibly visible through a translucent object. Actually, all view-independent attributes (including normal, texture, and antialiasing) can be precomputed and stored with each voxel.

There are several advantages to using RRT instead of conventional ray tracing. One such advantage is that sampled or computed data, possibly intermixed with voxelized geometric data, can be ray traced directly without having to approximate sampled data using geometric primitives. Another advantage is that there is only one primitive to deal with — the voxel, which greatly simplifies ray-object intersection calculations. Unlike conventional ray tracing that computes expensive continuous ray-object intersections, RRT traverses discrete rays through discrete data and, therefore, it is basically insensitive to scene complexity and object complexity. RRT is also very effective for ray tracing voxelized geometric models, such as constructive solid geometry (CSG) models. This is an example for the emerging field of volume graphics [31] in which geometric scenes are modeled using voxelized objects and efficiently rendered using a volume rendering algorithm such as RRT.

A volumetric ray tracer [64] is intended to produce much more accurate, informative images. In classical ray tracing, the rendering algorithm is designed to generate images that are accurate according to the laws of optics. Avolumetric ray tracer should handle volumetric data as well as classical geometric objects, and strict adherence to the laws of optics is not always desirable. For example, a user may wish to generate an image with no shadows or to view the maximum value along the segment of a ray passing through a volume, instead of the optically correct composited value.

In order to incorporate both volumetric and geometric objects into one scene, the standard ray tracing intensity equation must be expanded. Since the illumination equation in classical ray tracing is evaluated only at surface locations, volumetric data cannot be incorporated into the scene. This problem can be resolved by extending the standard illumination equation to include volumetric effects. The intensity of light, Ix(x, m), for a given wavelength X, arriving at a position x, from the direction m, can be computed by h(x, m) = Ivi(x, x')+Tx(x, x')Isl(x', m), (15)

where x' is the first surface intersection point encountered along the ray m originating at x. Isx(x', m) is the intensity of light at this surface location and can be computed with a standard ray tracing illumination equation [81]. Ivx (x, x') is the volumetric contribution to the intensity along the ray from x to x', and %x(x, x') is the attenuation of Isx(x', m) by any intervening volumes. These values are determined using volume rendering techniques, based on a transport theory model of light propagation [35]. The basic idea is similar to classical ray tracing, in that rays are cast from the eye into the scene, and surface shading is performed on the closest surface intersection point. The difference is that shading must be performed for all volumetric data that are encountered along the ray while traveling to the closest surface intersection point.

For photorealistic rendering, the user typically wants to include the maximum amount of shading effects that can be calculated within a given time limit. For visualization, however, the user may find it necessary to view volumetric data with no shading effects, such as when using a maximum-value projection. For example, the user may place a mirror behind a volumetric object in a scene in order to capture two views in one image, but may not want the volumetric object to cast a shadow on the mirror. This can be easily accomplished by "turning off" the shadowing calculations for the mirror, as shown in Fig. 8. The head data was obtained using magnetic resonance imaging, with the brain segmented from the same dataset. The mirror is a voxelized polygon, which was created using the nonbinary voxelization technique [66,78].

## Post a comment