Support builtin modules/transforms
Opened this issue · 0 comments
Michael-F-Bryan commented
It'd be really nice if the interpreter supported most of the builtin modules and transforms from the cheatsheet.
2D shapes:
-
circle(radius | d=diameter)
-
square(size, centre)
-
square([width, height], centre)
-
polygon([points...])
-
polygon([points...], [path...])
-
text(t, size, font, halign, valign, spacing, direction, language, script)
3D shapes:
-
sphere(radius
) -
sphere(d = diameter)
-
cube(size, center)
-
cylinder(h, r|d, center)
-
cylinder(h, r1|d1, r2|d2, center)
-
polyhedron([points...], [faces...], convexivity)
-
linear_extrude(height, center, convexivity, twist, slices)
-
rotate_extrude(angle, convexivity)
Transformations:
-
translate([x, y, z])
-
rotate([x, y, z])
-
rotate(a, [x, y, z])
-
scale([x, y, z])
-
resize([x, y, z], auto, convexivity)
-
mirror([x, y, z])
-
multmatrix(m)
-
color("colorname", alpha)
-
color("#hexvalue")
-
color([r, g, b, a])
-
offset(r|delta, chamfer)
-
hull()
-
minkowski()
Boolean operators:
-
union()
-
difference()
-
intersection()
Math functions:
-
abs()
-
sign()
-
sin()
-
cos()
-
tan()
-
acos()
-
asin()
-
atan()
-
atan2()
-
floor()
-
round()
-
ceil()
-
ln()
-
len()
-
let()
(contextual keyword?) -
log()
-
pow()
-
sqrt()
-
exp()
-
rands()
-
min()
-
max()
-
norm()
-
cross()