|
|
|
FGK |
Functionalities | Faceted Boolean |
|
 |
Boolean Basics:
 |
Target and
tool The operands of a boolean are called the target and the
tool. The target of a boolean is the body you begin with,
and the tool is the body you operate on it with. The target
is modified by the tool, and the tool is deleted at the end
of the operation. Faceted Boolean preserves the tags of
entities in the target as far as possible. Following figure
illustrate target, tool and possible Boolean output: |
The following diagram shows the
effect of swapping the target and tool of subtract:
Example of faceted boolean is
shown in below figures:
 |
 |
|
Cube +
Cylinder Union |
Cube -
Cylinder Subtraction |
 |
 |
|
Cube
Cylinder Intersection |
Cylinder
Remain |
Similarly faceted boolean can
also perform general body boolean i.e. non-manifold boolean as
shown in figures:
 |
|
|
Shared Edge |
Shared Face |
 |
Type of boolean
There are two types of booleans mostly used in CAD modeling:
 |
Global Booleans Global booleans perform boolean operations on whole bodies,
taking a single target body, and multiple tool bodies, and
applying the specified boolean operation to the target.
Because the operation is performed at the body level (by
comparing all pairs of faces in the target and tool), the
resulting body is guaranteed to be topologically consistent.
Global booleans, because of the nature of the face pair
comparison, can be computationally expensive. |
 |
Local Booleans Local booleans (sometimes known as partial booleans), tend
to be very quick to perform compared to global booleans.
Rather than working at the body level, local booleans use a
set of faces from a target body, and a set of faces from a
single tool body. User specifies these faces himself, and
only the faces user specify are used in the boolean
operation. Restricting the scope of the boolean operation in
this way can drastically improve performance. |
 |
Sheet Booleans
Faceted Boolean provides functionality to perform sheet
boolean. API used would be same as above only input
parameters are changed. If booleans in subtract operation
target is solid and tool is sheet then one can perform
trimming operation whereas target is sheet and tool is solid
produces punching operation.
Trimming operation are in particular highly useful in
trimming unwanted features or removing cusp during CAD
Repair.
|
|
|
 |
Boolean
Algorithm
A boolean may be a union, subtraction or intersection. The
type of boolean performed can be selected by setting the
'function' field in the option structure. If no function
code is supplied, the default action is union. Faceted
Booleans may be thought of as being performed in four main
phases. These are intersection, imprinting, gluing, and
selection.
 |
Intersection and
Imprinting
First step of a boolean operation is to intersect the target
and tool entities and imprint edges and vertices on them
where they intersect. These imprinted edges and vertices
form the boundaries of intersection between target and tool
entities. These edges divide the faces of each body into
face sets which are either inside, outside, or on the
boundary of, the other bodies. |
 |
Gluing and Selection
The resulting sets of faces are glued together into a single
intermediate body. The parts of the model which are to be
kept or rejected are selected, according to the type of
boolean being performed and the options supplied, using
information gained in the earlier phases. |
|
 |
Options for
Faceted Boolean
To modify and control the behaviour of Faceted Boolean an
options structure will be passed main function. The
following table summarizes the options available for global
and sheet booleans:
|
|
Option |
Description
|
|
function
|
The boolean operation to be
performed: union, subtraction or intersection.
|
|
allow_disjoint |
Whether to return a single
disjoint body if the operation would result in more
than one body. |
|
fence
|
Modify the behavior of the
subtract operation and determine which resultant
bodies are returned when performing solid/ sheet
(trimming) or sheet/solid (punching) boolean
operations. |
|
configuration
|
A sub-structure that describes
the configuration of the target and tool bodies.
(For optimizing boolean operations) |
|
matched_region |
A sub-structure that describes
regions in the target and tool bodies that should be
matched.
When performing boolean
operations in which there is a nearly coincident
region between the target and tool bodies, user can
specify that certain topological regions are matched
when performing boolean functions. Doing this can
produce better results, and make the boolean
operation faster. A matched region is a region of
overlap between two topological entities that are
geometrically coincident to a specified tolerance.
The entities in the matched region must be in the
target or tools of the boolean operation. The
following combinations of topological entities may
be provided as matched regions :
-
Vertex - Vertex
-
Edge - Edge
-
Face - Edge
-
Face - Face
|
|
check_fa |
Whether to check faces involved
in the boolean operation - only faces which are
adjacent to imprinted edges are checked.
If the face checking is switched
off, the boolean operation may produce an invalid
body without raising an error. However, in some
cases, if face checking is switched on the
performance of the boolean operation may be reduced. |
|
default_tol |
The default tolerance to which
the boolean operation, if it has to, may approximate
entities or assume that entities are coincident.
This value should be set to a
value that is related to the tolerance to which the
application is creating approximations.
If this field is set to zero
(0.0), it is assumed that the decision to set
tolerances on entities is being left to the code. |
|
max_tol |
The maximum tolerance which may
be applied to any entity involved in the boolean
operation. |
|
tracking |
Request additional topological
data on the result of the boolean, this is specific to the function being
called. Within this function this option can be used
to return additional tracking data when using a
single, non-disjoint tool body. |
|
nm_edge_repair |
Whether to attempt to repair
certain configurations of non-manifold results. |
 |
Optimizing local and
global boolean operations If the boolean operation involves instancing, i.e. a boolean
operation which takes a single target body and a list of
tool bodies, e.g. when drilling an array of holes in a body,
the performance of the operation can be improved by using
one of the following instancing options in the configuration
option sub-structure:
|
Option
|
Description
|
|
no_tool_intersect
|
This
option can be set when the set of tool bodies are known
not to intersect each other, though they are allowed to
clash with existing edges on the target (including the
periphery edge). |
|
no_loop_intersect
|
This
option can be set when there is no interference between
any instances and the existing edges of the target,
though the tools can clash with each other |
|
 |
Boolean Examples Following centrifugal pump assembly is
processed in FGK based application to perform global
boolean. Void space is filled and non-manfolid boolean
part is created as output.
|
|
|
|
|
|