From 573c1512416cf33c1efd7d642aef33ff09f1c662 Mon Sep 17 00:00:00 2001 From: ganovelli Date: Thu, 29 Jan 2009 11:27:32 +0000 Subject: [PATCH] bug on search cycle corrected (it was looping forever with vertices and twice slower with other elements) --- vcg/space/index/space_iterators.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vcg/space/index/space_iterators.h b/vcg/space/index/space_iterators.h index dd169c91..5194e230 100644 --- a/vcg/space/index/space_iterators.h +++ b/vcg/space/index/space_iterators.h @@ -476,8 +476,8 @@ namespace vcg{ CurrentElem = Elems.rbegin(); if ((!End())&& ToUpdate()) - while ((!End())&& Refresh()&&(!_EndGrid())) - _NextShell(); + do{_NextShell();} + while (Refresh()&&(!_EndGrid())); } ObjType &operator *(){return *((*CurrentElem).elem);}