Skip to content

Commit

Permalink
draw again the first flat folding line in order to easily wrap up the
Browse files Browse the repository at this point in the history
flatten representation
  • Loading branch information
nm2107 committed Mar 26, 2023
1 parent 32516d0 commit ac257e2
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions test_generatrices.FCMacro
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,6 @@ def showFoldingLinesOn3DShape(foldingLines: [FoldingLine]) -> None:

def flattenFoldingLine(foldingLines: [FoldingLine], previousFlatFoldingLine: FlatFoldingLine, i: int) -> FlatFoldingLine:
"""Computes the flatten representation of a folding line."""
if (i < 1):
return

foldingLine = foldingLines[i]
pointA = foldingLine.getPointFaceA()
Expand Down Expand Up @@ -218,6 +216,12 @@ def flattenFoldingLines(foldingLines: [FoldingLine]) -> [FlatFoldingLine]:
flatFoldingLines.append(previousFlatFoldingLine)
i += 1

# Add again the first folding line to be drawn in last position so the flatten
# representation can be wrapped up having the two drawings of the first folding line
# superposed.
previousFlatFoldingLine = flattenFoldingLine(foldingLines, previousFlatFoldingLine, 0)
flatFoldingLines.append(previousFlatFoldingLine)

return flatFoldingLines


Expand Down

0 comments on commit ac257e2

Please sign in to comment.