108 3D: Schlegel diagrams and polyhedral nets🔗ℹ
3D reference map · First 3D picture
Prepared
Schlegel-projection data. The diagnostics retain the deterministic outer face,
canonical target-plane basis, margin, and viewpoint distance.
Projects a selected simple outer face into a
canonical plane. It rejects projections whose inner vertices do not lie in the
outer polygon instead of returning a misleading diagram.
Builds the flat 3D edge visual from prepared data.
A positive-area pairwise overlap in root-plane
coordinates. Sharing only a hinge boundary has zero area and therefore does not
produce this record.
One
oriented parent-to-child hinge in a face-adjacency spanning tree.
An orientation-preserving rigid
frame from a source face to the net’s root plane.
Prepared
net data. diagnostics records strategy, search completion, selected
tree edges, overlap total, boundary crossings, and flat-net diameter.
Prepares a rigid flat net. Explicit
hinges
must form a connected spanning tree. The automatic breadth/depth policies use
source edge order.
'minimum-overlap enumerates candidate trees in that
order and minimizes total positive overlap area, then boundary crossings and
flat-net diameter. When its bounded search is truncated,
(hash-ref (polyhedron-net3d-diagnostics result) 'search-complete?) is
false and no optimality claim is made.
Returns one stable direct-child symbol per polygonal face, in face-index order.
An explicit polygonal face identity is retained, so face 'front is a
child at '(net front); generated faces use deterministic
'face-N identities.
Creates the canonical group of independent mesh children
for a prepared net.
materials, when present, has one
material3d
per face and is useful for making a net’s face boundaries visually legible.
Returns the source-to-sampled local transform for every
canonical face child. Interior samples recursively rotate each child around its
source hinge and inherit its parent’s current rigid map; the root stays fixed.
The endpoints use exact identity and prepared-flat transforms.
Returns a
scene-play request that unfolds the direct
face children below
target.
Returns the inverse request. It requires the exact flattened
endpoint produced by
unfold-polyhedron3d, and returns the exact source
transforms.
The canonical runnable demonstration is
"examples/3d/fold-unfold-polyhedron.rkt".
Limitations. Net faces must be simple polygonal faces. The overlap
kernel handles simple concave polygons by deterministic ear triangulation, but
does not repair self-intersection or hole boundaries. Fold/unfold presently
requires the independent, identity-local-transform face meshes made by
polyhedron-net3d-group; it does not yet retarget arbitrary authored
mesh trees, animate labels/strokes with their faces, sequence hinges to avoid
intermediate collisions, or solve a global collision-free folding path.