From e146331d62c27472b420c81f2eeacfb947458501 Mon Sep 17 00:00:00 2001 From: satabol Date: Sun, 13 Oct 2024 19:33:30 +0300 Subject: [PATCH] - fix count of angles after sorting points. --- nodes/CAD/stright_skeleton_2d_extrude.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/nodes/CAD/stright_skeleton_2d_extrude.py b/nodes/CAD/stright_skeleton_2d_extrude.py index f7c4d733c5..fea02a4c5e 100644 --- a/nodes/CAD/stright_skeleton_2d_extrude.py +++ b/nodes/CAD/stright_skeleton_2d_extrude.py @@ -508,13 +508,13 @@ def process(self): areas = [] for IJK in range(len(verts_boundaries)): verts_boundaries_IJK, edges_boundaries_IJK = verts_boundaries[len(verts_boundaries)-1-IJK], edges_boundaries[len(verts_boundaries)-1-IJK] - vect_boundaries_IJ_sorted = vertices_sort_by_edges(verts_boundaries_IJK, edges_boundaries_IJK) - res_boundaries_verts.append(vect_boundaries_IJ_sorted) - area = areas_from_polygons(vect_boundaries_IJ_sorted, [list(range(len(vect_boundaries_IJ_sorted)))], ) + vect_boundaries_IJK_sorted = vertices_sort_by_edges(verts_boundaries_IJK, edges_boundaries_IJK) + res_boundaries_verts.append(vect_boundaries_IJK_sorted) + area = areas_from_polygons(vect_boundaries_IJK_sorted, [list(range(len(vect_boundaries_IJK_sorted)))], ) areas.append(area[0]) - object_boundaries.append(vect_boundaries_IJ_sorted) - object_area_boundaries.append({"area":area, "object_boundaries":vect_boundaries_IJ_sorted}) - objects_angles_of_boundary.append( [ss_angle*180/math.pi,]*len(verts_boundaries_IJK) ) + object_boundaries.append(vect_boundaries_IJK_sorted) + object_area_boundaries.append({"area":area, "object_boundaries":vect_boundaries_IJK_sorted}) + objects_angles_of_boundary.append( [ss_angle*180/math.pi,]*len(vect_boundaries_IJK_sorted) ) pass srt = sort_together([areas, object_boundaries, objects_angles_of_boundary]) object_boundaries_sorted, objects_angles_of_boundary_sorted = list(reversed(srt[1])), list(reversed(srt[2]))