ITK
4.1.0
Insight Segmentation and Registration Toolkit
|
00001 /*========================================================================= 00002 * 00003 * Copyright Insight Software Consortium 00004 * 00005 * Licensed under the Apache License, Version 2.0 (the "License"); 00006 * you may not use this file except in compliance with the License. 00007 * You may obtain a copy of the License at 00008 * 00009 * http://www.apache.org/licenses/LICENSE-2.0.txt 00010 * 00011 * Unless required by applicable law or agreed to in writing, software 00012 * distributed under the License is distributed on an "AS IS" BASIS, 00013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00014 * See the License for the specific language governing permissions and 00015 * limitations under the License. 00016 * 00017 *=========================================================================*/ 00018 #ifndef __itkThinPlateR2LogRSplineKernelTransform_h 00019 #define __itkThinPlateR2LogRSplineKernelTransform_h 00020 00021 #include "itkKernelTransform.h" 00022 00023 namespace itk 00024 { 00035 template< class TScalarType, // Data type for scalars (float or double) 00036 unsigned int NDimensions = 3 > 00037 // Number of dimensions 00038 class ITK_EXPORT ThinPlateR2LogRSplineKernelTransform: 00039 public KernelTransform< TScalarType, NDimensions > 00040 { 00041 public: 00043 typedef ThinPlateR2LogRSplineKernelTransform Self; 00044 typedef KernelTransform< TScalarType, NDimensions > Superclass; 00045 typedef SmartPointer< Self > Pointer; 00046 typedef SmartPointer< const Self > ConstPointer; 00047 00049 itkNewMacro(Self); 00050 00052 itkTypeMacro(ThinPlateR2LogRSplineKernelTransform, KernelTransform); 00053 00055 typedef typename Superclass::ScalarType ScalarType; 00056 00058 typedef typename Superclass::ParametersType ParametersType; 00059 00061 typedef typename Superclass::JacobianType JacobianType; 00062 00064 itkStaticConstMacro(SpaceDimension, unsigned int, Superclass::SpaceDimension); 00065 00066 typedef typename Superclass::InputPointType InputPointType; 00067 typedef typename Superclass::OutputPointType OutputPointType; 00068 typedef typename Superclass::InputVectorType InputVectorType; 00069 typedef typename Superclass::OutputVectorType OutputVectorType; 00070 typedef typename Superclass::InputCovariantVectorType InputCovariantVectorType; 00071 typedef typename Superclass::OutputCovariantVectorType OutputCovariantVectorType; 00072 typedef typename Superclass::PointsIterator PointsIterator; 00073 protected: 00074 ThinPlateR2LogRSplineKernelTransform() {} 00075 virtual ~ThinPlateR2LogRSplineKernelTransform() {} 00076 00077 typedef typename Superclass::GMatrixType GMatrixType; 00086 virtual void ComputeG(const InputVectorType & landmarkVector, GMatrixType & gmatrix) const; 00087 00090 virtual void ComputeDeformationContribution(const InputPointType & inputPoint, 00091 OutputPointType & result) const; 00092 00093 private: 00094 ThinPlateR2LogRSplineKernelTransform(const Self &); //purposely not 00095 // implemented 00096 void operator=(const Self &); //purposely not 00097 // implemented 00098 }; 00099 } // namespace itk 00100 00101 // Define instantiation macro for this template. 00102 #define ITK_TEMPLATE_ThinPlateR2LogRSplineKernelTransform(_, EXPORT, TypeX, TypeY) \ 00103 namespace itk \ 00104 { \ 00105 _( 2 ( class EXPORT ThinPlateR2LogRSplineKernelTransform< ITK_TEMPLATE_2 TypeX > ) ) \ 00106 namespace Templates \ 00107 { \ 00108 typedef ThinPlateR2LogRSplineKernelTransform< ITK_TEMPLATE_2 TypeX > \ 00109 ThinPlateR2LogRSplineKernelTransform##TypeY; \ 00110 } \ 00111 } 00112 00113 #if ITK_TEMPLATE_EXPLICIT 00114 #include "Templates/itkThinPlateR2LogRSplineKernelTransform+-.h" 00115 #endif 00116 00117 #if ITK_TEMPLATE_TXX 00118 #include "itkThinPlateR2LogRSplineKernelTransform.hxx" 00119 #endif 00120 00121 #endif // __itkThinPlateR2LogRSplineKernelTransform_h 00122