0% found this document useful (0 votes)
11 views5 pages

Cell Projection of Convex Polyhedra

The paper presents an improved cell projection algorithm for visualizing unstructured grids in finite element methods, focusing on the performance of rendering convex polyhedra. By modifying the optical model and utilizing hardware acceleration, the proposed Projected Convex Polyhedra (PCP) algorithm achieves faster rendering speeds for various cell types, including tetrahedra and hexahedra. The algorithm is applicable not only for scientific visualization but also for real-time displays of gaseous phenomena like fire and ground fog.

Uploaded by

oscar.msdn
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views5 pages

Cell Projection of Convex Polyhedra

The paper presents an improved cell projection algorithm for visualizing unstructured grids in finite element methods, focusing on the performance of rendering convex polyhedra. By modifying the optical model and utilizing hardware acceleration, the proposed Projected Convex Polyhedra (PCP) algorithm achieves faster rendering speeds for various cell types, including tetrahedra and hexahedra. The algorithm is applicable not only for scientific visualization but also for real-time displays of gaseous phenomena like fire and ground fog.

Uploaded by

oscar.msdn
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

Volume Graphics (2003)

I. Fujishiro, K. Mueller, A. Kaufman (Editors)

Cell Projection of Convex Polyhedra

Stefan Roettger and Thomas Ertl

Visualization and Interactive Systems Group †


University of Stuttgart

Abstract
Finite element methods commonly use unstructured grids as the computational domain. As a matter of fact, the
volume visualization of these unstructured grids is a time consuming task. Here, the fastest known object order
algorithm is the projected tetrahedra algorithm of Shirley and Tuchman. Even with the upcoming of programmable
graphics hardware, the rendering performance did not keep up with the growing complexity of the simulation data.
In this paper we strive to improve the performance of the cell projection technique by posing several restrictions
on the optical model. This allows us to devise a simple but fast hardware-accelerated algorithm which is able to
project arbitrary polyhedral cells, that is tetrahedra, prisms, hexahedra, etc. For this reason, our algorithm is well
suited for the display of unstructured FEM meshes with mixed cell types, but it is also applicable to the real-time
display of gaseous phenonema, such as fire and ground fog.

CR Categories: I.3.5 [Computer Graphics]: Computational have to be sorted in a back to front fashion18, 1 . After that,
Geometry and Object Modeling, I.3.7 [Computer Graphics]: each cell is decomposed into tetrahedra which can be dis-
Three-Dimensional Graphics and Realism. played efficiently using the well known Projected Tetrahedra
(PT) algorithm of Shirley and Tuchman14, 15 . Actual imple-
Keywords: Direct volume rendering, unstructured grids,
mentations of this algorithm achieve a peak performance of
cell projection.
250,00019 to 600,0004 tetrahedra per second including times
for sorting. Due to the growing complexity of the simulation
1. Introduction data frame rates of less than one frame per second are still
quite common for typical unstructured data sets.
In the area of volume visualization the availability of pro-
grammable graphics hardware has lead to both improved Recently, hardware-accelerated methods have been pro-
performance and rendering quality. In the case of regular posed to speed up the PT algorithm, but with actual graph-
data the pre-integration technique3 is the predominant recent ics hardware still no more than approximately 480,00016 to
improvement. While the pre-integration technique has been 490,00020 tetrahedra are possible (timings do not include
applied to unstructured tetrahedral grids even before12 , the sorting). There also exist hardware concepts to overcome the
performance of unstructured volume rendering methods is speed limitations, but it is uncertain when these concepts will
still poor compared to the regular case. In this paper we try find its way into graphics accelerators6 . Since recent efforts
to narrow the performance gap by posing several restrictions to significantly speed up the PT algorithm have not led to
on the optical model. This allows us to devise an algorithm satisfactory results, we pursue a different strategy in this pa-
which efficiently utilizes the graphics hardware to speed up per: First we evaluate the theoretical limit on the number of
unstructured volume rendering. polyhedra that can be rendered on actual graphics hardware.
Based on these results we propose a reasonable modification
Typically, unstructured grids are generated by finite ele-
of the optical model to approach the theoretical limit.
ment methods. In order to visualize the data, all cells first

† University of Stuttgart, Computer Science Institute, VIS Group,


2. Theoretical Performance
Breitwiesenstrasse 20-22, 70565 Stuttgart, Germany; E-mail: In principal, all the faces of an unstructured data set have
[email protected] . to be treated to reconstruct the ray integral exactly. For the

c The Eurographics Association 2003.


S. Roettger and Th. Ertl / Cell Projection of Convex Polyhedra

case of hexahedral cells, this results in 6 faces with 4 ver- less visual clues but as we will see the implementation is
tices each. Assuming that the volumetric grid can be ren- extremely simple so that it can serve as a fast preview and
dered with triangle stripping, 8 vertices have to be passed prototyping option.
down the graphics pipeline per hexahedron. Actual graphics
Recently, Mech9 proposed a method to render bounded
accelerators like the NVIDIA GeForce3 reach a peak perfor-
layered fog using an emissive optical model. The bounded
mance of about 12 million vertices per second using triangle
fog is defined within a triangular surface mesh which al-
strips (in practical experience). Thus, the maximum theoret-
lows for easy hardware-accelerated computation of the ray
ical performance of the NVIDIA GeForce3 is 1.5 million
integral. The length of each ray segment is calculated in the
hexahedra per second.
frame buffer by coding the distance from the near clipping
In order to verify the theoretical result, we first applied plane into the vertex color. Then the length of the ray seg-
maximum intensity projection (MIP)5 . The advantage of ments can be computed by rendering the back faces of the
MIP is that a volumetric grid can be visualized just by ren- fog boundary and by subtracting the front faces. While this
dering all the faces of the cells in an unsorted order. Without approach is simple yet very fast, it assumes a constant fog
great loss of accuracy the scalar values can be assumed to density and requires a 12 bit visual to eliminate Mach bands.
vary linearly inside each hexahedron. Then the maximum In the following we extend this algorithm to project arbitrary
projected scalar value of each ray segment is either the value cell types, such as tetrahedra, hexahedra, or prisms, without
on the front or on the back face. Using this approach we the restriction to a 12 bit frame buffer and with linearly in-
achieved a performance of 643,000 hexahedra or 5.1 million terpolated densities within each cell.
triangles per second. Assuming that a hexahedron needs to
Our so called Projected Convex Polyhedra (PCP) algo-
be decomposed into at least 5 tetrahedra to be rendered with
rithm requires three passes per cell. In the first two passes
the PT algorithm the experimental result of 643,000 hexa-
the normalized length of the ray segments is calculated in the
hedra per second corresponds to 3.2 million tetrahedra per
alpha channel of the frame buffer. For this purpose, the dis-
second. This is still far away from the theoretical maximum,
tance d to the near plane is computed for each vertex of the
but it is almost a magnitude faster than the best known PT
cell. Let dmax denote the maximum distance per cell, let dmin
implementation.
denote the minimum distance, and let ∆d = dmax − dmin be
The performance for such a simple optical model like MIP the difference of both (see also Figure 1). Then the back
is already considerably lower than the theoretical limit. This faces of a cell are rendered into the alpha channel of the
is mainly due to the large rasterization overhead. Hence, it is frame buffer with the alpha component of each vertex set
no surprise that the performance is even worse in the case of to α = (d − dmin )/∆d. In the same fashion, the front faces of
the standard volume density optical model17 . This is due to the cell are rendered into the alpha channel with subtractive
the requirement of visibility sorting. Conceptually, the tetra- blending enabled. As a result, the normalized ray segment
hedra must be read, written, and read back from main mem- lengths are now available in the alpha channel of the frame
ory for sorting (compare Wittenbrink et. al19 ). With increas- buffer.
ing rendering speed of the graphics accelerator the memory
bandwidth consumed by visibility sorting becomes the limit-
ing factor. This behaviour starts at approximately 1.5 million near plane
tetrahedra per second on actual PC hardware. Since the total
performance is currently only around 600,000 tetrahedra per
second the main limiting factor is still the graphics accelera-
tor (and the CPU). We suspect that a significant performance
bump beyond the mentioned 1.5 million tetrahedra per sec-
ond limit is possible only with a structural paradigm shift of
graphics accelerators or special purpose hardware.

3. Projected Polyhedra Algorithm


min d
Because of the limiting behaviour of visibility sorting, we ∆d
devise an efficient algorithm for an emissive optical model8
which does not require sorting. In our opinion this optical Figure 1: Projection of polyhedral cells.
model can be considered to be a good tradeoff between speed
and quality. The emissive optical model neglects absorption
so that the ray integral is simply the sum of all emissions In the last pass all faces of the cell are rendered
along each ray. As a welcome side effect sorting is not re- into the color channel of the frame buffer. Let κ(S) de-
quired, since the blend function is commutative. In compar- note the transfer function of the emissive optical model
ison to the standard optical model the emissive model gives depending on the scalar value S. Then the color I

c The Eurographics Association 2003.


S. Roettger and Th. Ertl / Cell Projection of Convex Polyhedra

of each vertex is set to I = κ(S)∆d/2 using the fol-


lowing blend function in OpenGL notation: glBlend-
Func(GL_DST_ALPHA,GL_ONE). This effectively mul-
tiplies the average emission along each ray segment with the
segment length already stored in the alpha channel.
In contrast to Mech’s method we do not require a 12 bit
visual, since we use normalized ray segment lengths for each
cell. Another solution to suppress the Mach bands would be
Figure 3: Blunt Fin and Bucky Ball data set.
to use the floating point render target of actual PC graphics
accelerators such as the ATI Radeon 9700. However, since
the algorithm is mainly rasterization bound the increased
bandwidth for the floating point render target would signifi- Data set dimension #hexahedra frames per sec.
cantly slow down rendering. Also Mech’s algorithm is not as
BluntFin 32×32×40 37,479 8.5
flexible as ours. Using our method, almost any desired volu-
metric object or (emissive) effect can be constructed from Bucky Ball 32×32×32 29,791 15.9
tetrahedra, prisms, and hexahedra in a very compact way
(compare Figure 2). Search Light 16×4×32 1,395 115.8
Camp Fire 16×16×16 3375 51.3

Figure 4: Timings for hexahedral projection.

5. Application Example: Ground Fog


Besides the application area of scientific volume visual-
ization as demonstrated in Figure 3 the performance and
flexibility of the proposed cell projection algorithm paves
the way for other fields of application. As an example, we
demonstrate the real-time display of natural gaseous phe-
nomena. In principle, all effects related to light-emitting gas
can be modeled. In particular, the display of ground fog in
terrain rendering scenarios benefits from our algorithm, as
shown in the following.
Figure 2: Synthetic data sets: A search light with quadratic In a terrain rendering scenario the landscape is commonly
intensity attenuation (top row), a laser cone (bottom left), given as a height field. Here, the basic idea to display ground
and a campfire generated with 3D Perlin noise (bottom fog is to use a second height field (the ground fog map)
right). which defines the height of the fog layer above the ground.
Each triangle of the surface mesh is treated as a base triangle
onto which a vertically aligned prism is stacked. The height
of the prisms, that is the heights of the three vertical edges of
4. Results
each prism, are derived from the ground fog map (see Fig-
In principle, all types of cells used for FEM such as tetra- ure 5).
hedra, hexahedra, prisms, pyramids etc. are compatible with
At the top left of Figure 6 an example height field of
our approach. For the common case of projected hexahedra
Yukon Territory, Canada, is depicted. The shown ground fog
Schussman et al.13 report about 80,000 hexahedra per sec-
has been generated with 2D Perlin noise10 . In order to re-
ond. We achieve about 212,000 hexahedra per second, which
duce the number of displayed triangles and stacked prisms,
is a performance increase of 265%. Compared to the 643,000
we used a continuous level of detail (C-LOD) approach7, 2 .
hexahedra per second of the MIP method, the performance
The applied terrain rendering algorithm11 also implements
difference is mainly due to the increased number of render-
geomorphing so that the popping effect is suppressed ef-
ing passes (3 instead of 1).
ficiently. This allows the viewer to fly through the ground
In Figure 3 and 2 example data sets are shown that have fog without experiencing any temporal aliasing artifacts. We
been visualized with the PCP algorithm. The corresponding achieved an average frame rate of approximately 25 Hertz
timings are given in Table 4. To speed up projection hexahe- for a window size of 512×384. Inside the fog, we have to
dra with zero emission were discarded. take care of prisms that intersect the near clipping plane.

c The Eurographics Association 2003.


S. Roettger and Th. Ertl / Cell Projection of Convex Polyhedra

stacked prism

triangulated surface

edge height
is derived from
ground fog map base triangle

Figure 5: Stacking prisms onto a triangulated surface.

Figure 6: Ground fog generated with 2D Perlin noise. Top


In such a case the ray segment lengths are partially invalid, left: Emissive optical model. Top right: Maximum Intensity
since the corresponding back faces are not rendered com- Projection (MIP). Bottom: Aurea Borealis (polar light).
pletely. To circumvent this problem, we also render the inter-
section of each prism with the near clipping plane with α =
(dnear −dmin )/∆d after the second pass. The same strategy is
to visualize mixed type meshes that are generated by FEM
necessary after the third pass: The intersection of each prism
simulations. Due to their flexibility, they are also suited for
with the near clipping plane is rendered with correctly inter-
the display of volumetric effects in interactive entertainment.
polated colors to avoid the partial display of clipped tetrahe-
We have demonstrated this by rendering fire and ground fog
dra.
in real-time.
The ground fog in the valley as shown at the top right
of Figure 6 is displayed with maximum intensity projection.
The corresponding height field has been painted by hand 7. Acknowledgements
with a standard image manipulation application. Since the The terrain and ground fog renderer referenced in this pa-
MIP method requires only one pass in comparison to the per is licensed under the terms of the GNU LGPL. It is
three passes of the PCP algorithm the rasterization bottle- part of the vtp package (www.vterrain.org) and is available
neck is reduced significantly. This leads to more than twice on the home page of the author (wwwvis.informatik.uni-
the frame rate (> 50 Hz) as in the previous example. stuttgart.de/˜roettger/).
Despite the seemingly unsuitable optical model we have
found a reasonable setup for the MIP method: The fog’s op- References
tical density is set to zero at the bottom of the prisms. At the
top of the prisms the density correlates to the height of the 1. J. Comba, J. T. Klosowski, N. L. Max, J. S. B. Mitchell, C. T.
fog layer. Although this setting does not reproduce the fog Silva, and P. L. Williams. Fast Polyhedral Cell Sorting for In-
teractive Rendering of Unstructured Grids. Computer Graph-
physically it is well suited for the real-time display of foggy
ics Forum (Proc. Eurographics ’99), 18(3):369–376, 1999.
areas in interactive entertainment where fog can be used as
a game play relevant element. 2. M. Duchaineau, M. Wolinsky, D. E. Sigeti, M. C. Miller, Ch.
Aldrich, and M. B. Mineev-Weinstein. ROAMing Terrain:
Another application area of the described ground fog ren- Real-Time Optimally Adapting Meshes. In Proc. Visualiza-
dering method is the display of the Aurea Borealis, since tion ’97, pages 81–88. IEEE, 1997.
polar light is a purely emissive natural phenomenon. We set
up a height field that corresponds to the penetration depth 3. K. Engel, M. Kraus, and Th. Ertl. High-Quality Pre-Integrated
Volume Rendering Using Hardware-Accelerated Pixel Shad-
of the particles into the earth’s ionosphere. The result of this
ing. In Eurographics Workshop on Graphics Hardware ’01,
procedure can be seen at the bottom of Figure 6. pages 9–16. ACM SIGGRAPH, 2001.
4. S. Guthe, S. Roettger, A. Schieber, W. Strasser, and Th. Ertl.
6. Conclusion High-Quality Unstructured Volume Rendering on the PC Plat-
We have presented two fast yet simple cell projection algo- form. In Proc. EG/SIGGRAPH Graphics Hardware Workshop
rithms ,namely the MIP and the PCP method, that are suited ’02, pages 119–125, 2002.
for maximum intensity projection or an emissive optical 5. W. Heidrich, M. McCool, and J. Stevens. Interactive Max-
model, respectively. The algorithms are capable of project- imum Projection Volume Rendering. In Proc. Visualization
ing arbitrary polyhedral cells. Therefore they can be applied ’95, pages 11–18. IEEE, 1995.

c The Eurographics Association 2003.


S. Roettger and Th. Ertl / Cell Projection of Convex Polyhedra

6. D. King and C. M. Wittenbrink. An Architecture for Interac-


tive Tetrahedral Volume Rendering. In Proc. IEEE/EG Work-
shop on Volume Graphics ’01, pages 163–180. Springer Ver-
lag, Wien, 2001.
7. P. Lindstrom, D. Koller, W. Ribarsky, L. F. Hodges, N. Faust,
and G. Turner. Real-Time, Continuous Level of Detail Render-
ing of Height Fields. In Proc. SIGGRAPH ’96, pages 109–118.
ACM, 1996.
8. Nelson L. Max. Optical Models for Direct Volume Rendering.
IEEE Transactions on Visualization and Computer Graphics,
1(2):99–108, 1995.
9. Radomir Mech. Hardware-Accelerated Real-Time Rendering
of Gaseous Phenomena. Journal of Graphics Tools, 6(3):1–16,
2001.
10. Ken Perlin. An Image Synthesizer. Computer Graphics (Proc.
SIGGRAPH ’85), 19(3):287–296, 1985.
11. S. Roettger, W. Heidrich, Ph. Slusallek, and H.-P. Seidel. Real-
Time Generation of Continuous Levels of Detail for Height
Fields. In Proc. WSCG ’98, pages 315–322. EG/IFIP, 1998.
12. S. Roettger, M. Kraus, and Th. Ertl. Hardware-Accelerated
Volume and Isosurface Rendering Based on Cell-Projection.
In Proc. Visualization ’00, pages 109–116. IEEE, 2000.
13. G. Schussman and N. L. Max. Hierarchical Perspective Vol-
ume Rendering Using Triangle Fans. In Proc. TCVG Eu-
rographics Workshop (VolumeGraphics ’01), pages 309–320.
IEEE/EG, 2001.
14. P. Shirley and A. Tuchman. A Polygonal Approximation to
Direct Scalar Volume Rendering. ACM Computer Graphics
(San Diego Workshop on Volume Visualization), 24(5):63–70,
1990.
15. C. M. Stein, B. G. Becker, and N. L. Max. Sorting and Hard-
ware Assisted Rendering for Volume Visualization. In Sympo-
sium on Volume Visualization ’94, pages 83–89. IEEE, 1994.
16. M. Weiler and Th. Ertl. Hardware-Based View-Independent
Cell Projection. In Proc. IEEE Symposium on Volume Visual-
ization ’02, pages 13–22, 2002.
17. P. L. Williams and N. L. Max. A Volume Density Optical
Model. In Computer Graphics (Workshop on Volume Visual-
ization ’92), pages 61–68. ACM, 1992.
18. Peter L. Williams. Visibility Ordering Meshed Polyhedra.
ACM Transactions on Graphics, 11(2):103–126, 1992.
19. C. M. Wittenbrink. CellFast: Interactive Unstructured Volume
Rendering. In IEEE Visualization ’99 Late Breaking Hot Top-
ics, pages 21–24, 1999.
20. B. Wylie, K. Moreland, L. A. Fisk, and P. Crossno. Tetrahedral
Projection using Vertex Shaders. In Proc. IEEE Symposium on
Volume Visualization ’02, pages 7–12. ACM Press, 2002.

c The Eurographics Association 2003.

You might also like