removed old style usage of hash map and substituted with c+11 sytle unordered set and map.
This commit is contained in:
parent
47aaea332a
commit
f0c3d52849
|
@ -21,30 +21,11 @@
|
|||
* *
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
History
|
||||
|
||||
$Log: not supported by cvs2svn $
|
||||
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __VCGLIB_TRI_CLIP
|
||||
#define __VCGLIB_TRI_CLIP
|
||||
#include <unordered_map>
|
||||
#include <vcg/complex/complex.h>
|
||||
|
||||
#include <vector>
|
||||
|
||||
#ifdef _WIN32
|
||||
#ifndef __MINGW32__
|
||||
#include <hash_map>
|
||||
#define STDEXT stdext
|
||||
#else
|
||||
#include <ext/hash_map>
|
||||
#define STDEXT __gnu_cxx
|
||||
#endif
|
||||
#else
|
||||
#include <ext/hash_map>
|
||||
#define STDEXT __gnu_cxx
|
||||
#endif
|
||||
namespace vcg
|
||||
{
|
||||
namespace tri
|
||||
|
@ -183,11 +164,11 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
typedef STDEXT::hash_map<unsigned int, EdgeIntersections> UIntHMap;
|
||||
typedef std::unordered_map<unsigned int, EdgeIntersections> UIntHMap;
|
||||
typedef typename UIntHMap::iterator UIntHMap_i;
|
||||
typedef typename UIntHMap::value_type UIntHMap_v;
|
||||
|
||||
typedef STDEXT::hash_map<unsigned int, UIntHMap> EdgeMap;
|
||||
typedef std::unordered_map<unsigned int, UIntHMap> EdgeMap;
|
||||
typedef typename EdgeMap::iterator EdgeMap_i;
|
||||
typedef typename EdgeMap::value_type EdgeMap_v;
|
||||
|
||||
|
@ -576,15 +557,15 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
typedef STDEXT::hash_map<unsigned int, EdgeIntersections> UIntHMap;
|
||||
typedef std::unordered_map<unsigned int, EdgeIntersections> UIntHMap;
|
||||
typedef typename UIntHMap::iterator UIntHMap_i;
|
||||
typedef typename UIntHMap::value_type UIntHMap_v;
|
||||
|
||||
typedef STDEXT::hash_map<unsigned int, UIntHMap> EdgeMap;
|
||||
typedef std::unordered_map<unsigned int, UIntHMap> EdgeMap;
|
||||
typedef typename EdgeMap::iterator EdgeMap_i;
|
||||
typedef typename EdgeMap::value_type EdgeMap_v;
|
||||
|
||||
typedef STDEXT::hash_map<unsigned int, unsigned int> UIHMap;
|
||||
typedef std::unordered_map<unsigned int, unsigned int> UIHMap;
|
||||
typedef typename UIHMap::iterator UIHMap_i;
|
||||
|
||||
typedef typename TriMeshType::ConstFaceIterator ConstFaceIterator;
|
||||
|
@ -715,8 +696,6 @@ public:
|
|||
|
||||
numTriangles += n - 2;
|
||||
|
||||
size_t vBegin = vInfos.size();
|
||||
|
||||
VertexClipInfo vnfo;
|
||||
TriangleInfo tnfo;
|
||||
|
||||
|
@ -926,9 +905,6 @@ public:
|
|||
return;
|
||||
}
|
||||
|
||||
const unsigned int vSize = (unsigned int)(m.vn);
|
||||
const unsigned int tSize = (unsigned int)(m.fn);
|
||||
|
||||
typedef Allocator<TriMeshType> TriMeshAllocatorType;
|
||||
|
||||
TriMeshAllocatorType::AddVertices(r, (int)(vInfos.size()));
|
||||
|
|
Loading…
Reference in New Issue