I'm currently investigating using signed distance fields (SDF) to generate 3D printable volumes with

I’m currently investigating using signed distance fields (SDF) to generate 3D printable volumes with infinite resolution. The problem I have right now is that all the GCode generators rely on either vector or mesh data, while an SDF would generate volumetric data (something that would very well fit the new SVX format). The only ones I’ve found that work with bitmaps as input are cad.py and cam.py, but they’re only for 2D. Does anyone has any pointer on which software might exist for that? I’m targeting filament-based printers btw.

Curious why this is better than existing infinite-resolution formats like NURBS?

The big issue I think is that slicers utilize polygon/mesh intersection algorithms to deconstruct the model to 2d slices, and then utilize erosion algorithms to determine shell/infill regions. Whatever format you use has to be conveniently sliced. How would you do it for SDFs?

@Ryan_Carlyle is on point about this.

You have two options:

  1. slice your volume into 2D layers, then mesh the edges of each layer to the one above and below to make a STL.

This would end up with a huge STL, but would work (slowly) with any slicer.

  1. pick an open source slicer (like slic3r) and adapt it to handle your format.

You would have your format bypass the STL and mesh slicing phases, and go directly to layer generation.

Support autogeneration may be problematic, depending if the slicer does that at the mesh or layer phase.

This also limits you to only one slicer, but if it’s a good enough proof of concept, you should easily be able to get other slicers to support your representation.

Oh, and I believe that ImplicitCAD would be a great language for your SDF - it uses SDF as the backend also, I believe.

http://www.implicitcad.org/

IceSL perhaps

@Ryan_Carlyle You can do some fairly crazy shapes with SDFs, see https://www.shadertoy.com/view/4sX3R2 – I don’t think that would be easy with NURBS. The output format would be a volume of 1bit voxels (for instance, 1bit PNG for each layer).

@Jason_McMullan ImplicitCAD seems similar to what I’d like to do (although I’m more interested in fractal/organic shapes). ImplicitCAD doesn’t say much about export/printing though.

The author of ImplicitCAD has stated that he believes the SDF approach is not really the best (I can’t remember where he said it and exactly what he said, I’m terribly sorry). I investigated ImplicitCAD, but it is not usable for me as it is extremely slow to render.

@Oystein_Krog @Mark_Rehorst IceSL seems to be pretty much what I was looking for, I never heard about it before, thanks! Voxelizer might be a good fit, but the closed-source aspect of it is a no-go for me.

IceSL is amazing, I just wish it was open source :confused:

ImplicitCAD exports STL - maybe your can leverage its STL export engine for your system?

Http://www.implicitcad.org/docs/tutorial

@Jason_McMullan The prototype implementation I have can already generates STL, but the files are too big or the quality is too low for what I want to do. I use marching cube/tetrahedrons or surfacenets for that (from https://github.com/mikolalysenko/mikolalysenko.github.com/tree/master/Isosurface). I’m looking at https://abfab3d.com/ as another way to generate GCodes from volumetric data.