Hi Eric
I am increasingly having to produce DXF files of drawings of components for CNC cutting.
The parts that I draw are often quite complex shapes, consisting of polygons with hundreds of sides – like this:
CNC cutting can't cope with discontinuous path lines (gaps, crossovers, doubles etc). After I have drawn the component, I use ⌘J to join all the lines – sometimes takes several attempts, specially where a sharp corner has been cut with a radius fillet. Once all the lines join OK I turn the shape into a polygon using ⌥⌘P. Then I check using Action >> Length, area, center. If the polygon has an area (S=12345), then I know that at least there are no crossed lines. But if there is a gap, or if the sides of the polygon go past each other like this:
I get an area OK but don't always see that it's not a truly closed polygon. And when it comes to CNC cutting the component, the G-code will fail it.
My question:
Is it possible to provide an option (only an option - not a default) whereby I can select for, say, Action >> Length, area, center only to produce an area if the polygon is truly closed? Or produce an alert – "Polygon is not closed" – something like that?
I know it's a special case – but preparing drawings for CNC is becoming increasingly necessary (for me anyway)
Keep well and keep safe – increasingly difficult in this country at the moment ...
Cheers -- Goerge
A request
-
- Posts: 702
- Joined: Sat Dec 03, 2011 9:19 pm
- Location: Maine USA and Suffolk England
- Contact:
-
- Posts: 1073
- Joined: Sat Dec 03, 2011 12:31 pm
- Location: Tours - France
Re: A request
Eric Pousse
-
- Posts: 702
- Joined: Sat Dec 03, 2011 9:19 pm
- Location: Maine USA and Suffolk England
- Contact:
Re: A request
Absolutely Perfect.
Thank you very much indeed.
Still got a problem with my beamcamber script – see other post.
And the drawings seems much darker and bolder with b3 than with b2 – is that deliberate??
Cheers -- George
Thank you very much indeed.
Still got a problem with my beamcamber script – see other post.
And the drawings seems much darker and bolder with b3 than with b2 – is that deliberate??
Cheers -- George
-
- Posts: 1073
- Joined: Sat Dec 03, 2011 12:31 pm
- Location: Tours - France
Re: A request
A polygon is marked as closed if delta x and delta y between the first and the last point are <= 0.00001.
Eric Pousse
-
- Posts: 1073
- Joined: Sat Dec 03, 2011 12:31 pm
- Location: Tours - France
Re: A request
Yes George, I made some modifications to test the speed but I don't know if it is definitely or not...debenriver wrote: ↑Mon Nov 16, 2020 10:05 pm And the drawings seems much darker and bolder with b3 than with b2 – is that deliberate??
Eric Pousse