const correctness mesh_to_matrix.h PerVertexArea
This commit is contained in:
parent
96ad3c4f3a
commit
3932ce448b
|
|
@ -240,11 +240,11 @@ public:
|
||||||
tri::RequireCompactness(m);
|
tri::RequireCompactness(m);
|
||||||
h.resize(m.vn);
|
h.resize(m.vn);
|
||||||
fill(h.begin(),h.end(),0);
|
fill(h.begin(),h.end(),0);
|
||||||
for(FaceIterator fi=m.face.begin(); fi!=m.face.end();++fi)
|
for (int i = 0; i < m.FN(); ++i)
|
||||||
{
|
{
|
||||||
ScalarType a = DoubleArea(*fi)/6.0;
|
ScalarType a = DoubleArea(m.face[i])/6.0;
|
||||||
for(int j=0;j<fi->VN();++j)
|
for(int j=0;j<m.face[i].VN();++j)
|
||||||
h[tri::Index(m,fi->V(j))] += a;
|
h[tri::Index(m,m.face[i].cV(j))] += a;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue