VTK  9.2.6
vtkSmoothPolyDataFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkSmoothPolyDataFilter.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
137 #ifndef vtkSmoothPolyDataFilter_h
138 #define vtkSmoothPolyDataFilter_h
139 
140 #include "vtkFiltersCoreModule.h" // For export macro
141 #include "vtkPolyDataAlgorithm.h"
142 #include <memory> // For std::unique_ptr<>
143 
144 class vtkSmoothPoints;
145 
146 class VTKFILTERSCORE_EXPORT vtkSmoothPolyDataFilter : public vtkPolyDataAlgorithm
147 {
148 public:
157 
159 
164  void PrintSelf(ostream& os, vtkIndent indent) override;
166 
168 
172  vtkSetClampMacro(Convergence, double, 0.0, 1.0);
173  vtkGetMacro(Convergence, double);
175 
177 
180  vtkSetClampMacro(NumberOfIterations, int, 0, VTK_INT_MAX);
181  vtkGetMacro(NumberOfIterations, int);
183 
185 
192  vtkSetMacro(RelaxationFactor, double);
193  vtkGetMacro(RelaxationFactor, double);
195 
197 
200  vtkSetMacro(FeatureEdgeSmoothing, vtkTypeBool);
201  vtkGetMacro(FeatureEdgeSmoothing, vtkTypeBool);
202  vtkBooleanMacro(FeatureEdgeSmoothing, vtkTypeBool);
204 
206 
209  vtkSetClampMacro(FeatureAngle, double, 0.0, 180.0);
210  vtkGetMacro(FeatureAngle, double);
212 
214 
218  vtkSetClampMacro(EdgeAngle, double, 0.0, 180.0);
219  vtkGetMacro(EdgeAngle, double);
221 
223 
226  vtkSetMacro(BoundarySmoothing, vtkTypeBool);
227  vtkGetMacro(BoundarySmoothing, vtkTypeBool);
228  vtkBooleanMacro(BoundarySmoothing, vtkTypeBool);
230 
232 
235  vtkSetMacro(GenerateErrorScalars, vtkTypeBool);
236  vtkGetMacro(GenerateErrorScalars, vtkTypeBool);
237  vtkBooleanMacro(GenerateErrorScalars, vtkTypeBool);
239 
241 
244  vtkSetMacro(GenerateErrorVectors, vtkTypeBool);
245  vtkGetMacro(GenerateErrorVectors, vtkTypeBool);
246  vtkBooleanMacro(GenerateErrorVectors, vtkTypeBool);
248 
250 
258 
260 
265  vtkSetMacro(OutputPointsPrecision, int);
266  vtkGetMacro(OutputPointsPrecision, int);
268 
269 protected:
271  ~vtkSmoothPolyDataFilter() override = default;
272 
275 
276  double Convergence;
280  double FeatureAngle;
281  double EdgeAngle;
286 
287  std::unique_ptr<vtkSmoothPoints> SmoothPoints;
288 
289 private:
291  void operator=(const vtkSmoothPolyDataFilter&) = delete;
292 };
293 
294 #endif
a simple class to control print indentation
Definition: vtkIndent.h:119
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:200
adjust point positions using Laplacian smoothing
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
std::unique_ptr< vtkSmoothPoints > SmoothPoints
static vtkSmoothPolyDataFilter * New()
Construct object with number of iterations 20; relaxation factor .01; feature edge smoothing turned o...
~vtkSmoothPolyDataFilter() override=default
void SetSourceData(vtkPolyData *source)
Specify the source object which is used to constrain smoothing.
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods to obtain type information, and print the state of a class instance.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
vtkPolyData * GetSource()
Specify the source object which is used to constrain smoothing.
@ info
Definition: vtkX3D.h:382
@ port
Definition: vtkX3D.h:453
int vtkTypeBool
Definition: vtkABI.h:69
boost::graph_traits< vtkGraph * >::vertex_descriptor source(boost::graph_traits< vtkGraph * >::edge_descriptor e, vtkGraph *)
#define VTK_INT_MAX
Definition: vtkType.h:155