From 9691602218739df966d15498c3fe9f1f4c5ac18c Mon Sep 17 00:00:00 2001 From: nico Date: Wed, 21 Nov 2018 23:18:17 +1100 Subject: [PATCH] made the LaplacianReproject independent wrt scalar type used for the tri mesh --- vcg/complex/algorithms/polygonal_algorithms.h | 29 ++++++++++++------- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/vcg/complex/algorithms/polygonal_algorithms.h b/vcg/complex/algorithms/polygonal_algorithms.h index 972d4af0..d27c6b57 100644 --- a/vcg/complex/algorithms/polygonal_algorithms.h +++ b/vcg/complex/algorithms/polygonal_algorithms.h @@ -598,14 +598,16 @@ public: int nstep=100, ScalarType Damp=0.5) { - typedef typename TriMeshType::FaceType FaceType; - typedef vcg::GridStaticPtr TriMeshGrid; + typedef typename TriMeshType::FaceType TriFaceType; + typedef typename TriMeshType::ScalarType TriScalarType; + typedef typename TriMeshType::CoordType TriCoordType; + typedef vcg::GridStaticPtr TriMeshGrid; TriMeshGrid grid; //initialize the grid grid.Set(tri_mesh.face.begin(),tri_mesh.face.end()); - ScalarType MaxD=tri_mesh.bbox.Diag(); + TriScalarType MaxD=tri_mesh.bbox.Diag(); for (int s=0;s::PerVertexNormalizedPerFace(GuideSurf); vcg::tri::UpdateTopology::FaceFace(GuideSurf); vcg::tri::UpdateFlags::FaceBorderFromFF(GuideSurf); - LaplacianReproject(poly_m,GuideSurf,nstep,Damp=0.5); + LaplacianReproject(poly_m,GuideSurf,nstep,Damp=0.5); } static void Laplacian(PolyMeshType &poly_m,