From fe913e7bbf99aeab33d7a1b0ccee7f1e7981ff45 Mon Sep 17 00:00:00 2001 From: jdegenstein Date: Thu, 7 Dec 2023 15:52:00 -0600 Subject: [PATCH] Update topology.py fix Edge.intersections edge length --- src/build123d/topology.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/build123d/topology.py b/src/build123d/topology.py index 9fa5deaf..1ce4d8a2 100644 --- a/src/build123d/topology.py +++ b/src/build123d/topology.py @@ -4358,12 +4358,14 @@ def intersections( Returns: ShapeList[Vector]: list of intersection points """ - # Convert an Axis into an edge at least as large as self + # Convert an Axis into an edge at least as large as self and Axis start point if isinstance(edge, Axis): - self_bbox = self.bounding_box() + self_bbox_w_edge = self.bounding_box().add( + Vertex(edge.position).bounding_box() + ) edge = Edge.make_line( - edge.position + edge.direction * (-1 * self_bbox.diagonal), - edge.position + edge.direction * self_bbox.diagonal, + edge.position + edge.direction * (-1 * self_bbox_w_edge.diagonal), + edge.position + edge.direction * self_bbox_w_edge.diagonal, ) # To determine the 2D plane to work on plane = self.common_plane(edge)