Author Topic: Anyone using OpenSCAD?  (Read 8816 times)

0 Members and 1 Guest are viewing this topic.

Offline berkeTopic starter

  • Frequent Contributor
  • **
  • Posts: 258
  • Country: fr
  • F4WCO
Anyone using OpenSCAD?
« on: February 05, 2024, 09:10:41 am »
Just got a Prusa MINI+ last week and I started using it with OpenSCAD.  Otherwise I'm a 3D printing noob.  My use case is typical, printing enclosures for projects.

Here are my observations about OpenSCAD:

- The built-in editor (a Qt widget I guess) is trash, but you don't have to use it.  I use Emacs, and as soon as I save the file OpenSCAD gets inotify'd and refreshes the display.  Emacs even has a "SCAD" mode, and C-c C-o invokes OpenSCAD.
- The previewer GUI is OK, but rendering doesn't work very well with transparent surfaces, and because there is no cutting plane it's hard to see what's going on, you have to put switches in your code to remove parts.
- There is no interactive ruler / measure function in the GUI either.
- You can change parameters live in the GUI which is nice except that it doesn't refresh the view in a timely manner.
- The language is meh.  It pretends to be functional but it's irregular, doesn't even have decent closures.  Weird module/function distinction, no higher-order modules, no nested or anonymous modules, weird "children()" mechanism for defining operators...  It's not too bad but could be much better.  Because OpenSCAD has irritating language rules, some people have written generators around it.  There is at least one Rust crate.
- I have also used POVRay a bit, which is a CSG (constructive solid geometry) ray-tracer, the language there is more complete, more robust and coherent.
- There is no constraint resolution facility of any sort.
- OpenSCAD is based on CSG yet is still working on meshes, you need to specify meshing parameters for example for spheres and cylinders.
- Generating text is easy and you can use arbitrary fonts.
- Documentation is good
- No facility to verify if different parts are interfering or touching

Overall for me it's still much nicer than using FreeCAD.

I don't know if there is any fork or variant, or another CAD package that allows a similar workflow (text entry) but is of a higher quality.  If wouldn't have to be free but needs to work well under Linux and a cost not exceeding three digits.

For me, the things that need to be urgently done are:
- Fix the language so that it's actually functional, or maybe replace it with something that exists, like Ocaml or Scheme.  There are some libraries but not too much legacy so not much would be lost if the language is completely changed.
- Redo the previewer using a fragment shader that takes the CSG tree and properly implements transparency, etc. and can do cutting planes

To scratch my own itch I'll probably just define a couple of OCaml combinators that generate OpenSCAD primitives and define things that way.
 

Offline brucehoult

  • Super Contributor
  • ***
  • Posts: 4204
  • Country: nz
Re: Anyone using OpenSCAD?
« Reply #1 on: February 05, 2024, 09:59:44 am »
You might want to look at something I did in OpenSCAD. I defined a way to do cutaway using an arbitrary shape, not only a plane. I also made support for one layout for printing, and one for viewing the parts assembled.

https://www.thingiverse.com/thing:135065

Bruno Levy at INRIA Nancy has recently been working on a new CSG library that has a front end to input OpenSCAD files. I suspect he would be open to improving the language to be more functional, or an alternative equivalent language.

https://twitter.com/BrunoLevy01/status/1753815907221066239
 
The following users thanked this post: berke

Offline berkeTopic starter

  • Frequent Contributor
  • **
  • Posts: 258
  • Country: fr
  • F4WCO
Re: Anyone using OpenSCAD?
« Reply #2 on: February 05, 2024, 01:47:59 pm »
You might want to look at something I did in OpenSCAD. I defined a way to do cutaway using an arbitrary shape, not only a plane. I also made support for one layout for printing, and one for viewing the parts assembled.
Your cutaway idea is nice, I'll reuse that.  If you made the cutting plane location a parameter you would be able to adjust it from the previewer, no? For the layouts, I defined boolean parameters at the top for that reason, although I don't know when exactly OpenSCAD decides to re-render.

Quote
Bruno Levy at INRIA Nancy has recently been working on a new CSG library that has a front end to input OpenSCAD files. I suspect he would be open to improving the language to be more functional, or an alternative equivalent language.
Wow, Levy's Geogram stuff looks absolutely amazing.  I'll have to dig into it, at the very least his visualization works properly.
 

Offline abeyer

  • Frequent Contributor
  • **
  • Posts: 325
  • Country: us
Re: Anyone using OpenSCAD?
« Reply #3 on: February 05, 2024, 09:21:48 pm »
I don't know if there is any fork or variant, or another CAD package that allows a similar workflow (text entry) but is of a higher quality.  If wouldn't have to be free but needs to work well under Linux and a cost not exceeding three digits.

https://github.com/Irev-Dev/curated-code-cad
 

Offline SiliconWizard

  • Super Contributor
  • ***
  • Posts: 14863
  • Country: fr
Re: Anyone using OpenSCAD?
« Reply #4 on: March 03, 2024, 08:44:30 am »
Yes, I'm having a look at geogram as well. Interesting stuff to go beyond OpenSCAD.
 

Offline zapta

  • Super Contributor
  • ***
  • Posts: 6227
  • Country: us
Re: Anyone using OpenSCAD?
« Reply #5 on: June 29, 2024, 10:53:44 pm »
OpenSCAD makes difficult thing easy and easy things difficult. For example, applying fillet to specific edges is a nightmare.  I think that what it lakes is the ability to refer to object features such as faces, lines and corners.

I have used it for years but gave up and am now very happy with OnShape. Free, intuitive, platform independent, and cloud storage.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf