IMPLICIT MODELING WITH PROCEDURAL TECHNIQUES David S. Ebert, Edward Bedwell
CSEE Department University of Maryland Baltimore County 1000 Hilltop Circle Baltimore, MD 21250
[email protected],
[email protected]
ABSTRACT
Implicit modeling eases the design and animation of complex objects; however, it does not solve the problem completely for extremely complex surface design problems and for modeling volumetric phenomena. Procedural techniques are another growing solution to this problem because of their exibility, parametric control, and abstraction of speci cation. This paper discusses how to combine existing procedural modeling techniques with implicit modeling to provide a solution to the problem of modeling complex surfaces and volumetric clouds. We demonstrate the usefulness of combining volumetric procedural models with implicit surfaces for modeling volumetric clouds. We also show the advantage of using procedural genetic programming techniques to mate implicit surfaces. These combinations of techniques produce extensible,
exible, and powerful tools for modeling.
1. INTRODUCTION Implicit modeling is gaining popularity because of recent advances in skeletal implicit models, polygonalization techniques, and improved implicit animation techniques [1]. However, modeling complex shapes is still a dicult task, particularly for volumetric shapes. Procedural modeling techniques are also becoming popular because of their exibility and algorithmic abstraction of detail [3]. Combining procedural modeling techniques with implicit modeling provides an extremely powerful, exible design tool for modeling surface-based and volumetric objects. In this paper, we demonstrate the power of this combined approach for modeling volumetric clouds and complex implicit surfaces.
2. PREVIOUS WORK Implicit functions are by nature procedural; however, very few researchers have exploited their procedural nature for volumetric modeling. Perlin [7] used very simple implicit functions for describing the general
shape of hypertextures. Stam [10] showed the applicability of warped blobbies for simple re modeling. We have expanded upon these earlier eorts to develop a volumetric procedural cloud model that uses procedural abstraction of detail to allow the designer to control and animate volumetric clouds at a high level. The designer controls the macro-level speci cation and animation of the clouds by controlling implicit primitives, while procedural simulations determine the micro-level cloud structure. Genetic algorithms are another procedural technique that has been applied extensively in computer graphics for animation [5, 8], texturing, and modeling [6, 9]. This procedural technique allows animators and artists to design complex mathematical functions for modeling and animation without requiring an extensive mathematic background. We have combined implicit surfaces, as modeling primitives, with genetic programming to facilitate automated generation of exceedingly complex models. Our approach combines Latham's ideas for genetic modeling [6] with Sim's approach to arti cial evolution [9] and applies the result to the automated generation of implicit surfaces.
3. VOLUMETRIC PROCEDURAL IMPLICIT MODELING We have chosen to combine traditional volumetric procedural models with implicit functions to create a model that has the advantages of both techniques. This hybrid model is a general, exible, volumetric cloud modeling system that provides a natural way of specifying and animating the global structure of the cloud, while using more traditional procedural techniques to model the detailed structure of the cloud. Our general model has two main components: the cloud macrostructure and the cloud microstructure. These are modeled by implicit functions and turbulent volume densities, respectively. The basic structure of the cloud model combines these two components to determine the nal density of the cloud. Care is taken to link the microstructure turbulence space with the macrostructure implicit primitives so that
natural animation and growth of cloud structures result. The cloud's microstructure is created by using procedural turbulence and noise functions [2]. This allows the procedural simulation of natural detail to the level needed. Simple mathematical functions are added to allow shaping of the density distributions and control over the sharpness of the density fallo. A simple example of a volumetric procedural density function (vpm) with useful controls is the following [4]: vpm(pnt) pnt = map pnt to procedural turbulence space turb = turbulence(pnt) density = pow(denseness*turb, wispiness) return(density) end vpm
This procedure creates natural turbulent detail in a volume of space and allows the user two natural controls: denseness and wispiness. By varying denseness, the user can create a dense or sparse volume. By varying wispiness, the user can change from smoothly varying densities (wispiness = 1 0) to sharply varying densities (wispiness 1 0). The density value returned from this procedure speci es the density of the three-dimensional volumetric object. These densities are rendered using standard volume rendering techniques. We chose implicit functions to model the cloud macrostructure because of their ease of speci cation and smoothly blending density distributions. The user simply speci es the location, type, and weight of the implicit primitives to create the overall cloud shape. The system currently allows spheres, cylinders, and ellipsoids to be used as implicit primitives. Since these are volume rendered as a semi-transparent medium, the whole volumetric eld function is being rendered, as compared to implicit surface rendering where only a small range of values of the eld are used to create the objects. Our implicit density functions are primitive-based density functions: they are de ned by summed, weighted, parameterized, primitive implicit functions. To create non-solid implicit primitives, we procedurally alter the location of the point before the evaluation of the blending functions. This alteration may be the product of the procedure and the implicit function and/or a warping of the implicit space. The resulting hybrid cloud model can be described by the following pseudo-code:
:
:
cloud(pnt, blend%) perturbed_point = procedurally alter pnt using noise and turbulence density1 = implicit(perturbed_point) density2 = turbulence(pnt)
blend = blend% * density1 + (1 - blend%) * density2 density = shape resulting density based on user controls for wispiness and denseness, e.g., density = pow(blend*denseness, wispiness) return(density) end cloud
The density from the implicit primitives is combined with a pure turbulence based density using a user speci ed % (60% to 80% gives good results). The blending of the two densities allows the creation of clouds that range from entirely determined by the implicit function density to entirely determined by the procedural turbulence function. Control of the amount of turbulent detail is very useful for varying the cloud appearance from soft, smooth clouds to more naturalistic, turbulent clouds. To restrict the shape of the clouds to lie within the volume de ned by the implicit primitives, then the formula for blend is changed as follows: blend
blend = blend% * density1 + (1 - blend%) * density2* density1
The above general algorithm produces convincing images of several types of clouds. For cumulus clouds, a denseness value between 0.2 and 0.4, combined with a wispiness value of 0.5, and a blend value of 0.4 produces good cloud images. Cirrus clouds are generally thinner, less dense, and wispier. Cirrus clouds can be created by changing the implicit primitive shapes (thinner shapes, e.g., ellipses instead of spheres) and changing the parameters to the above algorithm. The denseness parameter should have a smaller value and the wispiness parameter should be larger, producing larger areas of no clouds and a greater number of individual clouds. To create cirrus clouds, the user can simply specify the global shape (envelope) of the clouds with a few implicit primitives, or specify implicit primitives to determine the location and shape of each cloud. In the former case, the shape of each cloud is mainly controlled by the volumetric procedural function and turbulence simulation, as opposed to cumulus clouds where the implicit functions are the main shape control. Stratus clouds can also be modeled by using a few implicits to create the global shape or extent of the stratus layer, while using volumetric procedural functions to de ne the detailed structure of all of the clouds within this layer. Stratus cloud layers are normally thicker and less wispy, as compared to cirrus clouds. This eect can be created by adjusting the size of the turbulent space (smaller/fewer wisps), using a smaller wispiness value (creates more of a cloud layer eect), and increasing the denseness of the cloud.
The animation of the implicits can be controlled by any implicit animation systems, key frames, or by a particle system. Incorporating particle system dynamics into the model is a natural way to introduce simple atmospheric and dynamics simulations into the animation of these volumetric objects. 3.1. Results
The results of this hybrid cloud modeling system can be seen in Figures 1, 2, and 3. Figure 1 shows an example cumulus cloud created with these techniques. Figure 2 shows the range of cloud creature eects that can be created using a simple graphical user interface to control the location of nine implicit primitives. Each of these were designed in less than 15 minutes. Figure 3 shows a high cirro-stratus layer created by a large elliptical primitive and a few individual lower cirrus clouds created with cylindrical primitives.
4. GENETIC MATING OF IMPLICIT SURFACES As previously mentioned, we have developed a system that combines implicit surfaces with genetic programming to ease the generation of exceedingly complex models. Traditionally, complex implicit forms are generated by blending together many smaller implicit shapes through functional composition. Our system introduces complexity within the base surface description by increasing the complexity of the entire surface's functional representation. Initial parents are chosen from a primitive community comprised of a few very simple implicit surfaces. The implicit functions are loaded into a LISP framework and stored as expressions, which are then manipulated as parse trees. A post-order traversal of each tree is performed. At each node there is a probability of it being agged as a cross-over point. Once one of these cross-over points is discovered in each tree, the subtrees at those points are swapped, thereby creating two new trees. This process is repeated using the same parents to generate more child trees. These expressions are then used to render the child implicit surfaces. This process is continued by picking two children from the new generation and repeating the process. As all the individuals are generated using only genetic material from the primitive parents, structural traits of the parents can be seen throughout the evolutionary cycles. Furthermore, the expressions have the tendency to grow larger as they get further away from the primitives. As one would expect, with the added functional complexity comes added visual complexity.
4.1. Results The results of mating a sphere and torus can be seen in Figure 4. This gure shows the initial ancestors and the third and fth generation surfaces selected for further mating. This image demonstrates the most important feature of the system: visual traits of the primitive parental surfaces are clearly evident throughout generations. Furthermore, complexity also increases as the individuals get further away from their more primitive ancestors. Thus, the user consciously plays an active role in determining the traits and directing the development of the community to meet his/her needs.
5. CONCLUSION We have demonstrated that combining procedural techniques such as volumetric procedural modeling, particle systems, and genetic programming with implicit surfaces creates powerful tools for modeling complex objects. This combination is very natural because of the inherent procedural nature of implicit models. We are currently looking at extending this work to investigate the bene ts of other procedural modeling techniques, such as grammar-based techniques and multi-fractals for increasing the power of traditional implicit modeling tools.
6. ACKNOWLEDGMENTS We wish to thank Dr. Richard Parent and Dr. Stephen May for their assistance in the implicit modeling code, and Ryoichi Suzuki for making the POV-Ray isosurface patch available. This project was supported in part by the National Science Foundation under grant CCR-9409243, by NASA under grant NCC5-220, and by the Department of Defense.
7. REFERENCES [1] Jules Bloomenthal, Chandrajit Bajaj, Jim Blinn, Marie-Paul Cani-Gascuel, Alyn Rockwood, Brian Wyvill, and Geo Wyvill. Introduction to Implicit Surfaces. Morgan Kaufman Publishers, Inc., 1997. [2] David Ebert, F. Kenton Musgrave, Darwyn Peachey, Ken Perlin, and Steve Worley. Texturing and Modeling: A Procedural Approach. Academic Press, October 1994. ISBN 0-12-228760-6. [3] David S. Ebert. Advanced modeling techniques for computer graphics. In CRC Handbook of Computer Science and Engineering, chapter 56. CRC, 1997. [4] David S. Ebert. Volumetric modeling with implicit functions: A cloud is born. In David Ebert, editor, SIGGRAPH 97 Visual Proceedings (SIGGRAPH 97, 03-08 August 1997, Los Angeles,
[5] [6] [7] [8] [9]
[10]
California), page 147. ACM SIGGRAPH, August 1997. L. Gritz and J. K. Hahn. Genetic programming for articulated gure motion. Journal of Visualization and Computer Animation, 6(3):129{142, July 1995. ISSN 1049-8907. William Latham. Evolution by esthetics. IEEE Computer Graphics and Applications, 11(2):5{9, March 1991. Ken Perlin and Eric M. Hoert. Hypertexture. In Jerey Lane, editor, Computer Graphics (SIGGRAPH '89 Proceedings), volume 23, pages 253{ 262, July 1989. Karl Sims. Arti cial evolution for computer graphics. In Thomas W. Sederberg, editor, Computer Graphics (SIGGRAPH '91 Proceedings), volume 25, pages 319{328, July 1991. Karl Sims. Evolving virtual creatures. In Andrew Glassner, editor, Proceedings of SIGGRAPH '94 (Orlando, Florida, July 24{29, 1994), Computer Graphics Proceedings, Annual Conference Series, pages 15{22. ACM SIGGRAPH, ACM Press, July 1994. ISBN 0-89791667-0. Jos Stam and Eugene Fiume. Depicting re and other gaseous phenomena using diusion processes. In Robert Cook, editor, SIGGRAPH 95 Conference Proceedings, Annual Conference Series, pages 129{136. ACM SIGGRAPH, Addison Wesley, August 1995. Held in Los Angeles, California, 06-11 August 1995.
Figure 1: An example cumulus cloud.
Figure 2: Volumetric procedural implicit cloud creatures.
Figure 3: An example of procedural implicit cirro-stratus clouds.
Figure 4: An example of genetically mated implicit surfaces.