VTK  9.4.20241221
vtkWarpTransform.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
13#ifndef vtkWarpTransform_h
14#define vtkWarpTransform_h
15
17#include "vtkCommonTransformsModule.h" // For export macro
18
19VTK_ABI_NAMESPACE_BEGIN
20class VTKCOMMONTRANSFORMS_EXPORT vtkWarpTransform : public vtkAbstractTransform
21{
22public:
24 void PrintSelf(ostream& os, vtkIndent indent) override;
25
32 void Inverse() override;
33
35
40 vtkGetMacro(InverseFlag, vtkTypeBool);
42
44
48 vtkSetMacro(InverseTolerance, double);
49 vtkGetMacro(InverseTolerance, double);
51
53
60 vtkSetMacro(InverseIterations, int);
61 vtkGetMacro(InverseIterations, int);
63
65
69 void InternalTransformPoint(const float in[3], float out[3]) override;
70 void InternalTransformPoint(const double in[3], double out[3]) override;
72
74
80 const float in[3], float out[3], float derivative[3][3]) override;
82 const double in[3], double out[3], double derivative[3][3]) override;
84
86
92 void TemplateTransformPoint(const float in[3], float out[3])
93 {
94 this->ForwardTransformPoint(in, out);
95 }
96 void TemplateTransformPoint(const double in[3], double out[3])
97 {
98 this->ForwardTransformPoint(in, out);
99 }
100 void TemplateTransformPoint(const float in[3], float out[3], float derivative[3][3])
101 {
102 this->ForwardTransformDerivative(in, out, derivative);
103 }
104 void TemplateTransformPoint(const double in[3], double out[3], double derivative[3][3])
105 {
106 this->ForwardTransformDerivative(in, out, derivative);
107 }
108 void TemplateTransformInverse(const float in[3], float out[3])
109 {
110 this->InverseTransformPoint(in, out);
111 }
112 void TemplateTransformInverse(const double in[3], double out[3])
113 {
114 this->InverseTransformPoint(in, out);
115 }
116 void TemplateTransformInverse(const float in[3], float out[3], float derivative[3][3])
117 {
118 this->InverseTransformDerivative(in, out, derivative);
119 }
120 void TemplateTransformInverse(const double in[3], double out[3], double derivative[3][3])
121 {
122 this->InverseTransformDerivative(in, out, derivative);
123 }
125
126protected:
129
131
135 virtual void ForwardTransformPoint(const float in[3], float out[3]) = 0;
136 virtual void ForwardTransformPoint(const double in[3], double out[3]) = 0;
138
140
144 const float in[3], float out[3], float derivative[3][3]) = 0;
146 const double in[3], double out[3], double derivative[3][3]) = 0;
148
150
155 virtual void InverseTransformPoint(const float in[3], float out[3]);
156 virtual void InverseTransformPoint(const double in[3], double out[3]);
158
160
165 virtual void InverseTransformDerivative(const float in[3], float out[3], float derivative[3][3]);
167 const double in[3], double out[3], double derivative[3][3]);
169
173
174private:
175 vtkWarpTransform(const vtkWarpTransform&) = delete;
176 void operator=(const vtkWarpTransform&) = delete;
177};
178
179VTK_ABI_NAMESPACE_END
180#endif
superclass for all geometric transformations
a simple class to control print indentation
Definition vtkIndent.h:108
superclass for nonlinear geometric transformations
void InternalTransformDerivative(const float in[3], float out[3], float derivative[3][3]) override
This will calculate the transformation, as well as its derivative without calling Update.
void TemplateTransformPoint(const double in[3], double out[3])
Do not use these methods.
vtkTypeBool InverseFlag
virtual void ForwardTransformPoint(const double in[3], double out[3])=0
If the InverseFlag is set to 0, then a call to InternalTransformPoint results in a call to ForwardTra...
void InternalTransformDerivative(const double in[3], double out[3], double derivative[3][3]) override
This will calculate the transformation, as well as its derivative without calling Update.
virtual void InverseTransformPoint(const double in[3], double out[3])
If the InverseFlag is set to 1, then a call to InternalTransformPoint results in a call to InverseTra...
void TemplateTransformPoint(const float in[3], float out[3])
Do not use these methods.
virtual void InverseTransformDerivative(const double in[3], double out[3], double derivative[3][3])
Calculate the inverse transform as well as the derivative of the forward transform (that's correct: t...
void TemplateTransformPoint(const float in[3], float out[3], float derivative[3][3])
Do not use these methods.
virtual void InverseTransformDerivative(const float in[3], float out[3], float derivative[3][3])
Calculate the inverse transform as well as the derivative of the forward transform (that's correct: t...
virtual void InverseTransformPoint(const float in[3], float out[3])
If the InverseFlag is set to 1, then a call to InternalTransformPoint results in a call to InverseTra...
void InternalTransformPoint(const double in[3], double out[3]) override
This will calculate the transformation without calling Update.
void InternalTransformPoint(const float in[3], float out[3]) override
This will calculate the transformation without calling Update.
~vtkWarpTransform() override
void TemplateTransformInverse(const float in[3], float out[3], float derivative[3][3])
Do not use these methods.
virtual void ForwardTransformDerivative(const double in[3], double out[3], double derivative[3][3])=0
Calculate the forward transform as well as the derivative.
void TemplateTransformPoint(const double in[3], double out[3], double derivative[3][3])
Do not use these methods.
void TemplateTransformInverse(const float in[3], float out[3])
Do not use these methods.
void TemplateTransformInverse(const double in[3], double out[3], double derivative[3][3])
Do not use these methods.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual void ForwardTransformPoint(const float in[3], float out[3])=0
If the InverseFlag is set to 0, then a call to InternalTransformPoint results in a call to ForwardTra...
virtual void ForwardTransformDerivative(const float in[3], float out[3], float derivative[3][3])=0
Calculate the forward transform as well as the derivative.
void Inverse() override
Invert the transformation.
void TemplateTransformInverse(const double in[3], double out[3])
Do not use these methods.
int vtkTypeBool
Definition vtkABI.h:64