Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itkSimilarity2DTransform.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkSimilarity2DTransform.h,v $
00005   Language:  C++
00006   Date:      $Date: 2006/06/07 16:06:32 $
00007   Version:   $Revision: 1.11 $
00008 
00009   Copyright (c) Insight Software Consortium. All rights reserved.
00010   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
00011 
00012      This software is distributed WITHOUT ANY WARRANTY; without even 
00013      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00014      PURPOSE.  See the above copyright notices for more information.
00015 
00016 =========================================================================*/
00017 
00018 #ifndef __itkSimilarity2DTransform_h
00019 #define __itkSimilarity2DTransform_h
00020 
00021 #include <iostream>
00022 #include "itkRigid2DTransform.h"
00023 
00024 namespace itk
00025 {
00026 
00061 template < class TScalarType=double >    // Data type for scalars (float or double)
00062 class ITK_EXPORT Similarity2DTransform : 
00063             public Rigid2DTransform< TScalarType > 
00064 {
00065 public:
00067   typedef Similarity2DTransform Self;
00068   typedef Rigid2DTransform< TScalarType >   Superclass;
00069   typedef SmartPointer<Self>        Pointer;
00070   typedef SmartPointer<const Self>  ConstPointer;
00071 
00073   itkNewMacro( Self );
00074 
00076   itkTypeMacro( Similarity2DTransform, Rigid2DTransform );
00077 
00079   itkStaticConstMacro(SpaceDimension,           unsigned int, 2);
00080   itkStaticConstMacro(InputSpaceDimension,      unsigned int, 2);
00081   itkStaticConstMacro(OutputSpaceDimension,     unsigned int, 2);
00082   itkStaticConstMacro(ParametersDimension,      unsigned int, 4);
00084 
00086   typedef typename Superclass::ScalarType  ScalarType;
00087   typedef          TScalarType             ScaleType;
00088 
00090   typedef typename Superclass::ParametersType  ParametersType;
00091 
00093   typedef typename Superclass::JacobianType  JacobianType;
00094 
00096   typedef typename Superclass::OffsetType  OffsetType;
00097 
00099   typedef typename Superclass::MatrixType MatrixType;
00100 
00102   typedef typename Superclass::InputPointType   InputPointType;
00103   typedef typename Superclass::OutputPointType  OutputPointType;
00104 
00106   typedef typename Superclass::InputVectorType   InputVectorType;
00107   typedef typename Superclass::OutputVectorType  OutputVectorType;
00108 
00110   typedef typename Superclass::InputCovariantVectorType   InputCovariantVectorType;
00111   typedef typename Superclass::OutputCovariantVectorType  OutputCovariantVectorType;
00112 
00114   typedef typename Superclass::InputVnlVectorType   InputVnlVectorType;
00115   typedef typename Superclass::OutputVnlVectorType  OutputVnlVectorType;
00116 
00118   void SetScale( ScaleType scale );
00119   itkGetConstReferenceMacro( Scale, ScaleType );
00121 
00131   void SetParameters( const ParametersType & parameters );
00132 
00142   const ParametersType & GetParameters( void ) const; 
00143 
00148  const JacobianType & GetJacobian(const InputPointType  &point ) const;
00149 
00151   virtual void SetIdentity( void );
00152 
00157   void CloneInverseTo( Pointer & newinverse ) const;
00158 
00163   void CloneTo( Pointer & clone ) const;
00164 
00178   virtual void SetMatrix( const MatrixType & matrix );
00179 
00180 protected:
00181   Similarity2DTransform();
00182   Similarity2DTransform( unsigned int spaceDimension, 
00183                          unsigned int parametersDimension);
00184 
00185   ~Similarity2DTransform(){};
00186   void PrintSelf(std::ostream &os, Indent indent) const;
00187 
00191   virtual void ComputeMatrix(void);
00192 
00197   virtual void ComputeMatrixParameters(void);
00198 
00200   void SetVarScale( ScaleType scale )
00201     { m_Scale = scale; }
00202 
00203 private:
00204   Similarity2DTransform(const Self&); //purposely not implemented
00205   void operator=(const Self&); //purposely not implemented
00206 
00207   ScaleType     m_Scale; 
00208 
00209 }; //class Similarity2DTransform
00210 
00211 
00212 }  // namespace itk
00213 
00214 // Define instantiation macro for this template.
00215 #define ITK_TEMPLATE_Similarity2DTransform(_, EXPORT, x, y) namespace itk { \
00216   _(1(class EXPORT Similarity2DTransform< ITK_TEMPLATE_1 x >)) \
00217   namespace Templates { typedef Similarity2DTransform< ITK_TEMPLATE_1 x > Similarity2DTransform##y; } \
00218   }
00219 
00220 #if ITK_TEMPLATE_EXPLICIT
00221 # include "Templates/itkSimilarity2DTransform+-.h"
00222 #endif
00223 
00224 #if ITK_TEMPLATE_TXX
00225 # include "itkSimilarity2DTransform.txx"
00226 #endif
00227 
00228 #endif /* __itkSimilarity2DTransform_h */
00229 

Generated at Mon Mar 12 03:01:59 2007 for ITK by doxygen 1.5.1 written by Dimitri van Heesch, © 1997-2000