VTK  9.6.1
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
37
38#ifndef vtkDecimatePolylineFilter_h
39#define vtkDecimatePolylineFilter_h
40
41#include "vtkDecimatePolylineDistanceStrategy.h" // Default decimation strategy
42#include "vtkFiltersCoreModule.h" // For export macro
43#include "vtkSmartPointer.h" // Needed for SP ivars
44#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
45
47
48VTK_ABI_NAMESPACE_BEGIN
50
52{
53public:
55
60 void PrintSelf(ostream& os, vtkIndent indent) override;
62
64
70 vtkSetClampMacro(TargetReduction, double, 0.0, 1.0);
71 vtkGetMacro(TargetReduction, double);
73
75
82 vtkSetClampMacro(MaximumError, double, 0.0, VTK_DOUBLE_MAX);
83 vtkGetMacro(MaximumError, double);
85
87
93 vtkSetMacro(OutputPointsPrecision, int);
94 vtkGetMacro(OutputPointsPrecision, int);
96
98
103 vtkSetMacro(DecimationStrategy, vtkDecimatePolylineStrategy*);
104 vtkGetObjectMacro(DecimationStrategy, vtkDecimatePolylineStrategy);
106
107 /*
108 * Inherits from vtkObject GetMTime() but also checks for the DecimationStrategy
109 * member MTime.
110 * @return The last time the state of the DecimatePolylineFilter got modified.
111 */
113
114protected:
117
119 int RequestUpdateExtent(vtkInformation* vtkNotUsed(request), vtkInformationVector** inputVector,
120 vtkInformationVector* outputVector) override;
121
122 class Polyline;
123 double ComputeError(vtkPolyData* input, Polyline* polyline, vtkIdType id);
124
126 double TargetReduction = 0.90;
129
130private:
132 void operator=(const vtkDecimatePolylineFilter&) = delete;
133
136};
137
138VTK_ABI_NAMESPACE_END
139#endif
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
~vtkDecimatePolylineFilter() override
static vtkDecimatePolylineFilter * New()
Standard methods for type information and printing.
vtkMTimeType GetMTime() override
Return this object's modified time.
vtkNew< vtkPriorityQueue > PriorityQueue
int RequestUpdateExtent(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
This is called by the superclass.
double ComputeError(vtkPolyData *input, Polyline *polyline, vtkIdType id)
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for type information and printing.
abstract class to define a decimation strategy for the vtkDecimatePolylineFilter
a simple class to control print indentation
Definition vtkIndent.h:29
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Allocate and hold a VTK object.
Definition vtkNew.h:58
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition vtkPolyData.h:72
a list of ids arranged in priority order
Hold a reference to a vtkObjectBase instance.
static vtkSmartPointer< T > New()
Create an instance of a VTK object.
int vtkIdType
Definition vtkType.h:368
vtkTypeUInt32 vtkMTimeType
Definition vtkType.h:323
#define VTK_DOUBLE_MAX
Definition vtkType.h:207
#define VTK_MARSHALAUTO