Ignore:
Timestamp:
06/09/06 08:24:19 (18 years ago)
Author:
gumbau
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/Lib/Geom/shared/GTGeometry/src/libs/SimplificationMethod.cpp

    r986 r1007  
    222222        simplifstep.y = (float)vdesp[qslim::Y]; 
    223223        simplifstep.z = (float)vdesp[qslim::Z]; 
    224         simplifstep.mV1 = v0->validID(); // the simplification method returns as v0 the alive vertex 
    225         simplifstep.mV0 = v1->validID(); // the simplification method returns as v1 the dead vertex 
    226  
    227         // Number of triangles that are removed in this simplification step 
    228         int _numDelTris = 0; // 1 or 2 triangles can be removed 
    229  
    230         for (i=0; i<changed.length(); i++) 
    231         { 
    232                 if (! changed(i)->isValid()) 
     224         
     225        //      Submeshes which pertains each vertex 
     226        simplifstep.mV1 = v0->validID();  
     227 
     228        //      The simplification method returns as v1 the dead vertex. 
     229        simplifstep.mV0 = v1->validID(); 
     230 
     231        //      Number of triangles that are removed in this simplification step. 
     232        int _numDelTris = 0; // 1 or 2 triangles can be removed. 
     233 
     234        for (i = 0;     i < changed.length();   i++) 
     235        { 
     236                if (!changed(i)->isValid()) 
     237                { 
    233238                        _numDelTris++; 
    234         } 
    235         int del_index=0; 
     239                } 
     240        } 
     241 
     242        int del_index   =       0; 
    236243 
    237244        // mModfaces y mT0, mT1 of simplifstep stores the triangles id's -> geomesh has not triangles id's 
     
    239246        { 
    240247                qslim::Face *auxface = changed(i); 
    241                 if (auxface->isValid())  
     248 
     249                if (auxface->isValid()) 
    242250                { 
    243251                        // Modified triangles 
    244252                        simplifstep.mModfaces.push_back(auxface->validID()); 
    245253                } 
    246                 else  
     254                else 
    247255                { 
    248256                        // Removed triangles 
     
    252260                                simplifstep.mT1=auxface->validID(); 
    253261                        } 
    254                         else  
    255                         { 
    256                                 if(del_index==0)  
     262                        else 
     263                        { 
     264                                if(del_index==0) 
    257265                                { 
    258266                                        simplifstep.mT0=auxface->validID(); 
    259267                                        del_index++; 
    260268                                } 
    261                                 else  
     269                                else 
    262270                                { 
    263271                                        simplifstep.mT1=auxface->validID(); 
Note: See TracChangeset for help on using the changeset viewer.