fbxobject.h File Reference

#include <fbxsdk/fbxsdk_def.h>
#include <fbxsdk/core/fbxclassid.h>
#include <fbxsdk/core/fbxquery.h>
#include <fbxsdk/core/fbxemitter.h>
#include <fbxsdk/core/fbxproperty.h>
#include <fbxsdk/core/fbxstream.h>
#include <fbxsdk/core/base/fbxstringlist.h>
#include <fbxsdk/utils/fbxnamehandler.h>
#include <fbxsdk/fbxsdk_nsbegin.h>
#include <fbxsdk/fbxsdk_nsend.h>

Go to the source code of this file.

Classes

class  FbxObject
 The base class of most FBX objects. More...
class  FbxIterator< FbxProperty >
 A utility class for iterating over the properties (FbxProperty) of any FbxObject. More...
class  FbxIteratorSrcBase
 A utility class for iterating over source objects that connect to property (FbxProperty) or object (FbxObject). More...
class  FbxIteratorSrc< Type >
 A utility class for iterating over source objects that connect to property (FbxProperty) or object (FbxObject). More...
class  FbxIteratorDstBase
 A utility class for iterating over destination objects that connect to property (FbxProperty) or object (FbxObject). More...
class  FbxIteratorDst< Type >
 A utility class for iterating over destination objects that connect to property (FbxProperty) or object (FbxObject). More...
class  FbxConnectEvent
class  FbxObjectPropertyChanged

Defines

#define FBXSDK_CLASS_DECLARE(Class, Parent)
#define FBXSDK_FBXOBJECT_DECLARE(Class, Parent)
#define FBXSDK_OBJECT_DECLARE(Class, Parent)
 Macro used to declare a new class derived from FbxObject.
#define FBXSDK_ABSTRACT_OBJECT_DECLARE(Class, Parent)
 Macro used to declare a new abstract class derived from FbxObject.
#define FBXSDK_OBJECT_IMPLEMENT(Class)
 Macro used to implement a new class derived from FbxObject.
#define FBXSDK_ABSTRACT_OBJECT_IMPLEMENT(Class)
 Macro used to implement a new abstract class derived from FbxObject.
#define FBX_TYPE(class)   ((const class*)0)
 Convert the class type parameter into a C class parameter for other function inputs.
#define FbxForEach(Iterator, Object)   for((Object)=(Iterator).GetFirst();(Object)!=0;(Object)=(Iterator).GetNext())
 Macro used to iterate over source or destination objects that connect to property (FbxProperty) or object (FbxObject).
#define FbxForEachReverse(Iterator, Object)   for(Object=(Iterator).GetLast();(Object)!=0;Object=(Iterator).GetPrevious())
 Macro used to reversely iterate over source or destination objects that connect to property (FbxProperty) or object (FbxObject)

Functions

template<class T >
T * FbxCast (FbxObject *pObject)
 Safe casting of FBX SDK objects into other FBX SDK class types.
template<class T >
const T * FbxCast (const FbxObject *pObject)
 Safe const casting of FBX SDK objects into other FBX SDK class types.
FBX_DEPRECATED bool FbxConnectSrc (FbxObject *pDstObject, FbxObject *pSrcObject)
FBX_DEPRECATED bool FbxConnectDst (FbxObject *pSrcObject, FbxObject *pDstObject)
template<class T >
FBX_DEPRECATED int FbxGetSrcCount (const FbxObject *pObject)
template<class T >
FBX_DEPRECATED int FbxGetSrcCount (const FbxObject *pObject, FbxClassId pClassId)
template<class T >
FBX_DEPRECATED T * FbxGetSrc (const FbxObject *pObject, int pIndex=0)
template<class T >
FBX_DEPRECATED T * FbxGetSrc (const FbxObject *pObject, int pIndex, FbxClassId pClassId)
template<class T >
FBX_DEPRECATED T * FbxFindSrc (const FbxObject *pObject, const char *pName, int pIndex=0)
template<class T >
FBX_DEPRECATED T * FbxFindSrc (const FbxObject *pObject, const char *pName, FbxClassId pClassId, int pIndex=0)
template<class T >
FBX_DEPRECATED bool FbxDisconnectAllSrc (FbxObject *pObject)
template<class T >
FBX_DEPRECATED int FbxGetDstCount (const FbxObject *pObject)
template<class T >
FBX_DEPRECATED int FbxGetDstCount (const FbxObject *pObject, FbxClassId pClassId)
template<class T >
FBX_DEPRECATED T * FbxGetDst (const FbxObject *pObject, int pIndex=0)
template<class T >
FBX_DEPRECATED T * FbxGetDst (const FbxObject *pObject, int pIndex, FbxClassId pClassId)
template<class T >
FBX_DEPRECATED T * FbxFindDst (const FbxObject *pObject, const char *pName, int pIndex=0)
template<class T >
FBX_DEPRECATED T * FbxFindDst (const FbxObject *pObject, const char *pName, FbxClassId pClassId, int pIndex=0)
template<class T >
FBX_DEPRECATED bool FbxDisconnectAllDst (const FbxObject *pObject)

Detailed Description

Definition in file fbxobject.h.


Define Documentation

#define FBXSDK_CLASS_DECLARE (   Class,
  Parent 
)
Value:
private:\
    Class(const Class&);\
    Class& operator=(const Class&);\
protected:\
    virtual ~Class(){};\
public:\
    static FbxClassId ClassId;\
    virtual FbxClassId GetClassId() const { return ClassId; }\
    friend class FBXSDK_NAMESPACE::FbxManager;\
    typedef Parent ParentClass;\
    static Class* Create(FbxManager* pManager, const char* pName);\

Macro used to declare ClassId mechanics.

Definition at line 39 of file fbxobject.h.

#define FBXSDK_FBXOBJECT_DECLARE (   Class,
  Parent 
)
Value:
FBXSDK_CLASS_DECLARE(Class, Parent)\
    FBXSDK_FRIEND_NEW()\
    static Class* Create(FbxObject* pContainer, const char* pName);\
protected:\
    static Class* Allocate(FbxManager* pManager, const char* pName, const Class* pFrom);\

Macro used to declare the FbxObject class.

Definition at line 53 of file fbxobject.h.

#define FBXSDK_OBJECT_DECLARE (   Class,
  Parent 
)
Value:
FBXSDK_FBXOBJECT_DECLARE(Class, Parent)\
protected:\
    Class(FbxManager& pManager, const char* pName) : Parent(pManager, pName){};\
private:

Macro used to declare a new class derived from FbxObject.

Definition at line 61 of file fbxobject.h.

#define FBXSDK_ABSTRACT_OBJECT_DECLARE (   Class,
  Parent 
)
Value:
FBXSDK_CLASS_DECLARE(Class, Parent)\
protected:\
    static FbxObjectCreateProc Allocate;\
    Class(FbxManager& pManager, const char* pName) : Parent(pManager, pName){};\
private:

Macro used to declare a new abstract class derived from FbxObject.

Definition at line 69 of file fbxobject.h.

#define FBXSDK_OBJECT_IMPLEMENT (   Class)
Value:
FbxClassId Class::ClassId;\
    Class* Class::Create(FbxManager* pManager, const char* pName)\
    {\
        return (Class*)pManager->CreateNewObjectFromClassId(Class::ClassId, pName);\
    }\
    Class* Class::Create(FbxObject* pContainer, const char* pName)\
    {\
        FBX_ASSERT_RETURN_VALUE(pContainer && pContainer->GetFbxManager(), NULL);\
        return (Class*)pContainer->GetFbxManager()->CreateNewObjectFromClassId(Class::ClassId, pName, pContainer);\
    }\
    Class* Class::Allocate(FbxManager* pManager, const char* pName, const Class* pFrom)\
    {\
        Class* lNewObject = FbxNew<Class>(*pManager, pName);\
        lNewObject->Construct(pFrom);\
        lNewObject->SetObjectFlags(FbxObject::eInitialized, true);\
        return lNewObject;\
    }\

Macro used to implement a new class derived from FbxObject.

Definition at line 78 of file fbxobject.h.

#define FBXSDK_ABSTRACT_OBJECT_IMPLEMENT (   Class)
Value:
FbxClassId Class::ClassId;\
    FbxObjectCreateProc Class::Allocate = 0;\
    Class* Class::Create(FbxManager* pManager, const char* pName)\
    {\
        return (Class*)pManager->CreateNewObjectFromClassId(Class::ClassId, pName);\
    }\

Macro used to implement a new abstract class derived from FbxObject.

Definition at line 98 of file fbxobject.h.

#define FBX_TYPE (   class)    ((const class*)0)

Convert the class type parameter into a C class parameter for other function inputs.

Usage example:

 //Assuming MyCamera is a valid FbxCamera object
 bool AreCamerasObject = MyCamera->Is<FbxObject>(); //Should return true :)

Definition at line 1652 of file fbxobject.h.

#define FbxForEach (   Iterator,
  Object 
)    for((Object)=(Iterator).GetFirst();(Object)!=0;(Object)=(Iterator).GetNext())

Macro used to iterate over source or destination objects that connect to property (FbxProperty) or object (FbxObject).

Definition at line 1677 of file fbxobject.h.

#define FbxForEachReverse (   Iterator,
  Object 
)    for(Object=(Iterator).GetLast();(Object)!=0;Object=(Iterator).GetPrevious())

Macro used to reversely iterate over source or destination objects that connect to property (FbxProperty) or object (FbxObject)

Definition at line 1680 of file fbxobject.h.


Function Documentation

T* FbxCast ( FbxObject pObject) [inline]

Safe casting of FBX SDK objects into other FBX SDK class types.

This cast will perform the complete test to make sure the object inherits from the requested class type. This is the equivalent of a dynamic_cast but much faster.

Parameters:
pPlugThe object to try to cast into T type.
Returns:
A non-null pointer if the cast was successful.

Definition at line 1660 of file fbxobject.h.

                                                     : 0;
}
const T* FbxCast ( const FbxObject pObject) [inline]

Safe const casting of FBX SDK objects into other FBX SDK class types.

This cast will perform the complete test to make sure the object inherits from the requested class type. This is the equivalent of a dynamic_cast but much faster.

Parameters:
pPlugThe object to try to cast into T type.
Returns:
A non-null pointer if the cast was successful.

Definition at line 1671 of file fbxobject.h.

                                                           : 0;
}

FBX_DEPRECATED bool FbxConnectSrc ( FbxObject pDstObject,
FbxObject pSrcObject 
) [inline]

Definition at line 1688 of file fbxobject.h.

{ return pObject ? pObject->GetSrcObjectCount(T::ClassId) : 0; }
FBX_DEPRECATED bool FbxConnectDst ( FbxObject pSrcObject,
FbxObject pDstObject 
) [inline]

Definition at line 1689 of file fbxobject.h.

{ return pObject ? pObject->GetSrcObjectCount(pClassId) : 0; }
FBX_DEPRECATED int FbxGetSrcCount ( const FbxObject pObject) [inline]

Definition at line 1690 of file fbxobject.h.

{ return pObject ? (T *) pObject->GetSrcObject(T::ClassId,pIndex) : 0; }
FBX_DEPRECATED int FbxGetSrcCount ( const FbxObject pObject,
FbxClassId  pClassId 
) [inline]

Definition at line 1691 of file fbxobject.h.

{ return pObject ? (T *) pObject->GetSrcObject(pClassId,pIndex) : 0; }
FBX_DEPRECATED T* FbxGetSrc ( const FbxObject pObject,
int  pIndex = 0 
) [inline]

Definition at line 1692 of file fbxobject.h.

{ return pObject ? (T *) pObject->FindSrcObject(T::ClassId,pName,pIndex) : 0; }
FBX_DEPRECATED T* FbxGetSrc ( const FbxObject pObject,
int  pIndex,
FbxClassId  pClassId 
) [inline]

Definition at line 1693 of file fbxobject.h.

{ return pObject ? (T *) pObject->FindSrcObject(pClassId, pName, pIndex) : 0; }
FBX_DEPRECATED T* FbxFindSrc ( const FbxObject pObject,
const char *  pName,
int  pIndex = 0 
) [inline]

Definition at line 1694 of file fbxobject.h.

{ return pObject->DisconnectAllSrcObject(T::ClassId); }
FBX_DEPRECATED T* FbxFindSrc ( const FbxObject pObject,
const char *  pName,
FbxClassId  pClassId,
int  pIndex = 0 
) [inline]

Definition at line 1695 of file fbxobject.h.

{ return pObject ? pObject->GetDstObjectCount(T::ClassId) : 0; }
FBX_DEPRECATED bool FbxDisconnectAllSrc ( FbxObject pObject) [inline]

Definition at line 1696 of file fbxobject.h.

{ return pObject ? pObject->GetDstObjectCount(pClassId) : 0; }
FBX_DEPRECATED int FbxGetDstCount ( const FbxObject pObject) [inline]

Definition at line 1697 of file fbxobject.h.

{ return pObject ? (T *) pObject->GetDstObject(T::ClassId,pIndex) : 0; }
FBX_DEPRECATED int FbxGetDstCount ( const FbxObject pObject,
FbxClassId  pClassId 
) [inline]

Definition at line 1698 of file fbxobject.h.

{ return pObject ? (T *) pObject->GetDstObject(pClassId,pIndex) : 0; }
FBX_DEPRECATED T* FbxGetDst ( const FbxObject pObject,
int  pIndex = 0 
) [inline]

Definition at line 1699 of file fbxobject.h.

{ return pObject ? (T *) pObject->FindDstObject(T::ClassId,pName,pIndex) : 0; }
FBX_DEPRECATED T* FbxGetDst ( const FbxObject pObject,
int  pIndex,
FbxClassId  pClassId 
) [inline]

Definition at line 1700 of file fbxobject.h.

{ return pObject ? (T *) pObject->FindDstObject(pClassId, pName, pIndex) : 0; }
FBX_DEPRECATED T* FbxFindDst ( const FbxObject pObject,
const char *  pName,
int  pIndex = 0 
) [inline]

Definition at line 1701 of file fbxobject.h.

{ return pObject->DisconnectAllDstObject(T::ClassId); }
FBX_DEPRECATED T* FbxFindDst ( const FbxObject pObject,
const char *  pName,
FbxClassId  pClassId,
int  pIndex = 0 
) [inline]

Definition at line 1702 of file fbxobject.h.

{
FBX_DEPRECATED bool FbxDisconnectAllDst ( const FbxObject pObject) [inline]

Definition at line 1703 of file fbxobject.h.

{