|
|
|
|
|
by phkahler
1973 days ago
|
|
>> My own cad is still far from working, probably because I had the brilliant idea to start my own csg kernel. SolveSpace maintainer here. After fixing a number of things in the SS Nurbs kernel, I've added "do this over in Rust" to my bucket list. It may never happen, but if you want to talk algorithms or strategy drop me an email. Same ID at gmail. AFAICT there is currently no other Free Software for trimmed NURBS other than Cascade and SolveSpace. |
|
I did start it in luajit first, because I thought that it will be a faster feedback loop. I created an OpenGL window, and set up nodemon to restart the luajit app on changes. It is quite fast, but still not as smooth as I imagined it. Doing it Rust from the start, with a TDD approach, might have been a better idea. Things got quite messy quite quickly because of the luajit OpenGL bindings.
The goal is to do difference, addition, intersection first between basic 3d volumes: sphere, cuboids, cylinders. And then yes, some extruded splines. I was thinking about starting with beziers, as this is the only spline I've implement before.
I haven't built a cad before, so I went with a data oriented approach, defined the data needed to represent each of the basic volumes, and 2d shapes, as well as the relationships(diff, union, intersection). Something like a normalized SQL database. A table (array), for positions, rotations, bounding boxes and so on. I'm yet to see how well this scales up to more complex models.
It is very much in the beginning. I've started from first principles, not looking up existing approaches and see what I can come up with. That's the reason it probably won't become something serious, but it's still fun to explore.
Thank you for offering help, might have a closer look at SolveSpace if I get to something serious that I cannot come up with a solution on my own.