From d8dfd241dd27bf6d3634a45722db6da8f845b215 Mon Sep 17 00:00:00 2001 From: Justin Lin Date: Sun, 25 Oct 2020 16:46:20 +0800 Subject: [PATCH] add radius param --- src/experimental/fibonacci_sphere.scad | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/experimental/fibonacci_sphere.scad b/src/experimental/fibonacci_sphere.scad index 6ea917d1..f907d352 100644 --- a/src/experimental/fibonacci_sphere.scad +++ b/src/experimental/fibonacci_sphere.scad @@ -1,4 +1,4 @@ -function fibonacci_sphere(n, dir = "CT_CLK") = +function fibonacci_sphere(n, radius, dir = "CT_CLK") = let( toDegrees = 180 / PI, phi = PI * (3 - sqrt(5)), @@ -13,5 +13,5 @@ function fibonacci_sphere(n, dir = "CT_CLK") = x = cos(theta * toDegrees) * r, y = sin(theta * toDegrees) * r ) - [x, y, z] + [x, y, z] * radius ]; \ No newline at end of file