1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-01-18 06:38:14 +01:00
This commit is contained in:
Justin Lin 2019-06-29 17:53:55 +08:00
parent f915b07289
commit a6caaac787

View File

@ -1,4 +1,4 @@
function px_sphere(radius, filled = true, width = 1) =
function px_sphere(radius, filled = true, thickness = 1) =
let(range = [-radius: radius - 1])
filled ? [
for(z = range)
@ -7,7 +7,7 @@ function px_sphere(radius, filled = true, width = 1) =
let(v = [x, y, z])
if(norm(v) < radius) v
] :
let(ishell = radius * radius - 2 * width * radius)
let(ishell = radius * radius - 2 * thickness * radius)
[
for(z = range)
for(y = range)