Skip to content
Snippets Groups Projects

Add strategy pattern for polyline decimation implementation.

Closed Loïc Gaillard requested to merge loic.gaillard/vtk:decimate-strategy-refactor into master

Externalize the way the error is computed by the filter so it can make use of different strategies. The current one used Eulerian distances, it has been externalised into its own vtkDecimatePolylineDistanceStrategy.

2 new strategies have also been added :

  • A strategy based on the angle betweeen three vertices vtkDecimateAngleStrategy. It uses the cos instead of the angle in term of implementation.
  • A strategy based on custom values provided by the user and attached to each vertices vtkDecimateCustomFieldStrategy. It uses an array in the PointData and performs a component to component distance computation (Could be generalized later by adding a custom metric logic).

Also brings support to distributed data by adding a ghost level.

Edited by Loïc Gaillard

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
Please register or sign in to reply
Loading