swap priority in BonePtrWeight comparator< yeild the same VG set

This commit is contained in:
Julien Valentin
2017-08-29 17:32:19 +02:00
parent ce6a316bde
commit fae9729560
2 changed files with 4 additions and 6 deletions

View File

@@ -51,11 +51,9 @@ namespace osgAnimation
inline const float & getWeight() const {return second;}
inline void setWeight(float b) {second=b;}
inline bool operator<(const BonePtrWeight &b1) const{
if (getBonePtr() < b1.getBonePtr())
return true;
else if (getBonePtr() > b1.getBonePtr())
return false;
return (getWeight() < b1.getWeight());
if (second > b1.second)return true;
if (second < b1.second)return false;
return (first.get() > b1.first.get());
}
};
typedef std::vector<BonePtrWeight> BonePtrWeightList;