Expand description
Boolean operations on two solids, built on top of remesh.
The algorithm is deliberately simple, and it is simple because remesh has already done the hard part. After remeshing, every face of either solid lies wholly inside the other, wholly outside it, or exactly on its boundary — no face straddles, because every intersection curve has been imprinted and every face it crossed has been split. That turns a boolean into a per-face classification followed by a keep/drop table.
remeshthe two solids against each other.- Classify each face with
classify_face, by taking a point strictly inside its trimmed region and asking where it sits relative to the other solid. - Keep the faces the operator wants (see
BooleanOp::keeps), reversing them where the operator needs the material on the other side. - Assemble the survivors into a new solid and discard everything else.
Enums§
- Boolean
Op - Which boolean to perform.
- Face
Classification - Where one solid’s face sits relative to the other solid.
Functions§
- boolean
solid_acombined withsolid_bunderop, as a new solid inmodel.- classify_
face - Where
face_idsits relative toother_solid, decided at a single point strictly inside the face’s trimmed region.