added a correct import data for managing the data of the newly refined faces.

This commit is contained in:
Paolo Cignoni 2012-12-17 15:31:28 +00:00
parent 08aeee8716
commit dcda89eac1
1 changed files with 83 additions and 82 deletions

View File

@ -398,18 +398,18 @@ bool RefineE(MESH_TYPE &m, MIDPOINT mid, EDGEPRED ep,bool RefineSelected=false,
FaceIterator oldendf = lastf;
/*
v0
f0
mp01 f3 mp02
f1 f2
v1 mp12 v2
* v0
*
*
* f0
*
* mp01 f3 mp02
*
*
* f1 f2
*
*v1 mp12 v2
*
*/
VertexPointer vv[6]; // The six vertices that arise in the single triangle splitting
@ -439,8 +439,9 @@ bool RefineE(MESH_TYPE &m, MIDPOINT mid, EDGEPRED ep,bool RefineSelected=false,
for(i=1;i<SplitTab[ind].TriNum;++i){
nf[i]=&*lastf; ++lastf; fca++;
if(RefineSelected || (*fi).IsS()) (*nf[i]).SetS();
if(tri::HasPerFaceColor(m))
nf[i]->C()=(*fi).cC();
nf[i]->ImportData(*fi);
// if(tri::HasPerFaceColor(m))
// nf[i]->C()=(*fi).cC();
}