ITK  4.2.0
Insight Segmentation and Registration Toolkit
itkCenteredSimilarity2DTransform.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 __itkCenteredSimilarity2DTransform_h
19 #define __itkCenteredSimilarity2DTransform_h
20 
21 #include <iostream>
23 
24 namespace itk
25 {
55 template <class TScalarType = double>
56 // Data type for scalars
58  public Similarity2DTransform<TScalarType>
59 {
60 public:
66 
68  itkNewMacro(Self);
69 
72 
74  itkStaticConstMacro(SpaceDimension, unsigned int, 2);
75  itkStaticConstMacro(InputSpaceDimension, unsigned int, 2);
76  itkStaticConstMacro(OutputSpaceDimension, unsigned int, 2);
77  itkStaticConstMacro(ParametersDimension, unsigned int, 6);
79 
81  typedef typename Superclass::ScalarType ScalarType;
82 
84  typedef typename Superclass::ParametersType ParametersType;
85  typedef typename Superclass::ParametersValueType ParametersValueType;
86 
88  typedef typename Superclass::JacobianType JacobianType;
89 
91  typedef typename Superclass::OffsetType OffsetType;
93 
95  typedef typename Superclass::InputPointType InputPointType;
96  typedef typename Superclass::OutputPointType OutputPointType;
97  typedef typename InputPointType::ValueType InputPointValueType;
98 
100  typedef typename Superclass::InputVectorType InputVectorType;
101  typedef typename Superclass::OutputVectorType OutputVectorType;
102 
104  typedef typename Superclass::InputCovariantVectorType
106  typedef typename Superclass::OutputCovariantVectorType
108 
110  typedef typename Superclass::InputVnlVectorType InputVnlVectorType;
111  typedef typename Superclass::OutputVnlVectorType OutputVnlVectorType;
112 
115  typedef typename Superclass::InverseTransformBaseType InverseTransformBaseType;
116  typedef typename InverseTransformBaseType::Pointer InverseTransformBasePointer;
117 
127  void SetParameters(const ParametersType & parameters);
128 
138  const ParametersType & GetParameters(void) const;
139 
141  virtual void ComputeJacobianWithRespectToParameters( const InputPointType & p, JacobianType & jacobian) const;
142 
145  virtual void SetFixedParameters(const ParametersType &);
146 
149  virtual const ParametersType & GetFixedParameters(void) const;
150 
154  void CloneInverseTo(Pointer & newinverse) const;
155 
157  bool GetInverse(Self *inverse) const;
158 
160  virtual InverseTransformBasePointer GetInverseTransform() const;
161 
165  void CloneTo(Pointer & clone) const;
166 
167 protected:
169  CenteredSimilarity2DTransform(unsigned int spaceDimension, unsigned int parametersDimension);
170 
172  {
173  }
174  void PrintSelf(std::ostream & os, Indent indent) const;
175 
176 private:
177  CenteredSimilarity2DTransform(const Self &); // purposely not implemented
178  void operator=(const Self &); // purposely not implemented
179 
180 }; // class
181  // CenteredSimilarity2DTransform
182 } // namespace itk
183 
184 // Define instantiation macro for this template.
185 #define ITK_TEMPLATE_CenteredSimilarity2DTransform(_, EXPORT, TypeX, TypeY) \
186  namespace itk \
187  { \
188  _( 1 ( class EXPORT CenteredSimilarity2DTransform<ITK_TEMPLATE_1 TypeX> ) ) \
189  namespace Templates \
190  { \
191  typedef CenteredSimilarity2DTransform<ITK_TEMPLATE_1 TypeX> \
192  CenteredSimilarity2DTransform##TypeY; \
193  } \
194  }
195 
196 #if ITK_TEMPLATE_EXPLICIT
197 #include "Templates/itkCenteredSimilarity2DTransform+-.h"
198 #endif
199 
200 #if ITK_TEMPLATE_TXX
201 #include "itkCenteredSimilarity2DTransform.hxx"
202 #endif
203 
204 #endif /* __itkCenteredSimilarity2DTransform_h */
205