Changed IPToP calls into IPiToPf, Markers passed by reference

This commit is contained in:
Paolo Cignoni 2008-10-31 10:40:06 +00:00
parent 0f2d864e05
commit dfc6417426
1 changed files with 41 additions and 41 deletions

View File

@ -98,7 +98,7 @@ namespace vcg{
///da verificare se vanno oltre ai limiti
vcg::Point3i ip;
Si.PToIP(start,ip);
Si.IPToP(ip,goal);
Si.IPiToPf(ip,goal);
for (int i=0;i<3;i++)
if(r.Direction().V(i)>0.0)
goal.V(i)+=Si.voxel.V(i);
@ -144,8 +144,8 @@ namespace vcg{
assert(!end);
vcg::Box3<ScalarType> bb_current;
Si.IPToP(CurrentCell,bb_current.min);
Si.IPToP(CurrentCell+vcg::Point3i(1,1,1),bb_current.max);
Si.IPiToPf(CurrentCell,bb_current.min);
Si.IPiToPf(CurrentCell+vcg::Point3i(1,1,1),bb_current.max);
CoordType inters;
Intersection_Ray_Box(bb_current,r,inters);
@ -194,7 +194,7 @@ namespace vcg{
max_dist=_max_dist;
};
void SetMarker(TMARKER _tm)
void SetMarker(TMARKER & _tm)
{
tm=_tm;
}
@ -315,7 +315,7 @@ namespace vcg{
Spatial_Idexing &Si; //reference to spatial index algorithm
bool end; //true if the scan is terminated
INTFUNCTOR &int_funct;
TMARKER tm;
TMARKER& tm;
std::vector<Entry_Type> Elems; //element loaded from curren cell
typedef typename std::vector<Entry_Type>::reverse_iterator ElemIterator;