From 1ada6a63ce0ec3eb8edb7ff69ad179462d3ca679 Mon Sep 17 00:00:00 2001 From: cnr-isti-vclab Date: Mon, 2 Oct 2006 12:06:40 +0000 Subject: [PATCH] BugFix --- vcg/complex/trimesh/hole.h | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/vcg/complex/trimesh/hole.h b/vcg/complex/trimesh/hole.h index d6d4b26f..7c14da15 100644 --- a/vcg/complex/trimesh/hole.h +++ b/vcg/complex/trimesh/hole.h @@ -24,6 +24,9 @@ History $Log: not supported by cvs2svn $ +Revision 1.3 2006/09/27 15:33:32 giec +It close one simple hole . . . + Revision 1.2 2006/09/27 09:29:53 giec Frist working release whit a few bugs. It almost fills the hole ... @@ -419,6 +422,7 @@ typename MESH::FaceIterator CloseHole(MESH &m, HoleInfo &h) std::vector > ES; //set > ES; // vettore con tutti gli edge adiacenti al buco. + h.CollectEdges(ES); vector H; // Heap delle ear da chiudere H.reserve(h.size); @@ -467,9 +471,8 @@ typename MESH::FaceIterator CloseHole(MESH &m, HoleInfo &h) if(H.back().IsUpToDate()) { - if(/*!*/H.back().Degen() && it != ES.end()){ + if(H.back().Degen() && it != ES.end()){ // Nota che nel caso di ear degeneri si DEVE permettere la creazione di un edge che gia'esiste - //TRACE("Evitata orecchia brutta!"); printf("\n -> Evitata orecchia brutta!"); } else { @@ -493,7 +496,7 @@ typename MESH::FaceIterator CloseHole(MESH &m, HoleInfo &h) } --cnt; ++f; - //return firstf;///////////////dbug + } } } @@ -516,8 +519,6 @@ typename MESH::FaceIterator CloseHole(MESH &m, HoleInfo &h) } } H.pop_back(); - make_heap(H.begin(),H.end()); - }