Skip to main content

Crate brep_offset

Crate brep_offset 

Source
Expand description

Solid offsets, shells and thickening of the BREP kernel.

It is one of the implementation crates the kernel is built from. Applications should depend on BREP_kernel, which re-exports the public API of every kernel crate at its root (brep_kernel::…) and adds the feature pipeline and the STEP, IGES, Parasolid (import), 3MF, GLB, STL and OBJ exchange. Many items here are public only so the other kernel crates can reach them; those are hidden from the documentation and carry no stability promise beyond the kernel’s own. The kernel crates are released together, at one version.

It contains:

  • shelling and offset shells, sharp and rounded;
  • thickening of sheets and faces, and sheets extruded from curves.

Kernel crates it requires: BREP_RANSAC, BREP_geometry, BREP_topology, BREP_surface_offset, BREP_boolean, BREP_construction, BREP_blend. It is required by BREP_direct_edit, BREP_kernel.

§Building

The crate builds natively and for wasm32-unknown-unknown. The parallel feature runs some per-face loops on rayon; profile-wall turns on a diagnostic wall-time partition. Both are off by default, and BREP_kernel forwards them.

The packaged crate ships the library sources, the README, the licence and the manifest; it carries no test suite.

§License

The Autodrop3d licence in LICENSE.md, shipped in the crate (license-file in the manifest). Source: https://github.com/mmiscool/next.BREP.io_RUST_BREP_KERNEL

Re-exports§

pub use brep_geometry::*;
pub use brep_topology::*;
pub use brep_surface_offset::*;
pub use brep_boolean::*;
pub use brep_construction::*;
pub use brep_blend::*;

Structs§

OffsetShellFaceImageRecord
OffsetShellResultRecord
ShellOptions
How offset_shell_with_options answers what offset_shell decides by convention. The default is offset_shell’s answer throughout.

Enums§

OffsetCorners
How the offset body closes the joins between offset faces.
OffsetFaceRole

Constants§

SHELL_ROUNDED_REFUSAL
The prefix of every refusal of this operation.
THICKEN_FACES_REFUSAL
The prefix of every refusal of this operation.

Functions§

extrude_curves_to_sheet
The sheet a chain of curves sweeps as it slides by distance along direction: one face per curve (the curve times the slide), each a sheet of its own, in the chain’s order. Every face’s normal is its curve’s direction crossed with the slide’s, so the faces of a chain run head to tail have their normals on one side of the sheet, as thicken_sheet_faces needs them; run the chain the other way for the other side.
is_offset_shell_no_retained_face
Whether refusal is the shell’s “every face was selected” refusal: the class and slug, never the text.
is_offset_shell_open_curved_rim
Whether refusal is an open curved rim the shell could not close: the assembly’s NonIntegralGenus (typed at finalize_assembled_solid, carried through every cause put in front of it) or the unwelded curved rim. The class, never the text; a genus sentence quoted under another class is not this refusal.
offset_shell
offset_shell_by_boolean
The textbook shell: the offset body with the opening faces HELD (copied at distance zero, so they cancel in the difference), then source − body for an inward shell and body − source for an outward one. The walls at the openings come out of the boolean. distance carries offset_shell’s sign (positive inward).
offset_shell_closed
Lane O row 34: the CLOSED hollow, a shell with no openings. The offset body, the whole source grown or shrunk with sharp joins, against the source: source − body inward and body − source outward, so the result is the outer shell and the inner void’s shell, with the walls of the band between them. distance carries offset_shell’s sign (positive inward). face_images are read back from the operands by surface as in offset_shell_by_boolean: Offset for the body’s faces, Source for the source’s.
offset_shell_rounded
source shelled to a wall distance thick, joined by arcs, open at the flat faces opening_face_ids. The sign is crate::offset_shell’s: a positive distance puts the wall inside the solid, a negative one outside.
offset_shell_with_diagnostics
Run offset shell with stable counters and validation diagnostics suitable for automated regressions and UI presentation.
offset_shell_with_options
offset_shell read with options.
offset_solid
Offset every face of source by distance (positive grows) and join the offset faces into a closed body.
thicken_face_sheet
§5.9 THICKEN a sheet (an open surface patch over its full parameter domain) into a closed solid.
thicken_sheet_faces
The sheet faces thickened by thickness along the faces’ normals (negative: against them), its open creases closed as corners says.
thicken_trimmed_sheet
§5.9 THICKEN a TRIMMED sheet region into a closed solid.