Conference PaperPDF Available

Know the Rules – Tutorial on Procedural Modeling

Authors:

Abstract and Figures

This tutorial introduces the concepts and techniques of procedural & generative modeling. It starts with some introductory examples to motivate the main idea: to describe a shape using an algorithm. After the explanation of technical terms, the second Section focuses on technical details of algorithm descriptions, programming languages, grammars and compiler construction, which play an important role in generative modeling. The purely geometric aspects are covered by the third Section. It comprehends the concepts of geometric building blocks and advanced modeling operations. Notes on semantic modeling aspects – i.e. the meaning of a shape – complete this Section and introduce the inverse problem. What is the perfect procedural description for a real object? The answer to this question is discussed in the fourth Section while its application is shown (among other applications of generative and inverse-generative modeling) in the fifth Section. The discussion of open research questions concludes this tutorial.
Content may be subject to copyright.
Know the Rules
Tutorial on Procedural Modeling
Know the Rules
Tutorial on Procedural Modeling
Christoph Schinko, Ulrich Krispel, Torsten Ullrich
?
Visual Computing, Fraunhofer Austria Research GmbH
Graz University of Technology, Austria
Abstract
This tutorial introduces the concepts and techniques of procedural & generative modeling. It starts
with some introductory examples to motivate the main idea: to describe a shape using an algorithm.
After the explanation of technical terms, the second Section focuses on technical details of algorithm
descriptions, programming languages, grammars and compiler construction, which play an important
role in generative modeling. The purely geometric aspects are covered by the third Section. It
comprehends the concepts of geometric building blocks and advanced modeling operations. Notes on
semantic modeling aspects i.e. the meaning of a shape complete this Section and introduce the
inverse problem. What is the perfect procedural description for a real object? The answer to this
question is discussed in the fourth Section while its application is shown (among other applications
of generative and inverse-generative modeling) in the fifth Section. The discussion of open research
questions concludes this tutorial.
keywords:
geometry processing; generative, procedural modeling; inverse modeling;
modeling applications; shape description; language design
This handout is based on:
@Article{KSU2014,
Title = {The Rules Behind -- Tutorial on Generative Modeling},
Author = {Krispel, Ulrich and Schinko, Christoph and Ullrich, Torsten},
Journal = {Proceedings of Symposium on Geometry Processing / Graduate School},
Year = {2014},
Pages = {2:1--2:49},
Volume = {12}
}
?
corresponding author:
mail: torsten.ullrich@fraunhofer.at
www: www.cgv.tugraz.at & www.fraunhofer.at
About the Authors
Christoph Schinko
Christoph Schinko, born in 1982, studied Telematics at Graz University of Tech-
nology. He received his Master’s degree in June 2009 and worked as a researcher
in the FIT-IT project MetaDesigner at the Institute of Computer Graphics and
Knowledge Visualization (CGV) at Graz University of Technology. His research
focuses on generative modeling, rapid prototyping and 3D Web technologies. Since
March 2013 he works for Fraunhofer Austria Research GmbH, Visual Computing.
Ulrich Krispel
Ulrich Krispel received his Master’s degree in Telematics in 2008 from Graz Uni-
versity of Technology, Austria. He has been a research assistant at the Institute
of Computer Graphics and Knowledge Visualization (CGV), Graz University of
Technology, and at Interactive Graphics Systems Group (GRIS), TU Darmstadt.
Currently, he is a research assistant at Fraunhofer Austria Research GmbH. His
fields of interest cover geometry processing for procedural descriptions and (inverse)
procedural modeling with a focus on shape grammars.
Torsten Ullrich (presenter)
Dr. Torsten Ullrich studied mathematics with a focus on computer science at the
University of Karlsruhe (TH) and received his doctorate in 2011 with his work “Re-
constructive Geometry” on the subject of reverse engineering at the Graz University
of Technology. Since 2005 he has been involved in the establishment of the newly
formed “Fraunhofer Austria Research GmbH”. He coordinates research projects in
the field of “Visual Decision Support”, “Virtual Engineering” and “Digital Society”
and is Deputy Head of the business area Visual Computing in Graz. His research in
the field of generative modeling languages and geometrical optimization has received
several international awards.
Contact information: torsten.ullrich@fraunhofer.at
Contents
1 Introduction to “Generative Modeling” 7
1.1 Ruler and Compass . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
1.2 Architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
1.3 Civil Engineering . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
1.4 Natural Patterns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
1.5 Entertainment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
1.6 Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2 Languages & Grammars 15
2.1 Language Processing & Compiler Construction . . . . . . . . . . . . . . . . . . . . . . . . 15
2.2 Scripting Languages for Generative Modeling . . . . . . . . . . . . . . . . . . . . . . . . . 18
3 Modeling by Programming 23
3.1 Building Blocks & Elementary Data Structures . . . . . . . . . . . . . . . . . . . . . . . . 23
3.2 Advanced Techniques . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
3.3 Semantic Modeling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
4 Inverse Modeling 31
4.1 Problem Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
4.2 Overview on Current Approaches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
5 Applications 35
5.1 Procedural Shape Modeling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
5.2 Semantic Enrichment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38
5.3 Form Follows Function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
6 Open Questions 45
C. Schinko, U. Krispel & T. Ullrich, 2015 7
1 Introduction to “Generative Modeling”
Generative modeling has been developed in order to generate highly complex objects based on a set of
formal construction rules. This modeling paradigm describes a shape by a sequence of processing steps,
rather than just the end result of applied operations: Shape design becomes rule design. This approach
is very general and it can be applied to any domain and to any shape representation that provides a set
of generating functions.
1.1 Ruler and Compass
The ruler-and-compass construction is the construction of lengths, angles, and other geometric figures
using only an idealized ruler and compass. Geometry from the days of the ancient Greeks placed great
emphasis on problems of constructing various geometric figures using only a ruler without markings (to
draw lines) and a compass (to draw circles). All ruler-and-compass constructions consist of repeated
application of five basic constructions based on Euclid’s axioms [48] using the points, lines and circles
that have already been constructed. Based on these geometric primitives and a fixed set of operations, the
ruler-and-compass constructions such as illustrated in Figure 1 are the first algorithmic descriptions
of generative models.
O
A
B
C
D
E
F
G
Construction of a pentagon:
1. Draw a circle in which to inscribe
the pentagon and mark the center
point O.
2. Construct a pair of perpendicu-
lar lines which intersect in O and
mark their intersection with the
circle A and B.
3. Let D be the midpoint of BO.
The circle with center D and ra-
dius | DA | intersects the line de-
fined by the points B and O.
Mark the intersection point as F .
4. The length of section AF is equal
to the edge length AG of an in-
scribed pentagon (red).
Figure 1: The construction of a pentagon can be performed using compass and a straightedge only. The con-
struction algorithm is based on Euclid’s axioms [48].
Because of the prominent place Greek geometric constructions held in Euclid’s Elements [48], these
constructions are sometimes also known as Euclidean constructions. Such constructions lay at the heart
of the geometric problems of antiquity of circle squaring, cube duplication, and angle trisection. The
Greeks were unable to solve these problems, but constructions for regular triangles, squares, pentagons,
and their derivatives had been given by Euclid.
It turns out that all constructions possible with a compass and straightedge can be done with a
compass alone, as long as a line is considered constructed when its two endpoints are located [149]. The
reverse is also true, since Jacob Steiner showed that all constructions possible with straightedge and
compass can be done using only a straightedge, as long as a fixed circle and its center have been drawn
beforehand. Such a construction is known as a Steiner construction.
8 Know the Rules Tutorial on Procedural Modeling
Figure 2: Compass and ruler operations have long been used in interactive procedural modeling. This Gothic win-
dow construction was created in the framework presented by Wolfgang Thaller et al. using direct manipulation
without any code or graph editing [126].
The long history of geometric constructions [71] is also reflected in the history of civil engineering and
architecture [79]. For example, Gothic architecture and especially window tracery exhibits quite complex
geometric shape configurations. But this complexity is achieved by combining only a few basic geometric
patterns. Sven Havemann and Dieter W. Fellner present some principles of this long-standing
domain, together with some delicate details, and show how the constructions of some prototypic Gothic
windows can be formalized using our generative modeling techniques [44]. Using modularization, so that
complex configurations can be obtained from combining elementary constructions, different combinations
of specific parametric features can be grouped together, which leads to the concept of styles. They
permit to differentiate between the basic shape and its appearance, i.e., in a particular ornamental
decoration [126]. This leads to an extremely compact representation for a whole class of shapes [15].
1.2 Architecture
Generative modeling techniques have rapidly gained attention throughout the past few years. Many
researchers enforced the creation of generative models due to its many advantages. All objects with
well-organized structures and repetitive forms can be described procedurally. In these cases, generative
modeling is superior to conventional approaches.
A big advantage of procedural modeling techniques is the included expert knowledge within an object
description [135], e.g., classification schemes used in architecture, archaeology, civil engineering, etc. can
be mapped to procedures. For a specific object, only its type and its instantiation parameters have to be
identified [138]; the generative building blocks themselves are fixed and do no change. As a consequence,
only their evaluation parameters have to be specified: Figure 3 illustrates variations of the same building
blocks.
The usage of generative modeling techniques in architecture is not limited to buildings of the past.
Over the last few decades, progressive architects have used a new class of design tools that support
generative design. Generative modeling software extends the design abilities of architects by harnessing
computing power in new ways. Computers, of course, have long been used to capture and implement
the design ideas of architects by means of CAD and, more recently, 3D modeling. But generative design
actually helps architects design by using computers to extend human abilities.
An impressive example is the Helix Bridge in Singapore (see Figure 4). The 280 m bridge is made
up of three 65 m spans and two 45 m end spans. The major and minor helices, which spiral in opposite
directions, have an overall diameter of 10.8 m and 9.4 m respectively. The outer helix is formed from
six tubes which are set equidistant from one another, whereas the inner helix consists of five tubes.
C. Schinko, U. Krispel & T. Ullrich, 2015 9
Figure 3: Gothic architecture flourished during the high and late medieval period. It is defined by strict rules with
its characteristics: pointed arcs, the ribbed vaults, and the flying buttresses. These building blocks have been com-
bined in various ways to create great churches and cathedrals all over Europe. The generative description of Gothic
cathedrals encodes these building blocks and the rules on how to combine them. The result is an algorithm that takes
a few high-level parameters. By modifying these parameters, it is easy to generate a family of Gothic examples (left,
middle, right). The building blocks have been created by Michael Curry, http://www.thingiverse.com/thing:2030.
10 Know the Rules Tutorial on Procedural Modeling
Figure 4: The Helix Bridge is a pedestrian bridge in the Marina Bay area in Singapore. Its generative design
has been optimized numerically. Furthermore, the bridge was fully modeled in order to visualize its form and
geometrical compatibility, as well as to visualize the pedestrian experience on the bridge.
The bridge design is the product of inseparable collaboration between architects (Cox Architecture and
Architects 61) and civil engineers (Arup Consultant). For its 280 meter length, the dual helix structure
of the bridge utilizes 5 times less steel than a conventional box girder bridge. This fact enabled the client
to direct the structure to be constructed entirely of stainless steel for its longevity.
1.3 Civil Engineering
The generative modeling approach is very general. It can be applied to any domain and is not restricted
to shape representations [25]. Nevertheless, this tutorial focuses on shape design, computer-aided design
and 3D modeling.
Figure 5: The design of ascent assemblies for offshore cranes (colored in red) results in high efforts and con-
tributes a major part of the overall engineering costs of a crane. In case of repetitive and nearly identical design
processes, the product development processes can be optimized by software driven design automation: the reduction
of engineering efforts by modeling design knowledge [38].
C. Schinko, U. Krispel & T. Ullrich, 2015 11
In the context of 3D computer-aided design (CAD), each design process that involves repetitive tasks is
perfectly suited for a generative approach. Engineering processes can be differentiated in repetitive and
creative processes. In contrast to creative processes, repetitive ones consist of nearly identical tasks and
are therefore independent of creative decisions. This condition is necessary for modeling them in a system
of rules as demonstrated by Gerald Frank [39]: Liebherr manufactures and sells an extensive range of
products including ship-, offshore and harbor mobile cranes as well as hydraulic duty cycle crawler cranes
and lift cranes. Due to customers’ needs each crane has to be partially or fully engineered, but the design
process of ascent assemblies is based on repetitive tasks based on a set of invariant rules that can be
modeled and stored. In numerous interviews with engineering experts at Liebherr the repetitive design
processes have been analyzed and a generative model has been designed. Integrated into the existing
CAD pipeline, a construction engineer now only has to determine the defining parameters of an assembly
and fill out the corresponding input fields in a user interface. The engineering of ascent assemblies of an
offshore crane required up to 150 hours. Using the procedural approach, the efforts have been reduced
down to 10%.
1.4 Natural Patterns
In today’s procedural modeling systems, scripting languages and grammars are often used as a set of rules
to achieve a description. Early systems based on grammars were Lindenmayer systems [99] (L-systems)
named after Aristid Lindenmayer. They were successfully applied to model plants. Given a set of
string rewriting rules, complex strings are created by applying these rules to simpler strings. Starting with
an initial string the predefined set of rules form a new, possibly larger string. The L-systems approach
reflects a biological motivation. In order to use L-systems to model geometry an interpretation of the
generated strings is necessary.
The modeling power of these early geometric interpretations of L-systems was limited to creating
fractals and plant-like branching structures (see Figure 6). This lead to the introduction of parametric
L-systems. The idea is to associate numerical parameters with L-system symbols to address continuous
phenomena which were not covered satisfactorily by L-systems alone.
L-System:
Axiom: F X
Angle: 28
Rules:
F 7→ C
0
F F [C
1
F +F ]+[C
2
+F F ]
X 7→ C
0
F F + [C
1
+ F ] + [C
3
F ]
whereas F denotes “draw forward” and +/
denote “turn left”/“turn right”. The square
bracket [ corresponds to saving the current
values for position and angle, which are re-
stored when the corresponding square bracket
] is executed. C
0
, C
1
, C
2
switch colors and X
does not correspond to any drawing action.
This example can be executed online by
Kevin Roast’s L-Systems-Demo:
http://www.kevs3d.co.uk/dev/lsystems/
Figure 6: Lindenmayer systems are a simple but elegant “turtle rendering” platform. The recursive nature of
L-system rules lead to self-similarity and thereby fractal-like forms. Plant models and natural-looking organic
forms “grow” and become more complex by increasing the iteration level i.e. the number of substitutions.
12 Know the Rules Tutorial on Procedural Modeling
Combined with additional 3D modeling techniques, Lindenmayer systems can be used to generate complex
geometry [129], [130]. In order to generate models of plants, terrains, and other natural phenomena that
are convincing at all different scales, Robert F. Tobler et al. introduce a combination of subdivision
surfaces, fractal surfaces, and parametrized L-systems, which makes it possible to choose which of them
should be used at each level of resolution. Since the whole description of such multi-resolution models
is procedural, their representation is very compact and can be exploited by level-of-detail renderers that
only generate surface details that are visible.
This kind of data amplification can be found in various fields of computer graphics. E.g. curved
surfaces specified by a few control points are tessellated directly on the GPU. This results in low storage
costs and allows generating the complex model only when needed, while also reducing memory transfer
overheads. Although L-systems are parallel rewriting systems, derivation through rewriting leads to very
uneven workloads. Furthermore, the interpretation of an L-system is an inherently serial process. Thus,
L-systems are not straightforwardly amenable to parallel implementation. In 2010, Markus Lipp et al.
presented a solution to this algorithmic challenge [68].
1.5 Entertainment
The demoscene is a computer related subculture that specializes in producing demos, which are pro-
grams that perform audio-visual presentations. The scene has been active since the advent of personal
computers, for a brief history we refer to the book of Tomas Polgar [98].
The creation of such programs is often tied to various constraints, as memory and general hardware
capabilities of the early personal computers were quite limited. Nowadays, these constraints are mostly
of self-imposed nature, e.g. creating a demo using only a filesize of 4096 bytes (or 4kB). Naturally, these
constraints facilitate the usage of procedural methods for any type of presentation content: 3D geometry
(meshes), textures [32], sound, etc.
Even without these limitations, content creation [133] has always been the main field of applica-
tion for procedural techniques: from game design [5], [27], [57], [97], [132], and virtual worlds [104], to
non-geometry aspects such as story-telling and drama management [85], camera movements [60] and
player [131] / artificial intelligence modeling [9], [54].
From a historical point of view, although procedural methods arose in the field of early video game
development, their use was not common in the special effects and feature animation community.
While computer-generated content made first appearance in movies in the late 70s, it was not until
the 90s, most notably with the movies Terminator 2 and Jurassic Park, that the film industry started
using 3D computer graphics for content authoring and animation. Nowadays, procedural effects for 3D
games are similar to procedural effects for movie productions. Differences can be found in the degree of
visual fidelity, but these are mainly caused by the real-time demands of 3D games.
Visual artists use 3D animation tools to create procedural effects (see Table 2). Several talks at
Siggraph 2014 [116] underly the relevance of the topic for the film industry:
Daniel Heckenberg et al. presented a procedural approach to create, animate and render repet-
itive geometric features such as scales or cobblestones developed for the movie Walking With Di-
nosaurs 3D. These tools were used to realize hundreds of different dinosaur characters from nine
different species.
An algorithm to create procedural tentacle bundles for an alien creature in the movie Edge of
Tomorrow was presented by Dan Sheerin. It allows an entire tentacle bundle to be defined by a
base curve and a list of parameters.
Francesco Giordana et al. presented a hybrid CPU/GPU, fully procedural node based frame-
work for fur animation. Each node can be GPU accelerated with the option to falling back to CPU
computation in case of errors at any point in the graph.
C. Schinko, U. Krispel & T. Ullrich, 2015 13
1.6 Applications
Procedural Generation of
Road [40]
Interactive Architectural
Modeling with Procedural
Extrusions [58]
Procedural Modeling of
Interconnected Structures
[62]
Interactive Modeling of
City Layouts using Layers
of Procedural Content [66]
Interactive Visual Editing
of Grammars for Procedu-
ral Architecture [67]
Model Synthesis: A Gen-
eral Procedural Modeling
Algorithm [76]
Computer-generated res-
idential building layouts
[77]
Interactive Furniture Lay-
out Using Interior Design
Guidelines [78]
Interactive Coherence-
Based Facade Modeling
[83]
Procedural Modeling of
Cities [92]
Modeling Procedural
Knowledge a genera-
tive modeler for cultural
heritage [106]
Scripting Technology for
Generative Modeling [107]
Procedural Descriptions
for Analyzing Digitized
Artifacts [138]
Modelling the Appear-
ance and Behaviour of Ur-
ban Spaces [144]
Procedural Design of Ex-
terior Lighting for Build-
ings with Complex Con-
straints [111]
Terrain Generation Using
Procedural Models Based
on Hydrology [41]
Generating and Explor-
ing Good Building Lay-
outs [12]
Procedural Facade Varia-
tions from a Single Layout
[11]
Table 1: Currently architecture, urban design and civil engineering are the predominant fields of applications for
generative modeling, although the main concept can be applied to any domain.
14 Know the Rules Tutorial on Procedural Modeling
C. Schinko, U. Krispel & T. Ullrich, 2015 15
2 Languages & Grammars
Originally, scripting languages have been designed for a special purpose, e.g., to be used for client-side
scripting in a web browser. Nowadays, the applications of scripting languages are manifold. JavaScript,
for example, is used to animate 2D and 3D graphics in VRML [23] and X3D [13] files. It checks user
forms in PDF files [22], controls game engines [31], configures applications, defines 3D shapes [107], and
performs many more tasks. According to John K. Ousterhout scripting languages use a higher level
of abstraction compared to system programming languages as they are often typeless and interpreted
to emphasize the rapid application development purpose [90]. Whereas system programming languages
are designed for creating algorithms and data structures based on low-level data types and memory
operations. As a consequence, graphics libraries [88], graphics shaders [86] and scene graph systems [102],
[146] are usually written in C/C++ dialects [33], and procedural modeling frameworks use scripting
languages such as Lua, JavaScript, etc.
2.1 Language Processing & Compiler Construction
The evaluation of procedural descriptions typically utilizes techniques used for description of formal
languages and compiler construction [93]. The range of different concepts of languages to describe a
shape is very wide and comprehends all kinds of linguistic concepts [26]. The main categories to describe
a shape are
rule-based: using substitutions and substitution rules to build complex structures out of simple
starting structures [91], [63], [82], [118].
imperative and scripting-based: using a scripting engine and techniques used in predominant pro-
gramming languages [43], [107], [62], or
GUI and dataflow-based: using new graphical user interfaces (GUI) and intelligent GUIs to detect
structures in modeling tasks, which can be mapped onto formal descriptions [67], [125].
Nevertheless, the general principles of formal descriptions and compiler construction are in all cases the
same independent of ahead-of-time compilation, just-in-time compilation or interpretation [109]. The
basic steps are illustrated in Figures 7 and 8. They outline the compilation process and show the main data
structures especially the abstract source tree (AST): In the first stage the input source code is passed
to lexer and parser. A first step is to convert a sequence of characters into a sequence of tokens, which is
done by special grammar rules forming the lexical analysis. For instance, in some languages only a limited
number of characters is allowed for an identifier: all characters A-Z, a-z, digits 0-9 and the underscore
are allowed with the condition that an identifier must not begin with a digit or an underscore. Such lexer
rules are embedded in another set of rules the parser rules. They are analyzing the resulting sequence
of tokens to determine their grammatical structure. The complete grammar consists of a hierarchical
structure of rules for analyzing all possible statements and expressions that can be formed in a language,
thus forming the syntactic analysis.
For each language construct available a set of rules is validating syntactic correctness. At the same
time actions within these rules create the intermediate AST structure that represents the input source
code. The resulting AST is the main data structure for the next stage: semantic analysis. Once all
statements and expressions of the input source code are collected in the AST, a tree walker analyzes their
semantic relationships, i.e., errors and warnings are generated, for instance, when symbols are used but
not defined, or defined but not used.
Having performed all compile-time checks, a translator uses the AST to generate platform-specific
files. In other words, this task involves complete and accurate mapping of the AST to constructs of the
target platform.
The example in Figures 7 and 8 shows a compilation process of JavaScript. In JavaScript, the top-level
rule of an AST is always a simple list of statements – no enclosing class structures, no package declaration,
no inclusion instructions, etc. Each statement contains all included substatements and expressions as
well as associated comments. During the validation step, this tree structure is extended by reference and
occurrence links; e.g., each method call references the method’s definition and each variable definition
links to all its occurrences. Having assured that all compile-time checks are carried out, symbols are
stored in a so called namespace. During validation, this data structure is used to detect name collisions
(e.g. redefinition of variables) and undefined references (e.g. usage of undeclared variables).
16 Know the Rules Tutorial on Procedural Modeling
var pi = 3.14159 ; function circle_area
( radius ) { return pi * radius *
radius ; } for ( var i = 1 ; i
< 10 ; ++ i ) { var radius = 10
+ 2 * i ; var area = circle_area
( radius ) ; var text = "circle #"
+ i + ": " + "r = " + radius +
" cm, " + "A = " + area + " cm^2." ;
IO . print ( text ) ; }
= ;
( ) {
* * ;
}
( = ; < ; ++ ) {
= + * ;
= ( );
= + +
+ + +
+ + + ;
. ( );
}
var
function
return
for var
var
var
var
pi
circle_area radius
pi radius radius
i i i
radius i
area circle_area radius
text i
radius
area
IO print text
3.14159
1 10
10 2
"circle #" ": "
"r = " " cm, "
"A = " " cm^2."
1. The first step in a compiler
pipeline is performed by a lexi-
cal analyzer. It converts source
code (top left) into a sequence
of tokens, i.e. a string of one
or more characters that is sig-
nificant as a group. Tokens are
identified based on specific rules
of the lexer.
2. The stream of to-
kens (middle right) is pro-
cessed by the syntactic an-
alyzer based on the gram-
mar rules of the language
to parse. This example is
written in JavaScript. Its
entry point into the gram-
mar rules is a statement-
rule.
3. The result of the parsing step is an abstract
source tree (AST) (see Figure 8 right). Af-
terwards, the sematic analyzer constructs the
table of symbols (see Figure 8 left) and gen-
erates all references needed to resolve names
(see Figure 8 red pointers).
4. In an optional step, an optimizer may per-
form changes in the AST in order to speed
up the final code; in this example, the vari-
able pi and the function circle area are only
assigned once. Therefore, they might be re-
solved and inlined in order to reduce the num-
ber of look-ups and function calls.
5. In the final step a code generator produces
object code of the target platform.
Figure 7: A compiler consists of three main components: a front-end reads in the source code and constructs
a language-independent representation a so-called abstract source tree (AST). The middleware performs nor-
malization and optimization steps on the AST. Finally, the back-end generates platform-specific object code, i.e.
executables, libraries, etc.
C. Schinko, U. Krispel & T. Ullrich, 2015 17
variable declaration
name: value:
pi 3.14159
function declaration
name:
circle_area
parameters:
radius
body:
{
return
value:pi * radius * radius
}
for-loop
declared iterator: value:
i 1.0
conditional
expression:
increment expression:
i < 10.0 ++ i
body:
{
variable declaration
name: value:
radius 10.0 + 2.0 * i
variable declaration
name: value:
area circle_area(radius)
variable declaration
name: value:
text "circle #" + i +
": " + "r = " +
radius + " cm, "
+ "A = " + area +
" cm^2."
expression
IO.print(text)
}
Table of symbols:
GLOBAL .IO
[. . . ]
GLOBAL .area
[. . . ]
GLOBAL .circle area
[. . . ]
GLOBAL .circle area.msg
[. . . ]
GLOBAL .circle area.radius
[. . . ]
GLOBAL .i
[. . . ]
GLOBAL .pi
declaration statement:
var pi = 3.14159;
declaration file & line:
example.ecs:1
references:
1. example.ecs:1
var pi = 3.14159;
2. example.ecs:4
return pi * radius * radius;
GLOBAL .radius
[. . . ]
GLOBAL .text
[. . . ]
Figure 8: The most important data structure within a compiler (suite) is the abstract source tree (AST), which
represents the input source code in a language-independent way. It consists of a tree structure to encode the
hierarchical, nested statements (right) enriched by references to resolve symbols (visualized in red). Additional
data structures such as a table of symbols (left) simplify the work performed by the compiler’s middleware.
18 Know the Rules Tutorial on Procedural Modeling
From a historical point of view, the first procedural modeling systems were Lindenmayer systems [99],
or L-systems for short. These early systems, based on grammars, provided the means for modeling plants.
The idea behind it is to start with simple strings and create more complex strings by using a set of string
rewriting rules. The modeling power of these early geometric interpretations of L-systems was limited to
creating fractals and plant-like branching structures.
Later on, L-systems are used in combination with shape grammars to model cities [92]. Yogi Parish
and Pascal M
¨
uller presented a system that generates a street map including geometry for buildings
given a number of image maps as input. The resulting framework is known as CityEngine a modeling
environment for CGA Shape. Also based on CGA Shape, Markus Lipp et al. presented another modeling
approach [67] following the notation of Pascal M
¨
uller [82]. It deals with the aspects of more direct local
control of the underlying grammar by introducing visual editing. Principles of semantic and geometric
selection are combined as well as functionality to store local changes persistently over global modifications.
Sven Havemann takes a different approach to generative modeling. He proposes a stack based
language called Generative Modeling Language (GML) [43]. The postfix notation of the language is very
similar to that of Adobe Postscript.
Generative modeling inherits methodologies of 3D modeling and programming [136], which leads
to drawbacks in usability and productivity. The need to learn and use a programming language is
a significant inhibition threshold especially for archaeologists, cultural heritage experts, etc., who are
seldom experts in computer science and programming. The choice of the scripting language has a huge
influence on how easy it is to get along with procedural modeling. Processing is a good example of how
an interactive, easy to use, yet powerful, development environment can open up new user groups. It has
been initially created to serve as a software sketchbook and to teach students fundamentals of computer
programming. It quickly developed into a tool that is used for creating visual arts [101].
Processing is basically a Java-like interpreter offering new graphics and utility functions together
with some usability simplifications. A large community behind the tool produced libraries to facilitate
computer vision, data visualization, music, networking, and electronics. Offering an easy access to pro-
gramming languages that are difficult to approach directly reduces the inhibition threshold dramatically.
Especially in non-computer science contexts, easy-to-use scripting languages are more preferable than
complex programming paradigms that need profound knowledge of computer science. The success of
Processing is based on two factors: the simplicity of the programming language on the one hand and the
interactive experience on the other hand. The instant feedback of scripting environments allow the user
to program via “trial and error”. In order to offer our users this kind of experience, we enhanced our
already existing compiler to an interactive environment for rapid application development.
2.2 Scripting Languages for Generative Modeling
There exists a broad variety of tools and techniques for procedural modeling. We provide an overview of
a collection of generative modeling techniques (see Table 2) under the following aspects:
application domain: Generative modeling tools often incorporate prior knowledge of a specific applica-
tion domain, e.g. generative modeling of architecture [122], or modeling of organic structures [69],
[99], which is reflected in this aspect.
programming category: Some methods are built on top of conventional programming languages, or
scripting languages. On the contrary, some techniques are built using proprietary languages, such
as rule-based systems for buildings [151], or [82] for urban modeling. Some systems can be used
even without any scripting, e.g. graph-based languages [126], or the visual interactive editing of
split grammars [67].
environment: This aspect covers the tool set that provides geometric entities and operations, for ex-
ample the geometry kernel of a 3d modeling software, e.g. the open source modeling suite blender
or a proprietary system such as shape grammars on convex polyhedra [127].
C. Schinko, U. Krispel & T. Ullrich, 2015 19
Tool Name Application Domain Programming Category Environment
Blender Scripting general purpose model-
ing
python scripting open source modeling
software blender
CityEngine [82] urban modeling CGA shape commercial integrated
development environ-
ment CityEngine
Generalized Grammar
G
2
[63]
scientific python scripting commercial modeling
software Houdini
Generative Modeling
Language (GML) [43]
CAD postscript dialect proprietary, integrated
development environ-
ment for polygonal and
subdivision modeling
Grasshopper 3D visual arts, rapid proto-
typing, architecture
visual programming
based on dataflow
graphs, Microsoft .NET
family of languages
commercial modeling
software Rhinoceros3D
HyperFun [94] scientific specialized high-level
programming language
proprietary geometry
kernel FRep (Function
Representation)
Maya Scripting general purpose model-
ing
Maya Embedded Lan-
guage (MEL) and
python scripting
commercial modeling
software Autodesk Maya
OpenSCAD CAD OpenSCAD language open source, based on
CGAL geometry kernel
PLaSM scientific python scripting, Func-
tion Level scripting
integrated development
environment Xplode
Processing visual arts, rapid proto-
typing
Java dialect open source, integrated
development environ-
ment Processing
PythonOCC general purpose model-
ing and CAD
python scripting Open CASCADE Tech-
nology
Revit Scripting architecture Microsoft .NET family of
languages
commercial modeling
software Autodesk Revit
siteplan [58] rapid prototyping, archi-
tecture
interactive GUI-based
modeler
open source, integrated
development environ-
ment siteplan
Sketchup Scripting architecture, urban mod-
eling and CAD
Ruby scripting commercial modeling
software SketchUp
Skyline Engine [95] urban modeling visual programming
based on dataflow
graphs, python scripting
commercial modeling
software Houdini
speedtree plants/trees interactive GUI-based
modeler, SDK for C++
standalone modeler and
integration into various
game engines
Terragen landscape modeling interactive GUI-based
modeler
free and commercial,
integrated development
environment Terragen
XFrog [30] plants/trees interactive GUI-based
modeler
integrated development
environment, standalone
and plugins for Maya
and Cinema4D
Table 2: Overview on generative / procedural 3D modeling tools and approaches.
20 Know the Rules Tutorial on Procedural Modeling
There are many different programming paradigms in software development. Therefore, they also apply
to the field of generative modeling, where some paradigms emerged to be useful for specific domains.
imperative: In many cases, generative modeling is carried out using classical programming paradigms:
A programming language is used to issue the commands that generate a specific object using a
library that utilizes some sort of geometry representation and operations to perform changes. An
example are compass and ruler systems used by an imperative language. Furthermore, any modeling
software that is scriptable by an imperative language or provides some sort of API falls into this
category. Note that the resulting geometry is often produced as side effects.
dataflow based: The program is represented as a directed graph of the data flowing between operations.
The graph representation also allows for a graphical representation; Visual Programming Languages
(VPL) allow to create a program by linking and modifying visual elements, many VPL’s are based
on the dataflow paradigm. Examples in the domain of generative modeling are the Grasshopper3D
plug-in for the Rhinoceros3D modeling suite, or the work of Gustova Patow et al. [95] built on
top of the procedural modeler Houdini.
rule based systems: Another different representation that proved useful for generative modeling are
rule-based systems. Such systems provide a declarative description of the construction behavior of a
model by a set of rules. An example are L-Systems, as described in the Introduction. Furthermore,
the seminal work of George Stiny and James Gips [122] introduced shape grammars, as a formal
description of capturing the design of paintings and sculptures, in the sense of “design is calculating”.
Similar to formal grammars, shape grammars are based on rule replacement.
shape grammars In the classical definition [122], a shape grammar is the 4-tuple SG = (V
T
, V
M
, R, I),
where V
T
a set of shapes, V
T
denotes the set of the shapes of V
T
with any scale or rotation. V
M
is
a finite set of non-terminal shapes (markers) such that V
T
V
M
= . R denotes the set of rules,
which consists of pairs (u, v), such that u = (s, m) consists of a shape s V
T
combined with a
marker of m V
M
, and v is a shape consisting of either
v = s
v = (s, ˜m) with ˜m V
M
v = (s ˜s, ˜m with ˜s V
T
and ˜m V
M
Elements of the set V
T
that appear in and rules of R are called terminal shapes. I is called the
initial shape, and typically contains an u (u, v) R. The final shape is generated from the shape
grammar by starting with the initial shape and applying matching rules from R: for an input shape
and a rule (u, v) whose u matches a subset of the input, the resulting shape is another shape that
consists of the input shape with the right side of the rule substituted in the matching subset of
the input. The matching identifies a geometric transformation (scale, translation, rotation, mirror)
such that u matches the subset of the input shape and applies it to the right side of the rule. The
language defined by a shape grammar SG is the set of shapes that will be generated by SG that
do not contain any elements of V
M
.
split grammars The work of Peter Wonka et al. [151] applied the concepts of shape grammars
to derive a system for generative modeling of architectural models. This system uses a combination
of a spatial grammar system (split grammar) to control the spatial design and a control grammar,
which distributes the design ideas spatially (e.g. set different attributes for the first floor of a
building). Both of these grammars consist of rules with attributes that steer the derivation process.
The grammar consists of two types of rules: split and convert. The split rule is a partition operation
which replaces a shape by an arrangement of smaller shapes that fit in the boundary of the original
shape. The convert rule replaces a shape by a different shape that also fits in the boundary of the
original shape. A simple example is shown in Figure 9.
This system has further been extended by the work of Pascal M
¨
uller et al. [82], which introduced
a component split to extend the split paradigm to arbitrary 3d meshes, as well as occlusion queries
and snap lines to model non-local influences of rules. For example, two wall segments that intersect
each other should not produce windows such that the window of one wall coincides with the other
wall, therefore occlusion queries are used to decide if a window should be placed or not.
C. Schinko, U. Krispel & T. Ullrich, 2015 21
The derivation of a split grammar, starting from an initial shape, yields a tree structure, which
suggests that the derivation can be speed up by a parallel implementation, which has been shown
by Jean-Eudes Marvie et al.[72]. Parallel generation is especially useful in an urban context,
with scenes with high complexity and detail. The work of Lars Krecklau et al. [61] used gpu
accelerated generation in the context of generating and rendering high detailed building fa¸cades; the
work of Zhengzheng Kuang et al. [64] proposes a memory-efficient procedural representation of
urban buildings for real-time visualization.
With more advanced shape grammar systems, the non-local influences are a problem because
they introduce dependencies between arbitrary nodes of the derivation tree. Recent work by
Markus Steinberger et al. [120] shows how to overcome this problem in an GPU implemen-
tation. Furthermore, the same authors presented methods to interactively generate and render only
the visible part of a procedural scene using procedural occlusion culling and level of detail [121]
Figure 9: The tiles of a floor that contains windows with decorative elements (keystones) are generated by a
split grammar. The set of rules (left) will yield the final instance of the floor if applied to a start image (right).
The derivation process is guided by an additional control grammar (e.g. which keystone is selected), which is not
shown in this figure [151].
22 Know the Rules Tutorial on Procedural Modeling
C. Schinko, U. Krispel & T. Ullrich, 2015 23
3 Modeling by Programming
3D objects, which consist of organized structures and repetitive forms, are well suited for procedural
description, e.g. by the combination of building blocks or by using shape grammars. We discuss the
problems in conjunction with the definition of a shape:
What is a suitable interface for a building block?
Especially within a pipeline of different tools, this question is gaining in importance.
Figure 10: In this Figure, three different data structures are used to represent a mug. A polygonal mesh is shown
in the left image. The image in the middle shows a subdivision surface with the corresponding control mesh. On
the right hand side, the mug is represented by a 64 × 64 × 64 grid of voxels.
3.1 Building Blocks & Elementary Data Structures
Several elementary data structures are commonly used in computer graphics (see Figure 10).
Figure 11: The quality of the polygonal approximation of a cylinder highly depends on the number of primitives.
By increasing the number of primitives a better approximation of a cylinder can be created. In our case we have
n-gonal prisms, where n is 4 (left), 8 (middle), 64 (right). Once the approximation is selected and saved as a
mesh, the semantic information: “This is a cylinder.‘” is lost.
Polygonal Meshes A polygonal mesh representation is well-suited for real-time computer graphics.
Their inherent structure consisting of vertices, edges and faces can be more or less directly
mapped onto consumer graphics cards. Due to numerical problems with floating point numbers,
modeling with polygons can lead to undesirable results. During many mesh operations, even within
a simple intersection routine, the trade-off between range and precision may cause inaccuracies.
Another drawback of polygonal meshes can be seen when trying to model free-form shapes. The
quality of the approximation of an object’s surface with polygons highly depends on the number
of primitives and the modeling operations used. Once an approximation is found, all information
about the approximated surface is often lost, see Figure 11.
24 Know the Rules Tutorial on Procedural Modeling
Apart from approximation problems, all operations are well-defined, e.g. boolean mesh operations
always yield a polygonal mesh. However, important questions remain unanswered: How does an
interface for binary mesh operations on polygonal meshes look like? Are half-edges in this context
a suitable interface?
Non-Uniform Rational B-Splines This problem gets worse when modeling with non-uniform rational
B-splines (NURBS). Even the question for a simple intersection of two NURBS curves is not easy
to answer. Apart from the cases where two curves do not intersect or are identical, there can be
at most 9 intersection points, when looking at cubic curves. Calculating the intersection leads to
numerical issues. The problems get worse when intersecting two NURBS surfaces. There can be
various intersection components such as curve segments, points, loops and singular points. These
components are approximated with respect to given tolerances. Given the intersection curve, how
are the two surfaces stitched together? An interface for this operation has to deal with all these
aspects.
Subdivision Surfaces Subdivision surfaces are defined recursively starting with a given polygonal mesh
(typically a quadrilateral, or a triangle mesh), as illustrated in Figure 10 (middle). A refinement
scheme is applied to this mesh creating new vertices and faces converging to the limit subdivision
surface (which is the surface produced by applying the refinement scheme infinitely many times).
Intersection operations are often carried out on a per-facet basis. Therefore, the surfaces are
subdivided into a great number of facets and the intersection of surfaces is approximated by the
intersection of the facet pairs. Although, the stitching problem remains and undesired artifacts
around the intersection curve may occur.
For ensuring manufacturability, additional constraints have to be considered. For 3D printing
purposes, the geometry has to be water-tight and free of self-intersections. The former can, for
example, be ensured by using topology preserving Euler operators for mesh creation. They operate
on the connection graph of the mesh representation and obtain a valid boundary. The latter
property can be ensured by careful use of modeling operations.
Convex Polyhedra However there are data structures that do not have these problems. Shapes can be
defined by the intersection of half-spaces. In general, the intersection of arbitrary half-spaces need
not be bounded. So called convex polyhedra can be defined algebraically as the set of bounded
solutions to a system of linear inequalities. An important topological property is that convex
polyhedra are homeomorphic to a closed ball. All operations are well-defined, leaving the problem
with the finite precision of floating point numbers.
Voxel Representations A voxel represents a data point on a regular, three-dimensional grid similar to
a pixel in an image. Depending on the area of application, the data point can be multi-dimensional,
e.g. a vector of density and color. Due to the fact that position and size of a voxel are pre-
defined, voxels are good at representing regularly sampled spaces. The approximation of free-form
shapes suffers from this inherent property, as can be seen in Figure 10 (right). Nevertheless, voxel
representations do not suffer from numerical instabilities as they are typically defined on an integer
grid.
Implicit Surfaces Implicit surfaces are defined as isosurfaces by a function R
3
R. Therefore, similar
to voxels, a surface is only indirectly specified. Also, with a function it is hard to describe sharp
features and it is difficult to enumerate points on a surface. However, this representation has
several advantages. There is an efficient check, whether a point is inside a shape, or not. Surface
intersections as well as binary operations can be implemented efficiently. Since the surface is not
represented explicitly, topology changes are easily possible.
C. Schinko, U. Krispel & T. Ullrich, 2015 25
Creating shapes with the presented elementary data structures requires the definition of modeling opera-
tions. Depending on the underlying representation, certain modeling operations are difficult or impossible
to implement. The selection of operations for these data structures are manifold and can be grouped as
follows:
Instantiation are operations for creating new shapes.
Binary Creations are operations involving two shapes such as constructive solid geometry (CSG)
operations.
Deformations and Manipulations stand for all deforming and modifying operations like morphing
or displacing.
Also building blocks can be regarded as modeling operations. Complex shapes typically consist of subparts
so called building blocks. We have already mentioned the open problem of defining a suitable interface on
a data structure level. This problem still exists when describing shapes on a more abstract level. When
creating an algorithmic description of a shape, one has to identify inherent properties and repetitive
forms. These properties must be accounted for in the structure of the description. Identified subparts
or repetitive forms are best mapped to functions in order to be reusable. However, the true power of an
algorithmic description becomes obvious when parameters are introduced for these functions. As little as
the possibility to position a subpart at a different location using input parameters makes the difference.
From that point on, the algorithmic description no longer stands for a single object, but for a whole
object family.
Within a composition of modeling functions, where each function is attached via its parameters to
topological entities defined in previous states of the model, another problem occurs. Referenced entities
must then be named in a persistent way in order to be able to reevaluate the model in a consistent
manner. In particular, when a reevaluation leads to topological modifications, references between entities
used during the design process are frequently reevaluated in an erroneous way, giving results different
from those expected. This problem is known as “persistent naming problem” [70].
3.2 Advanced Techniques
Besides classical, geometric operations – such as CSG – procedural and functional descriptions offer novel,
additional possibilities to describe a shape.
Architectural Modeling with Procedural Extrusions This method utilizes the paradigm of foot-
print extrusion to automatically derive geometry from a coarse description. Input to this system are
polygons whose segments can be associated with an extrusion profile polygon. The system utilizes the
weighted straight skeleton method [7] to calculate the resulting geometry. Examples can be seen in Fig-
ure 12. An implementation is available under the name siteplan, see also the tools section and Table 2.
While the growing demand for new building models contained in virtual worlds, games, and movies,
makes the easy and fast creation of modifiable models more and more important, 3D modeling of buildings
can be a tedious task due to their sometimes complex geometry. For historic buildings, especially the
roofs can be challenging. Johannes Edelsbrunner et al. present a new method of combining simple
building solids to form more complex buildings, and give an emphasis on the blending of roof faces.
This can be integrated in common pipelines for procedural modeling of buildings and will bring more
expressiveness than existing methods [34].
Deformation Aware Shape Grammars Generative models based on shape and split grammar sys-
tems often exhibit planar structures. This is the case because these systems are based on planar primitives
and planar splits. There are many geometric tools available in modeling software to transform planar
objects into curved ones, e.g. free-form deformation [112]. Applying such a transformation as a post-
processing step might yield undesirable results. For example, if we bend a planar facade of a building
into a curved shape, the windows inside the fa¸cade will have a curved surface as well. Another possibly
unwanted property arises when an object is deformed by scaling, e.g. the windows on a fa¸cade would
have different appearances. Therefore, Ren
´
e Zmugg et al. introduced deformation aware shape gram-
mars [156], which integrate deformation information into grammar rules. The system still uses established
26 Know the Rules Tutorial on Procedural Modeling
Figure 12: The work of Tom Kelly and Peter Wonka [58] offers a framework to specify the geometry of a
building by extrusion profiles. The segments of footprint polygons (e.g. c) are associated with extrusion profiles,
e.g. the green segments are associated to the profile a, the purple segments to the profile b. The resulting geometry
can be seen in d.
methods utilizing planar primitives and splits, however, measurements that determine the available space
for rules are performed in deformed space. In this way, deformed splits can be carried out, the deforma-
tion can be baked at any point to allow for straight splits in deformed geometry. An example is shown
in Figure 13.
Variance Analysis Analyzing and visualizing differences of similar objects is important in many re-
search areas: scan alignment, nominal/actual value comparison, and surface reconstruction to name a
few. In computer graphics, for example, differences of surfaces are used to validate reconstruction and
fitting results of laser scanned surfaces. Scanned representations are used for documentation as well as
analysis of ancient objects revealing smallest changes and damages. Analyzing and documentation tasks
are also important in the context of engineering and manufacturing to check the quality of productions.
Christoph Schinko et al. [110] contribute a comparison of a reference / nominal surface with an ac-
tual, laser-scanned data set. The reference surface is a procedural model whose accuracy and systematics
describe the semantic properties of an object, whereas the laser-scanned object is a real-world data set
without any additional semantic information. The first step of the process is to register a generative
model (including its free parameters) to a laser scan. Then, the difference between the generative model
and the laser scan is stored in a texture, which can be applied to all instances of the same shape family
as illustrated in Figure 14.
As generative models represent an ideal object rather than a real one, the combination of noisy 3D
data with an ideal description enhances the range of potential applications. This bridge between both
C. Schinko, U. Krispel & T. Ullrich, 2015 27
Figure 13: Deformation aware shape grammars allow the integration of free-form deformation into a grammar-
based system that is based on planar primitives and splits. Measurement about the available space for placing
objects are taken in deformed space while splits are carried out in undeformed space. An undeformed building
with rooms (left image) is deformed using two different deformations (middle, right). It can be observed that the
amount of windows and rooms adapts automatically to the available space [156].
the generative and the explicit geometry description is very important: it combines the accuracy and
systematics of generative models with the realism and the irregularity of real-world data as pointed out
by David Arnold [6]. Once the procedural description is registered to a real-world artifact, we can use
the fitted procedural model to modify a 3D shape. In this way we can design both low-level details and
high-level shape parameters at the same time.
3.3 Semantic Modeling
In some application domains, e.g. in the context of digital libraries, semantic meta data plays an important
role. It provides semantic information that makes up the basis for digital library services: indexing,
archival, and retrieval. Depending on the field of application, meta data can be classified according to
the following criteria [139]:
Data Type The data type of the object can be of any elementary data structure (e.g. Polygons, NURBS,
Subdivision Surfaces, . . . ).
Scale of Semantic Information This property describes, whether meta data is added for the entire
data set or only for a sub part of the object.
Type of Semantic Information The type of meta data can be descriptive (describing the content),
administrative (providing information regarding creation, storing, provenance, etc.) or structural
(describing the hierarchical structure).
Type of creation The creation of the semantic information for an object can be done manually (by a
domain expert) or automatically (e.g. using a generative description).
Data organization The two basic concepts of storing meta data are storing the information within the
original object (e.g. EXIF data for images), or storing it separately (e.g. using a database).
Information comprehensiveness The comprehensiveness of the semantic information can be declared
varying from low to high in any gradation.
An important aspect of semantic enrichment are standards. Many concepts for encoding semantic
information can be applied to 3D data, unfortunately only a few 3D data formats support semantic
markup [114]:
Collada The XML-based Collada format allows storing meta data like title, author, revision etc. not
only on a global scale but also for parts of the scene. This file format can be found in Google
Warehouse where meta data is, for example, used for geo-referencing objects.
PDF 3D PDF 3D allows to store annotations separated from the 3D data even allowing annotating the
annotations. An advantage is that the viewer application is widely spread and PDF documents are
the quasi standard for textual documents.
28 Know the Rules Tutorial on Procedural Modeling
Figure 14: This figure shows the scanned model (top left), the procedural reference model (top middle), as well
as the output of the combined representation (top right). The combined version consists of a static instance of
the procedural model with details stored in a texture. The details are applied to the procedural base geometry via
shaders. The procedural reference model has been defined by a set of parameters obtained in a fitting process
applied on the scanned model. Having modified the procedural parameters, new procedural cups can be generated
(bottom middle). If one of these new cups is combined with an already existing texture, previously captured details
can be transferred (bottom right).
Due to the persistent naming problem, a modification of the 3D model can break the integrity of the
semantic information. Any change of the geometry can cause the referenced part of the model to no
longer exist or being changed.
There are a lot of examples for semantic modeling in various contexts [42], [128], [143], [153], [20].
Here, one representative from the field of geospatial modeling is selected to illustrate the topic:
Input parameters for a generative description can be either artificial or derived from real-world mea-
surements, like survey or satellite images. In the domain of geospatial modeling, data exported from
geospatial databases is used. The two file formats GeographyML (www.opengeospatial.org) and CityGML
(www.citygml.org) are wide-spread. Erick Mendez et al. [74] generate models using data exported from
geospatial databases, typically available in a vector format, to transcode it into 3D models suitable for
standard rendering engines. The transcoding process involves information loss, therefore the right point in
the pipeline has to be found to perform transcoding – this is called transcoding trade-off. Their modeling
framework lets developers optimize the transcoding trade-off to create 3D interactive visualizations. The
example augmented reality application shown in Figure 15 displays underground infrastructure created
out of geographic information systems (GIS) data.
C. Schinko, U. Krispel & T. Ullrich, 2015 29
Figure 15: An augmented reality application displays underground infrastructure created out of GIS data together
with wireframe building models that help retain spatial context [74].
30 Know the Rules Tutorial on Procedural Modeling
C. Schinko, U. Krispel & T. Ullrich, 2015 31
4 Inverse Modeling
4.1 Problem Description
In order to use the full potential of generative techniques, the inverse problem has to be solved; i.e. what
is the best generative description of one or several given instances of an object class? This problem can
be interpreted in several ways. The simplest way to create a generative model out of a given 3D object
is to store it in the geometry definition file format called OBJ. A simple cube may result in a file with
content:
# definition of vertices
v 1.0 -1.0 -1.0
v 1.0 -1.0 1.0
v -1.0 -1.0 1.0
v -1.0 -1.0 -1.0
v 1.0 1.0 -1.0
v 1.0 1.0 1.0
v -1.0 1.0 1.0
v -1.0 1.0 -1.0
# definition of faces
f 1 2 3 4
f 5 8 7 6
f 1 5 6 2
f 2 6 7 3
f 3 7 8 4
f 5 1 4 8
This file format structure can be interpreted as a simple language in Polish prefix notation. Prefix
notation is a form of notation for logic, arithmetic, and algebra. Its distinguishing feature is that it places
operators (v, f, . . . ) to the left of their operands / parameters. Obviously, this is not the desired result
as the generative model can only represent a shape families, which are composed of only one member.
4.2 Overview on Current Approaches
Parsing shape grammars Shape grammars can be used to describe the design space of a class of
buildings / fa¸cades . An interesting application is therefore: given a set of rules and measurements of a
building, typically photographs or range scans, which application of rules yields the measurements? In
this context, the applied rules can also be seen as parse tree of a given input.
The work of Hayko Riemenschneider et al. [103] utilizes shape grammars to enhance the results of a
machine learning classifier that is pre-trained to classify pixels of an orthophoto of a fa¸cade into categories
like windows, walls, doors and sky. The system applies techniques from formal language parsing, a variant
of the CYK algorithm, to parse a two-dimensional split grammar that consists of horizontal and vertical
splits, as well as repetition and symmetry operations. In order to reduce the search space, an irregular
grid is derived from the classifications, and the parsing algorithm is applied to yield the most probable
application of rules that yields a classification label per grid cell. Such a parse tree can easily be converted
into a procedural model, as can be seen in Figure 16.
Fuzhang Wu et al. [152] also address the problem of how to generate a meaningful split grammar
explaining a given facade layout. Given a segmented facade image, the system uses an approximate
dynamic programming framework to evaluate if a grammar is a meaningful description. However, the
work does not contribute to the problem of facade image segmentation.
Model synthesis The work of Paul Merell and Dinesh Manocha [75] is set in the context of
automatic generation of a variation of models. The task is that given an exemplaric object (i.e. a mesh)
and constraints, derive a locally similar object. The method was inspired by texture synthesis methods.
These methods generate a large two-dimensional texture from a small input sample, where the result
is locally similar to the input texture, but should not contain visible regularities or repetitions. The
method computes a set of acceptable states, according to several types of constraints, and constructs a
set of parallel planes that correspond to faces orientations of the input model. Intersections of these planes
yield possible vertex positions in the output model. The system proceeds by assigning an acceptable state
32 Know the Rules Tutorial on Procedural Modeling
(a) orthophoto (b) classification result (c) irregular grid
(d) parsed structure (e) 3d rendering (f) reconstruction
Figure 16: A building fa¸cade (a) is classified into pre-trained categories using a machine learning classifier (b).
From these classifications, a irregular grid is derived (c), and a two-dimensional split grammar is parsed (d). It
can be seen that the system was able to detect horizontally repeated columns (red rectangles) and two side parts,
symmetric around the middle part (connected blue rectangles). The resulting parse tree can be transformed to
a generative description, which can be evaluated to geometry for rendering (e). Parts of the city of Graz were
reconstructed from photographs and range scans using this technique (f).
(a) input model (b) parallel lines (c) acceptable output shape
(d) input model (e) generated variation
Figure 17: The work of Paul Merell and Dinesh Manocha [75] uses a mesh with constraints as input (a).
The input model is analyzed, and a set of identical lines is identified. Parallel translation of these lines yields a
discretization of space (b), from which a new model is synthesized that locally satisfies the constraints of the input
model (c). The bottom row shows an example in 3D, where many complex buildings (e) are generated from four
simple ones (d). The output contains vertices that have been constrained to intersect in four faces, some of them
are circled in red.
C. Schinko, U. Krispel & T. Ullrich, 2015 33
(a) procedural tree model
(b) input model and variations generated from the procedural model
Figure 18: The method of Ondrej Stava et al. [119] utilizes a statistical growth model of trees that is able
to generate a variety of different tree species, as can be seen in the top row (a). The system uses a statistical
optimization method to find the parameters of the model, given an input exemplar. The bottom row shows an
input model and three variations generated from the procedural model using the parameters that resulted from the
optimization process.
to a vertex and remove incompatible states in its neighborhood. The system terminates, if every vertex
has been assigned a state. This process is illustrated in Figure 17.
Inverse procedural modeling of trees The work of Ondrej Stava et al. [119] proposes a method
that estimates the parameters of a stochastic tree model, given polygonal input tree models, such that the
stochastic model produces trees similar to the input. Finding such a set of parameters is a complex task.
The parameters are estimated using Markov Chain Monte Carlo (MCMC) optimization techniques. The
method uses a statistical growth model that consists of 24 geometrical and environmental parameters.
The authors propose a similarity measure between the statistical model and a given input mesh that
consists of three parts: shape distance, which measures the overall shape discrepancy, geometric distance,
which reflects the statistics of geometry of its branches, and structural distance, which encodes the cost
of transforming a graph representation of the statistical tree model into a graph representation of the
input tree model. For some examples see Figure 18.
The MCMC method has also been applied by other methods to find parameters of a statistical
generative model: [124], [145], [154].
Parameter Fitting and Shape Recognition The approach presented by Torsten Ullrich and
Dieter W. Fellner uses generative modeling techniques to describe a class of objects and to identify
objects in real-world data e.g. laser scans [135]. The input data sets of the algorithm are a point cloud
P and a generative model M. Then, the algorithm answers the questions
1. whether the point cloud can be described by the generative model and if so,
2. what are the input parameters x
0
such that M (x
0
) is a good description of P .
The implementation uses a hierarchical optimization routine based on fuzzy geometry and a differentiating
compiler; i.e. the complete generative model description M (x
1
, . . . , x
k
) (including all possibly called
subroutines) is differentiated with respect to the input parameters. This differentiating compiler offers
the possibility to use gradient-based optimization routines in the first place. Without partial derivatives
many numerical optimization routines cannot be used at all or in a limited way.
34 Know the Rules Tutorial on Procedural Modeling
Figure 19: The scanned cup (rendered in semi-transparent gray) have been identified as instances of the gener-
ative cup description.In these cases the cups’ properties (position, orientation, radius, height, handle shape) are
determined successfully.
The example data set shown in Figure 19 consists of laser-scanned cups and a generative cup descrip-
tion. The algorithm is able to detect an instance of the generative cup. In these cases the cups’ properties
(position, orientation, radius, height, handle shape) are determined with only a small error.
C. Schinko, U. Krispel & T. Ullrich, 2015 35
5 Applications
Real-world applications demonstrate the power and versatility of generative modeling techniques.
5.1 Procedural Shape Modeling
First, we demonstrate the effectiveness of procedural shape modeling for mass customization of consumer
products [16]. A generative description composed of a few well-defined procedures can generate a large
variety of shapes. Furthermore, it covers most of the design space defined by an existing collection of
designs in this case wedding rings, see Figure 20. The challenge is whether it is actually possible to
find a suitably general generative description.
Figure 20: The challenge: Samples from the JohannKaiser wedding ring design space. This is the input for
the creation of a generative description, which is both an abstraction and a generalization of the given individual
designs.
Careful analysis of the existing collection of designs reveals that the basic shape of most rings can be
defined using the following parameters:
1. a profile polygon,
2. the angular step size defined by the number of supporting profiles to be placed around the ring’s
center,
3. the radius, and
4. a vertex transformation function.
The idea is to decompose the design variations into a set of transformation functions. Each function
transforms selected in a certain way. Effects can be combined by calling a sequence of different transfor-
mations. Figure 21a shows an example of a profile polygon, copies of which are placed radially around
the origin (Figure 21b). These polygons are first converted to double-sided faces. Then, corresponding
back and front sides are connected (Figure 21c) and a subdivision surface is created (Figure 21d). The
profile polygon, the rotation angle, and a set of custom parameters are the input to this transformation
function (Figure 21f). In a post-processing step selected faces can be colored differently (Figure 21h).
The creation of the basic shape is separated from optional steps to create engravings, change materials,
or add gems. Engravings are implemented as per-vertex displacements (to maintain the option for 3D-
printing) and can be applied on quadrilateral parts of the ring’s mesh using half-edges to specify position
and spatial extend, or projectively by using a parametric cylindrical projection.
Typically noble materials like gold, silver, and platinum are used for wedding rings. Their surfaces
can be treated with various finishing techniques like polishing, brushing, or hammering. In order to
account for these effects, a per-pixel shading model using an approximation of the Fresnel reflection term
36 Know the Rules Tutorial on Procedural Modeling
(a) (b) (c) (d)
(e) (f) (g) (h)
Figure 21: Parametric wedding ring construction: n copies of the the profile polygon (a) are radially placed
around the center (b). Consecutive profiles are connected using a newly-designed operator to form a control
mesh (c) that has a simple toroidal structure. It defines a subdivision surface forming the actual ring shape (d).
Switching the profile transformation function from identity (e) to a selective sine transformation (f) creates a
decorative wave on the surface (g). Using a post-processing step the wave faces can be colored differently (h).
is used to model anisotropic highlights. Additionally, a cube map is deployed to create visually appealing
reflections. Predefined surface finishes can be applied using normal mapping techniques.
The gem model is of the round brilliant cut type. The mathematical model consists of a convex
polyhedron representing the surface of the gem. Only five parameters are needed to define the shape.
Procedural gem instances can be placed by specifying the apex point, an upvector, and a scale factor.
The presented approch is used in a hardware accelerated server-side rendering framework [105], which
has been included in an online system called REx by JohannKaiser. It addresses specialist retailers like
jewelers and wedding ring studios and offers an intuitive web interface for configuring and visualizing
wedding rings (Figure 22). The rendering is done on a dedicated server greatly reducing the hardware
requirements on the client-side. This approach is feasible for a small number of clients offering the
advantage of intellectual property protection, because rendering on the client-side is reduced to displaying
images (renderings coming from the server) and proxy geometry for interaction purposes. The actual 3D
content and its generative description is not transferred to the client.
This work demonstrates the efficiency of procedural shape modeling for the mass customization of
wedding rings. The presented generative description is able to produce a large variety of wedding rings.
Figure 23 shows a few results of the parametric toolkit. The approach is considered to be used for
visualization, information purposes only.
C. Schinko, U. Krispel & T. Ullrich, 2015 37
Figure 22: The REx wedding ring configurator: The user can specify the various parameters of the wedding rings
like profile of the ring, placement and number of diamonds, etc. The interactive 3D rendering gives an immediate
feedback to the user how the choices will influence the final appearance.
Figure 23: The presented generative description is able to produce a large variety of wedding rings. Features like
engravings, recesses, different materials, unusal forms and gems can be created and customized.
38 Know the Rules Tutorial on Procedural Modeling
5.2 Semantic Enrichment
With increasing number of (3D) documents, digital library services become more and more important. A
digital library provides markup, indexing, and retrieval services based on metadata. In the simplest case,
metadata is of the Dublin Core type [55] (title, creator/author, time of creation, etc). This is insufficient
for large databases with a huge number of 3D objects, because of their versatility and rich structure.
Scanned models are used in raw data collections, for documentation archival, virtual reconstruction,
historical data analysis, and for high-quality visualization for dissemination purposes [115]. Navigation
and browsing through the geometric models should be possible not only in 3D, but also on the semantic
level. This requires higher-level semantic information. Semantic questions (“How many windows does
this facade have?”, “How many steps do these stairs have?”, etc.) cannot be answered, if the library
simply treats 3D objects as binary large objects (BLOB). The need for semantic information becomes
immediately clear in the context of electronic data exchange, storage and retrieval [35], [37]. The problem
of 3D semantic enrichment is closely related to the shape description problem [73]:
How to describe a shape and its structure on a higher, more abstract level?
The traditional way of classifying objects, pursued both in mathematics and, in a less formal manner, in
dictionaries, is to define a class of objects by listing their distinctive properties:
cup a small, open container made of china, glass, metal, etc., usually having a handle and
used chiefly as a receptable from which to drink tea, soup, etc.
http://dictionary.reference.com
This approach is hardly realizable because of the fact that definitions cannot be self-contained. They
depend on other definitions (e.g., container, handle, receptable, . . . ), which leads to circular dependencies
that cannot be resolved automatically by strict reasoning, but rely on intuitive understanding at some
point.
An alternative, non-recursive approach for describing shape uses examples. Each entry in a picture
dictionary is illustrated with a photo or a drawing. This approach is widely used, for example in biology
for plant taxonomy. It avoids listing an exhaustive list of required properties for each entry. However,
it requires some notion of similarity, simply because the decision whether object x belongs to class A
or B requires measuring the closeness of x to the exemplars a A resp. b B. This decision can be
reached by a classifier using statistics and machine learning [18], [142]. A good survey on content-based
3D object retrieval is provided by Benjamin Bustos et al. [24]. Statistical approaches clearly have their
strength in discriminating object classes. However, feature-based object detection, e.g., of rectangular
shapes, does not yield object parameters: width and height of a detected rectangle must typically be
computed separately.
To describe a shape and its construction process, its inner structure must be known. Structural
decomposition is well in line with human perception. In general, shapes are recognized and coded mentally
in terms of relevant parts and their spatial configuration or structure [59]. One idea to operationalize this
concept was proposed, among others, by Masaki Hilaga [51], who introduces the Multiresolution Reeb
Graph, to represent the skeletal and topological structure of a 3D shape at various levels of resolution.
Structure recognition is a very active branch in the field of geometry processing. The detection of shape
regularities [96], self-similarities [19] and symmetries [80], [81] is important to understand a 3D shape.
To summarize, structural decomposition proceeds by postulating that a certain type of general regularity
or structure exists in a class of shapes. This approach clearly comes to its limits when very specific
structures are to be detected, i.e., complicated constructions with many parameter interdependencies.
A possibility to describe a shape is realized by the generative modeling paradigm [91], [137]. The
key idea is to encode a shape with a sequence of shape-generating operations, and not just with a list
of low-level geometric primitives. In its practical consequence, every shape needs to be represented
by a program, i.e., encoded in some form of programming language, shape grammar [82], modeling
language [43] or modeling script [8].
The implementation of the “definition by algorithm” approach is based on a scripting language [135]:
Each class of objects is represented by one algorithm M. Furthermore, each described object is a set
C. Schinko, U. Krispel & T. Ullrich, 2015 39
of high-level parameters x, which reproduces the object, if an interpreter evaluates M (x). As this kind
of modeling resembles programming rather than “designing”, it is obvious to use software engineering
techniques such as versioning and annotations. In this way, model M may contain a human-readable
description of the object class it represents.
This encoding of semantic information can be used to enrich 3D objects semantically: the algorithm
starts with a point cloud P and a generative model M. Without user interaction it determines a pa-
rameter set x
0
, which minimizes the geometrical distance between P and M(x
0
). This distance d can be
interpreted as a multidimensional error function of a global optimization problem. Therefore, standard
techniques of function minimization can be used. Having found the global minimum x
0
, the geometric
distance d(P, M(x
0
)) can be interpreted. A low value corresponds to a perfect match; i.e. the point cloud
P is (at least partly) similar to M (x), whereas a high value indicates no similarity. Consequently, the
algorithm is able to semantically recognize instances of generative objects in real data sets.
As the computational complexity of global optimization depends on the dimensions of the error func-
tion, Torsten Ullrich et al. use a hierarchical optimization strategy with coarse model descriptions
and few parameters at the beginning and detailed model descriptions at the end. This multi-step op-
timization determines free parameters successively, fixes them and introduces new parameters. This
process stops, if the end of the hierarchy is reached, or if high error values indicate no object similarity.
In contrast to other related techniques using fitting algorithms, such as “Creating Generative Models
from Range Images” by Ravi Ramamoorthi and James Arvo [100], the approach by Torsten Ullrich
et al. can classify data semantically. Although Ravi Ramamoorthi and James Arvo also use genera-
tive models to fit point clouds, they modify the generative description during the fitting process. As a
consequence the optimization can be performed locally with a computational complexity, which is sig-
nificantly reduced. But starting with the same generative description to fit a spoon as well as a banana
does not allow to generate or preserve semantic data.
An example illustrates this process. The generative model to describe a vase takes 13 parameters:
R(r
x
, r
y
, r
z
) is the base reference point of the vase in 3D and T (t
x
, t
y
, t
z
) is its top-most point. The points
R and T define an axis of rotational symmetry. The remaining seven parameters define the distances
d
0
, . . . , d
6
of equally distributed B´ezier vertices to the axis of rotation (see Figure 24). The resulting 2D
B´ezier curve defines a surface of revolution the generative vase.
In our example, the result of the registration step is a particular generative vase out of a family
of vases. A small selection of vases is shown in Figure 25 to demonstrate the versatility of the shape
template. It is the best generative vase to describe the digitized artifact it has been registered to. Figure
26 illustrates this result. Please note, the registration algorithm can only modify the input parameters
of the generative description. It cannot modify the description itself. As a consequence, features, which
cannot be generated by the script, cannot be included in the generative result.
40 Know the Rules Tutorial on Procedural Modeling
R(r
x
, r
y
, r
z
)
T (t
x
, t
y
, t
z
)
d
0
d
1
d
2
d
3
d
4
d
5
d
6
Figure 24: A digitized artifact is often represented by a list of triangles with additional information such as
textures (to describe the visual appearance) and meta data (to describe its context); e.g. the vase on the left
hand side is a digitized artifact of the “Museum Eggenberg” collection. It consists of 364 774 vertices and 727 898
triangles.
A generative model describes a 3D shape by an algorithm and a set of high-level parameters. This example of a
procedural shape on the right hand side takes two points R and T in 3D and some distance values, which define
the control vertices of a ezier curve. The result is a surface of revolution to describe a vase.
Figure 25: The generative vase is defined by two reference points of an axis of rotation (top and bottom) and
seven distances d
0
, . . . , d
6
, which define a surface of revolution. Changing only the parameters d
0
, . . . , d
6
, keeps
the vases’ height fixed and modifies the outer shape.
Figure 26: The digitized artifact (left) has been registered to a generative description of a vase. The result is
the best-fitting vase of the complete family of vases defined by the generative description i.e. the generative vase
(right; rendered in red) is very similar to the digitized artifact (right; rendered in beige).
C. Schinko, U. Krispel & T. Ullrich, 2015 41
5.3 Form Follows Function
The last application involves design procedures and optimization methods used in inverse modeling as
well as civil engineering techniques namely thermal analysis.
The adjustment of architectural forms to local and specific solar radiation conditions is a fundamental
study. When discussing energy consumption and solar power harness in buildings, important aspects
have to be taken into account, e.g., the relation between a building form and its energy behavior, and the
local weather conditions on an all-year basis. Several studies were published so far, trying to answer these
questions. “Form follows energy” has become an omnipresent dogma in architecture, but its realization is
difficult. The manual analysis of the various relations between form, volume, and energy consumption has
to face many not only numerical problems. Christina R. Lemke points out these difficulties [65].
Already existing, common building forms (64 different shapes in total) are analyzed and discussed.
In “Impact of building shape on thermal performance of office buildings in Kuwait” [4] a simplified
analysis method to estimate the impact of the building shape on energy efficiency of office buildings
is presented. This method is based on results obtained from a comprehensive whole building energy
simulation analysis. The simplified method, presented in the form of a correlation equation, is, according
to the authors, suitable for architects during preliminary design phase in order to assess the impact of
shape on the energy efficiency of office buildings. Although a building’s shape has a significant impact
on the energy costs, and although these maintenance costs surpass the initial costs in several orders of
magnitude, no general guidelines are available for architects on the impact of a building’s shape on its
energy efficiency.
Several studies try to reduce the complex relationship of “Form follows Energy” to a few equations.
Naresh K. Bansal and Amitabh Bhattacharya[10] as well as Ramzi Ourghi et al. [89] derived
simplified analysis methods. Although some simplifications are acceptable for special scenarios, all of them
may introduce a significant, systematic error as discussed by Patrick Depecker et al. [29]. According
to them many parameters are often missing, such as orientation or climate in order to produce reliable
results. The climate aspects are usually simplified to the season with the harshest weather, often forgetting
that temperatures in cities at certain latitudes can drop below thermal comfort limits in winter and that
temperatures in cities at other latitudes often raise above thermal comfort limits in summer [87].
Similar to our example, Veerparkash P. Sethi analyzes five of the most commonly used single
span shapes of greenhouses (even-span, uneven-span, vinery, modified arch and Quonset types) [113].
Hence, in this study an attempt has been made to select the most suitable shape and orientation of a
greenhouse for different climatic zones (latitudes) on the basis of total solar radiation availability and its
subsequent effect on the greenhouse air temperature. From this study important conclusions were taken
regarding greenhouse shapes and their relation to maximum solar radiation extraction by using several
different simulations.
Using generative modeling techniques we perform an optimization within a configuration space of a
complete family of buildings. The numerical optimization routine used in “Generative Modeling and
Numerical Optimization for Energy-Efficient Buildings” [141] has to tackle several problems which occur
in many complex, nonlinear optimization tasks: the choice of initial values and the problem of local min-
ima. Both problems are addressed by a modified differential evolution method. Differential evolution is
a heuristic approach for minimizing nonlinear, non differentiable space functions. It is described in “Dif-
ferential Evolution: A simple and efficient heuristic for global optimization over continuous spaces” [123],
[21]. The differential evolution method for minimizing continuous space functions can also handle discrete
problems by embedding the discrete parameter domain in a continuous domain. It converges quite fast
and is inherently parallel, which allows an execution on a cluster of computers.
The greenhouse to optimize is based on an extruded, quartic ezier curve: the first and the last
control point have distance width, which may vary from 3m to 50m. The second control point is located
directly above the first one at a fixed height of 2m. Symmetrically, the second to last control point is
directly above the last one. The third control point can be chosen freely. It is parameterized by its
absolute height height [4m 75m] and its relative position ratio [0, 1]. Finally, the greenhouse has a
geographical orientation α [0
180
] measured towards northern direction. These parameters define
the upright projection and the vertical section as illustrated in Figure 27.
42 Know the Rules Tutorial on Procedural Modeling
control point height
length (dependent)
width
control point ratio
orientation
Figure 27: This greenhouse is defined by four parameters: its width, a free control point of a ezier curve (with
two free coordinates), and an overall orientation within its environment. This image sketches the construction
process and shows the optimization result at the same time the optimal solution according to energy needs.
The surface area under the defined ezier curve has been calculated analytically. Its symbolic represen-
tation is included as a function in the scripted model in order to determine the greenhouse’s length
a non-free parameter. If the length were a free parameter, the minimization would set it to zero. The
resulting greenhouse would have no volume and no energy need. To exclude such trivial solutions the
volume has to be a constant.
Having scripted the construction process our framework generates a population of parameter vectors
x
1,1
, . . . , x
1,n
, evaluates the script with each parameter and passes the corresponding geometry to Au-
todesk Ecotect
(TM)
, which performs an energy-efficiency analysis. This analysis returns an approximation
for the greenhouse’s annual energy needs the back coupling for a gradient-free optimization method.
The outcome of the numerical optimization process is the best building (within the family of buildings
described by its script) concerning energy-efficiency.
The generative models are scripted in a JavaScript dialect. The geometry is encoded in a simple mesh
structure, which contains additional, semantic information and markup. For example, each polygon is
annotated with
its meaning (floor, roof, wall, window, etc.),
its material (a reference name of the material data base of Autodesk Ecotect
(TM)
: concrete, glass,
etc.), and
its hierarchy level (e.g. each window references its surrounding wall).
Furthermore, the generative model contains global meta data about energy respectively heat sources;
especially
its location (a geographically referenced climate data file in WEA format according to Drury B.
Crawley [28]) in order to include solar energy effects and the building’s environment as well as
occupancy and activity data to include waste heat into the energy efficiency calculation.
Each trial vector of a new generation x
?
k+1,i
has to be </