Skip to content

Commit 26f8855

Browse files
committed
Update RoundedStarPolygon.swift
1 parent 8d1b016 commit 26f8855

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

Sources/Shapes/RoundedStarPolygons/RoundedStarPolygon.swift

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -69,16 +69,10 @@ extension Path {
6969

7070
//radius
7171
if usableConvexRadius == 0 {
72-
// let sideLength = sqrt((point.x - viaPoint.x) * (point.x - viaPoint.x) + (point.y - viaPoint.y) * (point.y - viaPoint.y))
73-
// let inradius = sideLength / (2 * tan(.pi / CGFloat(points * 2)))
74-
7572
usableConvexRadius = min(convexRadius, inradius)
7673
}
7774

7875
if usableConcaveRadius == 0 {
79-
// let sideLength = sqrt((point.x - viaPoint.x) * (point.x - viaPoint.x) + (point.y - viaPoint.y) * (point.y - viaPoint.y))
80-
// let inradius = sideLength / (2 * tan(.pi / CGFloat(points * 2)))
81-
8276
usableConcaveRadius = min(concaveRadius, inradius - convexRadius)
8377
}
8478

@@ -113,7 +107,6 @@ struct RoundedStarPolygon_Previews: PreviewProvider {
113107

114108
RoundedStarPolygon(points: 5, smoothness: 0.5, convexRadius: 10, concaveRadius: 10)
115109
.fill(Color.orange)
116-
//.background(StarPolygon(points: 5, smoothness: 0.36))
117110
.background(Circle())
118111
.previewLayout(.fixed(width: 400, height: 400))
119112

0 commit comments

Comments
 (0)