00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #ifndef __itkAzimuthElevationToCartesianTransform_h
00019 #define __itkAzimuthElevationToCartesianTransform_h
00020
00021 #include "itkAffineTransform.h"
00022 #include "vnl/vnl_math.h"
00023
00024 namespace itk
00025 {
00026
00076 template < class TScalarType=float,
00077 unsigned int NDimensions=3 >
00078 class ITK_EXPORT AzimuthElevationToCartesianTransform :
00079 public AffineTransform< TScalarType, NDimensions >
00080 {
00081 public:
00083 typedef AzimuthElevationToCartesianTransform Self;
00084 typedef AffineTransform< TScalarType, NDimensions > Superclass;
00085 typedef SmartPointer<Self> Pointer;
00086 typedef SmartPointer<const Self> ConstPointer;
00087
00089 itkStaticConstMacro(SpaceDimension, unsigned int, NDimensions);
00090 itkStaticConstMacro(ParametersDimension, unsigned int,
00091 NDimensions * (NDimensions+1) );
00092
00094 itkTypeMacro( AzimuthElevationToCartesianTransform, AffineTransform);
00095
00097 itkNewMacro( Self );
00098
00100 typedef typename Superclass::ParametersType ParametersType;
00101
00103 typedef typename Superclass::JacobianType JacobianType;
00104
00106 typedef typename Superclass::ScalarType ScalarType;
00107
00109 typedef typename Superclass::InputPointType InputPointType;
00110 typedef typename Superclass::OutputPointType OutputPointType;
00111
00113 typedef Matrix<TScalarType, itkGetStaticConstMacro(SpaceDimension),
00114 itkGetStaticConstMacro(SpaceDimension)> MatrixType;
00115
00117 void SetAzimuthElevationToCartesianParameters( const double sampleSize,
00118 const double blanking,
00119 const long maxAzimuth,
00120 const long maxElevation,
00121 const double azimuthAngleSeparation,
00122 const double elevationAngleSeparation);
00123
00124 void SetAzimuthElevationToCartesianParameters( const double sampleSize,
00125 const double blanking,
00126 const long maxAzimuth,
00127 const long maxElevation);
00128
00130 OutputPointType TransformPoint (const InputPointType &point ) const;
00131
00133 inline InputPointType BackTransform(const OutputPointType &point ) const;
00134 InputPointType BackTransformPoint(const OutputPointType &point) const;
00135
00137 void SetForwardAzimuthElevationToCartesian();
00138
00140 void SetForwardCartesianToAzimuthElevation();
00141
00143 OutputPointType TransformAzElToCartesian(const InputPointType &point) const;
00144
00146 OutputPointType TransformCartesianToAzEl(const OutputPointType &point) const;
00147
00152 itkSetMacro(MaxAzimuth, long);
00153
00158 itkSetMacro(MaxElevation, long);
00159
00161 itkSetMacro(RadiusSampleSize, double);
00162
00164 itkSetMacro(AzimuthAngularSeparation, double);
00165
00167 itkSetMacro(ElevationAngularSeparation, double);
00168
00170 itkSetMacro(FirstSampleDistance, double);
00171
00172 protected:
00174 AzimuthElevationToCartesianTransform();
00175
00177 virtual ~AzimuthElevationToCartesianTransform();
00178
00180 void PrintSelf(std::ostream &s, Indent indent) const;
00181
00182 private:
00183 AzimuthElevationToCartesianTransform(const Self&);
00184 void operator=(const Self&);
00185
00186 long m_MaxAzimuth;
00187 long m_MaxElevation;
00188 double m_RadiusSampleSize;
00189 double m_AzimuthAngularSeparation;
00190 double m_ElevationAngularSeparation;
00191 double m_FirstSampleDistance;
00192 bool m_ForwardAzimuthElevationToPhysical;
00193
00194 };
00195
00196
00197 }
00198
00199
00200 #ifndef ITK_MANUAL_INSTANTIATION
00201 #include "itkAzimuthElevationToCartesianTransform.txx"
00202 #endif
00203
00204 #endif
00205
00206