1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-08-09 08:16:50 +02:00

consider y dir curve

This commit is contained in:
Justin Lin
2021-05-22 20:10:25 +08:00
parent 4f0b530e39
commit bba2ae4f0f

View File

@@ -33,7 +33,7 @@ module sf_curve(levels, points, thickness, depth, invert = false) {
[ [
for(x = [0:columns - 1]) for(x = [0:columns - 1])
let(p = (pts[x] + pts[x + 1]) / 2) let(p = (pts[x] + pts[x + 1]) / 2)
[p[0], y, p[2]] + normal_vts[x] * s[y][x][2] p + [0, y, 0] + normal_vts[x] * s[y][x][2]
] ]
]; ];
@@ -156,12 +156,12 @@ invert = false;
points = bezier_curve(1 / len(levels[0]) * 0.5, points = bezier_curve(1 / len(levels[0]) * 0.5,
[ [
[-20, 0, 0], [-20, 0, 0],
[40, 0, 155], [40, 20, 155],
[50, 0, -30], [50, 50, -30],
[-20, 0, 35], [-20, 0, 35],
[130, 0, -20], [130, -70, -20],
[150, 0, 168], [150, 0, 100],
[180, 0, 0] [180, 30, 0]
] ]
); );
@@ -169,4 +169,5 @@ sf_curve(levels, points, thickness, depth, invert);
#hull_polyline3d(points); #hull_polyline3d(points);
*/ */