Skip to content

Commit

Permalink
descriptions tweaked following @peterjamesnugent's suggestion
Browse files Browse the repository at this point in the history
  • Loading branch information
pawelbaran committed Mar 13, 2024
1 parent 18c3bf3 commit c0900c1
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions Geometry_Engine/Compute/BooleanDifference.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,23 +37,23 @@ public static partial class Compute
/**** public Methods - Lines ****/
/***************************************************/

[Description("Returns the parts of the first line that are _not_ overlapping with the reference line, i.e. removes that parts of the first line that _is_ overlapping with the reference line. If the lines are not colinear or within tolerance distance of each other the full first line is returned.")]
[Description("Returns the parts of the first line that are not overlapping with the reference line, i.e. removes that parts of the first line that is overlapping with the reference line. If the lines are not colinear or within tolerance distance of each other the full first line is returned.")]
[Input("line", "The line to remove overlaps from.")]
[Input("refLine", "The reference line. Any parts of this line that are overlapping with the first line are removed from the first line.")]
[Input("tolerance", "Tolerance used for checking colinearity and proximity of the two lines.", typeof(Length))]
[Output("line", "The parts of the first line _not_ overlapping with the reference line.")]
[Output("line", "The parts of the first line not overlapping with the reference line.")]
public static List<Line> BooleanDifference(this Line line, Line refLine, double tolerance = Tolerance.Distance)
{
return new List<Line> { line }.BooleanDifference(new List<Line> { refLine }, tolerance);
}

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

[Description("Returns the parts of the first lines that are _not_ overlapping with any of the reference lines, i.e. removes that parts of the first lines that _is_ overlapping with any of the reference lines. If a line and a reference line are not colinear or within distance tolerance of each other, no action will be taken for that particular pair of lines.")]
[Description("Returns the parts of the first lines that are not overlapping with any of the reference lines, i.e. removes that parts of the first lines that is overlapping with any of the reference lines. If a line and a reference line are not colinear or within distance tolerance of each other, no action will be taken for that particular pair of lines.")]
[Input("lines", "The lines to remove overlaps from.")]
[Input("refLines", "The reference lines. Any parts of these lines that are overlapping with the first lines are removed from the first lines.")]
[Input("tolerance", "Tolerance used for checking colinearity and proximity between two lines.", typeof(Length))]
[Output("lines", "The parts of the first lines _not_ overlapping with the reference lines.")]
[Output("lines", "The parts of the first lines not overlapping with the reference lines.")]
public static List<Line> BooleanDifference(this List<Line> lines, List<Line> refLines, double tolerance = Tolerance.Distance)
{
double sqTol = tolerance * tolerance;
Expand Down Expand Up @@ -87,11 +87,11 @@ public static List<Line> BooleanDifference(this List<Line> lines, List<Line> ref
/**** public Methods - Regions ****/
/***************************************************/

[Description("Returns the areas of the closed Polyline region that are _not_ overlapping with the closed Polyline reference regions, i.e. removes that areas of the first region that _is_ overlapping with any of the reference regions. Requires the region and all reference regions to be closed. The method only considers reference regions that are co-planar with the region being evaluated.")]
[Description("Returns the areas of the closed Polyline region that are not overlapping with the closed Polyline reference regions, i.e. removes that areas of the first region that is overlapping with any of the reference regions. Requires the region and all reference regions to be closed. The method only considers reference regions that are co-planar with the region being evaluated.")]
[Input("region", "The line to remove overlaps from. Should be a closed planar curve.")]
[Input("refRegions", "The reference regions. Any parts of these regions that are overlapping with the first region are removed from the first region. All regions required to be closed. Reference regions not coplanar with the region are not considered.")]
[Input("tolerance", "Tolerance used for checking co-planarity and proximity of the regions.", typeof(Length))]
[Output("regions", "The region parts of the first region _not_ overlapping with any of the reference regions.")]
[Output("regions", "The region parts of the first region not overlapping with any of the reference regions.")]
public static List<Polyline> BooleanDifference(this Polyline region, List<Polyline> refRegions, double tolerance = Tolerance.Distance)
{
if (!region.IsClosed(tolerance) || refRegions.Any(x => !x.IsClosed()))
Expand Down Expand Up @@ -242,11 +242,11 @@ public static List<Polyline> BooleanDifference(this Polyline region, List<Polyli

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

[Description("Returns the areas of the closed ICurve region that are _not_ overlapping with the closed ICurve reference regions, i.e. removes that areas of the first region that _is_ overlapping with any of the reference regions. Requires the region and all reference regions to be closed. The method only considers reference regions that are co-planar with the region being evaluated.")]
[Description("Returns the areas of the closed ICurve region that are not overlapping with the closed ICurve reference regions, i.e. removes that areas of the first region that is overlapping with any of the reference regions. Requires the region and all reference regions to be closed. The method only considers reference regions that are co-planar with the region being evaluated.")]
[Input("region", "The line to remove overlaps from. Should be a closed planar curve.")]
[Input("refRegions", "The reference regions. Any parts of these regions that are overlapping with the first region are removed from the first region. All regions required to be closed. Reference regions not coplanar with the region are not considered.")]
[Input("tolerance", "Tolerance used for checking co-planarity and proximity of the regions.", typeof(Length))]
[Output("regions", "The region parts of the first region _not_ overlapping with any of the reference regions.")]
[Output("regions", "The region parts of the first region not overlapping with any of the reference regions.")]
public static List<PolyCurve> BooleanDifference(this ICurve region, IEnumerable<ICurve> refRegions, double tolerance = Tolerance.Distance)
{
List<ICurve> refRegionsList = refRegions.ToList();
Expand Down

0 comments on commit c0900c1

Please sign in to comment.