Expand description
Sub-object (face/edge) topology for direct modeling.
CSG trees have no persistent face/edge identity: meshes are regenerated
wholesale and carry no provenance. This module derives that identity
analytically from the tree itself — faces are named per-primitive
(FaceTag), leaves are addressed by structural LeafPaths, and
geom evaluates rays/membership against the tree exactly, independent
of the active render backend (mesh or SDF ray-march).
Modules§
- edge
- Analytic edge resolution: turn a pair of leaf faces into a verified edge curve on the final solid, or a typed rejection.
- geom
- Analytic ray/membership evaluation of a
DynamicObjecttree. - lower
- Lower an
EdgeFeatureDatainto pure-CSG masks against its child.
Structs§
- Circular
Edge - A verified full-circle edge (rim), in
framecoordinates. - CsgLeaves
- Flattened analytic model of one tree: primitive leaves + boolean structure.
- Edge
Feature Data - Payload of an
EdgeFeaturenode: which edges to feature and how. Edges are re-resolved against the current child geometry every evaluation, so the feature follows parameter edits; unresolvable edges are skipped. - EdgeSel
- An edge, identified as the intersection curve of two faces. Stored in canonical (sorted) order so the same edge always compares equal.
- FaceRef
- A face of a specific leaf, addressed structurally (survives node-id churn and scene save/load).
- Geom
Leaf - A primitive leaf with its accumulated world transform.
- HitBoundary
- One surface crossing along a ray.
- HitSpan
- A solid stretch of the ray:
enter.t < exit.t. - Leaf
Path - Structural address of a leaf inside a subtree, independent of node ids.
- Lower
Report - What a lowering pass did — callers log/report the skip count.
- Lowered
Masks - Masks for one lowering pass, in the child’s frame:
subcuts material (chamfers, convex fillets),addfills it in (concave ring fillets). - Straight
Edge - A verified straight edge on the final solid, in the evaluation frame.
Enums§
- Convexity
- Whether material bends away from (convex) or wraps around (concave) an edge, on the final solid.
- CsgExpr
- Boolean structure over leaf indices into
CsgLeaves::leaves. - Edge
Feature Kind - Which feature an
EdgeFeaturenode applies to its edges. - Edge
Geom - Resolved edge geometry, in the evaluation frame.
- Edge
Reject - Why an edge candidate did not resolve. Frontends surface
messageverbatim. - FaceTag
- A face of a supported primitive, named in the primitive’s local frame.
- Leaf
Prim - A supported primitive in its local frame.
Functions§
- csg_
aabb - Evaluation-frame AABB over every leaf (probe scaling).
- leaf_
face_ tags - Face tags a leaf primitive exposes (candidate enumeration).
- leaf_
flipped - Per-leaf orientation:
truewhen the leaf sits under an odd number ofDifferencesubtrahend positions, so its surfaces bound the final solid with inverted normals (hole walls). - lower
- Lower
dataagainstchild: subtract the cut masks, union the fill masks, or pass the child through unchanged when nothing resolves. - lower_
masks - The masks for
dataagainstchild, in the child’s frame. Unresolvable/unsupported edges are skipped and counted. - resolve_
edge - Resolve the edge where faces
(leaf_a, face_a)and(leaf_b, face_b)meet on the final solid. See the module docs for what resolves and why things reject.
Type Aliases§
- Aabb
Hint - Callback supplying a conservative local-space AABB for a subtree this
module cannot evaluate analytically (sketch/extrude/revolve/offset based).
Returning
Nonedrops the subtree from the model (it stops occluding).