From 6be09b766912ee747db6ebfa8727d7acbf710243 Mon Sep 17 00:00:00 2001 From: Revar Desmera Date: Fri, 3 May 2019 11:27:25 -0700 Subject: [PATCH] Fixed extrude_2d_path_along_spiral()'s anchoring. --- paths.scad | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/paths.scad b/paths.scad index c8f404f..4bd8877 100644 --- a/paths.scad +++ b/paths.scad @@ -259,7 +259,7 @@ module extrude_2d_hollow(wall=2, height=50, twist=90, slices=60, center=undef, o // Example: // poly = [[-10,0], [-3,-5], [3,-5], [10,0], [0,-30]]; // extrude_2dpath_along_spiral(poly, h=200, r=50, twist=1080, $fn=36); -module extrude_2dpath_along_spiral(polyline, h, r, twist=360, center=undef, orient=ORIENT_Z, anchor=CENTER) { +module extrude_2dpath_along_spiral(polyline, h, r, twist=360, center=undef, orient=ORIENT_Z, anchor=BOTTOM) { pline_count = len(polyline); steps = ceil(segs(r)*(twist/360)); @@ -275,7 +275,7 @@ module extrude_2dpath_along_spiral(polyline, h, r, twist=360, center=undef, orie polyline, [ matrix4_xrot(90), matrix4_zrot(a), - matrix4_translate([dx, dy, dz]) + matrix4_translate([dx, dy, dz-h/2]) ] ) ) for (pt = pts) pt