Skip to content

Instantly share code, notes, and snippets.

@arnholm
Last active September 5, 2017 21:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save arnholm/df9171ec09e8ac5cb383cefb2b5652f9 to your computer and use it in GitHub Desktop.
Save arnholm/df9171ec09e8ac5cb383cefb2b5652f9 to your computer and use it in GitHub Desktop.

Cube minus sphere

shape@ main_shape()
{
   solid@ myShape = cube(size:100,center:true) - sphere(r:64);
   return myShape;
}

void main()
{
   shape@ obj = main_shape();
   obj.write_xcsg(GetInputFullPath());
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment