From bb8d80c311054fb2ada80292c246a45a62bda746 Mon Sep 17 00:00:00 2001 From: nicopietroni Date: Sun, 12 Apr 2015 06:12:51 +0000 Subject: [PATCH] added the possibility to set user added constraints --- wrap/igl/smooth_field.h | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/wrap/igl/smooth_field.h b/wrap/igl/smooth_field.h index 2c0147e9..8fde04ff 100644 --- a/wrap/igl/smooth_field.h +++ b/wrap/igl/smooth_field.h @@ -333,6 +333,8 @@ public: SmoothMethod SmoothM; //the number of faces of the ring used ot esteem the curvature int curvRing; + //this are additional hard constraints + std::vector > AddConstr; SmoothParam() { @@ -353,7 +355,7 @@ public: static void SelectConstraints(MeshType &mesh,SmoothParam &SParam) { //clear all selected faces - vcg::tri::UpdateFlags::FaceClearS(mesh); + vcg::tri::UpdateFlags::FaceClear(mesh); //add curvature hard constraints //ScalarType Ratio=mesh.bbox.Diag()*0.01; @@ -368,6 +370,18 @@ public: //add border constraints if (SParam.align_borders) AddBorderConstraints(mesh); + + //aff final constraints + for (int i=0;i