Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support builtin modules/transforms #2

Open
54 tasks
Michael-F-Bryan opened this issue Aug 11, 2022 · 0 comments
Open
54 tasks

Support builtin modules/transforms #2

Michael-F-Bryan opened this issue Aug 11, 2022 · 0 comments

Comments

@Michael-F-Bryan
Copy link
Owner

Michael-F-Bryan commented Aug 11, 2022

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()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant