From 4accdf78d60599fb91453bb86e57376dea828737 Mon Sep 17 00:00:00 2001 From: Justin Lin Date: Thu, 8 Jun 2017 14:34:52 +0800 Subject: [PATCH] refactored --- src/hull_polyline3d.scad | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/hull_polyline3d.scad b/src/hull_polyline3d.scad index 9745b0ab..f773e36a 100644 --- a/src/hull_polyline3d.scad +++ b/src/hull_polyline3d.scad @@ -17,10 +17,13 @@ module hull_polyline3d(points, thickness) { leng = len(points); module hull_line3d(index) { + point1 = points[index - 1]; + point2 = points[index]; + hull() { - translate(points[index - 1]) + translate(point1) sphere(half_thickness); - translate(points[index]) + translate(point2) sphere(half_thickness); } }