corrected bug in the number of added vertices

This commit is contained in:
ganovelli 2008-08-19 09:09:44 +00:00
parent 5843045302
commit 4ac273db73
1 changed files with 2 additions and 1 deletions

View File

@ -149,7 +149,8 @@ void SubSet(S_MESH_TYPE & m, STL_CONT & subSet)
}
typename std::vector< InsertedV<S_MESH_TYPE> >::iterator newE=unique(newVertices.begin(), newVertices.end());
vi = vcg::tri::Allocator<S_MESH_TYPE>::AddVertices(m,newVertices.size());
vi = vcg::tri::Allocator<S_MESH_TYPE>::AddVertices(m,newE-newVertices.begin());
for(curr=newVertices.begin(); curr!=newE; ++curr,++vi)
(*vi).ImportLocal(*((*curr).v));