remove utility classes BoneWeight and IndexWeight in order to avoid unnecessary symbols
(but decrease a bit clarity of the code)
This commit is contained in:
@@ -25,26 +25,14 @@
|
||||
namespace osgAnimation
|
||||
{
|
||||
// first is bonename, and second the weight
|
||||
struct BoneWeight: public std::pair<std::string, float>
|
||||
{
|
||||
BoneWeight( std::string f,float s):
|
||||
std::pair<std::string,float>(f,s){}
|
||||
inline const std::string& getBoneName()const{return first;}
|
||||
inline void setBoneName(const std::string&s){first=s;}
|
||||
inline const float &getWeight()const{return second;}
|
||||
inline void setWeight(float i){second=i;}
|
||||
};
|
||||
typedef std::pair<std::string, float> BoneWeight;
|
||||
// first is vertex index, and second the weight
|
||||
struct VertexIndexWeight: public std::pair<unsigned int, float>
|
||||
{
|
||||
VertexIndexWeight( unsigned int f = 0xffffffff,float s = 0.0f): std::pair<unsigned int,float>(f,s){}
|
||||
inline const unsigned int& getIndex()const{return first;}
|
||||
inline void setIndex(unsigned int i){first=i;}
|
||||
inline const float &getWeight()const{return second;}
|
||||
inline void setWeight(float i){second=i;}
|
||||
};
|
||||
typedef std::pair<unsigned int, float> VertexIndexWeight;
|
||||
// list of IndexWeight
|
||||
typedef std::vector<VertexIndexWeight> IndexWeightList;
|
||||
// list of IndexWeight
|
||||
typedef std::vector<BoneWeight> BoneWeightList;
|
||||
// list of Index
|
||||
typedef std::vector<unsigned int> IndexList;
|
||||
|
||||
//Bone influence list
|
||||
|
||||
Reference in New Issue
Block a user