Excluded from the computation of the mass intergrals the faces with an area that is <= std num limits <scalar>::min()

This commit is contained in:
Paolo Cignoni 2013-07-03 21:44:39 +00:00
parent 1655f806df
commit 7b8f21ba7a
1 changed files with 15 additions and 15 deletions

View File

@ -197,7 +197,7 @@ void Compute(MeshType &m)
= T2[X] = T2[Y] = T2[Z]
= TP[X] = TP[Y] = TP[Z] = 0;
FaceIterator fi;
for (fi=m.face.begin(); fi!=m.face.end();++fi) if(!(*fi).IsD()) {
for (fi=m.face.begin(); fi!=m.face.end();++fi) if(!(*fi).IsD() && vcg::DoubleArea(*fi)>std::numeric_limits<float>::min()) {
FaceType &f=(*fi);
nx = fabs(f.N()[0]);