Open mbedward opened 11 years ago
From michael.bedward@gmail.com on October 05, 2012 02:55:41 The new parameter will have a default value (e.g. 0.001 = 0.1% of largest contour envelope diagonal)
Setting the parameter to zero will give the same algorithm as present, ie. just remove co-linear vertices.
From michael.bedward@gmail.com on October 06, 2012 08:43:16 Looks like it might be best to move the simplification step out of the Segments class and do it in the OpImage class instead. That way we can also put it after any Bezier smoothing.
Original author: michael.bedward@gmail.com (October 05, 2012 00:58:57)
At the moment, the Contour operation simplifies contours by removing co-linear vertices. Martin Davis points out that this is overly conservative and that in many cases more vertices could be removed with very little effect on contour path.
Replace the current simplification step with use of the JTS DouglasPeuckerSimplifier and add an extra parameter to ContourDescriptor for the degree of simplification. This parameter value will be treated as follows:
Later, we might investigate using an alternative, faster simplifying algorithm.
Original issue: http://code.google.com/p/jaitools/issues/detail?id=207