Skip to main content

ogeom_geom/
lib.rs

1//! Parametric geometry: the `Curve3d`, `Curve2d` and `Surface` traits plus every
2//! concrete type behind them.
3//!
4//! *Elsewhere:* the `Geom` and `Geom2d` type vocabularies and the `Adaptor`
5//! family.
6//!
7//! The trait layer is the point, and it is the best idea in the conventional
8//! design: every intersection, projection and extrema algorithm is written against
9//! an *adaptor*, so nothing downstream cares whether the input is an analytic
10//! cylinder or a NURBS patch. Concrete types implement the traits; algorithms only
11//! ever see the traits.
12
13pub mod convert;
14pub mod curve;
15pub mod curve2d;
16pub mod fit;
17pub mod surface;
18pub mod traits;
19
20pub use curve::{
21    BSplineCurve, CircleCurve, Curve, CurveOnSurface, EllipseCurve, HelixCurve, HyperbolaCurve,
22    LineCurve, OffsetCurve, ParabolaCurve, TrimmedCurve,
23};
24pub use curve2d::{
25    BSpline2d, Circle2d, Ellipse2d, Line2d, Offset2d, PlanarCurve, Trig2d, Trimmed2d, tangent_angle,
26};
27pub use surface::{
28    BSplineSurface, ConeSurface, CylinderSurface, ExtrusionSurface, OffsetSurface, PlaneSurface,
29    RevolutionSurface, SphereSurface, SurfaceGeometry, TorusSurface, TrimmedSurface,
30};
31pub use traits::{
32    Continuity, Curve2d, Curve3d, CurveKind, Reversible, Surface, SurfaceCurvature, SurfaceJet,
33    SurfaceKind, Transformable,
34};