Share

Boolean operations

Methods

Name Syntax Description
bool Result = mesh:bool(othermesh:TLUAMesh; operationtype:integer) Bools the current mesh with a another. Operationtype 0 adds the mesh, 1 subtracts it.
insertselfintersections mesh:insertselfintersections(epsilon:number) Replaces a mesh with itself but split along its self-intersections.
intersect mesh:intersect() Replaces a mesh with the Boolean intersection of its shells
unify mesh:unify(epsilon:number) Replaces a mesh with the Boolean unification of its shells. Tip: To subtract a shell, invert it before unifying. epsilon is mandatory for legacy reasons, but its actual value is ignored internally. It used to be a tolerance.
wrap mesh:wrap() Replaces a mesh with the wrap of its shells: Discards any internal surfaces, fully enclosed or created by self-intersections alike. Uses a parallel multicore algorithm.
wrapsinglecore mesh:wrapsinglecore() Replaces a mesh with the wrap of its shells. Uses the old singlecore algorithm.

Back to top

Examples

Name Example Return value
unify found_self_intersections = mesh:unify(0.05) Boolean: Returns true if any self-intersections were found (or whether they were disregarded due to the epsilon value). With very intricate meshes, this function may create many small shells which should be trimmed using "removeghostshells"
intersect found_self_intersections = mesh:intersect() Boolean: See unify
insertselfintersections found_self_intersections = mesh:insertselfintersections(0.05) Boolean: Returns true if any self-intersections were found (or if they were disregarded due to the epsilon value). Attention: This function may create a lot of shells, but it can orient not-orientable surfaces.
wrap mesh:wrap() -

Back to top

Was this information helpful?