OpenSCAD the Programmers Solid 3D CAD Modeller

openscad.org

64 points by b-man 4 days ago


erjiang - 3 hours ago

Be aware that the way OpenSCAD works (CSG) makes a lot of things difficult compared to "normal" CAD programs. A lot of common operations, such as arbitrary fillets on various edges, are simply hard to express or do.

The more powerful option is something built on the open-source Open Cascade geometry kernel: FreeCAD, cadquery, or build123d. This also gives you interop with the broader CAD ecosystem by enabling you to import and export STEP files. (Your favorite LLM can advise you on or drive these options as well.)

YuechenLi - 3 hours ago

Oh, since this came up, for people who like code CAD and want to try something more powerful than OpenSCAD:

https://github.com/yuechen-li-dev/Aetheris/

Not an OpenCascade wrapper, it's based off my own experimental BREP geometry kernel. So, fillets/chamfers work, booleans works fairly robustly, surfacing, sheet metal, etc all works decently, it exports STEP AP242 by default.

Haven't had time to get the AIs to write a more up to date documentation and polish the language server. Not the easiest thing to use right now, so, using it through Codex/Claude Code or CLI is probably the easiest way to get started.

Still working on the webUI currently, in case someone want to DIY the UI. Note that the WASM compilation path is still unoptimized and way slower than the RyuJIT C# compilation though.

https://github.com/yuechen-li-dev/helioscad

jacquesm - 3 hours ago

The one you want is the experimental build, it is way faster to the point that 'preview mode' should be disabled. I use OpenSCAD a lot, it ties right into my workflow and plays nice with versioning and re-using modules from one project to another. Over time I've built up a nice library of parts that I can quickly customize for whatever it is that I'm building. Latest project: pick-and-place machine modification for Prusa MK3 3D printers (an interesting challenge, to put it mildly), now working on some robotics stuff.

The most important thing about OpenSCAD for programmers to remember is that it looks as if you are programming but really you are describing geometry and objects so things like variables and such do not quite work in the way you would expect from a programmers point of view.

timonoko - 3 minutes ago

For these eternal Fillet-Whiners: Antigravity made simple Blender-tool that rounds all edges in STL-file. Sharp edges never look good in print and avoiding them feels often like too much extra work.

https://github.com/timonoko/OpenSCAD-rounding-in-Blender

jeffbarr - 2 hours ago

I have been using OpenSCAD to create cool geometric designs for 3D printing on fabric, with great results. The functional model is likely unfamiliar to most developers, but I have found that I can be efficient and productive with it.

Check out my repos of OpenSCAD objects at https://github.com/jeffbarr/OpenSCADObjects and Truchet Tilings at https://github.com/jeffbarr/TruchetTilings .

My code kind of looks like the C that I wrote in the 1980s, with lots of braces and careful indenting -- not sure if that is a bug or a feature.

As another commenter noted, use the latest nightly build for best results.

stateoff - an hour ago

I tried OpenSCAD but it ends up being too abstract and hard to maintain for me and like others it does not solve fillets/procedural selection well.

So here is my shameless plug "sograph": https://imgur.com/a/u1n2Grg

I should consider a Show HN instead, but it is too early to release yet.

maouida - an hour ago

Shamelss plug:

I have built FluidCAD[1] to overcome the issues of CAD by code, less mental effort to design by providing visual guidance. Slowly it became more of a hybrid CAD experience (mouse or code driven), almost all features now can be done by mouse and the code is generated for you. It'll pick the right selection filters for you.

https://github.com/Fluid-CAD/FluidCAD

https://fluidcad.io/

WillAdams - 3 hours ago

One of my favourite tools.

As noted, use the Nightly builds from: https://openscad.org/downloads.html#snapshots

When working with kids, it's well worth keeping: https://www.blockscad3d.com/editor/ in mind, or for folks who like to draw connections: https://github.com/derkork/openscad-graph-editor

Eventually, someone will note that its programming model limits variables and so forth --- for folks who want a more traditional language choice there are a number of options, notably for Python:

https://pythonscad.org/

tylermarques - 2 hours ago

I've been using Opus 5.5 to write openscad models for me for the past week, with great success. I wanted to expand the project Open Source Watch Winder [0] to have 8 watches, with gears instead of pulleys, and in little back and forth I have a version I've started printing. [1]

[0] https://github.com/mwood77/osww [1] https://imgur.com/a/bWent0K

TGower - 4 hours ago

It would be interesting to see a head to head comparison of frontier LLMs building models with OpenSCAD, Blender scripting, and Fusion MCP. My intuition would be that blender winds up the best for the immediate result due to training data prevalence and RL tuning, but the concise nature of OpenSCAD could help.

I'll have to add this to my backlog of experiments to try when I have unused tokens near a reset...

dvh - 3 hours ago

I use openscad for all my kicad 3d models via scad->off->obj->(manually edit in mm3d to add colors)->wrl->kicad

It's not as bad as it looks, it's all automatic except adding colors which takes about 2 minutes.

looofooo0 - 3 hours ago

Yes, also have a look at build123d which has a vscode plugin.

RobotToaster - 3 hours ago

Note that the current release version is very old, I strongly recommend downloading the nightly version and turning on the manifold geometry solver in settings as it's much faster.

bee_rider - 2 hours ago

How does OpenSCAD type stuff play with simulation, in general. (If at all?)

I’m thinking of something like finite element analysis… but, I guess since the shapes in OpenSCAD are defined through this constructive geometry system, can things be better/more mathematically defined general purpose “discretize the PDEs over my mesh” type solutions?

matthova - 3 hours ago

I love OpenSCAD. Have been a power user for years. It's so great asking LLMs to make 3d models in openscad.

I made a rust-implementation of openscad called openrscad (https://openrscad.com). It still has some rough edges, but runs quite fast both on desktop and in the browser

joewalnes - 3 hours ago

Wrote a tutorial:

https://github.com/joewalnes/toybrick

LLMs are excellent at building OpenSCAD models. The tutorial (written in the before-times) will help understanding of the key concepts of OpenSCAD: primitives, transformations, and constructive solid geometry.

aeonik - 2 hours ago

BOSL2 library combined with LLMs really make me fly with my creations.

kennywinker - 3 hours ago

If you want openscad without the abomination that is the openscad language - check out jscad

TacticalCoder - 3 hours ago

OpenSCAD is amazing for those who know nothing about 3D but know about programming.

I bought a 3D printer (which is basically simpler and more reliable than a 2D inkjet printer by now: it's send the file, put the filament, and 3D print and it just works) recently and already fixed shitload of stuff around the house with 3D printed parts.

I even did "print in place" pieces where you add a pause a a certain layer, insert "stuff" (like say a 3D metal angle) into your print, then finish your print. Effectively creating parts that are both plastic and metal.

Now the language itself in OpenSCAD is kinda really bad: you can define variables inside of other functions and then use them everywhere. You can redefine already defined variables and you'll get zero warning. The language itself is really pretty WTF.

But you get modelling for free as a programmer. And LLMs are okay'ish at it for simple stuff.

I'd recommend people to use the BOSL2 library for OpenSCAD:

https://github.com/BelfrySCAD/BOSL2/wiki

It's really not hard.

If you love programming and like to DIY stuff around the house, buying a 3D printer and learning some OpenSCAD is a no-brainer.

OpenSCAD ain't the only option: many people like Fusion (for example). But as I'm a dev, OpenSCAD just feels natural to me.

pdntspa - 4 hours ago

The nightly builds for this are so much better. When are they going to merge the nightlies into a new mainline release? The last one showing 2021 isn't the best look...

asmodeuslucifer - 3 hours ago

I barely know openscad (used Fusion 360 before autodesk enshitified it) but gemini is very good at creating code I can paste into openscad.

ramses0 - an hour ago

[dead]