1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-01-17 14:18:13 +01:00
dotSCAD/examples/voronoi/voronoi_torus.scad

16 lines
314 B
OpenSCAD
Raw Normal View History

2022-06-06 13:11:46 +08:00
use <voronoi/vrn2_cells_space.scad>
use <polyline_join.scad>
use <ptf/ptf_torus.scad>
2020-04-09 14:53:05 +08:00
size = [40, 80];
grid_w = 5;
2020-06-10 20:17:18 +08:00
cells = vrn2_cells_space(size, grid_w);
2020-04-09 14:53:05 +08:00
$fn = 4;
for(cell = cells) {
cell_poly = [for(p = cell[1]) ptf_torus(size, p, [10, 5], [360, 360])];
2021-10-08 09:36:01 +08:00
polyline_join(cell_poly)
sphere(d = 1);
2020-04-09 14:53:05 +08:00
}