fbxcolladaanimationelement.h

Go to the documentation of this file.
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_FILEIO_COLLADA_ANIMATION_ELEMENT_H_
00014 #define _FBXSDK_FILEIO_COLLADA_ANIMATION_ELEMENT_H_
00015 
00016 //----------------------------------------------------------------------------//
00017 
00018 #include <map>
00019 #include "fbxcolladaelement.h"
00020 
00021 #include <fbxsdk/fbxsdk_nsbegin.h>
00022 
00023 FBX_COLLADA_NAMESPACE_OPEN
00024 
00025 //----------------------------------------------------------------------------//
00026 
00029 class AnimationElement : public ElementBase
00030 {
00031 public:
00032     typedef ElementBase base_type;
00033 
00034     AnimationElement();
00035     virtual ~AnimationElement();
00036 
00040     int GetChannelCount() const;
00041 
00045     void FromCOLLADA(xmlNode * pElement, const std::map< FbxString, xmlNode* > & pSourceElements);
00046 
00052     void FromFBX(const FbxAnimCurve * pCurve, double pUnitConversion = 1.0);
00053 
00059     void ToFBX(FbxAnimCurve * pFBXCurve, int pChannelIndex,
00060         double pUnitConversion = 1.0) const;
00061 
00066     void ToFBX(FbxNode * pFBXNode, FbxAnimLayer * pAnimLayer,
00067         double pUnitConversion = 1.0) const;
00068 
00074     void ToCOLLADA(xmlNode * pAnimationLibrary, const char * pNodeID,
00075         const char * pAttributeSID);
00076 
00077 private:
00078     int mKeyCount;
00079     double * mInputArray;
00080     double * mOutputArray;
00081     int mOutputStride;
00082     FbxString * mInterpolationArray;
00083     int mInterpolationStride;
00084     double * mInTangentArray;
00085     int mInTangentStride;
00086     double * mOutTangentArray;
00087     int mOutTangentStride;
00088 };
00089 
00090 FBX_COLLADA_NAMESPACE_CLOSE
00091 
00092 #include <fbxsdk/fbxsdk_nsend.h>
00093 
00094 #endif /* _FBXSDK_FILEIO_COLLADA_ANIMATION_ELEMENT_H_ */