Download Acceleration Techniques for Numerical Flow Visualization
Transcript
2.4. VOLUME VISUALIZATION 53 Figure 2.11 Comparison of sampling distances in slice-based volume rendering (left) and volume rendering based on ray-casting (right). Only ray-casting guarantees constant sampling rates. Software solutions for evaluating the volume rendering integral usually resort to a different approach termed ray-casting. In this approach, rays are cast from a hypothetical eye or camera position into the volume. Usually, exactly one ray per pixel is generated by mapping 2D pixel coordinates to 3D world coordinates and setting up parametric ray equations based on the viewer position and the derived world coordinates. By successively incrementing the ray parameter, the volume can then be sampled at regular intervals. Compared to slice-based volume rendering, the latter is a major advantage since it reduces artifacts (Figure 2.11). The compositing, however, now has to be accomplished in a front-to-back order which makes the blending operation more expensive: Cout = Cin + (1 − αin )αC; αout = αin + (1 − αin )α. We will have more to say about the pros and cons of the two approaches in Section 5.4.2. In both ray-casting and slice-based volume rendering the volume is sampled before the transfer function is applied. Thus, while the sampling frequency might suffice for the original volume data, it might no longer suffice after the transfer function has been applied (as, e.g., spikes might have been introduced). Preintegration is an approach developed to address this problem [18]. In this technique, the volume rendering integral is calculated in advance for pairs of sample values. This calculation is performed in software and only for a relatively low, fixed number of combinations. Thus, high-quality integration techniques with adaptive sampling rates can be utilized to compute the contributions of the slabs defined by the two samples. The price paid for the improved quality is the need to sample the volume both on the front and back plane of the slab during rendering and the need to re-compute the pre-integration table after changing the transfer function. Pre-integration is used in Section 5.4.2.