Skip to content

Commit

Permalink
Merge branch 'master' into fix-pattern-segments-error
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesbradleym authored Jan 5, 2024
2 parents 6f31dcd + ca7fffd commit 024dbb6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Grids/Grid/src/Grid.cs
Original file line number Diff line number Diff line change
Expand Up @@ -708,9 +708,9 @@ private static (Line x, Line y) CalculateAxes(Polygon alignedBoundingBox2d)
continue;
}

var angle = new Vector3(axis.End - axis.Start).AngleTo(Vector3.XAxis);
var angle = axis.Direction().AngleTo(Vector3.XAxis);

if (angle < 45)
if (angle <= 45 && axes.x == null) // in case where both x and y will have the same angle of 45 degrees
{
axes.x = axis;
}
Expand Down

0 comments on commit 024dbb6

Please sign in to comment.