5 ms·
So I've looked at potentially working with OpenSCAD before, but unfortunately had to go back to something like Autodesk Inventor before really starting. The big
by pwnna 12y ago
So I've looked at potentially working with OpenSCAD before, but unfortunately had to go back to something like Autodesk Inventor before really starting. The biggest problem I have with all open source 3D CAD systems are the lack of parametric modeling.
If you're unfamiliar with this, this basically is setting constraints on your geometry. For example, you can say that edge A has the same length as edge B, and it mirrors across plane C, which is 10 cm away from the primary XY plane.
This is essential to my workflow in 3D modeling and makes most geometry based operations (such as specifying that edge A is 10cm and starts at 3,4) obsolete. It also allows easy assemblies: you can specify the axis of shaft A need to be coincidental with the axis of hole B.
Plain text based 3D modelling would be awesome as you can use reasonable revision controls and have reasonable merge strategies.. but the lack of parametric modelling, at least for me, is a deal breaker. I've looked into writing a library for parametric modelling in Python, but then I realized that you probably need to be a PhD in geometry to write a correct implementation with reasonable speed....
- kanzure 12y ago> I've looked into writing a library for parametric modelling in Python, but then I realized that you probably need to be a PhD in geometry to write a correct implementation with reasonable speed.... Well, here's a video of sympy + OpenCASCADE for parametric modeling: https://www.youtube.com/watch?v=ZUCv7COgzU0&t=25s https://www.youtube.com/watch?v=ZUCv7COgzU0&t=25s but see also my other comment for my thoughts regarding OpenCASCADE..
- kaoD 12y ago> The biggest problem I have with all open source 3D CAD systems are the lack of parametric modeling. I remember doing that in FreeCAD. Maybe I didn't get all the intrincacies and you mean something bigger than what I tried, but there was definitely a constraint system. EDIT: Found a video https://www.youtube.com/watch?v=qY_GGTa9-mU https://www.youtube.com/watch?v=qY_GGTa9-mU Is this what you mean?
- pwnna 12y agoAFAIK FreeCAD has a 2D constraint system. I need a 3D one to really work efficiently.
- monochr 12y agohttp://www.freecadweb.org/wiki/index.php?title=Basic_Part_Design_Tutorial http://www.freecadweb.org/wiki/index.php?title=Basic_Part_De... The above looks pretty 3d to me.
- m4x 12y agoThat part is constructed using a series of 2D sketches with 2D constraints. It is still difficult to create complex assemblies in FreeCAD with 3D constraints between parts (such as aligning two faces of different parts or constraining different parts to the same axis) An assembly module is being developed which addresses this problem, but it's a recent addition and still has some limitations FreeCAD is a very good piece of software none the less
- wtallis 12y agoSame here. I'm stuck with SolidWorks and thus Windows. My workflow involves running the output of the CAD program through a simulation and using that to optimize the parameters of the CAD model, relying on the various geometry constraints being solved by the CAD program. SolidWorks is great for modeling the devices in a parametrized fashion, but it really isn't meant to be scriptable.
- FredDollen 12y agoSolidWorks has a powerful API that allows you to script almost all aspects of the program: http://help.solidworks.com/2014/English/api/sldworksapiprogguide/Welcome.htm http://help.solidworks.com/2014/English/api/sldworksapiprogg...
- wtallis 12y agoAnd yet it still manages to be the ugliest kludge in my workflow. Just getting it to rebuild and reexport an updated model requires at least a full minute of it popping up windows all over the place—one each for every part, assembly, and spreadsheet holding the parameters—and I have to structure the rest of my code around the limitation that I can only have one SolidWorks instance running at a time while everything else is highly parallel. There's a problem when the CAD program is a noticeable bottleneck in a process that also runs multi-GB FEM simulations.
- kanzure 12y ago> Just getting it to rebuild and reexport an updated model requires at least a full minute of it popping up windows all over the place Huh, are you sure Solidworks has to be running for that workflow? Can't you just load the DLL?
- wtallis 12y agoI'm not sure; I didn't write that component and I don't think it's been rewritten in probably a decade, just linked against newer versions of SolidWorks. It's ugly but it works, so we only start looking at the internals of SolidWorks when they introduce a new bug that affects us, which hasn't happened in several years. I'm not optimistic, though. Even in normal interactive use, SolidWorks cannot manage to read updated values from a linked Excel spreadsheet upon opening a part (or writing while saving the part) without the embedded Excel window flashing up briefly. Getting SolidWorks and it's Excel child process to both stay in the background isn't really worth much effort to us at the moment, and I do occasionally get the benefit of spotting something breaking when the model flashes up on screen, instead of discovering it much later. It's really something that shouldn't even require COM/OLE style stuff, just some basic command line functionality. But why would a Windows-only app support that method of interaction?
- jakeogh 12y agoBRLCAD is working on a constraint solver: http://brlcad.org/wiki/Geometric_Constraint_Solver http://brlcad.org/wiki/Geometric_Constraint_Solver
- mkeeter 12y agoI've been doing some work on this -- not a full-on parametric solver, but setting a directed acyclic graph of relationships then evaluating the graph to produce a set of solid models. The tool is being beta-tested in fab academy [1] this semester; shoot me an email (in my profile) if you're interested in learning more. [1] http://www.fabacademy.org/ http://www.fabacademy.org/
- colah3 12y agoAuthor of ImplicitCAD here. I completely agree. At first, I tried to implement constraints in a Haskell DSL. Unfortunately, constraints usually only partially describe your object. Even a well-constrained object can be flipped and maintain the constraints, in most systems. I coudln't find a reasonable way to implement a text-based interface for this. It really needs to be graphical. I abandoned ImplicitCAD to write a constraint-based CAD program with my friend Rob Gilson. (I handled constraint solving with gradient descent, which worked surprisingly well, and a dab of grobner bases here and there.) We got some neat stuff working, but eventually got pulled away to other projects. I think there's a lot of interesting work to be done linking programmatic and graphical CAD. In particular, I think there's neat connections between constraint based CAD which is a form of visual logic programming, and functional programming. (Aside: I like Bret Victor's talk "Stop Drawing Dead Fish" which is on a kind of related topic.) Unfortunately, I'm too busy with ML research these days to work on this stuff!
- ObviousScience 12y agoI've had an interest in constraint-based CAD programs (with an interest in designing things for 3D printers), and was wondering if you could recommend any literature on the subject.
- colah3 12y agoSadly, I never did a serious literature review. That said, I naively tried a bunch of naive approaches and had quite a bit of success with plain old gradient descent -- it was really surprising. I'm not sure if it would scale to really significant models, but it's something you could implement in a few hours and you could use to get a project off the ground.
- colah3 12y agoFor the algebraic geometry side, though, *Ideals, Varieties and Algorithms" by Cox, Little and O'Shea is great.
- toong 12y ago
- leoedin 12y agoThere's an absolutely fantastic open source 3D CAD program called SolveSpace (http://solvespace.com/index.pl http://solvespace.com/index.pl) For some reason it's barely known about, which is a shame. It's truly fantastic - once you understand the UI it's almost as powerful as SolidWorks or other commercial parametric CAD systems (for smaller tasks anyway - once you get larger and more complex models it starts to struggle).