Skip to content

Commit

Permalink
Fix for control point near duplicates
Browse files Browse the repository at this point in the history
  • Loading branch information
JWock82 committed Apr 24, 2023
1 parent 57a21b1 commit fe4bd62
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions PyNite/Mesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -458,6 +458,7 @@ def generate(self):
# Only keep the value at `i` if it's not a duplicate or near duplicate
if not isclose(x_control[i], x_control[i+1]):
unique_list.append(x_control[i])
unique_list.append(x_control[-1])
x_control = unique_list

# Remove any values that are duplicates or near duplicates from `y_control`
Expand All @@ -466,6 +467,7 @@ def generate(self):
# Only keep the value at `i` if it's not a duplicate or near duplicate
if not isclose(y_control[i], y_control[i+1]):
unique_list.append(y_control[i])
unique_list.append(y_control[-1])
y_control = unique_list

# Each node number will be increased by the offset calculated below
Expand Down

0 comments on commit fe4bd62

Please sign in to comment.