OpenSCAD Rounded Box (minkowski) example

OpenSCAD examples
/

Rounded Box (minkowski)

Advanced

Advanced geometry

Lesson 14 of 22

Compare full 3D edge rounding with a cheaper 2D rounded-profile extrusion.

Try changing:

lengthwidthheightradiusmethod

High compile complexity. 3D Minkowski is costly. Use the 2D option for fast iteration.

How this model works

The Minkowski sum expands a centered core by radius on every side. Subtracting twice radius from each core dimension targets the requested envelope; lifting by half height targets z = 0. Faceted spheres approximate those dimensions, so inspect the final bounds rather than assuming exact extrema. The 2D alternative rounds only vertical edges, so top and bottom edges remain sharp. It is intentionally not an equivalent fillet, but often gives the needed silhouette at much lower cost.

main.scad

Loading draft

Ctrl/Cmd+Enter or F5: preview · F6: render · Ctrl/Cmd+F: search · Ctrl+Space: complete · Tab: leave editor

0 messages

Make it your own

Compile both methods and compare their times and triangle counts at the same dimensions. Inspect the top edge to see exactly what the cheaper method omits.

Change one parameter at a time and inspect the result. Use the workspace reset action to return to this lesson’s original model.

FAQ