vtkDecimatePolylineFilter completely broken
This issue was created automatically from an original Mantis Issue. Further discussion may take place here.
The current vtkDecimatePolylineFilter does not work. There was a bug report in 4 Dec 2010 via email from donnyz, here: http://public.kitware.com/pipermail/vtkusers/2010-December.txt
This patch fixes the described problem, but was not applied.
Instead, in commit d35b305e Arnaud Gelas worked on improving the decimation filter to update the Error measure as points were popped from the priority queue. A test was added too.
Unfortunately, that patch completely fails when there is more than one polyline, and the test only covers a single polyline case.
There are 2 problems:
-
The filter will only generate one polyline - it joins all of the lines up in the order they appear in the cell array.
-
There is a "Closed" variable which is always fixed to TRUE, and this will always add a final line-point to the cell array, pointing back to the zero vertex, thereby joining the last polyline back onto the first polyline.
So, as it stands, this filter cannot be used for decimating anything except a single open polyline that should be closed.