src/gsim/se_mesh_import.cpp
// should finished the contours by detecting loops to join or holes info to attach
should finished the contours by detecting loops to join or holes info to attach
should finished the contours by detecting loops to join or holes info to attach
void SeMeshImport::Data::solve_lasting_contours ( SeMeshBase *m )
 {
   int i;
   bool genus_increased;
   SeBase *s, *c;
   while ( !contours_to_solve.empty() )
    { genus_increased = false;
      s = contours_to_solve.pop();
      GS_TRACE_CONTOUR(s,m);
      for ( i=0; i<contours_to_solve.size(); i++ )
       { c = coincident_contour(s,contours_to_solve[i]);
         if ( c )
          { GS_TRACE1 ( "Making one genus..." );
            GS_TRACE_CONTOUR(c,m);
            contours_to_solve.remove(i);
            genus_increased = true;
            m->mg ( s, c );
            break;
          }
       }
      if ( !genus_increased )
       { GS_TRACE1 ( "Closing last contour as a hole..." );
         self->attach_hole_info ( s->fac() );
       }
    }
 }
void SeMeshImport :: Data :: solve_lasting_contours ( SeMeshBase * m ) { int i ; bool genus_increased ; SeBase * s , * c ; while ( ! contours_to_solve . empty ( ) ) { genus_increased = false ; s = contours_to_solve . pop ( ) ; GS_TRACE_CONTOUR ( s , m ) ; for ( i = 0 ; i < contours_to_solve . size ( ) ; i ++ ) { c = coincident_contour ( s , contours_to_solve [ i ] ) ; if ( c ) { GS_TRACE1 ( " " ) ; GS_TRACE_CONTOUR ( c , m ) ; contours_to_solve . remove ( i ) ; genus_increased = true ; m -> mg ( s , c ) ; break ; } } if ( ! genus_increased ) { GS_TRACE1 ( " " ) ; self -> attach_hole_info ( s -> fac ( ) ) ; } } }
should finished the contours by detecting loops to join or holes info to attach
should finished the contours by detecting loops to join or holes info to attach
//[i]=contours_to_solve.pop();