Corrected typename usage and removed excess ';' from end of template functions, for gcc compiling

This commit is contained in:
Paolo Cignoni 2005-12-02 00:30:27 +00:00
parent 02e28cc9e5
commit 03007bab77
1 changed files with 9 additions and 6 deletions

View File

@ -24,6 +24,9 @@
History History
$Log: not supported by cvs2svn $ $Log: not supported by cvs2svn $
Revision 1.6 2005/10/03 13:57:32 pietroni
added GridGetInSphere and GridGetInBox functions
Revision 1.5 2005/10/02 23:18:06 cignoni Revision 1.5 2005/10/02 23:18:06 cignoni
Small bug in the computation of the intersection between the todo box and the grid bbox that failed for extrema points. Small bug in the computation of the intersection between the todo box and the grid bbox that failed for extrema points.
@ -79,7 +82,7 @@ namespace vcg{
typename SPATIAL_INDEX:: CoordType &_closestPt) typename SPATIAL_INDEX:: CoordType &_closestPt)
{ {
typedef typename SPATIAL_INDEX::ObjPtr ObjPtr; typedef typename SPATIAL_INDEX::ObjPtr ObjPtr;
typedef typename SPATIAL_INDEX SpatialIndex; typedef SPATIAL_INDEX SpatialIndex;
typedef typename SPATIAL_INDEX::CoordType CoordType; typedef typename SPATIAL_INDEX::CoordType CoordType;
typedef typename SPATIAL_INDEX::ScalarType ScalarType; typedef typename SPATIAL_INDEX::ScalarType ScalarType;
typedef typename SPATIAL_INDEX::Box3x Box3x; typedef typename SPATIAL_INDEX::Box3x Box3x;
@ -93,7 +96,7 @@ namespace vcg{
ScalarType radius; ScalarType radius;
Box3i iboxdone,iboxtodo; Box3i iboxdone,iboxtodo;
CoordType t_res; CoordType t_res;
SPATIAL_INDEX::CellIterator first,last,l; typename SPATIAL_INDEX::CellIterator first,last,l;
if(Si.bbox.IsInEx(_p)) if(Si.bbox.IsInEx(_p))
{ {
Point3i _ip; Point3i _ip;
@ -153,7 +156,7 @@ namespace vcg{
while (_minDist>radius); while (_minDist>radius);
return winner; return winner;
}; }
template <class SPATIALINDEXING,class OBJPOINTDISTFUNCTOR, class OBJMARKER, template <class SPATIALINDEXING,class OBJPOINTDISTFUNCTOR, class OBJMARKER,
class OBJPTRCONTAINER, class DISTCONTAINER, class POINTCONTAINER> class OBJPTRCONTAINER, class DISTCONTAINER, class POINTCONTAINER>
@ -184,7 +187,7 @@ namespace vcg{
i++; i++;
} }
return (i); return (i);
}; }
template <class SPATIALINDEXING,class OBJRAYISECTFUNCTOR, class OBJMARKER> template <class SPATIALINDEXING,class OBJRAYISECTFUNCTOR, class OBJMARKER>
typename SPATIALINDEXING::ObjPtr GridDoRay(SPATIALINDEXING &_Si, typename SPATIALINDEXING::ObjPtr GridDoRay(SPATIALINDEXING &_Si,
@ -241,7 +244,7 @@ namespace vcg{
const vcg::Box3<typename SPATIALINDEXING::ScalarType> _bbox, const vcg::Box3<typename SPATIALINDEXING::ScalarType> _bbox,
OBJPTRCONTAINER & _objectPtrs) OBJPTRCONTAINER & _objectPtrs)
{ {
SPATIALINDEXING::CellIterator first,last,l; typename SPATIALINDEXING::CellIterator first,last,l;
_objectPtrs.clear(); _objectPtrs.clear();
vcg::Box3i ibbox; vcg::Box3i ibbox;
Box3i Si_ibox(Point3i(0,0,0),_Si.siz-Point3i(1,1,1)); Box3i Si_ibox(Point3i(0,0,0),_Si.siz-Point3i(1,1,1));
@ -261,7 +264,7 @@ namespace vcg{
for(l=first;l!=last;++l) for(l=first;l!=last;++l)
if (!(**l).IsD()) if (!(**l).IsD())
{ {
SPATIALINDEXING::ObjPtr elem=&(**l); typename SPATIALINDEXING::ObjPtr elem=&(**l);
if( ! _marker.IsMarked(elem)){ if( ! _marker.IsMarked(elem)){
_objectPtrs.push_back(elem); _objectPtrs.push_back(elem);
_marker.Mark(elem); _marker.Mark(elem);