Skip to main content

Crate brep_reconstruction

Crate brep_reconstruction 

Source
Expand description

Integration boundary between neutral recognition and BREP topology.

Modules§

brep
Optional interoperability with the public brep_kernel API.
step_validation
STEP face-level validation against exact analytic carriers imported by brep_kernel.
stl
Binary and ASCII STL import with deterministic vertex welding.
stl_conversion
STL-mesh to STEP conversion orchestration.

Structs§

AnalyzedMesh
A validated mesh with cached geometry, topology, and sampling weights.
ConeSurface
One nappe of a right circular cone.
ConstraintMask
Parameter-level constraints. Vector fields constrain all three components; axis origins/centers still use the conventional along-axis gauge freedom.
CylinderSurface
An infinite circular cylinder.
DebugObjExport
In-memory Wavefront OBJ geometry and its companion material library.
FitDiagnostics
Provenance and execution details for a fitted surface.
FitMetrics
Residual and support measurements for a fitted surface.
GeometricError
Residual-only snapshot used to compare a supplied/initialized carrier with the final refined carrier without duplicating support bookkeeping.
Mesh
An indexed triangle mesh and optional recognition metadata.
MeshAnalysisOptions
Controls mesh validation and feature-edge classification.
PhaseTimings
Optional wall-clock phase measurements. Timing is disabled by default so deterministic results remain bit-for-bit comparable.
PlaneSurface
A plane represented by a point and unit normal.
RecognitionOptions
Controls surface recognition, refinement, and region discovery.
RecognitionResult
All recognized regions and triangles left unresolved by discovery.
SourceMetadata
Versioned sidecar metadata. Stable source IDs are deliberately distinct from sequential tessellation face indices.
SphereSurface
A sphere represented by its center and radius.
SurfaceConstraints
Initial surface parameters and the subset held fixed during fitting.
SurfaceFitResult
The fitted carrier and quality information for one requested selection.
SurfaceParameterDelta
Gauge-aware change from an initial/supplied carrier to its final carrier. Fields that do not apply to a primitive remain None.
SurfaceRegion
A recognized surface and the mesh triangles assigned to it.
TorusSurface
A circular torus represented by its center, axis, and radii.
TriangleData
Geometry and topology derived for one input triangle.
UnresolvedRegionDiagnostic
Why a metadata-associated triangle subset remained unresolved after both metadata-guided reconstruction and generic analytic fallback failed.
Vec3
A three-dimensional vector with double-precision components.

Enums§

AnalyticSurface
Parameters for one supported analytic surface.
DesignIntentError
Failure to express a requested design-intent relation with the current parameter-group constraint model.
FitPath
The recognition or refinement route that produced a fit.
MetadataTrust
Describes how strongly imported metadata should influence fitting.
RecognitionError
An error produced while validating geometry or recognizing a surface.
SamplingMode
Selects which geometric samples are used during fitting.
SurfaceHint
Optional source knowledge used to guide surface recognition.
SurfaceType
The supported analytic primitive families.

Functions§

constrain_concentric_centers
Fix sphere or torus centers to an existing sphere/torus center.
constrain_cylinder_coaxial
Constrain a cylinder to the complete axis line of another axial carrier. This is safe because a cylinder’s axis origin has gauge freedom along the line; cone apex and torus center locations do not, so those target types are intentionally unsupported here.
constrain_equal_radii
Fix equal radius groups for two carriers of the same type. For tori this copies and fixes both major and minor radii; mixed-type radius semantics are deliberately rejected.
constrain_plane_perpendicular_to_axis
Constrain a plane to be perpendicular to a known axis. The plane normal is the axis direction; its offset remains free.
constrain_planes_coplanar
Fix a plane to the same infinite carrier as a reference plane. Tangential origin coordinates are a gauge and are preserved from the target.
constrain_planes_parallel
Preserve parallelism to a reference plane while leaving plane offset free.
constrain_planes_perpendicular
Preserve perpendicularity to a reference plane using the target’s current normal to select the otherwise non-unique perpendicular direction.
constrain_shared_axis
Fix a target cylinder, cone, or torus axis direction to an existing axial carrier. Cone-to-nondirected-carrier transfer is rejected because a cone’s nappe direction is not sign-equivalent.
constrain_tangent
Derive exact sphere/plane tangency from the target’s current side and orientation. Other tangency pairs require coupled parameters and are rejected explicitly.
export_debug_obj
Export an input mesh and recognition result as Wavefront OBJ/MTL text.
recognize_surfaces
Discover and reconstruct analytic regions in an entire mesh.
recognize_surfaces_with_unresolved
Discover analytic regions and retain triangles that no model accepted.
reconstruct_surface
Reconstruct one selected triangle region using an explicit metadata hint.
reconstruct_surface_from_vertices
Reconstruct one surface from an explicit subset of mesh vertices.