ITK  5.4.0
Insight Toolkit
itkScaleSkewVersor3DTransform.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright NumFOCUS
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * https://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef itkScaleSkewVersor3DTransform_h
19 #define itkScaleSkewVersor3DTransform_h
20 
21 #include <iostream>
23 
24 namespace itk
25 {
53 template <typename TParametersValueType = double>
54 class ITK_TEMPLATE_EXPORT ScaleSkewVersor3DTransform : public VersorRigid3DTransform<TParametersValueType>
55 {
56 public:
57  ITK_DISALLOW_COPY_AND_MOVE(ScaleSkewVersor3DTransform);
58 
64 
66  itkNewMacro(Self);
67 
69  itkOverrideGetNameOfClassMacro(ScaleSkewVersor3DTransform);
70 
72  static constexpr unsigned int InputSpaceDimension = 3;
73  static constexpr unsigned int OutputSpaceDimension = 3;
74  static constexpr unsigned int ParametersDimension = 15;
75 
77  using typename Superclass::ParametersType;
78  using typename Superclass::FixedParametersType;
79  using typename Superclass::JacobianType;
80  using typename Superclass::JacobianPositionType;
81  using typename Superclass::InverseJacobianPositionType;
82  using typename Superclass::ScalarType;
83  using typename Superclass::InputPointType;
84  using typename Superclass::OutputPointType;
85  using typename Superclass::InputVectorType;
86  using typename Superclass::OutputVectorType;
87  using typename Superclass::InputVnlVectorType;
88  using typename Superclass::OutputVnlVectorType;
89  using typename Superclass::InputCovariantVectorType;
90  using typename Superclass::OutputCovariantVectorType;
91  using typename Superclass::MatrixType;
92  using typename Superclass::InverseMatrixType;
93  using typename Superclass::CenterType;
94  using typename Superclass::OffsetType;
95  using typename Superclass::TranslationType;
96 
97  using typename Superclass::VersorType;
98  using typename Superclass::AxisType;
99  using typename Superclass::AngleType;
100 
104 
108 
109  using typename Superclass::AxisValueType;
110  using typename Superclass::ParametersValueType;
111 
117  void
118  SetMatrix(const MatrixType & matrix) override;
119  void
120  SetMatrix(const MatrixType & matrix, const TParametersValueType tolerance) override;
131  void
132  SetParameters(const ParametersType & parameters) override;
133 
134  const ParametersType &
135  GetParameters() const override;
136 
137  void
138  SetScale(const ScaleVectorType & scale);
139 
140  itkGetConstReferenceMacro(Scale, ScaleVectorType);
141 
142  void
143  SetSkew(const SkewVectorType & skew);
144 
145  itkGetConstReferenceMacro(Skew, SkewVectorType);
146 
147  void
148  SetIdentity() override;
149 
154  void
155  ComputeJacobianWithRespectToParameters(const InputPointType & p, JacobianType & jacobian) const override;
156 
157 protected:
159  ScaleSkewVersor3DTransform(const MatrixType & matrix, const OutputVectorType & offset);
160  ScaleSkewVersor3DTransform(unsigned int parametersDimension);
161  ~ScaleSkewVersor3DTransform() override = default;
162 
163  void
164  PrintSelf(std::ostream & os, Indent indent) const override;
165 
166  void
168  {
169  m_Scale = scale;
170  }
171 
172  void
174  {
175  m_Skew = skew;
176  }
177 
179  void
180  ComputeMatrix() override;
181 
182  void
183  ComputeMatrixParameters() override;
184 
185 private:
187  ScaleVectorType m_Scale{};
188 
190  SkewVectorType m_Skew{};
191 }; // class ScaleSkewVersor3DTransform
192 } // namespace itk
193 
194 #ifndef ITK_MANUAL_INSTANTIATION
195 # include "itkScaleSkewVersor3DTransform.hxx"
196 #endif
197 
198 #endif /* __ScaleSkewVersor3DTransform_h */
itk::OptimizerParameters
Class to hold and manage different parameter types used during optimization.
Definition: itkOptimizerParameters.h:36
itk::ScaleSkewVersor3DTransform::SkewVectorValueType
typename SkewVectorType::ValueType SkewVectorValueType
Definition: itkScaleSkewVersor3DTransform.h:106
itk::VersorRigid3DTransform
VersorRigid3DTransform of a vector space (e.g. space coordinates)
Definition: itkVersorRigid3DTransform.h:46
itk::ScaleSkewVersor3DTransform
ScaleSkewVersor3DTransform of a vector space (e.g. space coordinates)
Definition: itkScaleSkewVersor3DTransform.h:54
itk::Vector< TParametersValueType, 3 >
itk::SmartPointer< Self >
itk::Indent
Control indentation during Print() invocation.
Definition: itkIndent.h:49
itk::Vector< TParametersValueType, 3 >::ValueType
TParametersValueType ValueType
Definition: itkVector.h:71
itk::LightObject
Light weight base class for most itk classes.
Definition: itkLightObject.h:55
itk::ScaleSkewVersor3DTransform::ScaleVectorValueType
typename ScaleVectorType::ValueType ScaleVectorValueType
Definition: itkScaleSkewVersor3DTransform.h:105
itkVersorRigid3DTransform.h
itk::Matrix< TParametersValueType, Self::OutputSpaceDimension, Self::InputSpaceDimension >
itk::ScaleSkewVersor3DTransform::TranslationValueType
typename TranslationType::ValueType TranslationValueType
Definition: itkScaleSkewVersor3DTransform.h:107
itk
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Definition: itkAnnulusOperator.h:24
itk::ScaleSkewVersor3DTransform::SetVarSkew
void SetVarSkew(const SkewVectorType &skew)
Definition: itkScaleSkewVersor3DTransform.h:173
itk::Point
A templated class holding a geometric point in n-Dimensional space.
Definition: itkPoint.h:53
itk::Array2D
Array2D class representing a 2D array.
Definition: itkArray2D.h:42
itk::ScaleSkewVersor3DTransform::SetVarScale
void SetVarScale(const ScaleVectorType &scale)
Definition: itkScaleSkewVersor3DTransform.h:167