using a custom compare function instead of a global aiVector3t less than operator
This commit is contained in:
@@ -261,7 +261,7 @@ void ObjExporter :: WriteGeometryFile()
|
||||
|
||||
int ObjExporter::vecIndexMap::getIndex(const aiVector3D& vec)
|
||||
{
|
||||
std::map<aiVector3D, int>::iterator vertIt = vecMap.find(vec);
|
||||
vecIndexMap::dataType::iterator vertIt = vecMap.find(vec);
|
||||
if(vertIt != vecMap.end()){// vertex already exists, so reference it
|
||||
return vertIt->second;
|
||||
}
|
||||
@@ -274,7 +274,7 @@ int ObjExporter::vecIndexMap::getIndex(const aiVector3D& vec)
|
||||
void ObjExporter::vecIndexMap::getVectors( std::vector<aiVector3D>& vecs )
|
||||
{
|
||||
vecs.resize(vecMap.size());
|
||||
for(std::map<aiVector3D, int>::iterator it = vecMap.begin(); it != vecMap.end(); it++){
|
||||
for(vecIndexMap::dataType::iterator it = vecMap.begin(); it != vecMap.end(); it++){
|
||||
vecs[it->second-1] = it->first;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user