00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #ifndef CAL_MODEL_H
00012 #define CAL_MODEL_H
00013
00014
00015 #include "cal3d/global.h"
00016 #include "cal3d/vector.h"
00017
00018
00019 class CalCoreModel;
00020 class CalSkeleton;
00021 class CalAbstractMixer;
00022 class CalMixer;
00023 class CalMorphTargetMixer;
00024 class CalPhysique;
00025 class CalSpringSystem;
00026 class CalRenderer;
00027 class CalMesh;
00028
00029
00030 class CAL3D_API CalModel : cal3d::noncopyable
00031 {
00032 public:
00033 CalModel(CalCoreModel* pCoreModel);
00034 ~CalModel();
00035
00036 bool attachMesh(int coreMeshId);
00037 bool detachMesh(int coreMeshId);
00038 CalCoreModel *getCoreModel() const;
00039 CalMesh *getMesh(int coreMeshId) const;
00040 CalMixer *getMixer() const;
00041 CalAbstractMixer *getAbstractMixer() const;
00042 void setAbstractMixer(CalAbstractMixer* pMixer);
00043 CalMorphTargetMixer *getMorphTargetMixer() const;
00044 CalPhysique *getPhysique() const;
00045 CalRenderer *getRenderer() const;
00046 CalSkeleton *getSkeleton() const;
00047 CalSpringSystem *getSpringSystem() const;
00048 CalBoundingBox & getBoundingBox(bool precision = false);
00049 Cal::UserData getUserData() const;
00050 std::vector<CalMesh *>& getVectorMesh();
00051 void setLodLevel(float lodLevel);
00052 void setMaterialSet(int setId);
00053 void setUserData(Cal::UserData userData);
00054 void update(float deltaTime);
00055 void disableInternalData();
00056
00057 private:
00058 CalCoreModel *m_pCoreModel;
00059 CalSkeleton *m_pSkeleton;
00060 CalAbstractMixer *m_pMixer;
00061 CalMorphTargetMixer *m_pMorphTargetMixer;
00062 CalPhysique *m_pPhysique;
00063 CalSpringSystem *m_pSpringSystem;
00064 CalRenderer *m_pRenderer;
00065 Cal::UserData m_userData;
00066 std::vector<CalMesh *> m_vectorMesh;
00067 CalBoundingBox m_boundingBox;
00068 };
00069
00070 #endif
00071
00072