00001 /**************************************************************************************** 00002 00003 Copyright (C) 2012 Autodesk, Inc. 00004 All rights reserved. 00005 00006 Use of this software is subject to the terms of the Autodesk license agreement 00007 provided at the time of installation or download, or which otherwise accompanies 00008 this software in either electronic or hard copy form. 00009 00010 ****************************************************************************************/ 00011 00013 #ifndef _FBXSDK_SCENE_GEOMETRY_SKIN_H_ 00014 #define _FBXSDK_SCENE_GEOMETRY_SKIN_H_ 00015 00016 #include <fbxsdk/fbxsdk_def.h> 00017 00018 #include <fbxsdk/core/math/fbxmatrix.h> 00019 #include <fbxsdk/core/base/fbxerror.h> 00020 #include <fbxsdk/scene/geometry/fbxdeformer.h> 00021 #include <fbxsdk/scene/fbxgroupname.h> 00022 00023 #include <fbxsdk/fbxsdk_nsbegin.h> 00024 00025 class FbxManager; 00026 class FbxGeometry; 00027 class FbxCluster; 00028 class FbxNode; 00029 00042 class FBXSDK_DLL FbxSkin : public FbxDeformer 00043 { 00044 FBXSDK_OBJECT_DECLARE(FbxSkin,FbxDeformer); 00045 00046 public: 00052 void SetDeformAccuracy(double pDeformAccuracy); 00053 00057 double GetDeformAccuracy() const; 00058 00063 bool SetGeometry(FbxGeometry* pGeometry); 00064 00068 FbxGeometry* GetGeometry(); 00069 00074 bool AddCluster(FbxCluster* pCluster); 00075 00080 FbxCluster* RemoveCluster(FbxCluster* pCluster); 00081 00085 int GetClusterCount() const; 00086 00091 FbxCluster* GetCluster(int pIndex); 00092 00097 FbxCluster const* GetCluster(int pIndex) const; 00098 00102 EDeformerType GetDeformerType() const {return eSkin; }; 00103 00111 enum EType 00112 { 00113 eRigid, 00114 eLinear, 00115 eDualQuaternion, 00116 eBlend 00117 }; 00118 00122 void SetSkinningType(EType pType); 00123 00127 EType GetSkinningType() const; 00128 00137 00145 void AddControlPointIndex(int pIndex, double pBlendWeight = 0); 00146 00151 int GetControlPointIndicesCount() const; 00152 00157 int* GetControlPointIndices() const; 00158 00163 double* GetControlPointBlendWeights() const; 00164 00169 void SetControlPointIWCount(int pCount); 00170 00172 00174 // 00175 // WARNING! 00176 // 00177 // Anything beyond these lines may not be documented accurately and is 00178 // subject to change without notice. 00179 // 00181 #ifndef DOXYGEN_SHOULD_SKIP_THIS 00182 00183 virtual FbxObject& Copy(const FbxObject& pObject); 00184 00185 protected: 00186 FbxSkin(FbxManager& pManager, char const* pName); 00187 00188 virtual FbxStringList GetTypeFlags() const; 00189 00190 // Skin deformer 00191 double mDeformAccuracy; 00192 EType mSkinningType; 00193 00194 //Control points 00195 FbxArray<int> mControlPointIndices; 00196 FbxArray<double> mControlPointBlendWeights; 00197 00198 friend class FbxScene; 00199 00200 #endif // #ifndef DOXYGEN_SHOULD_SKIP_THIS 00201 }; 00202 00203 #include <fbxsdk/fbxsdk_nsend.h> 00204 00205 #endif /* _FBXSDK_SCENE_GEOMETRY_SKIN_H_ */