]> Creatis software - FrontAlgorithms.git/blobdiff - lib/fpa/Image/RegionGrow.hxx
...
[FrontAlgorithms.git] / lib / fpa / Image / RegionGrow.hxx
index 17775e737773e285dbf1a2941db03e7d6617f7b5..326dc5421ec9f3108f216f762ca1e5080c51cccc 100644 (file)
@@ -1,5 +1,5 @@
-#ifndef __FPA__IMAGE__REGIONGROW__HXX__
-#define __FPA__IMAGE__REGIONGROW__HXX__
+#ifndef __fpa__Image__RegionGrow__hxx__
+#define __fpa__Image__RegionGrow__hxx__
 
 // -------------------------------------------------------------------------
 template< class _TInputImage, class _TOutputImage >
@@ -8,7 +8,7 @@ RegionGrow( )
   : Superclass( )
 {
 }
+
 // -------------------------------------------------------------------------
 template< class _TInputImage, class _TOutputImage >
 fpa::Image::RegionGrow< _TInputImage, _TOutputImage >::
@@ -16,6 +16,19 @@ fpa::Image::RegionGrow< _TInputImage, _TOutputImage >::
 {
 }
 
-#endif // __FPA__IMAGE__REGIONGROW__HXX__
+// -------------------------------------------------------------------------
+template< class _TInputImage, class _TOutputImage >
+void fpa::Image::RegionGrow< _TInputImage, _TOutputImage >::
+_BeforeGenerateData( )
+{
+  this->Superclass::_BeforeGenerateData( );
+  this->m_InitResult = this->GetOutsideValue( );
+  TGrowFunction* grow =
+    dynamic_cast< TGrowFunction* >( this->GetGrowFunction( ) );
+  if( grow != NULL )
+    grow->SetImage( this->GetInput( ) );
+}
+
+#endif // __fpa__Image__RegionGrow__hxx__
 
 // eof - $RCSfile$