Professional Documents
Culture Documents
2
Topics covered
• What is CSG
• Operations
• Applications of CSG
3
What is CSG
• Constructive solid geometry (CSG) is a technique
used in solid modeling.
• CSG is often, but not always, a procedural
modeling technique used in 3D computer graphics
and CAD.
• Constructive solid geometry allows a modeler to
create a complex surface or object by using
Boolean operators to combine objects.
• Often CSG presents a model or surface that
appears visually complex, but is actually little
more than cleverly combined or decombined
objects.
4
What is CSG
• The simplest solid objects used for the
representation are called primitives.
• The primitives: cuboids, cylinders, prisms,
pyramids, spheres, cones & torus.
• The set of allowable primitives is limited by
each software package.
• Some software packages allow CSG on
curved objects while other packages do not.
5
Operations
• In modeling packages, basic geometric
objects such as the cube or 'box', sphere or
ellipse, torus, and a number of other shapes
that can be described using a mathematical
formula, are commonly known as primitives.
• These objects can typically be described by
a procedure which accepts some number of
parameters; for example, a sphere may be
described by the coordinates of its center
point, along with a radius value
Operations
• Boolean union () - merger of two or more
objects into one
• Boolean difference (-) - subtraction of one
object from another
• Boolean intersect () - overlapping portion
of objects
Operations
• The following example illustrates the three
CSG operations in use on simple three
dimensional primitives.
• The two primitives: a sphere and a box.
Operations - Union
• The union of the two primitives.
Operations - Intersection
• The intersection of the two primitives.
Operations - Difference
• The difference of the two primitives: box
minus sphere.
CSG - Modeling Technique
• The following example shows an object for which
CSG is (probably) the only sensible modeling
technique. The object rendered in the right-hand
image is constructed from the primitives shown
in the left-hand image.
Applications
• Constructive solid geometry has a number of
practical uses. It is used in cases where simple
geometric objects are desired, or where
mathematical accuracy is important.
• The Unreal engine uses this system, as do
Hammer (the mapping engine for the Source
engine) and Quake. (Hammer actually started out
as Worldcraft, which was an editor for Quake.)
• BRL-CAD is a solid modeling CAD package that is
fundamentally based on CSG modeling techniques.
CSG is popular because a modeler can use a set of
relatively simple objects to create very complicated
geometry.
Example of CSG 1