Comment by jacquesm

Comment by jacquesm 6 hours ago

8 replies

I use OpenSCAD for parametric stuff and it has served me very well, even if it has a learning curve and some serious limitations. The trick is to stop thinking interactively and to treat the shapes you want to make in a more generative manner. For instance, you could try to fillet or chamfer an edge, or you could create that edge using a sphere or a shape tracing a path and then tying it all together with a hull. But it can take a while before you become adept at seeing how shapes decompose into simpler shapes.

[removed] 4 hours ago
[deleted]
ur-whale 6 hours ago

If you like to code, OpenSCAD is really the best for simple shapes and my go-to tool for these situations, stuff like making a project box for an electronic contraption.

OpenSCAD however fails spectacularly for any kind of complex filetting situation when compared to tools like Fusion or even FreeCAD (FreeCAD's UI is an abomination though).

The morphological ops in OpenSCAD (minkowski type stuff) are a very poor substitute to real fillets, and are extremely slow (underlying algos are all polynomials in number of triangles) when your objects get complex, and they are global operations, it is extremely hard to limit their action to a localized part of your object.

Even Blender, which was truly never designed for this type of operations can sometimes do better than OpenSCAD for fillets.

Another thing that's a real pain in OpenSCAD: you cannot "probe" (measure) your existing object at a certain stage, grab the result of that measurement and re-use it in the rest of the code. MAJOR limitation.

  • danielheath 5 hours ago

    I've long imagined something comparable in use to OpenSCAD, but where the primitives are tool-paths rather than shapes; you specify the cuts (or prints) the machine will make, and get a render of how the material will look afterwards.

    This would, of course, be a great hassle to use, but I think I'd really enjoy being able to eg preview the texture different tool heads / cut patterns would leave. I imagine thinking in terms of "how the machine will cut this" would also improve my ability to reason about the machine.

    • bronze 5 hours ago

      Sounds like you just want to write GCode? There are some helpers to make it a little less tedious, like FullControllGcode. Gcode, especially for printers, is really 2 commands, G0 and G1, so writing your own helper is also pretty easy.

      • jacquesm 5 hours ago

        There is a lot more to it than that. For instance, for overhangs and bridges you need fairly fine control of the fan in relationship to the movement of the extruder head. You'll need to do circular interpolation in such a way that the toolhead does not slow down too much or you'll get really crappy corners and seams and other joints can be really hard to do properly if you are just using naive point-to-point moves rather than lots of little tweaks to get partial overlap between the two adjacent paths. And then there is control of the extruder retraction and pressure advance, which are pretty complex and difficult to get right for even a subset of the most common use cases, especially if you want to have a range of speed options. "pretty easy" does not match my experience so far, but then again, I am only using this when the regular slicer can't cope so there is a chance that the problem is me.

  • robk 5 hours ago

    I never understood why this is such a deal breaker. I just export The stl from Openscad then do fillets in Fusion. It's another step but usually only a few mins of clicking.

  • jacquesm 6 hours ago

    > OpenSCAD however fails spectacularly for any kind of complex filetting situation when compared to tools like Fusion or even FreeCAD (FreeCAD's UI is an abomination though).

    I've never had a problem with this, but I build up from the ground with the edges the way I want them to be. The reason many people struggle with this is that they start from 'hard' primitives such as cubes and triangles and then they want to process the edges once the rough shape is there. That's all but impossible. But you don't have to do it that way at all.

    > The morphological ops in OpenSCAD (minkowski type stuff) are a very poor substitute to real fillets, and are extremely slow (underlying algos are all polynomials in number of triangles) when your objects get complex, and they are global operations, it is extremely hard to limit their action to a localized part of your object.

    That's because they're used as 'after the fact' tools. It's a bit like trying to change the shape of a folded piece of metal after the fact. It's much easier to shape it right the first time than to 'fix' it later on.

    When I start working on a shape like that I use a truncated cube rotated 45/45/0, place copies of that cube on the vertices of the shape I want and then cover the whole thing with a hull. Instant chamfer. If I want to use fillets I'll use a sphere. That's much easier than to first create an arrangement of cubes and other primitives and then to decide where I want the fillets to go. Picking those initial shapes for the corners is the tricky part, after that it is very quick to make (and change) objects. I've done some pretty complex shapes like this, fully parametric that would have cost me days with a traditional workflow.

    > Another thing that's a real pain in OpenSCAD: you cannot "probe" (measure) your existing object at a certain stage, grab the result of that measurement and re-use it in the rest of the code. MAJOR limitation.

    Yes, agreed, this kind of second order primitive is not possible. I understand the reason for it (and the reason why you can't change variables on the fly) and it is a serious drawback. This makes it very hard to relate two non-trivial shapes to each other. Interactive CAD programs are better for things like that, but there - usually - the kind of change that takes a second in OpenSCAD means a whole pile of manual work. So my recipe is to stick to OpenSCAD for those things that I think I can make with it and to use an interactive tool for everything else.

    One thing that OpenSCAD excels at is remixing stuff based on existing STLs, I've yet to find another tool that allows me to do that so easily and with such versatility. Before my 'serious' cad tools have imported a mesh the OpenSCAD workflow is already printing the remixed result. As with everything: the right tool for the job is the key.