VTK  9.3.0
vtkDecimatePolylineFilter.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
44 #ifndef vtkDecimatePolylineFilter_h
45 #define vtkDecimatePolylineFilter_h
46 
47 #include "vtkFiltersCoreModule.h" // For export macro
48 #include "vtkSmartPointer.h" // Needed for SP ivars
49 
50 #include "vtkPolyDataAlgorithm.h"
51 
52 VTK_ABI_NAMESPACE_BEGIN
53 class vtkPriorityQueue;
54 
55 class VTKFILTERSCORE_EXPORT vtkDecimatePolylineFilter : public vtkPolyDataAlgorithm
56 {
57 public:
59 
63  void PrintSelf(ostream& os, vtkIndent indent) override;
65 
70 
72 
77  vtkSetClampMacro(TargetReduction, double, 0.0, 1.0);
78  vtkGetMacro(TargetReduction, double);
80 
82 
88  vtkSetClampMacro(MaximumError, double, 0.0, VTK_DOUBLE_MAX);
89  vtkGetMacro(MaximumError, double);
91 
93 
98  vtkSetMacro(OutputPointsPrecision, int);
99  vtkGetMacro(OutputPointsPrecision, int);
101 
102 protected:
105 
107 
108  class Polyline;
109  double ComputeError(vtkPolyData* input, Polyline* polyline, vtkIdType id);
110 
113  double MaximumError;
115 
116 private:
118  void operator=(const vtkDecimatePolylineFilter&) = delete;
119 };
120 
121 VTK_ABI_NAMESPACE_END
122 #endif
reduce the number of lines in a polyline
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
~vtkDecimatePolylineFilter() override
static vtkDecimatePolylineFilter * New()
Instantiate this object with a target reduction of 0.90.
double ComputeError(vtkPolyData *input, Polyline *polyline, vtkIdType id)
vtkSmartPointer< vtkPriorityQueue > PriorityQueue
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for type information and printing.
a simple class to control print indentation
Definition: vtkIndent.h:38
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce only polydata as output.
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:89
a list of ids arranged in priority order
int vtkIdType
Definition: vtkType.h:315
#define VTK_DOUBLE_MAX
Definition: vtkType.h:154