]> Creatis software - FrontAlgorithms.git/blobdiff - lib/fpa/Image/PolyLineParametricPath.hxx
...
[FrontAlgorithms.git] / lib / fpa / Image / PolyLineParametricPath.hxx
index 4616dcf1e7eddc8e6db88c86cb22c5855206ec0f..3093a997c60a8fc8fe7873c9416b4e39dd51d95c 100644 (file)
@@ -141,6 +141,29 @@ SetDirection( const TDirection& dir )
   } // fi
 }
 
+// -------------------------------------------------------------------------
+template< unsigned int _VDim >
+void fpa::Image::PolyLineParametricPath< _VDim >::
+Graft( itk::DataObject* o )
+{
+  this->Superclass::Graft( o );
+  Self* other = dynamic_cast< Self* >( o );
+  if( other != NULL )
+  {
+    this->m_DefaultInputStepSize = other->m_DefaultInputStepSize;
+    this->Initialize( );
+    for( unsigned long i = 0; i < other->GetSize( ); ++i )
+      this->AddVertex( other->GetContinuousVertex( i ) );
+    this->m_Spacing = other->m_Spacing;
+    this->m_Origin = other->m_Origin;
+    this->m_Direction = other->m_Direction;
+    this->m_InverseDirection = other->m_InverseDirection;
+    this->m_IndexToPhysicalPoint = other->m_IndexToPhysicalPoint;
+    this->m_PhysicalPointToIndex = other->m_PhysicalPointToIndex;
+
+  } // fi
+}
+
 // -------------------------------------------------------------------------
 template< unsigned int _VDim >
 fpa::Image::PolyLineParametricPath< _VDim >::