00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #ifndef CAL_CORESKELETON_H
00012 #define CAL_CORESKELETON_H
00013
00014 #include "cal3d/global.h"
00015
00016
00017 class CalCoreBone;
00018 class CalCoreModel;
00019
00020
00021 class CAL3D_API CalCoreSkeleton
00022 {
00023 public:
00024 CalCoreSkeleton();
00025 ~CalCoreSkeleton();
00026
00027 int addCoreBone(CalCoreBone *pCoreBone);
00028 void calculateState();
00029 CalCoreBone* getCoreBone(int coreBoneId);
00030 CalCoreBone* getCoreBone(const std::string& strName);
00031 int getCoreBoneId(const std::string& strName);
00032 bool mapCoreBoneName(int coreBoneId, const std::string& strName);
00033 std::list<int>& getListRootCoreBoneId();
00034 std::vector<CalCoreBone *>& getVectorCoreBone();
00035 void calculateBoundingBoxes(CalCoreModel * pCoreModel);
00036 void scale(float factor);
00037 void incRef();
00038 bool decRef();
00039
00040 private:
00041 std::vector<CalCoreBone *> m_vectorCoreBone;
00042 std::map< std::string, int > m_mapCoreBoneNames;
00043 std::list<int> m_listRootCoreBoneId;
00044 int m_referenceCount;
00045 };
00046
00047 #endif
00048
00049