Skip to content

Commit d853a78

Browse files
committed
Merge branch 'dev'
2 parents c4cf408 + 686492e commit d853a78

File tree

6 files changed

+18
-25
lines changed

6 files changed

+18
-25
lines changed

Package.resolved

Lines changed: 11 additions & 20 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Package.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ let package = Package(
1010
.executable(name: "Helical-Demo", targets: ["Demo"]),
1111
],
1212
dependencies: [
13-
.package(url: "https://github.com/tomasf/Cadova.git", .upToNextMinor(from: "0.1.2")),
13+
.package(url: "https://github.com/tomasf/Cadova.git", .upToNextMinor(from: "0.2.0")),
1414
],
1515
targets: [
1616
.target(

Sources/Helical/Holes/ClearanceHole.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public struct ClearanceHole: Shape3D {
1616
self.boltHeadRecess = boltHeadRecess
1717
}
1818

19-
public init(diameter: Double, depth: Double, edgeProfile: EdgeProfile?) {
19+
public init(diameter: Double, depth: Double, edgeProfile: EdgeProfile? = nil) {
2020
self.diameter = diameter
2121
self.depth = depth
2222
self.edgeProfile = edgeProfile
@@ -37,6 +37,7 @@ public struct ClearanceHole: Shape3D {
3737
.revolved()
3838
}
3939
}
40+
.within(z: ...depth)
4041
}
4142
}
4243
}

Sources/Helical/Holes/ThreadedHole.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,8 @@ public struct ThreadedHole: Shape3D {
4040

4141
EdgeProfile.chamfer(depth: leadinChamferSize)
4242
.profile
43-
.translated(x: chamferInnerDiameter / 2)
43+
.aligned(at: .minX)
44+
.translated(x: chamferInnerDiameter / 2, y: leadinChamferSize)
4445
.revolved()
4546
}
4647
}

Sources/Helical/Nut/Bodies/TSlotNutBody.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ public struct TSlotNutBody: NutBody {
2222
Box(effectiveBaseSize)
2323
.aligned(at: .centerXY)
2424
.replaced(if: bottomProfile) { input, bottomProfile in
25-
input.applyingEdgeProfile(bottomProfile, to: .bottom, along: .x)
25+
input.cuttingEdgeProfile(bottomProfile, on: .bottom, along: .x)
2626
}
2727

2828
Box(x: effectiveBaseSize.x, y: slotWidth + tol, z: fullHeight - baseSize.z)

Sources/Helical/Thread/TrapezoidalThreadForm.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ public struct TrapezoidalThreadform: Threadform {
1515
@Environment(\.thread!) var thread
1616
let slopeLength = thread.depth / tan(90° - angle / 2)
1717

18-
Polygon([
18+
return Polygon([
1919
[0, -crestWidth / 2 - slopeLength],
2020
[0, crestWidth / 2 + slopeLength],
2121
[thread.depth, crestWidth / 2],

0 commit comments

Comments
 (0)