void SetCollisions( const TCollisions& collisions );
void ClearSeeds( );
- void AddSeed( const TVertex& seed );
+ void AddSeed( const TVertex& seed, unsigned long fId );
virtual TVertex GetParent( const TVertex& v ) const = 0;
virtual void SetParent( const TVertex& v, const TVertex& p ) = 0;
} // rof
} // rof
+ this->m_Seeds.resize( N );
this->Modified( );
}
// -------------------------------------------------------------------------
template< class _TVertex, class _Superclass >
void fpa::DataStructures::MinimumSpanningTree< _TVertex, _Superclass >::
-AddSeed( const _TVertex& seed )
+AddSeed( const _TVertex& seed, unsigned long fId )
{
- this->m_Seeds.push_back( seed );
+ this->m_Seeds[ fId - 1 ] = seed;
this->Modified( );
}
Dijkstra( );
virtual ~Dijkstra( );
+ virtual void _AfterGenerateData( ) override;
virtual void _PostComputeOutputValue( TNode& n ) override;
private:
{
}
+// -------------------------------------------------------------------------
+template< class _TDataInterface, class _TMST >
+void fpa::Filters::Dijkstra< _TDataInterface, _TMST >::
+_AfterGenerateData( )
+{
+ this->Superclass::_AfterGenerateData( );
+
+ TMST* mst = this->GetMinimumSpanningTree( );
+ mst->ClearSeeds( );
+ mst->SetCollisions( this->m_Collisions );
+ for( TNode seed: this->GetSeeds( ) )
+ mst->AddSeed( seed.Vertex, seed.FrontId );
+}
+
// -------------------------------------------------------------------------
template< class _TDataInterface, class _TMST >
void fpa::Filters::Dijkstra< _TDataInterface, _TMST >::