1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-08-19 04:51:26 +02:00

c-style for loop

This commit is contained in:
Justin Lin
2019-06-14 08:32:28 +08:00
parent beaebfcc37
commit 41db148815

View File

@@ -14,8 +14,9 @@ function shape_ellipse(axes) =
let(
frags = __frags(axes[0]),
step_a = 360 / frags,
a_end = 360 - step_a,
shape_pts = [
for(a = [0:step_a:360 - step_a])
for(a = 0; a <= a_end; a = a + step_a)
[axes[0] * cos(a), axes[1] * sin(a)]
]
) shape_pts;