I need to create 2D drawings of cabinets parts for CNC milling. I do this “manually”, by making a 2D drawing of the 3D part, and then adjusting its curves into different layers, which will be used for g-coding later.
It takes a lot of time and I’d like to automate this process. Do you have an idea of how to do it or even know a script?
The cutout is not gonna be that hard. You can sort the surfaces of the polysurface by area and then extract the edges of that surface. Then you need to find a way to check which curves are inside other curves.
Finding the pockets with matching depth shouldn’t be that hard but the tricky thing might be to come up with a logic that knows in which direction to increase the curves for the pocket, when it’s overlapping on the edge.
This will take a few hrs (while i’m not a work) so it might get pushed to the weekend. I made good progress last night was on a pos laptop and it crashed, with work that will need to be recreated for explanatory purposes.
Why do 7 and 10 mm pockets get put on the 8 mm pocket layer? Doesn’t make sense to try and automate converting your polysurfaces to curves if your polysurfaces are drawn wrong.
Still needs work; remove duplicate lines, sort-define mill pockets etc, this would be done on the branch level most likely – due to various requirements of the parts. The idea being you can create your own workflow from the various parts of this workflow.