Skip to main content

Crate manifold3d

Crate manifold3d 

Source
Expand description

Safe Rust bindings to manifold3d — a geometry kernel for constructive solid geometry (CSG).

This crate is a thin re-export of manifold-csg. The two crates provide the same API under different names — use whichever one you prefer.

If you are migrating from manifold3d 0.0.x (the original crate by @NickUfer, now transferred to this project), see the migration guide. The API has changed significantly between 0.0.x and 0.1+.

Modules§

bounding_box
3D axis-aligned bounding box wrapping ManifoldBox.
cross_section
Safe wrapper around a manifold3d CrossSection object (2D region).
execution
Cooperative cancellation + progress observation for long-running boolean evaluations.
manifold
Safe wrapper around a manifold3d Manifold object (3D solid).
mesh
Safe wrappers for manifold3d mesh data types.
ray
Ray casting against manifold solids.
rect
2D axis-aligned bounding rectangle wrapping ManifoldRect.
samples
Sample CSG constructions ported from manifold3d’s samples/ C++ sources.
triangulation
Constrained Delaunay triangulation of 2D polygons.
types
Common types and error definitions.

Structs§

BoundingBox
A 3D axis-aligned bounding box.
CrossSection
A safe wrapper around a manifold3d CrossSection object.
ExecutionContext
Observes progress and allows cooperative cancellation of long-running boolean evaluations. See the module docs for usage.
Manifold
A safe wrapper around a manifold3d Manifold object.
MeshGL
Safe wrapper around a manifold3d MeshGL object (f32 vertices, u32 indices).
MeshGL64
Safe wrapper around a manifold3d MeshGL64 object (f64 vertices, u64 indices).
MeshGL64Options
Optional metadata for constructing a MeshGL64.
MeshGLOptions
Optional metadata for constructing a MeshGL.
RayHit
Result of a single ray-manifold intersection.
Rect
A 2D axis-aligned bounding rectangle.
Rect2
2D axis-aligned bounding rectangle (legacy convenience type).

Enums§

CsgError
Errors from manifold3d operations.
FillRule
Fill rule for constructing cross-sections from polygons.
JoinType
Join type for CrossSection::offset.
OpType
Boolean operation type for generic manifold and cross-section booleans.

Functions§

get_circular_segments
Get the number of circular segments for a given radius.
reserve_ids
Reserve a block of n original IDs for use with manifold tracking.
reset_to_circular_defaults
Reset circular tessellation parameters to defaults.
set_circular_segments
Set the number of circular segments for tessellation.
set_min_circular_angle
Set the minimum circular angle (degrees) for tessellation.
set_min_circular_edge_length
Set the minimum circular edge length for tessellation.
triangulate_polygons
Triangulate a set of 2D polygon rings using manifold3d’s constrained Delaunay triangulator.