- Cal3D 0.9 API Reference -

coreanimation.h

00001 //****************************************************************************//
00002 // coreanimation.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_COREANIMATION_H
00012 #define CAL_COREANIMATION_H
00013 
00014 
00015 #include "cal3d/global.h"
00016 
00017 
00018 class CalCoreTrack;
00019 struct CalAnimationCallback;
00020 
00021 class CAL3D_API CalCoreAnimation
00022 {
00023 public:
00024   CalCoreAnimation();
00025   ~CalCoreAnimation();
00026 
00027   void addCoreTrack(CalCoreTrack *pCoreTrack);
00028   CalCoreTrack *getCoreTrack(int coreBoneId);
00029   float getDuration();
00030   std::list<CalCoreTrack *>& getListCoreTrack();
00031   void setDuration(float duration);
00032   void scale(float factor);
00033   void setFilename(const std::string& filename);
00034   const std::string& getFilename(void);
00035   void setName(const std::string& name);
00036   const std::string& getName(void);
00037   void incRef();
00038   bool decRef();  
00039 
00040   void registerCallback(CalAnimationCallback *callback,float min_interval);
00041   void removeCallback(CalAnimationCallback *callback);
00042 
00043   struct CallbackRecord
00044   {
00045     CalAnimationCallback *callback;
00046     float                 min_interval;
00047   };
00048 
00049   std::vector<CallbackRecord>& getCallbackList() { return m_listCallbacks; }
00050 
00051 private:
00052 
00053 
00054   std::vector<CallbackRecord> m_listCallbacks;
00055 
00056   float m_duration;
00057   std::list<CalCoreTrack *>   m_listCoreTrack;
00058   std::string m_name;
00059   std::string m_filename;
00060 
00061   int m_referenceCount;
00062 };
00063 
00064 #endif
00065 
00066 //****************************************************************************//

Generated at Mon Jul 3 11:16:28 2006 by The Cal3D Team with doxygen 1.4.6 © 1997-2001 Dimitri van Heesch