# Remove collinear points from polyline

**URL:** https://discourse.vtk.org/t/remove-collinear-points-from-polyline/1282
**Category:** Support
**Created:** [July 5, 2019, 1:04pm UTC](https://discourse.vtk.org/t/remove-collinear-points-from-polyline/1282 "2019-07-05T13:04:46Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![lplavorante](https://discourse.vtk.org/user_avatar/discourse.vtk.org/lplavorante/32/272_2.png) [@lplavorante](https://discourse.vtk.org/u/lplavorante)
#### Post date: [July 5, 2019, 1:04pm UTC](https://discourse.vtk.org/t/remove-collinear-points-from-polyline/1282/1 "2019-07-05T13:04:46Z")

</div>

Greetings!

Does VTK provide a filter to remove collinear points from a polyline (stored as vtkPolyData)? Basically, my polylines contain contiguous collinear segments and I need to replace each such group with a single segment.  
I tried using vtkDecimatepolylineFilter with standard parameters, but the number of points increased.

Thank you in advance for any help.

```
  Luca Pallozzi Lavorante
```
