ITK 6.0.0
Insight Toolkit
 
Loading...
Searching...
No Matches
itkQuaternionRigidTransform.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 itkQuaternionRigidTransform_h
19#define itkQuaternionRigidTransform_h
20
21#include <iostream>
22#include "itkRigid3DTransform.h"
23#include "vnl/vnl_quaternion.h"
24
25namespace itk
26{
47template <typename TParametersValueType = double>
48class ITK_TEMPLATE_EXPORT QuaternionRigidTransform : public Rigid3DTransform<TParametersValueType>
49{
50public:
51 ITK_DISALLOW_COPY_AND_MOVE(QuaternionRigidTransform);
52
58
60 itkNewMacro(Self);
61
63 itkOverrideGetNameOfClassMacro(QuaternionRigidTransform);
64
66
69 GetInverseTransform() const override;
70
72 static constexpr unsigned int InputSpaceDimension = 3;
73 static constexpr unsigned int OutputSpaceDimension = 3;
74 static constexpr unsigned int SpaceDimension = 3;
75 static constexpr unsigned int ParametersDimension = 7;
76
78 using typename Superclass::ParametersType;
82 using typename Superclass::JacobianType;
85 using typename Superclass::ScalarType;
86 using typename Superclass::InputPointType;
87 using typename Superclass::OutputPointType;
88 using typename Superclass::InputVectorType;
89 using typename Superclass::OutputVectorType;
91 using typename Superclass::InputVnlVectorType;
95 using typename Superclass::MatrixType;
96 using typename Superclass::InverseMatrixType;
97 using typename Superclass::CenterType;
98 using typename Superclass::OffsetType;
99 using typename Superclass::TranslationType;
100
102 using VnlQuaternionType = vnl_quaternion<TParametersValueType>;
103
108 void
110
114 const VnlQuaternionType &
116 {
117 return m_Rotation;
118 }
119
121 void
122 SetIdentity() override;
123
129 void
130 SetParameters(const ParametersType & parameters) override;
131
132 const ParametersType &
133 GetParameters() const override;
134
140 void
142
143protected:
144#if !defined(ITK_LEGACY_REMOVE)
145 [[deprecated("Removed unused constructor")]] QuaternionRigidTransform(const MatrixType & matrix,
146 const OutputVectorType & offset);
147#endif
148 QuaternionRigidTransform(unsigned int parametersDimension);
150 ~QuaternionRigidTransform() override = default;
151
152 void
153 ComputeMatrix() override;
154
155 void
157
158 void
160 {
161 m_Rotation = rotation;
162 }
163
164 const InverseMatrixType &
166
167 void
168 PrintSelf(std::ostream & os, Indent indent) const override;
169
170private:
173}; // class QuaternionRigidTransform
174} // namespace itk
175
176#ifndef ITK_MANUAL_INSTANTIATION
177# include "itkQuaternionRigidTransform.hxx"
178#endif
179
180#endif /* itkQuaternionRigidTransform_h */
Control indentation during Print() invocation.
Definition itkIndent.h:51
Point< double, Self::InputSpaceDimension > InputPointType
Vector< double, Self::OutputSpaceDimension > OutputVectorType
Matrix< TParametersValueType, Self::InputSpaceDimension, Self::OutputSpaceDimension > InverseMatrixType
Matrix< double, Self::OutputSpaceDimension, Self::InputSpaceDimension > MatrixType
void SetParameters(const ParametersType &parameters) override
void ComputeMatrixParameters() override
const ParametersType & GetParameters() const override
~QuaternionRigidTransform() override=default
InverseTransformBasePointer GetInverseTransform() const override
void PrintSelf(std::ostream &os, Indent indent) const override
const InverseMatrixType & GetInverseMatrix() const
static constexpr unsigned int OutputSpaceDimension
Rigid3DTransform< TParametersValueType > Superclass
const VnlQuaternionType & GetRotation() const
vnl_quaternion< TParametersValueType > VnlQuaternionType
void SetRotation(const VnlQuaternionType &rotation)
void ComputeJacobianWithRespectToParameters(const InputPointType &p, JacobianType &jacobian) const override
static constexpr unsigned int InputSpaceDimension
static constexpr unsigned int ParametersDimension
typename InverseTransformBaseType::Pointer InverseTransformBasePointer
static constexpr unsigned int SpaceDimension
QuaternionRigidTransform(unsigned int parametersDimension)
SmartPointer< const Self > ConstPointer
void SetVarRotation(const VnlQuaternionType &rotation)
typename InverseTransformBaseType::Pointer InverseTransformBasePointer
vnl_matrix_fixed< ParametersValueType, VInputDimension, VOutputDimension > InverseJacobianPositionType
Array2D< ParametersValueType > JacobianType
Rigid3DTransform(unsigned int paramDim)
vnl_matrix_fixed< ParametersValueType, VOutputDimension, VInputDimension > JacobianPositionType
Implements transparent reference counting.
OptimizerParameters< ParametersValueType > ParametersType
TParametersValueType ParametersValueType
OptimizerParameters< FixedParametersValueType > FixedParametersType
OptimizerParameters< ParametersValueType > ParametersType
Matrix< TParametersValueType, Self::OutputSpaceDimension, Self::InputSpaceDimension > MatrixType
Point< TParametersValueType, VOutputDimension > OutputPointType
CovariantVector< TParametersValueType, VOutputDimension > OutputCovariantVectorType
vnl_vector_fixed< TParametersValueType, VInputDimension > InputVnlVectorType
Point< TParametersValueType, VInputDimension > InputPointType
CovariantVector< TParametersValueType, VInputDimension > InputCovariantVectorType
Vector< TParametersValueType, VInputDimension > InputVectorType
Vector< TParametersValueType, VOutputDimension > OutputVectorType
vnl_vector_fixed< TParametersValueType, VOutputDimension > OutputVnlVectorType
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....