mirror of
https://github.com/hannobraun/Fornjot
synced 2025-07-22 18:06:05 +00:00
Add CurveGeom2
This commit is contained in:
parent
7891a69895
commit
b6146dfd16
@ -47,6 +47,34 @@ pub struct LocalCurveGeom {
|
|||||||
pub path: Path<2>,
|
pub path: Path<2>,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// # The geometric definition of a curve
|
||||||
|
///
|
||||||
|
/// Curves are represented by polylines, their uniform intermediate
|
||||||
|
/// representation. However, this representation can be 2D (local to a surface)
|
||||||
|
/// or 3D. This enum distinguishes between the two cases.
|
||||||
|
///
|
||||||
|
/// ## Implementation Note
|
||||||
|
///
|
||||||
|
/// The name, `CurveGeom2`, is a placeholder. As of this writing, there is an
|
||||||
|
/// ongoing transition to a new geometry system, and the name `CurveGeom` is
|
||||||
|
/// still taken by an old-style type.
|
||||||
|
pub enum CurveGeom2 {
|
||||||
|
/// # The curve is defined locally on a surface
|
||||||
|
Surface {
|
||||||
|
/// # The geometric representation of the curve
|
||||||
|
geometry: Box<dyn GenPolyline<2>>,
|
||||||
|
|
||||||
|
/// # The surface that the curve geometry is defined on
|
||||||
|
surface: Handle<Surface>,
|
||||||
|
},
|
||||||
|
|
||||||
|
/// # The curve is defined globally in 3D space
|
||||||
|
Global {
|
||||||
|
/// # The geometric representation of the curve
|
||||||
|
geometry: Box<dyn GenPolyline<3>>,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
/// # Generate polylines, the uniform representation of curve geometry
|
/// # Generate polylines, the uniform representation of curve geometry
|
||||||
///
|
///
|
||||||
/// This trait provides a generic and uniform interface to curve geometry. It is
|
/// This trait provides a generic and uniform interface to curve geometry. It is
|
||||||
|
@ -10,7 +10,7 @@ mod vertex;
|
|||||||
|
|
||||||
pub use self::{
|
pub use self::{
|
||||||
boundary::{CurveBoundary, CurveBoundaryElement},
|
boundary::{CurveBoundary, CurveBoundaryElement},
|
||||||
curve::{CurveGeom, GenPolyline, LocalCurveGeom},
|
curve::{CurveGeom, CurveGeom2, GenPolyline, LocalCurveGeom},
|
||||||
geometry::Geometry,
|
geometry::Geometry,
|
||||||
path::Path,
|
path::Path,
|
||||||
surface::SurfaceGeom,
|
surface::SurfaceGeom,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user