Current best practices - Removing excess vertices from shapes

Current best practices - Removing excess vertices from shapes

christian_paulsen98V29
Enthusiast Enthusiast
390 Views
5 Replies
Message 1 of 6

Current best practices - Removing excess vertices from shapes

christian_paulsen98V29
Enthusiast
Enthusiast

Hello everyone, I wasn't sure if this would be best to put in this forum or the General autocad forum but this is where I ended up.

I'm sure we've all ran into scenarios where we have a shape (usually arcs or curves) that just has too many vertices. Sometimes times these arcs aren't really acts at all but instead are just hundreds or tiny straight lines all put together. I've recently been receiving files of shapes that were created in adobe illustrator and running into this issue a lot.

Which leads me to my question:

What are the current best practices everyone's been using to deal with these situations???

Personally I've used 3rd party programs such as signlab or some cnc softwares, but these can be expensive. I've also found some LISP files such as one called PLDiet (id credit the guy who created it but i don't remember his name) which seems to work good at reducing the amount of vertices but still does not give you a smooth edge. This LISP was created years ago though and is probably a bit outdated now. Then there's always the option of tracing or redrawing something but that can be time consuming and isn't always accurate.

Does anyone have any new lisps that work for this? Or maybe a AutoCAD extension, addon, or plugin? Any cheap and easy 3rd party softwares? I'm open to any and all ideas. My current process has been working but I'm sure someone out there smarter than me has an even better way or doing this.

0 Likes
391 Views
5 Replies
Replies (5)
Message 2 of 6

Sea-Haven
Mentor
Mentor

Pretty sure there is a convert facets to an arc, this is the opposite of convert an arc into straights. You need the straights to all have the same length for it to work. It looks at the change in angle and length being consistent.  Not something I have.

0 Likes
Message 3 of 6

Kent1Cooper
Consultant
Consultant

I'm the author of PLDiet.lsp.  Yes, it's pretty old now, but still does what it was intended to do, which unfortunately does not involve creating curves, only removal of vertices.  @Sea-Haven's idea is something that I have code to do for the very limited condition of turning a regular polygon into a Circle.  [What it looks at includes the edges being of equal length, but instead of comparing changes of angle, it checks that all vertices are the same distance from the center].  I don't imagine that's very often the situation you have.

 

You might try using PLDiet, perhaps multiple times, to get a kinkified reduction, and then using PEDIT's Fit or Spline option to get real curvature.  Which of those options works best probably depends on how convoluted the original shape is, and whether you need the result to actually pass through vertex locations.  It's probably worth experimenting.

Kent Cooper, AIA
0 Likes
Message 4 of 6

komondormrex
Mentor
Mentor

@christian_paulsen98V29 

hey there,

could you post an example of such a shape to evaluate best practice?

0 Likes
Message 5 of 6

Sea-Haven
Mentor
Mentor

Here is one to have a play with an arc now facets.

 

Yes need a sample dwg.

0 Likes
Message 6 of 6

david.waight
Contributor
Contributor

Attached is a routine by Marko Ribar, which is pretty close to doing what you require.

 

I have yet to find anything free (for Autocad) which works any better.

 

There is a commercial program (works within Autocad) called Curvefit which seems to do what you are looking for.

https://tcicorp.com/curvefit/

0 Likes