Constructor GeoPolylineArc3
- Namespace
- GeometryHelper.Geometry
- Assembly
- GeometryHelper.dll
GeoPolylineArc3(IEnumerable<GeoPoint3>)
Initializes a chain of straight pieces.
public GeoPolylineArc3(IEnumerable<GeoPoint3> vertices)
Parameters
verticesIEnumerable<GeoPoint3>The vertices, in order; at least two, and no two neighbours in the same place.
Exceptions
- ArgumentNullException
Thrown when the vertices are null.
- ArgumentException
Thrown when fewer than two distinct vertices are given.
GeoPolylineArc3(IEnumerable<GeoPoint3>, IEnumerable<double>, IEnumerable<GeoVector3>)
Initializes a chain whose pieces may be arcs.
public GeoPolylineArc3(IEnumerable<GeoPoint3> vertices, IEnumerable<double> bulges, IEnumerable<GeoVector3> normals)
Parameters
verticesIEnumerable<GeoPoint3>The vertices, in order; at least two, and no two neighbours in the same place.
bulgesIEnumerable<double>The bulge of the edge leaving each vertex; null or short means the rest are straight, and anything past the last edge is ignored.
normalsIEnumerable<GeoVector3>The plane each bulge is read about, laid out the way the bulges are; only wanted where a bulge is not nought.
Exceptions
- ArgumentNullException
Thrown when the vertices are null.
- ArgumentException
Thrown when fewer than two distinct vertices are given, or when a bulge that is not nought comes with no usable plane.
GeoPolylineArc3(IEnumerable<GeoPoint3>, IEnumerable<double>, IEnumerable<GeoVector3>, Tolerance)
Initializes a chain whose pieces may be arcs, within a tolerance.
public GeoPolylineArc3(IEnumerable<GeoPoint3> vertices, IEnumerable<double> bulges, IEnumerable<GeoVector3> normals, Tolerance tolerance)
Parameters
verticesIEnumerable<GeoPoint3>The vertices, in order; at least two, and no two neighbours in the same place.
bulgesIEnumerable<double>The bulge of the edge leaving each vertex; null or short means the rest are straight.
normalsIEnumerable<GeoVector3>The plane each bulge is read about; only wanted where a bulge is not nought.
toleranceToleranceThe tolerance, which decides when two vertices are in the same place and how square to its chord a normal must be.
Remarks
A vertex within the point tolerance of the one kept before it is dropped, and so is the edge between the two, which has no length; the edge running on from the dropped vertex keeps its own bulge and normal. The chain (0, 0, 0), (10, 0, 0), (10.0004, 0, 0), (20, 0, 0) with bulges 0, 0, 1 about Z is the straight edge to (10, 0, 0) and then the half circle of bulge 1 from there to (20, 0, 0).
Exceptions
- ArgumentException
Thrown when a bulge is not a finite number, or a vertex at either end of an edge that bulges is not a finite point.
GeoPolylineArc3(IEnumerable<GeoEdge3>)
Initializes a chain from edges that run end to end.
public GeoPolylineArc3(IEnumerable<GeoEdge3> edges)
Parameters
edgesIEnumerable<GeoEdge3>The edges, each starting where the one before it ended.
Exceptions
- ArgumentNullException
Thrown when the edges are null.
- ArgumentException
Thrown when no edges are given, or one does not start where the one before it ended.
GeoPolylineArc3(GeoPolyline3)
Initializes a chain from a straight one, with no bulges.
public GeoPolylineArc3(GeoPolyline3 polyline)
Parameters
polylineGeoPolyline3The straight chain to widen.
Remarks
Widening loses nothing: every edge simply carries a bulge of zero. It is Flatten() going the other way that throws the curves away.
Exceptions
- ArgumentNullException
Thrown when the chain is null.