- Main Page
- Classes
- Files
- Directories
- Examples

- File List
- File Members

# fbxobjectscontainer.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_SCENE_OBJECTS_CONTAINER_H_
    00014 #define _FBXSDK_SCENE_OBJECTS_CONTAINER_H_
    00015
    00016 #include <fbxsdk/fbxsdk_def.h>
    00017
    00018 #include <fbxsdk/core/base/fbxarray.h>
    00019 #include <fbxsdk/scene/fbxscene.h>
    00020
    00021 #include <fbxsdk/fbxsdk_nsbegin.h>
    00022
    00023 typedef FbxArray<FbxNodeAttribute::EType> FbxAttributeFilters;
    00024
    00025 /* Internal helper class used to traverse scene in the FbxAxisSystem and FbxSystemUnit
    00026  */
    00027 class FbxObjectsContainer
    00028 {
    00029 public:
    00030     enum EDepth
    00031     {
    00032         eChildOnly,
    00033         eChildAndSubChild,
    00034         eSubChildWithNoScaleInherit
    00035     };
    00036
    00037     FbxObjectsContainer() : mStartNode(NULL) {}
    00038     virtual ~FbxObjectsContainer(){ Clear(); }
    00039
    00040     // Store all anim curve nodes pointers that need to be converted
    00041     FbxArray<FbxAnimCurveNode*> mFCurvesT;
    00042     FbxArray<FbxAnimCurveNode*> mFCurvesR;
    00043     FbxArray<FbxAnimCurveNode*> mFCurvesS;
    00044
    00045     // Store all node that need to be converted
    00046     FbxArray<FbxNode*> mNodes;
    00047
    00048 public:
    00049     void ExtractSceneObjects(FbxScene* pScene, EDepth pDepth, const FbxAttributeFilters& pFilters);
    00050
    00051     void ExtractSceneObjects(FbxNode* pRootNode, EDepth pDepth, const FbxAttributeFilters& pFilters);
    00052
    00053     void Clear() { mFCurvesT.Clear(); mFCurvesR.Clear(); mFCurvesS.Clear(); mNodes.Clear(); mStartNode = NULL; }
    00054
    00055 protected:
    00056     // Extract all node and fcurve from all take for this node.
    00057     void ExtractNodesAnimCurveNodes(FbxNode* pNode, EDepth pDepth, const FbxAttributeFilters& pFilters);
    00058     void ExtractAnimCurveNodes(FbxNode* pNode);
    00059     bool InheritsScale( FbxNode* pNode ) const;
    00060
    00061     FbxNode* mStartNode;
    00062 };
    00063
    00064 #include <fbxsdk/fbxsdk_nsend.h>
    00065
    00066 #endif /* _FBXSDK_SCENE_OBJECTS_CONTAINER_H_ */