Skip to content

Commit

Permalink
Add descriptions for curve methods
Browse files Browse the repository at this point in the history
  • Loading branch information
IsakNaslundBh authored and pawelbaran committed Nov 15, 2022
1 parent 547a11a commit bc170c8
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions Geometry_Engine/Compute/Join.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ public static partial class Compute
/**** Join curves ****/
/***************************************************/

[Description("Joins a collection of PolyCurves into one or more continous PolyCurves. Input PolyCurves are split into segmenets before joining why discontinuous PolyCurves will be split into continuous segments. Method atempts to align tangents of subsequent joined segments which means some segments of the input PolyCurves might be flipped in the returned joined PolyCurves.")]
[Input("curves", "The PolyCurves to join.")]
[Input("tolerance", "Distance tolerance to be used to check proximity of start and endpoints of curves.", typeof(Length))]
[Output("polyCurves", "The joined continous PolyCurves.")]
public static List<PolyCurve> Join(this List<PolyCurve> curves, double tolerance = Tolerance.Distance)
{

Expand Down Expand Up @@ -91,6 +95,10 @@ public static List<PolyCurve> Join(this List<PolyCurve> curves, double tolerance

/***************************************************/

[Description("Joins a collection of Lines into one or more continous Polylines. Method atempts to align tangents of subsequent joined segments which means some input Lines might be flipped in the returned joined Polylines.")]
[Input("lines", "The Lines to join.")]
[Input("tolerance", "Distance tolerance to be used to check proximity of start and endpoints of curves.", typeof(Length))]
[Output("pLines", "The joined continous Polyline.")]
public static List<Polyline> Join(this List<Line> lines, double tolerance = Tolerance.Distance)
{
List<Polyline> sections = lines.Select(l => new Polyline { ControlPoints = l.ControlPoints() }).ToList();
Expand All @@ -99,6 +107,10 @@ public static List<Polyline> Join(this List<Line> lines, double tolerance = Tole

/***************************************************/

[Description("Joins a collection of Polylines into one or more continous Polylines. Method atempts to align tangents of subsequent joined segments which means some input Polylines might be flipped in the returned joined Polylines.")]
[Input("curves", "The Polyline to join.")]
[Input("tolerance", "Distance tolerance to be used to check proximity of start and endpoints of curves.", typeof(Length))]
[Output("pLines", "The joined continous Polyline.")]
public static List<Polyline> Join(this List<Polyline> curves, double tolerance = Tolerance.Distance)
{
List<Polyline> sections = curves.Select(l => new Polyline { ControlPoints = new List<Point>(l.ControlPoints) }).ToList();
Expand Down Expand Up @@ -149,6 +161,10 @@ public static List<Polyline> Join(this List<Polyline> curves, double tolerance =
/**** Public Methods - Interfaces ****/
/***************************************************/

[Description("Joins a collection of Curve into one or more PolyCurve. Method atempts to align tangents of subsequent joined segments which means some input Curves might be flipped in the returned joined PolyCurve.")]
[Input("curves", "The Curves to join.")]
[Input("tolerance", "Distance tolerance to be used to check proximity of start and endpoints of curves.", typeof(Length))]
[Output("polyCurves", "The joined PolyCurve.")]
public static List<PolyCurve> IJoin(this List<ICurve> curves, double tolerance = Tolerance.Distance)
{
if (curves == null)
Expand Down

0 comments on commit bc170c8

Please sign in to comment.