X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2Ffpa%2FImage%2FRegionGrowWithMultipleThresholds.h;h=f538e7bb49734f4bcbf9508a5e404269982bc211;hb=67b67cafced0d039cf6ff2ccf7839088fd091395;hp=5156b33dbd9bce73614bd7c28734fd4be82aa37b;hpb=9f7b6541d030299dff60fb93caa4371f8f9825de;p=FrontAlgorithms.git diff --git a/lib/fpa/Image/RegionGrowWithMultipleThresholds.h b/lib/fpa/Image/RegionGrowWithMultipleThresholds.h index 5156b33..f538e7b 100644 --- a/lib/fpa/Image/RegionGrowWithMultipleThresholds.h +++ b/lib/fpa/Image/RegionGrowWithMultipleThresholds.h @@ -40,8 +40,13 @@ namespace fpa itkNewMacro( Self ); itkTypeMacro( RegionGrowWithMultipleThresholds, RegionGrow ); - itkGetConstMacro( DerivativeThreshold, double ); - itkSetMacro( DerivativeThreshold, double ); + itkGetConstMacro( InsideValue, TPixel ); + itkGetConstMacro( OutsideValue, TPixel ); + itkGetConstMacro( DifferenceThreshold, double ); + + itkSetMacro( InsideValue, TPixel ); + itkSetMacro( OutsideValue, TPixel ); + itkSetMacro( DifferenceThreshold, double ); public: void AddThreshold( const TPixel& v ); @@ -59,6 +64,8 @@ namespace fpa virtual void _AfterMainLoop( ); virtual void _AfterLoop( ); virtual bool _UpdateResult( _TNode& n ); + virtual void _Mark( const _TNode& n ); + virtual bool _CheckStopCondition( ); private: RegionGrowWithMultipleThresholds( const Self& ); // Not impl. @@ -66,15 +73,23 @@ namespace fpa protected: TThresholds m_Thresholds; - double m_DerivativeThreshold; + TPixel m_InsideValue; + TPixel m_OutsideValue; + double m_DifferenceThreshold; THistogram m_Histogram; + unsigned long m_TotalCount; + double m_LastDiff; + bool m_StopForced; + TPixel m_StopThreshold; }; } // ecapseman } // ecapseman +#ifndef ITK_MANUAL_INSTANTIATION #include +#endif // ITK_MANUAL_INSTANTIATION #endif // __FPA__IMAGE__REGIONGROWWITHMULTIPLETHRESHOLDS__H__