Computer Graphics & Geometry
Fig. 1.
Surfaces produced by composition of base and deviation function are smooth. Often only few such compositions are needed to construct complex surfaces (Fig. 1. Scene defined by 45 quadrics). 4.2. Scalar shape driving functionsFig. 2.
The dream of every simulator designer is to render a terrain as easily as a texture. The algorithm considered below does this (Fig. 2. Mountain landscape without feature texture generated for altitude/height map 64x64). A terrain model is coded as differential height map, i.e. the carrier surface is defined by algebraic means and only deviation from this basic surface is stored in the each node. Such a modeling method simplifies creation of smooth detail levels and shading. The data of height grid is not subject to geometry transformations as the triangle vertices do. The geometry transformations are only required for the carrier surface. During the recursive voxel subdivision on each level, we project the centers of the voxels onto some plane. The computed coordinates, as well as in the case of ordinary RGB texture map, will define address in the so-called �altitude map� or �shape texture� [19]. We calculate the altitude corresponding to this address and a level of details, and use it to modify coefficients of the plane or quadric equation. As a result we will obtain a smooth surface of arbitrary shape modulated with the values from the altitude map. But the problems solved by this algorithm require much more complicated methods within the traditional approach. Indeed, the common way to present terrain with polygons requires an abundance of polygons. Besides, the number of additional problems arises such as high depth complexity, hidden polygons removal, priorities, switching between levels of detail, clipping polygons by the pyramid of vision, etc. Such problems do not appear in the proposed method. The Geometry Processor works with the single plane. The corresponding traversing of the tree and the set of masks provide the right priority order. The backside of a terrain is rejected automatically. The clipping terrain by the pyramid of vision becomes unnecessary since sampling of just required altitudes from the altitude map is provided automatically by the rendering algorithm. To switch between levels of detail the same procedure is used as for the ordinary texture. 5. Definition of volume areas by scalar arrays,
where is final pixel color, is either r, g or b (i.e. red, green or blue), is intensity computed in n-th voxel by Phong model, is the transparence (opacity) of n-th voxel. is reflected light at the first point on a ray, is the background color and . Accumulation threshold test: if on k-th step summed transparency is less than , then all voxels after k can be discarded. 5.2. CSG set operations for volumesFig. 3.
5.3. Considering perspective for transparency computationFig.4.
Texture is generated at visualization time using three-dimensional density map. Transparency of elements is computed depending on density value and normal to iso-surface (Fig.4.Cylinder with 2 oval shells, normal is needed in lighting model) is computed as density gradient [20]. For applications with high frame rate (real-time visualization systems) efficient antialiasing is required. To accomplish this 3D variant of mipmapping technique should be used as well as quadrolinear interpolation for texture filtering. Important property of algorithm should be an ability of fast rendering anisotropic and pseudo-anisotropic objects for which it is not necessary to scan volume down to the last recursion level, but anisotropic areas should be skipped along z-coordinate, colors and transparency are computed immediately - visualization of atmospheric effects � 3D-clouds, smoke, fog (Fig. 5).Fig. 5.
6. New rasterization techniqueFig. 6.
6.1. Transformation of coefficients to local coordinates of cell V_{i} during subdivision of V_{i-1 } _{}Quadric object is base for building all other objects. Its surface is zero level surface of quadric three-dimensional function, i.e. function of its surface is defined in non-explicit form using ten quotients (A, B, C, � K): Q(x,y,z)= Ax^{2} + By^{2} + Cz^{2} + Dxy + Exz + Fyz + Gx + Hy + Iz + K = 0, where x, y � z are spatial variables. It is possible to write this equation in matrix form: The space in which the algorithm subdivides cubic volume is called further work or model space. M will denote this space further. Now introduce coordinate system immediately related to real space metrics (viewer or camera coordinate system). Four planes and depth of view field define viewing frustum in this space. Frustum volume is called pyramidal volume and denoted by P. If geometry transform is represented by matrix C then new, transformed, matrix of quotients Q� = C^{T} * Q * C is applied in space M according to matrix Q in space P. In particular on each subdivision step along quadtree, when scaling by 2 and shift by �1 along two coordinate axes is performed, recursive transformation of quadric quotients looks like: A�=A/4, B�=B/4, C�=C, D�=D/4, E�=E/2, F�=F/2,If K+R<0 and (|A|+|B|+|C|+|D|+|E|+|F| +|G|+|H|+|I| < -(K+R)) then slab is outside;
11. References
Computer Graphics & Geometry