Skip to content

Commit c04f0d8

Browse files
maxcapodi78maxcapodi78
authored andcommitted
Added a method to find the face closest to bounding box (in case there is no face touching the bounding box).
Also added a method in Hfss3dLayout to filder objects by layer and by nets.
1 parent 5f759b6 commit c04f0d8

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pyaedt/modeler/object3dlayout.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -538,15 +538,15 @@ def edge_by_point(self, point):
538538
int
539539
Edge id.
540540
"""
541-
id = 0
541+
index_i = 0
542542
v_dist = None
543543
edge_id = None
544544
for edge in self.edges:
545545
v = GeometryOperators.v_norm(GeometryOperators.distance_vector(point, edge[0], edge[1]))
546546
if not v_dist or v < v_dist:
547547
v_dist = v
548-
edge_id = id
549-
id += 1
548+
edge_id = index_i
549+
index_i += 1
550550
return edge_id
551551

552552
@property

0 commit comments

Comments
 (0)