Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef __itkHessianToObjectnessMeasureImageFilter_h
00018 #define __itkHessianToObjectnessMeasureImageFilter_h
00019
00020 #include "itkSymmetricSecondRankTensor.h"
00021 #include "itkImageToImageFilter.h"
00022
00023 namespace itk
00024 {
00025
00060 template < typename TInputImage, typename TOutputImage >
00061 class ITK_EXPORT HessianToObjectnessMeasureImageFilter : public
00062 ImageToImageFilter< TInputImage,TOutputImage>
00063 {
00064 public:
00066 typedef HessianToObjectnessMeasureImageFilter Self;
00067
00068 typedef ImageToImageFilter< TInputImage, TOutputImage > Superclass;
00069
00070 typedef SmartPointer< Self > Pointer;
00071 typedef SmartPointer< const Self > ConstPointer;
00072
00073 typedef typename Superclass::InputImageType InputImageType;
00074 typedef typename Superclass::OutputImageType OutputImageType;
00075 typedef typename InputImageType::PixelType InputPixelType;
00076 typedef typename OutputImageType::PixelType OutputPixelType;
00077 typedef typename OutputImageType::RegionType OutputImageRegionType;
00078
00080 itkStaticConstMacro(ImageDimension, unsigned int, ::itk::GetImageDimension<InputImageType>::ImageDimension);
00081
00082 typedef double EigenValueType;
00083 typedef itk::FixedArray< EigenValueType, itkGetStaticConstMacro( ImageDimension ) > EigenValueArrayType;
00084
00085
00087 itkNewMacro(Self);
00088
00090 itkTypeMacro( HessianToObjectnessMeasureImageFilter, ImageToImageFilter );
00091
00095 itkSetMacro(Alpha,double);
00096 itkGetConstMacro(Alpha,double);
00098
00102 itkSetMacro(Beta,double);
00103 itkGetConstMacro(Beta,double);
00105
00108 itkSetMacro(Gamma,double);
00109 itkGetConstMacro(Gamma,double);
00111
00113 itkSetMacro(ScaleObjectnessMeasure,bool);
00114 itkGetConstMacro(ScaleObjectnessMeasure,bool);
00115 itkBooleanMacro(ScaleObjectnessMeasure);
00117
00121 itkSetMacro(ObjectDimension,unsigned int);
00122 itkGetConstMacro(ObjectDimension,unsigned int);
00124
00126 itkSetMacro(BrightObject,bool);
00127 itkGetConstMacro(BrightObject,bool);
00128 itkBooleanMacro(BrightObject);
00130
00131 #ifdef ITK_USE_CONCEPT_CHECKING
00132
00133 itkConceptMacro(DoubleConvertibleToOutputCheck,(Concept::Convertible<double, OutputPixelType>));
00134
00136 #endif
00137
00138 protected:
00139 HessianToObjectnessMeasureImageFilter();
00140 ~HessianToObjectnessMeasureImageFilter() {};
00141 void PrintSelf(std::ostream& os, Indent indent) const;
00142
00143 void BeforeThreadedGenerateData( void );
00144 void ThreadedGenerateData(const OutputImageRegionType& outputRegionForThread, int threadId);
00145
00146 private:
00147 HessianToObjectnessMeasureImageFilter(const Self&);
00148 void operator=(const Self&);
00149
00150
00151 struct AbsCompare
00152 {
00153 bool operator()( EigenValueType a, EigenValueType b )
00154 {
00155 return vnl_math_abs(a) > vnl_math_abs(b);
00156 }
00157 };
00158
00159 double m_Alpha;
00160 double m_Beta;
00161 double m_Gamma;
00162 unsigned int m_ObjectDimension;
00163 bool m_BrightObject;
00164 bool m_ScaleObjectnessMeasure;
00165 };
00166
00167 }
00168
00169 #ifndef ITK_MANUAL_INSTANTIATION
00170 #include "itkHessianToObjectnessMeasureImageFilter.txx"
00171 #endif
00172
00173 #endif
00174