corrected bug in the face laplacian normal smoothing
This commit is contained in:
parent
4778217ec5
commit
64d7f31279
|
|
@ -71,7 +71,7 @@ public:
|
||||||
// This is precisely what curvature flow does.
|
// This is precisely what curvature flow does.
|
||||||
// Curvature flow smoothes the surface by moving along the surface
|
// Curvature flow smoothes the surface by moving along the surface
|
||||||
// normal n with a speed equal to the mean curvature
|
// normal n with a speed equal to the mean curvature
|
||||||
void VertexCoordLaplacianCurvatureFlow(MeshType &m, int step, ScalarType delta)
|
void VertexCoordLaplacianCurvatureFlow(MeshType &/*m*/, int /*step*/, ScalarType /*delta*/)
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -962,13 +962,13 @@ static void FaceNormalLaplacianFF(MeshType &m, int step=1, bool SmoothSelected=f
|
||||||
|
|
||||||
FaceIterator fi;
|
FaceIterator fi;
|
||||||
tri::UpdateNormals<MeshType>::AreaNormalizeFace(m);
|
tri::UpdateNormals<MeshType>::AreaNormalizeFace(m);
|
||||||
for(int i=0;i<step;++i)
|
for(int iStep=0;iStep<step;++iStep)
|
||||||
{
|
{
|
||||||
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())
|
||||||
{
|
{
|
||||||
CoordType normalSum=(*fi).N();
|
CoordType normalSum=(*fi).N();
|
||||||
|
|
||||||
for(i=0;i<3;++i)
|
for(int i=0;i<3;++i)
|
||||||
normalSum+=(*fi).FFp(i)->N();
|
normalSum+=(*fi).FFp(i)->N();
|
||||||
|
|
||||||
TDF[*fi].m=normalSum;
|
TDF[*fi].m=normalSum;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue