void fpa::Image::MinimumSpanningTree< _VDim >::
GetPath( typename TPath::Pointer& path, const TVertex& a ) const
{
- this->Superclass::GetPath( path, a );
+ if( path.GetPointer( ) == NULL )
+ path = TPath::New( );
path->SetReferenceImage( this );
+ this->Superclass::GetPath( path, a );
}
// -------------------------------------------------------------------------
typename TPath::Pointer& path, const TVertex& a, const TVertex& b
) const
{
- this->Superclass::GetPath( path, a, b );
+ if( path.GetPointer( ) == NULL )
+ path = TPath::New( );
path->SetReferenceImage( this );
+ this->Superclass::GetPath( path, a, b );
}
// -------------------------------------------------------------------------