1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-08-15 03:05:41 +02:00
This commit is contained in:
Justin Lin
2022-04-06 17:02:32 +08:00
parent 0b23e5666a
commit adf07c5da8
8 changed files with 25 additions and 36 deletions

View File

@@ -23,17 +23,16 @@ pts_angles = golden_spiral(
a_step = 360 / spirals;
cells = [
for(i = [0:spirals - 1])
for(pt_angle = pts_angles)
ptf_rotate(pt_angle[0], i * a_step)
for(i = [0:spirals - 1], pt_angle = pts_angles)
ptf_rotate(pt_angle[0], i * a_step)
];
noised = [
for(y = [-half_size[1]:pixel_step:half_size[1]])
[
for(x = [-half_size[0]:pixel_step:half_size[0]])
let(n = nz_cell(cells, [x, y] * height_factor) )
[x, y, n < half_pixel_step ? half_pixel_step : n]
]
[
for(x = [-half_size[0]:pixel_step:half_size[0]])
let(n = nz_cell(cells, [x, y] * height_factor) )
[x, y, n < half_pixel_step ? half_pixel_step : n]
]
];
sf_thicken(noised, thickness);