Taking distance-based CAD to the next level

For those who regularly model CAD models, a pair of calipers are essential as they allow reasonably accurate measurements to fit a specific part. However, [Jason Harris] takes this concept to the next level with a CAD tool based on the signed distance function, SDFX.

For those who don't know, signed distance functions can tell you from a given point how far away the nearest part of the model is. The model is represented as a single function that offers interesting advantages. For example, chamfering and threading are often quite complex in traditional CAD programs and trivial in an SDF environment. SDFX is a golang library that lets you write golang programs to describe the model. OpenSCAD is a Hackaday favorite because it is a beautiful code-based parametric CAD package. But the syntax and language are somewhat confusing, to put it mildly. The advantage of using golang rather than a DSL is that you can use all the niceties that a full language brings. For example, you can export multiple objects, perform network queries, and connect to GUI libraries to recreate something like the customizer for OpenSCAD.

Objects are rendered in STL using walking squares. Then they can be printed in any slicing software that suits you. It's a great project with a great API and nearly a hundred examples.

The code is available on GitHub under an MIT license.

Taking distance-based CAD to the next level

For those who regularly model CAD models, a pair of calipers are essential as they allow reasonably accurate measurements to fit a specific part. However, [Jason Harris] takes this concept to the next level with a CAD tool based on the signed distance function, SDFX.

For those who don't know, signed distance functions can tell you from a given point how far away the nearest part of the model is. The model is represented as a single function that offers interesting advantages. For example, chamfering and threading are often quite complex in traditional CAD programs and trivial in an SDF environment. SDFX is a golang library that lets you write golang programs to describe the model. OpenSCAD is a Hackaday favorite because it is a beautiful code-based parametric CAD package. But the syntax and language are somewhat confusing, to put it mildly. The advantage of using golang rather than a DSL is that you can use all the niceties that a full language brings. For example, you can export multiple objects, perform network queries, and connect to GUI libraries to recreate something like the customizer for OpenSCAD.

Objects are rendered in STL using walking squares. Then they can be printed in any slicing software that suits you. It's a great project with a great API and nearly a hundred examples.

The code is available on GitHub under an MIT license.

What's Your Reaction?

like

dislike

love

funny

angry

sad

wow