# RamerDouglasPeucker

**function** RamerDouglasPeucker(**const** path: TArrayOfPointD; epsilon: double): TArrayOfPointD; **overload;**

**function** RamerDouglasPeucker(**const** path: TArrayOfArrayOfPointD; epsilon: double): TArrayOfArrayOfPointD; **overload;**

A line simplification algorithm that removes extraneous vertices.

The algorithm recursively finds the vertex between line endpoints that's furthest from the virtual segment joining these endpoints, If this vertex is within 'epsilon' distance, then all vertices between endpoints will be removed. Otherwise the line is divided into two at this vertex and the process is repeated. See **Wikipedia**

Simplification is especially useful when vectorizing raster images and this function is demonstrated in the **VectorizeImage** example.

## See Also

Vectorize, SmoothLine

Copyright ©2019 Angus Johnson - Image32 ver. 1.44 - Documentation last updated on 1-March-2020