VTK  9.7.1
vtkTransformFilter.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
32 #ifndef vtkTransformFilter_h
33 #define vtkTransformFilter_h
34 
35 #include "vtkFiltersGeneralModule.h" // For export macro
36 #include "vtkPointSetAlgorithm.h"
37 
38 VTK_ABI_NAMESPACE_BEGIN
40 class vtkDataSet;
42 
43 class VTKFILTERSGENERAL_EXPORT vtkTransformFilter : public vtkPointSetAlgorithm
44 {
45 public:
47 
51  static vtkTransformFilter* New();
53  void PrintSelf(ostream& os, vtkIndent indent) override;
55 
59  vtkMTimeType GetMTime() override;
60 
62 
65  virtual void SetTransform(vtkAbstractTransform*);
66  vtkGetObjectMacro(Transform, vtkAbstractTransform);
68 
70 
75  vtkSetMacro(OutputPointsPrecision, int);
76  vtkGetMacro(OutputPointsPrecision, int);
78 
80 
86  vtkSetMacro(TransformAllInputVectors, bool);
87  vtkGetMacro(TransformAllInputVectors, bool);
88  vtkBooleanMacro(TransformAllInputVectors, bool);
90 
91 protected:
93  ~vtkTransformFilter() override;
94 
98  int RequestDataObject(vtkInformation* request, vtkInformationVector** inputVector,
99  vtkInformationVector* outputVector) override;
100 
105 
111  int FillInputPortInformation(int port, vtkInformation* info) override;
112 
117 
122  vtkDataArray* CreateNewDataArray(vtkDataArray* input = nullptr);
123 
127 
128 private:
129  vtkTransformFilter(const vtkTransformFilter&) = delete;
130  void operator=(const vtkTransformFilter&) = delete;
131 
137  vtkDataSet* CreateNewDataSetIfNeeded(vtkDataSet* input, vtkDataSet* output);
138 
142 
147  bool ExecuteDataSet(vtkDataSet* input, vtkPointSet* output, bool useCachedGeometry);
151  vtkSmartPointer<vtkPointSet> ConvertInput(vtkDataSet* input);
156  void InitializeOutputPointSet(vtkPointSet* input, vtkPointSet* output);
160  void TransformPointData(vtkPointSet* input, vtkPointSet* output, bool preservePoints);
164  void TransformCellData(vtkPointSet* input, vtkPointSet* output);
168  vtkDataArray* CreateFromArray(vtkDataArray* input);
170 
172 };
173 
174 VTK_ABI_NAMESPACE_END
175 #endif
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
Store vtkAlgorithm input/output information.
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:318
virtual int RequestDataObject(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:56
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for instantiation, obtaining type information, and printing instances of the class...
concrete class for storing a set of points
Definition: vtkPointSet.h:58
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
int FillOutputPortInformation(int port, vtkInformation *info) override
Fill the output port information objects for this algorithm.
a simple class to control print indentation
Definition: vtkIndent.h:28
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:44
superclass for all geometric transformations
virtual vtkMTimeType GetMTime()
Return this object's modified time.
Superclass for algorithms that process vtkPointSet input.
vtkAbstractTransform * Transform
static vtkPointSetAlgorithm * New()
Standard methods for instantiation, obtaining type information, and printing instances of the class...
transform points and associated normals and vectors
Store zero or more vtkInformation instances.
vtkDataObjectMeshCache is a class to store and reuse the mesh of a vtkDataSet, while forwarding data ...