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 a predefined (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.
Copyright ©2019 Angus Johnson - Image32 ver. 1.46 - Documentation last updated on 17-April-2020