VTK
vtkWarpTransform.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkWarpTransform.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 =========================================================================*/
25 #ifndef vtkWarpTransform_h
26 #define vtkWarpTransform_h
27 
28 #include "vtkCommonTransformsModule.h" // For export macro
29 #include "vtkAbstractTransform.h"
30 
31 class VTKCOMMONTRANSFORMS_EXPORT vtkWarpTransform : public vtkAbstractTransform
32 {
33 public:
34 
36  void PrintSelf(ostream& os, vtkIndent indent) override;
37 
44  void Inverse() override;
45 
47 
52  vtkGetMacro(InverseFlag,int);
54 
56 
60  vtkSetMacro(InverseTolerance,double);
61  vtkGetMacro(InverseTolerance,double);
63 
65 
72  vtkSetMacro(InverseIterations,int);
73  vtkGetMacro(InverseIterations,int);
75 
77 
81  void InternalTransformPoint(const float in[3], float out[3]) override;
82  void InternalTransformPoint(const double in[3], double out[3]) override;
84 
86 
91  void InternalTransformDerivative(const float in[3], float out[3],
92  float derivative[3][3]) override;
93  void InternalTransformDerivative(const double in[3], double out[3],
94  double derivative[3][3]) override;
96 
98 
104  void TemplateTransformPoint(const float in[3], float out[3]) {
105  this->ForwardTransformPoint(in,out); };
106  void TemplateTransformPoint(const double in[3], double out[3]) {
107  this->ForwardTransformPoint(in,out); };
108  void TemplateTransformPoint(const float in[3], float out[3],
109  float derivative[3][3]) {
110  this->ForwardTransformDerivative(in,out,derivative); };
111  void TemplateTransformPoint(const double in[3], double out[3],
112  double derivative[3][3]) {
113  this->ForwardTransformDerivative(in,out,derivative); };
114  void TemplateTransformInverse(const float in[3], float out[3]) {
115  this->InverseTransformPoint(in,out); };
116  void TemplateTransformInverse(const double in[3], double out[3]) {
117  this->InverseTransformPoint(in,out); };
118  void TemplateTransformInverse(const float in[3], float out[3],
119  float derivative[3][3]) {
120  this->InverseTransformDerivative(in,out,derivative); };
121  void TemplateTransformInverse(const double in[3], double out[3],
122  double derivative[3][3]) {
123  this->InverseTransformDerivative(in,out,derivative); };
125 
126 protected:
128  ~vtkWarpTransform() override;
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 
143  virtual void ForwardTransformDerivative(const float in[3], float out[3],
144  float derivative[3][3]) = 0;
145  virtual void ForwardTransformDerivative(const double in[3], double out[3],
146  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],
166  float derivative[3][3]);
167  virtual void InverseTransformDerivative(const double in[3], double out[3],
168  double derivative[3][3]);
170 
174 private:
175  vtkWarpTransform(const vtkWarpTransform&) = delete;
176  void operator=(const vtkWarpTransform&) = delete;
177 };
178 
179 #endif
180 
181 
182 
183 
184 
void TemplateTransformPoint(const double in[3], double out[3])
Do not use these methods.
void TemplateTransformPoint(const float in[3], float out[3])
Do not use these methods.
a simple class to control print indentation
Definition: vtkIndent.h:39
void TemplateTransformInverse(const float in[3], float out[3], float derivative[3][3])
Do not use these methods.
void TemplateTransformInverse(const float in[3], float out[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.
superclass for all geometric transformations
virtual void Inverse()=0
Invert the transformation.
void TemplateTransformInverse(const double in[3], double out[3], double derivative[3][3])
Do not use these methods.
superclass for nonlinear geometric transformations
void TemplateTransformInverse(const double in[3], double out[3])
Do not use these methods.
virtual void InternalTransformPoint(const float in[3], float out[3])=0
This will calculate the transformation without calling Update.
virtual void InternalTransformDerivative(const float in[3], float out[3], float derivative[3][3])=0
This will transform a point and, at the same time, calculate a 3x3 Jacobian matrix that provides the ...
void TemplateTransformPoint(const float in[3], float out[3], float derivative[3][3])
Do not use these methods.
void TemplateTransformPoint(const double in[3], double out[3], double derivative[3][3])
Do not use these methods.