Skip to content

Instantly share code, notes, and snippets.

@madhephaestus
Last active May 4, 2026 01:27
Show Gist options
  • Select an option

  • Save madhephaestus/2374524a0882601de95fc16e47dfd9e9 to your computer and use it in GitHub Desktop.

Select an option

Save madhephaestus/2374524a0882601de95fc16e47dfd9e9 to your computer and use it in GitHub Desktop.
Slice a csg and fillet around the slice
/.settings
/.project
/.classpath
/.cproject
/cache/
/*.class
double rad =2
def base = new Cube(20,30,10).toCSG()
.union(new Cube(40,20,10).toCSG())
.difference(new Cube(8,10,20).toCSG())
.difference(new Cube(10,5,20).toCSG())
.rotz(20)
.toZMin()
.scalex(3)
.scaley(0.6)
List<Polygon> polys = Slice.slice(base)
return [base.difference(Fillet.innerFillet( base,(double)rad,24)).roty(180).toZMin(),polys]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment