Piercing / Preserving the vertex order

Hi @easytarget.
As you may have seen I just submitted a PR to your branch. It’s a simple mod that adds another laser cutting option where the imported vertex order from a path are preserved. Originally the mergePath function was trying to figure out if the path vertex order had to be reversed or not to optimize the tool path. This conflicts with the need for piercing certain material. In my case, I need the laser to always “drill” or “pierce” the material before starting the path cutting. At the piercing location, there’s a bit of surrounding damage of about 2-3mm diameter. What I do is I add a simple line or arc before the cutting path starts. That line can be inside if the inside part is to be scrapped or outside if the inside part is to be kept. If mergePath is left as it was originally, it would at times keep the vertex order, and at other times start at the end of the path, defeating my little trick. With this PR someone can select whether or not they want the cutting path optimized (original Laser Cut with mergePath) or not by keeping the imported vertex order.


I may have made a small mistake. I didn’t check the diagram, so for now it shows blank. Not sure why yet.

Okidoki, let us know what you find…

I like this in principle, as noted in the PR I’ll look at it once I’ve merged this.

Ok I’ve found the typo. What’s the best way to do this? Cancel the previous PR and reissue a new one?

If you push extra commits to your fork+branch they will be added to the PR. The PR is for the whole branch :wink:

Use the comments in the PR to explain what you did if needed…