- Cal3D 0.11 API Reference -

skeleton.h

00001 //****************************************************************************//
00002 // skeleton.h                                                                 //
00003 // Copyright (C) 2001, 2002 Bruno 'Beosil' Heidelberger                       //
00004 //****************************************************************************//
00005 // This library is free software; you can redistribute it and/or modify it    //
00006 // under the terms of the GNU Lesser General Public License as published by   //
00007 // the Free Software Foundation; either version 2.1 of the License, or (at    //
00008 // your option) any later version.                                            //
00009 //****************************************************************************//
00010 
00011 #ifndef CAL_SKELETON_H
00012 #define CAL_SKELETON_H
00013 
00014 #include "cal3d/global.h"
00015 
00016 class CalCoreSkeleton;
00017 class CalCoreModel;
00018 class CalBone;
00019 
00020 class CAL3D_API CalSkeleton
00021 {
00022 public:
00023   CalSkeleton(CalCoreSkeleton *pCoreSkeleton);
00024   ~CalSkeleton();
00025 
00026   void calculateState();
00027   void clearState();
00028   bool create(CalCoreSkeleton *pCoreSkeleton);
00029   CalBone *getBone(int boneId);
00030   const CalBone *getBone(int boneId) const;
00031   CalCoreSkeleton *getCoreSkeleton();
00032   const CalCoreSkeleton *getCoreSkeleton() const;
00033   std::vector<CalBone *>& getVectorBone();
00034   const std::vector<CalBone *>& getVectorBone() const;
00035   void lockState();
00036   void getBoneBoundingBox(float *min, float *max);
00037   void calculateBoundingBoxes();
00038 
00039   // DEBUG-CODE
00040   int getBonePoints(float *pPoints) const;
00041   int getBonePointsStatic(float *pPoints) const;
00042   int getBoneLines(float *pLines) const;
00043   int getBoneLinesStatic(float *pLines) const;
00044 
00045 private:
00046   CalCoreSkeleton       *m_pCoreSkeleton;
00047   std::vector<CalBone *> m_vectorBone;
00048   bool                   m_isBoundingBoxesComputed;
00049 };
00050 
00051 #endif
00052 
00053 //****************************************************************************//

Generated by The Cal3D Team with Doxygen 1.7.3