ITK  4.2.0
Insight Segmentation and Registration Toolkit
itkVersorRigid3DTransform.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
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  * http://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 __itkVersorRigid3DTransform_h
19 #define __itkVersorRigid3DTransform_h
20 
21 #include <iostream>
22 #include "itkVersorTransform.h"
23 
24 namespace itk
25 {
45 template <class TScalarType = double>
46 // Data type for scalars (float or double)
47 class ITK_EXPORT VersorRigid3DTransform :
48  public VersorTransform<TScalarType>
49 {
50 public:
56 
58  itkNewMacro(Self);
59 
62 
64  itkStaticConstMacro(SpaceDimension, unsigned int, 3);
65  itkStaticConstMacro(InputSpaceDimension, unsigned int, 3);
66  itkStaticConstMacro(OutputSpaceDimension, unsigned int, 3);
67  itkStaticConstMacro(ParametersDimension, unsigned int, 6);
69 
71  typedef typename Superclass::ParametersType ParametersType;
72  typedef typename Superclass::JacobianType JacobianType;
73  typedef typename Superclass::ScalarType ScalarType;
74  typedef typename Superclass::InputPointType InputPointType;
75  typedef typename Superclass::OutputPointType OutputPointType;
76  typedef typename Superclass::InputVectorType InputVectorType;
77  typedef typename Superclass::OutputVectorType OutputVectorType;
78  typedef typename Superclass::InputVnlVectorType InputVnlVectorType;
79  typedef typename Superclass::OutputVnlVectorType OutputVnlVectorType;
80  typedef typename Superclass::InputCovariantVectorType InputCovariantVectorType;
81  typedef typename Superclass::OutputCovariantVectorType OutputCovariantVectorType;
82  typedef typename Superclass::MatrixType MatrixType;
83  typedef typename Superclass::InverseMatrixType InverseMatrixType;
84  typedef typename Superclass::CenterType CenterType;
85  typedef typename Superclass::OffsetType OffsetType;
86  typedef typename Superclass::TranslationType TranslationType;
87 
89  typedef typename Superclass::VersorType VersorType;
90  typedef typename Superclass::AxisType AxisType;
91  typedef typename Superclass::AngleType AngleType;
92 
93  typedef typename Superclass::AxisValueType AxisValueType;
94  typedef typename Superclass::TranslationValueType TranslationValueType;
95  typedef typename Superclass::ParameterValueType ParameterValueType;
96 
101  void SetParameters(const ParametersType & parameters);
102 
103  virtual const ParametersType & GetParameters(void) const;
104 
109  virtual void ComputeJacobianWithRespectToParameters( const InputPointType & p, JacobianType & jacobian) const;
110 
111 protected:
112  VersorRigid3DTransform(const MatrixType & matrix, const OutputVectorType & offset);
113  VersorRigid3DTransform(unsigned int paramDim);
116  {
117  }
118 
119  void PrintSelf(std::ostream & os, Indent indent) const;
120 
121 private:
122  VersorRigid3DTransform(const Self &); // purposely not implemented
123  void operator=(const Self &); // purposely not implemented
124 
125 }; // class VersorRigid3DTransform
126 } // namespace itk
127 
128 // Define instantiation macro for this template.
129 #define ITK_TEMPLATE_VersorRigid3DTransform(_, EXPORT, TypeX, TypeY) \
130  namespace itk \
131  { \
132  _( 1 ( class EXPORT VersorRigid3DTransform<ITK_TEMPLATE_1 TypeX> ) ) \
133  namespace Templates \
134  { \
135  typedef VersorRigid3DTransform<ITK_TEMPLATE_1 TypeX> VersorRigid3DTransform##TypeY; \
136  } \
137  }
138 
139 #if ITK_TEMPLATE_EXPLICIT
140 #include "Templates/itkVersorRigid3DTransform+-.h"
141 #endif
142 
143 #if ITK_TEMPLATE_TXX
144 #include "itkVersorRigid3DTransform.hxx"
145 #endif
146 
147 #endif /* __itkVersorRigid3DTransform_h */
148