]> Creatis software - cpMesh.git/blob - lib/cpm/Algorithms/QuadEdge/DecimationFilter.hxx
First commit
[cpMesh.git] / lib / cpm / Algorithms / QuadEdge / DecimationFilter.hxx
1 #ifndef __CPM__ALGORITHMS__QUADEDGE__DECIMATIONFILTER__HXX__
2 #define __CPM__ALGORITHMS__QUADEDGE__DECIMATIONFILTER__HXX__
3
4 // -------------------------------------------------------------------------
5 template< class I, class O, class C >
6 cpm::Algorithms::QuadEdge::DecimationFilter< I, O, C >::
7 DecimationFilter( )
8   : Superclass( )
9 {
10   this->m_Iteration = 0;
11 }
12
13 // -------------------------------------------------------------------------
14 template< class I, class O, class C >
15 cpm::Algorithms::QuadEdge::DecimationFilter< I, O, C >::
16 ~DecimationFilter( )
17 {
18 }
19
20 // -------------------------------------------------------------------------
21 template< class I, class O, class C >
22 void cpm::Algorithms::QuadEdge::DecimationFilter< I, O, C >::
23 GenerateData( )
24 {
25   // TODO: this->CopyInputMeshToOutputMesh( );
26
27   this->Initialize( );
28   this->FillPriorityQueue( );
29   this->m_Iteration = 0;
30   bool stop = false;
31   do
32   {
33     this->Extract( );
34     stop = this->ProcessWithTopologicalGuarantee( );
35     ++this->m_Iteration;
36   }
37   while( !( this->IsCriterionSatisfied( ) ) && !stop );
38
39   /* TODO
40      if( stop )
41      this->GetOutput( )->SqueezePointsIds( );
42   */
43 }
44
45 // -------------------------------------------------------------------------
46 template< class I, class O, class C >
47 void cpm::Algorithms::QuadEdge::DecimationFilter< I, O, C >::
48 Initialize( )
49 {
50 }
51
52 #endif // __CPM__ALGORITHMS__QUADEDGE__DECIMATIONFILTER__HXX__
53
54 // eof - $RCSfile$