readd VertexInfluence whenever it's bad named and kinda useless

This commit is contained in:
Julien Valentin
2017-08-30 15:13:54 +02:00
parent 6d1193ee70
commit 8fad310ce1
7 changed files with 34 additions and 18 deletions

View File

@@ -89,14 +89,16 @@ void VertexInfluenceMap::cullInfluenceCountPerVertex(unsigned int numbonepervert
if(sum>1e-4){
sum=1.0f/sum;
for(BoneWeightOrdered::iterator bwit=bwset.begin(); bwit!=bwset.end(); ++bwit) {
IndexWeightList & inf= (*this)[bwit->getBoneName()];
VertexInfluence & inf= (*this)[bwit->getBoneName()];
inf.push_back(IndexWeight(mapit->first, bwit->getWeight()*sum));
inf.setName(bwit->getBoneName());
}
}
}else{
for(BoneWeightOrdered::iterator bwit=bwset.begin(); bwit!=bwset.end(); ++bwit) {
IndexWeightList & inf= (*this)[bwit->getBoneName()];
VertexInfluence & inf= (*this)[bwit->getBoneName()];
inf.push_back(IndexWeight(mapit->first,bwit->getWeight()));
inf.setName(bwit->getBoneName());
}
}