3 ms·
OpenSCAD is all triangles and vertices. Fillets are difficult to do. Outputting circles/spheres generally requires you to for-loop over vertices a lot. Librari
by gcr 6mo ago
OpenSCAD is all triangles and vertices. Fillets are difficult to do. Outputting circles/spheres generally requires you to for-loop over vertices a lot.
Libraries like build123d and cadquery use OpenCASCADE, a boundary representation kernel. You think in terms of the enclosed solid and perform operations - boolean add/subtract, fillet/chamfer, stamp text, etc - that return a new solid.
- 7bees 6mo agoI'm not sure I understand your comment; OpenSCAD has functions like sphere(), cylinder(), etc. Most OpenSCAD models I have seen are built up primarily from solid primitives combined using boolean operations, just as you describe for the other tools. https://en.wikibooks.org/w/index.php?title=OpenSCAD_User_Manual/Primitive_Solids&stable=1 https://en.wikibooks.org/w/index.php?title=OpenSCAD_User_Man...
- seltzered_ 6mo agoTheres a better description of the differences here: https://build123d.readthedocs.io/en/latest/OpenSCAD.html#transitioning-from-openscad https://build123d.readthedocs.io/en/latest/OpenSCAD.html#tra... Some of the differences may be in when you are trying to reference a face/edge to build off of, not just about the primitive function being used.
- Doxin 6mo agoOpenSCAD works natively with triangle meshes. sphere() will create a spherical triangle mesh. These libraries on the other hand can natively represent a sphere for instance. This means that during CAD-ing you don't need to worry about resolution, that's a consideration for export only.
- flowerbreeze 6mo agoDo you mean that OpenScad performs boolean/other operations on triangle meshes, but these libraries don't until output? So they might instead use curved surfaces/edges etc as outputs for operations and only convert to triangles for output or export at the very end?
- Doxin 6mo agoyes, exactly.
- Karliss 6mo agoIt isn't even necessary to create triangle meshes during export. You can export as step files. It is a commonly used brep based file format supported by almost any "proper" CAD software. Triangle mesh based modelers can't easily export good step files because they don't operate at that level of abstraction.
- rowanG077 6mo agoIn professional CAD systems, geometry is not stored as triangle meshes but as mathematically defined surfaces (such as parametric and NURBS surfaces). Triangle meshes are only generated as approximations for rendering. This is analogous to vector graphics (SVG/EPS) versus raster images (PNG/JPG). Any serious manufacturing will work require a STEP (or something equivalent) which stores these parametric surfaces rather than a mesh.
- ur-whale 6mo ago> I'm not sure I understand your comment Try to do the following with OpenSCAD: 1. put a sphere and a torus somewhat close to each other 2. find the shortest segment between the two surfaces 3. place an infinite cylinder whose axis is aligned with the segment you just found 4. fillet the cylinder with both the torus and the sphere along its intersection curve with each surface This is very, very hard to do with OpenSCAD.
- somat 6mo agoWhile true your argument is weak, for example in pov-ray the shapes are pure exact mathematical concepts. But nobody is saying how great this is for 3d printing or general cad work because it's not. The real key benefit from these programs is the interchange format they can generate, something you can feed to a machine, this prevents it from ending up like pov-ray, a terminal process only fit for generating pictures. Fillets are difficult to do in openscsd because fillets are difficult to do in general. What your argument probably should have been is that if openscad had chosen a geometry kernel where fillets were already solved it could then do fillets. Which is the sort of obvious tautology that helps no one. Now I am off to see if anyone has ever built an export plugin for pov-sdl, either a 3d rasterizer(g-code slicer) for 3d printing, or a boundary layer mesh generator for import into another program. language wise it is probably equivalent to or better than the openscad sdl, One subtle advantage to using python as the sdl is that it gets access to the vast corpus of python modules out there. Most of which are probably useless. but one thing I want to try is to see if I can use sympy to define a more declarative style of constraint.
- Cargo4286 6mo agoNot perfectly relevant but build123d docs have an example using sympy as part of solving constraints for a design. https://build123d.readthedocs.io/en/latest/tttt.html#t-24-curved-support https://build123d.readthedocs.io/en/latest/tttt.html#t-24-cu...