44 #ifndef SKELETONOBJECTDATA_HH 45 #define SKELETONOBJECTDATA_HH 49 #define OBJECTDATA_SKELETON "Skeleton Object Data" 82 int skin(
unsigned int _index ){
83 if ( _index >= skins_.size() )
85 return skins_[_index];
100 for(
unsigned int i=0; i < skins_.size(); i++)
101 if ( skins_[i] == _objectId )
104 skins_.push_back(_objectId);
112 for(
unsigned int i=0; i < skins_.size(); i++)
113 if ( skins_[i] == _objectId ){
114 skins_.erase( skins_.begin() + i );
118 std::cerr <<
"Cannot remove skin with object id:" << _objectId <<
". Not found!" << std::endl;
130 std::vector< int > skins_;
133 #endif //SKELETONOBJECTDATA_HH PerObjectData()
You have to provide your own constructor for your object.
int skin(unsigned int _index)
Get the skin with given index (0 <= _index < skinCount())
void addSkin(int _objectId)
Add a skin to the skeleton.
unsigned int skinCount()
Get the number of associated skins.
PerObjectData * copyPerObjectData()
Copy Function.
void removeSkin(int _objectId)
Remove a skin from the skeleton.
Data object attached to the skeleton.
void clearSkins()
Remove all skins from the skeleton.