fbxlayercontainer.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_GEOMETRY_LAYER_CONTAINER_H_
00014 #define _FBXSDK_SCENE_GEOMETRY_LAYER_CONTAINER_H_
00015 
00016 #include <fbxsdk/fbxsdk_def.h>
00017 
00018 #include <fbxsdk/scene/geometry/fbxnodeattribute.h>
00019 #include <fbxsdk/scene/geometry/fbxlayer.h>
00020 
00021 #include <fbxsdk/core/base/fbxarray.h>
00022 
00023 #include <fbxsdk/core/math/fbxvector4.h>
00024 
00025 #include <fbxsdk/fbxsdk_nsbegin.h>
00026 
00027 class FbxManager;
00028 
00029 
00036 class FBXSDK_DLL FbxLayerContainer : public FbxNodeAttribute
00037 {
00038     FBXSDK_OBJECT_DECLARE(FbxLayerContainer,FbxNodeAttribute);
00039 public:
00040 
00043     virtual FbxNodeAttribute::EType GetAttributeType() const;
00044 
00049 
00053     int CreateLayer();
00054 
00056     void ClearLayers();
00057 
00061     int GetLayerCount() const;
00062 
00068     int GetLayerCount(FbxLayerElement::EType pType,  bool pUVCount=false) const;
00069 
00074     FbxLayer* GetLayer(int pIndex);
00075 
00080     FbxLayer const* GetLayer(int pIndex) const;
00081 
00090     FbxLayer* GetLayer(int pIndex, FbxLayerElement::EType pType, bool pIsUV=false);
00091 
00100     FbxLayer const* GetLayer(int pIndex, FbxLayerElement::EType pType, bool pIsUV=false) const;
00101 
00110     int GetLayerIndex(int pIndex, FbxLayerElement::EType pType, bool pIsUV=false) const;
00111 
00118     int GetLayerTypedIndex(int pGlobalIndex, FbxLayerElement::EType pType, bool pIsUV=false) const;
00120 
00126     bool ConvertDirectToIndexToDirect(int pLayer);
00127 
00129 //
00130 //  WARNING!
00131 //
00132 //  Anything beyond these lines may not be documented accurately and is 
00133 //  subject to change without notice.
00134 //
00136 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00137 
00138     virtual FbxObject& Copy(const FbxObject& pObject);
00139 
00140     int  GTC(FbxUInt i, int j);
00141     void* GT (int  i,    FbxUInt l, int j); 
00142     int  AT (void* t,    FbxUInt l, int j);
00143     int  GTI(char const* n, FbxUInt l, int j);
00144     int  GMC(FbxUInt i, void* n = NULL);
00145     void* GM (int  i,    FbxUInt l, void* n = NULL);
00146     int  AM (void* m,    FbxUInt l, void* n = NULL, bool b = false);
00147     int  GMI(char const* n, FbxUInt l, void* d = NULL);
00148 
00149     int AddToLayerElementsList(FbxLayerElement* pLEl);
00150     void RemoveFromLayerElementsList(FbxLayerElement* pLEl);
00151 
00152 protected:
00153     FbxLayerContainer(FbxManager& pManager, char const* pName);
00154     virtual void Destruct(bool pRecursive, bool pDependents);
00155 
00156     void CopyLayers(FbxLayerContainer const* pLayerContainer);
00157 
00158     virtual void SetDocument(FbxDocument* pDocument);
00159     virtual bool ConnecNotify (FbxConnectEvent const &pEvent);
00160 
00161     FbxArray<FbxLayer*> mLayerArray;
00162     FbxArray<FbxLayerElement*> mLayerElementsList;
00163 
00164     friend class FbxScene;
00165     friend class FbxGeometryConverter;
00166 
00167 #endif // #ifndef DOXYGEN_SHOULD_SKIP_THIS
00168 
00169 };
00170 
00171 #include <fbxsdk/fbxsdk_nsend.h>
00172 
00173 #endif /* _FBXSDK_SCENE_GEOMETRY_LAYER_CONTAINER_H_ */