FBX C++ API Reference
All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FbxLayerElementUserData Class Reference

#include <fbxlayer.h>

Class Description

Layer element for mapping custom user data to a geometry.

This layer element is different from the other types of layer elements in that it has multiple direct arrays. There is one array for each user data attribute. Each array is indexed by the index array.

Examples:
ExportScene03/main.cxx.

Definition at line 1518 of file fbxlayer.h.

+ Inheritance diagram for FbxLayerElementUserData:

Public Member Functions

FbxLayerElementArrayTemplate< void * > * GetDirectArrayVoid (int pIndex, bool *pStatus=((void *) 0))
 Returns the direct array with the specified attribute index. More...
 
const FbxLayerElementArrayTemplate< void * > * GetDirectArrayVoid (int pIndex, bool *pStatus=((void *) 0)) const
 Returns the direct array with the specified attribute index. More...
 
FbxLayerElementArrayTemplate< void * > * GetDirectArrayVoid (const char *pName, bool *pStatus=((void *) 0))
 Returns the direct array with the specified attribute name. More...
 
const FbxLayerElementArrayTemplate< void * > * GetDirectArrayVoid (const char *pName, bool *pStatus=((void *) 0)) const
 Returns the direct array with the specified attribute name. More...
 
FbxDataType GetDataType (int pIndex) const
 Returns the data type for the specified index. More...
 
FbxDataType GetDataType (const char *pName) const
 Returns the specified attribute data type. More...
 
const char * GetDataName (int pIndex) const
 Returns the attribute name at the specified index. More...
 
void ResizeAllDirectArrays (int pSize)
 Resizes all direct arrays to the specified size. More...
 
void RemoveFromAllDirectArrays (int pIndex)
 Removes a single element at pIndex from every direct array. More...
 
int GetArrayCount (int pIndex) const
 Returns the direct array count for the attribute at pIndex. More...
 
int GetId () const
 Queries the this layer element's ID. More...
 
int GetDirectArrayCount () const
 Returns this layer element's direct array count. More...
 
FbxLayerElementUserDataoperator= (FbxLayerElementUserData const &pOther)
 Assignment operator which performs a deep copy. More...
 
bool Clear ()
 Removes all data from this layer element. More...
 
virtual int MemorySize () const
 Queries the amount of memory used by this object as well as its content. More...
 
- Public Member Functions inherited from FbxLayerElementTemplate< void *>
FbxLayerElementArrayTemplate< void * > & GetDirectArray () const
 Returns the direct array of Layer Elements. More...
 
FbxLayerElementArrayTemplate< void * > & GetDirectArray ()
 Returns the direct array of Layer Elements. More...
 
FbxLayerElementArrayTemplate< int > & GetIndexArray () const
 Returns the index array of Layer Elements. More...
 
FbxLayerElementArrayTemplate< int > & GetIndexArray ()
 Returns the index array of Layer Elements. More...
 
bool Clear ()
 Removes all elements from the direct and the index arrays. More...
 
bool operator== (const FbxLayerElementTemplate &pOther) const
 Equivalence operator. More...
 
FbxLayerElementTemplateoperator= (FbxLayerElementTemplate const &pOther)
 Assignment operator. More...
 
int RemapIndexTo (FbxLayerElement::EMappingMode pNewMapping)
 Changes the Mapping mode to the new one and re-computes the index array. More...
 
- Public Member Functions inherited from FbxLayerElement
void SetMappingMode (EMappingMode pMappingMode)
 Sets the Mapping Mode. More...
 
void SetReferenceMode (EReferenceMode pReferenceMode)
 Sets the Reference Mode. More...
 
EMappingMode GetMappingMode () const
 Returns the Mapping Mode. More...
 
EReferenceMode GetReferenceMode () const
 Returns the Reference Mode. More...
 
void SetName (const char *pName)
 Sets the name of this object. More...
 
const char * GetName () const
 Returns the name of this object. More...
 
bool operator== (const FbxLayerElement &pOther) const
 Equivalence operator. More...
 
FbxLayerElementoperator= (FbxLayerElement const &pOther)
 Assignment operator. More...
 
void Destroy ()
 Removes this layer element from its owner and delete it. More...
 

Static Public Member Functions

static FbxLayerElementUserDataCreate (FbxLayerContainer *pOwner, const char *pName, int pId, FbxArray< FbxDataType > &pDataTypes, FbxArray< const char *> &pDataNames)
 Allocation method. More...
 
static FbxLayerElementUserDataCreate (FbxLayerContainer *pOwner, FbxLayerElementUserData const &pOther)
 Allocation method. More...
 

Friends

template<typename T >
T * fbxsdk ::FbxNew ()
 
template<typename T , typename T1 >
T * fbxsdk ::FbxNew (T1 &p1)
 
template<typename T , typename T1 >
T * fbxsdk ::FbxNew (const T1 &p1)
 
template<typename T , typename T1 , typename T2 >
T * fbxsdk ::FbxNew (T1 &p1, T2 &p2)
 
template<typename T , typename T1 , typename T2 >
T * fbxsdk ::FbxNew (T1 &p1, const T2 &p2)
 
template<typename T , typename T1 , typename T2 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2)
 
template<typename T , typename T1 , typename T2 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2)
 
template<typename T , typename T1 , typename T2 , typename T3 >
T * fbxsdk ::FbxNew (T1 &p1, T2 &p2, T3 &p3)
 
template<typename T , typename T1 , typename T2 , typename T3 >
T * fbxsdk ::FbxNew (T1 &p1, T2 &p2, const T3 &p3)
 
template<typename T , typename T1 , typename T2 , typename T3 >
T * fbxsdk ::FbxNew (T1 &p1, const T2 &p2, T3 &p3)
 
template<typename T , typename T1 , typename T2 , typename T3 >
T * fbxsdk ::FbxNew (T1 &p1, const T2 &p2, const T3 &p3)
 
template<typename T , typename T1 , typename T2 , typename T3 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2, T3 &p3)
 
template<typename T , typename T1 , typename T2 , typename T3 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2, const T3 &p3)
 
template<typename T , typename T1 , typename T2 , typename T3 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, T3 &p3)
 
template<typename T , typename T1 , typename T2 , typename T3 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (T1 &p1, T2 &p2, T3 &p3, T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (T1 &p1, T2 &p2, T3 &p3, const T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (T1 &p1, T2 &p2, const T3 &p3, T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (T1 &p1, T2 &p2, const T3 &p3, const T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (T1 &p1, const T2 &p2, T3 &p3, T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (T1 &p1, const T2 &p2, T3 &p3, const T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (T1 &p1, const T2 &p2, const T3 &p3, T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2, T3 &p3, T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2, T3 &p3, const T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2, const T3 &p3, T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2, const T3 &p3, const T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, T3 &p3, T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, T3 &p3, const T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3, T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (T1 &p1, T2 &p2, T3 &p3, T4 &p4, T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2, T3 &p3, T4 &p4, T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, T3 &p3, T4 &p4, T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2, const T3 &p3, T4 &p4, T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2, T3 &p3, const T4 &p4, T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, T2 &p2, T3 &p3, T4 &p4, const T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3, T4 &p4, T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, T3 &p3, const T4 &p4, T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, T3 &p3, T4 &p4, const T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4, T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3, T4 &p4, const T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4, const T5 &p5)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4, const T5 &p5, const T6 &p6)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4, const T5 &p5, const T6 &p6, const T7 &p7)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4, const T5 &p5, const T6 &p6, const T7 &p7, const T8 &p8)
 
template<typename T , typename T1 , typename T2 , typename T3 , typename T4 , typename T5 , typename T6 , typename T7 , typename T8 , typename T9 >
T * fbxsdk ::FbxNew (const T1 &p1, const T2 &p2, const T3 &p3, const T4 &p4, const T5 &p5, const T6 &p6, const T7 &p7, const T8 &p8, const T9 &p9)
 
template<typename T >
void fbxsdk ::FbxDelete (T *p)
 
template<typename T >
void fbxsdk ::FbxDelete (const T *p)
 
template<typename T >
T * fbxsdk ::FbxNewArray (const int n)
 
template<typename T >
void fbxsdk ::FbxDeleteArray (T *p)
 

Additional Inherited Members

- Public Types inherited from FbxLayerElement
enum  EType {
  eUnknown, eNormal, eBiNormal, eTangent,
  eMaterial, ePolygonGroup, eUV, eVertexColor,
  eSmoothing, eVertexCrease, eEdgeCrease, eHole,
  eUserData, eVisibility, eTextureDiffuse, eTextureDiffuseFactor,
  eTextureEmissive, eTextureEmissiveFactor, eTextureAmbient, eTextureAmbientFactor,
  eTextureSpecular, eTextureSpecularFactor, eTextureShininess, eTextureNormalMap,
  eTextureBump, eTextureTransparency, eTextureTransparencyFactor, eTextureReflection,
  eTextureReflectionFactor, eTextureDisplacement, eTextureDisplacementVector, eTypeCount
}
 Layer Element type identifier. More...
 
enum  EMappingMode {
  eNone, eByControlPoint, eByPolygonVertex, eByPolygon,
  eByEdge, eAllSame
}
 Determines how the element is mapped to a surface. More...
 
enum  EReferenceMode { eDirect, eIndex, eIndexToDirect }
 Determines how the mapping information is stored in the array of coordinates. More...
 
- Static Public Attributes inherited from FbxLayerElement
static const int sTypeTextureStartIndex = int(eTextureDiffuse)
 The start index of texture type layer elements. More...
 
static const int sTypeTextureEndIndex = int(eTypeCount) - 1
 The end index of texture type layer elements. More...
 
static const int sTypeTextureCount = sTypeTextureEndIndex - sTypeTextureStartIndex + 1
 The count of texture type layer elements. More...
 
static const int sTypeNonTextureStartIndex = int(eNormal)
 The start index of non-texture type layer elements. More...
 
static const int sTypeNonTextureEndIndex = int(eVisibility)
 The end index of non-texture type layer elements. More...
 
static const int sTypeNonTextureCount = sTypeNonTextureEndIndex - sTypeNonTextureStartIndex + 1
 The count of non-texture type layer elements. More...
 
static const char *const sTextureNames []
 Array of names of texture type layer elements. More...
 
static const char *const sTextureUVNames []
 Array of names of UV layer elements. More...
 
static const char *const sNonTextureNames []
 Array of names of non-texture type layer elements. More...
 
static const FbxDataType sTextureDataTypes []
 Array of texture types. More...
 
static const char *const sTextureChannelNames []
 Array of texture channels. More...
 

Member Function Documentation

◆ Create() [1/2]

static FbxLayerElementUserData* Create ( FbxLayerContainer pOwner,
const char *  pName,
int  pId,
FbxArray< FbxDataType > &  pDataTypes,
FbxArray< const char *> &  pDataNames 
)
static

Allocation method.

Parameters
pOwnerThe owner of this layer element.
pNameThe layer element name.
pIdThe layer element ID.
pDataTypesAttribute data types of this layer element, one direct array is allocated for each Attribute data type.
pDataNamesAttribute names of this layer element.
Returns
A pointer to the layer element or NULL if creation fails.
Remarks
Only "bool", "int", "float" and "double" are supported.
Examples:
ExportScene03/main.cxx.

◆ Create() [2/2]

static FbxLayerElementUserData* Create ( FbxLayerContainer pOwner,
FbxLayerElementUserData const &  pOther 
)
static

Allocation method.

Parameters
pOwnerThe owner of this layer element.
pOtherOther layer element from which to copy.
Returns
A pointer to the layer element or NULL if creation fails.

◆ GetDirectArrayVoid() [1/4]

FbxLayerElementArrayTemplate<void*>* GetDirectArrayVoid ( int  pIndex,
bool *  pStatus = ((void*)0) 
)
inline

Returns the direct array with the specified attribute index.

Parameters
pIndexSpecified attribute index.
pStatusA flag to indicate whether the direct array is returned successfully or not.
Returns
The specified attribute's direct array.
Examples:
ExportScene03/main.cxx.

Definition at line 1546 of file fbxlayer.h.

1547  {
1548  if( pIndex >= 0 || pIndex < GetDirectArray().GetCount() )
1549  {
1550  if (pStatus) *pStatus = true;
1551  return (FbxLayerElementArrayTemplate<void*>*)GetDirectArray().AsReference(pIndex);
1552  }
1553  else
1554  {
1555  if( pStatus ) *pStatus = false;
1556  FBX_ASSERT_NOW("Index out of bounds");
1558  }
1559  }
FbxLayerElementArrayTemplate provides data array manipulation of the data buffer for FbxLayerElement...
Definition: fbxlayer.h:858
#define NULL
Definition: fbxarch.h:210
FbxLayerElementArrayTemplate< void * > & GetDirectArray() const
Returns the direct array of Layer Elements.
Definition: fbxlayer.h:1030

◆ GetDirectArrayVoid() [2/4]

const FbxLayerElementArrayTemplate<void*>* GetDirectArrayVoid ( int  pIndex,
bool *  pStatus = ((void*)0) 
) const
inline

Returns the direct array with the specified attribute index.

Parameters
pIndexSpecified attribute index.
pStatusA flag to indicate whether the direct array is returned successfully or not.
Returns
The specified attribute's direct array.

Definition at line 1566 of file fbxlayer.h.

1567  {
1568  if( pIndex >= 0 || pIndex < GetDirectArray().GetCount() )
1569  {
1570  if (pStatus) *pStatus = true;
1571  return (FbxLayerElementArrayTemplate<void*>*)GetDirectArray().AsReference(pIndex);
1572  }
1573  else
1574  {
1575  if( pStatus ) *pStatus = false;
1576  FBX_ASSERT_NOW("Index out of bounds");
1578  }
1579  }
FbxLayerElementArrayTemplate provides data array manipulation of the data buffer for FbxLayerElement...
Definition: fbxlayer.h:858
#define NULL
Definition: fbxarch.h:210
FbxLayerElementArrayTemplate< void * > & GetDirectArray() const
Returns the direct array of Layer Elements.
Definition: fbxlayer.h:1030

◆ GetDirectArrayVoid() [3/4]

FbxLayerElementArrayTemplate<void *>* GetDirectArrayVoid ( const char *  pName,
bool *  pStatus = ((void*)0) 
)
inline

Returns the direct array with the specified attribute name.

Parameters
pNameSpecified attribute name.
pStatusA flag to indicate whether the direct array is returned successfully or not.
Returns
The specified attribute's direct array.

Definition at line 1587 of file fbxlayer.h.

1588  {
1589  FbxString lName( pName );
1590  for( int i = 0; i < mDataNames.GetCount(); ++i )
1591  {
1592  if( *mDataNames[i] == lName )
1593  return GetDirectArrayVoid(i, pStatus);
1594  }
1595 
1596  if (pStatus) *pStatus = false;
1598  }
FbxLayerElementArrayTemplate provides data array manipulation of the data buffer for FbxLayerElement...
Definition: fbxlayer.h:858
#define NULL
Definition: fbxarch.h:210
Utility class to manipulate strings.
Definition: fbxstring.h:66
FbxLayerElementArrayTemplate< void * > * GetDirectArrayVoid(int pIndex, bool *pStatus=((void *) 0))
Returns the direct array with the specified attribute index.
Definition: fbxlayer.h:1546

◆ GetDirectArrayVoid() [4/4]

const FbxLayerElementArrayTemplate<void*>* GetDirectArrayVoid ( const char *  pName,
bool *  pStatus = ((void*)0) 
) const
inline

Returns the direct array with the specified attribute name.

Parameters
pNameSpecified attribute name.
pStatusA flag to indicate whether the direct array is returned successfully or not.
Returns
The specified attribute's direct array.

Definition at line 1605 of file fbxlayer.h.

1606  {
1607  FbxString lName( pName );
1608  for( int i = 0; i < mDataNames.GetCount(); ++i )
1609  {
1610  if( *mDataNames[i] == lName )
1611  return GetDirectArrayVoid(i, pStatus);
1612  }
1613 
1614  if (pStatus) *pStatus = false;
1616  }
FbxLayerElementArrayTemplate provides data array manipulation of the data buffer for FbxLayerElement...
Definition: fbxlayer.h:858
#define NULL
Definition: fbxarch.h:210
Utility class to manipulate strings.
Definition: fbxstring.h:66
FbxLayerElementArrayTemplate< void * > * GetDirectArrayVoid(int pIndex, bool *pStatus=((void *) 0))
Returns the direct array with the specified attribute index.
Definition: fbxlayer.h:1546

◆ GetDataType() [1/2]

FbxDataType GetDataType ( int  pIndex) const
inline

Returns the data type for the specified index.

Parameters
pIndexThe index of the attribute being queried
Returns
The data type, or FbxUndefinedDT if pIndex is out of range

Definition at line 1622 of file fbxlayer.h.

1623  {
1624  if( pIndex < 0 || pIndex >= mDataTypes.GetCount() )
1625  return FbxUndefinedDT;
1626 
1627  return mDataTypes[pIndex];
1628  }
FbxDataType FbxUndefinedDT

◆ GetDataType() [2/2]

FbxDataType GetDataType ( const char *  pName) const
inline

Returns the specified attribute data type.

Parameters
pNameThe name of the attribute being queried
Returns
The data type, or FbxUndefinedDT if no attribute has the given name

Definition at line 1634 of file fbxlayer.h.

1635  {
1636  FbxString lName( pName );
1637 
1638  for( int i = 0; i < mDataNames.GetCount(); ++i )
1639  {
1640  if( *mDataNames[i] == lName )
1641  return mDataTypes[i];
1642  }
1643 
1644  return FbxUndefinedDT;
1645  }
Utility class to manipulate strings.
Definition: fbxstring.h:66
FbxDataType FbxUndefinedDT

◆ GetDataName()

const char* GetDataName ( int  pIndex) const
inline

Returns the attribute name at the specified index.

Parameters
pIndexAttribute index
Returns
The name, or NULL if pIndex is out of range.

Definition at line 1651 of file fbxlayer.h.

1652  {
1653  if( pIndex >= 0 && pIndex < mDataNames.GetCount() )
1654  return mDataNames[pIndex]->Buffer();
1655 
1656  return NULL;
1657  }
#define NULL
Definition: fbxarch.h:210

◆ ResizeAllDirectArrays()

void ResizeAllDirectArrays ( int  pSize)
inline

Resizes all direct arrays to the specified size.

Parameters
pSizeThe new size of the direct arrays.
Examples:
ExportScene03/main.cxx.

Definition at line 1662 of file fbxlayer.h.

1663  {
1664  for( int i = 0; i < GetDirectArray().GetCount(); ++i )
1665  {
1666  switch( mDataTypes[i].GetType() )
1667  {
1668  case eFbxBool: FbxGetDirectArray<bool>(this,i).Resize( pSize ) ; break;
1669  case eFbxInt: FbxGetDirectArray<int>(this,i).Resize( pSize ) ; break;
1670  case eFbxFloat: FbxGetDirectArray<float>(this,i).Resize( pSize ) ; break;
1671  case eFbxDouble: FbxGetDirectArray<double>(this,i).Resize( pSize ); break;
1672  //case eFbxDouble3: GetDirectArray< FbxDouble3 >(i).Resize( pSize ); break;
1673  //case eFbxDouble4: GetDirectArray< FbxDouble4 >(i).Resize( pSize ); break;
1674  //case eFbxDouble4x4: GetDirectArray< FbxDouble4x4>(i).Resize( pSize ); break;
1675  default:
1676  FBX_ASSERT_NOW("unknown type" ); break;
1677  }
1678  }
1679  }
32 bit signed integer.
Double width floating point value.
Boolean.
FbxLayerElementArrayTemplate< void * > & GetDirectArray() const
Returns the direct array of Layer Elements.
Definition: fbxlayer.h:1030
Floating point value.

◆ RemoveFromAllDirectArrays()

void RemoveFromAllDirectArrays ( int  pIndex)
inline

Removes a single element at pIndex from every direct array.

Parameters
pIndexThe index of the element to be removed.

Definition at line 1684 of file fbxlayer.h.

1685  {
1686  for( int i = 0; i < GetDirectArray().GetCount(); ++i )
1687  {
1688  switch( mDataTypes[i].GetType() )
1689  {
1690  case eFbxBool: FbxGetDirectArray<bool>(this,i).RemoveAt( pIndex ) ; break;
1691  case eFbxInt: FbxGetDirectArray<int>(this,i).RemoveAt( pIndex ) ; break;
1692  case eFbxFloat: FbxGetDirectArray<float>(this,i).RemoveAt( pIndex ) ; break;
1693  case eFbxDouble: FbxGetDirectArray<double>(this,i).RemoveAt( pIndex ); break;
1694  //case eFbxDouble3: GetDirectArray< FbxDouble3 >(i).RemoveAt( pIndex ); break;
1695  //case eFbxDouble4: GetDirectArray< FbxDouble4 >(i).RemoveAt( pIndex ); break;
1696  //case eFbxDouble4x4: GetDirectArray< FbxDouble4x4>(i).RemoveAt( pIndex ); break;
1697  default:
1698  FBX_ASSERT_NOW("unknown type" ); break;
1699  }
1700  }
1701  }
32 bit signed integer.
Double width floating point value.
Boolean.
FbxLayerElementArrayTemplate< void * > & GetDirectArray() const
Returns the direct array of Layer Elements.
Definition: fbxlayer.h:1030
Floating point value.

◆ GetArrayCount()

int GetArrayCount ( int  pIndex) const
inline

Returns the direct array count for the attribute at pIndex.

Parameters
pIndexThe attribute index
Returns
The specified attribute's direct array count.

Definition at line 1707 of file fbxlayer.h.

1708  {
1709  if( pIndex >= 0 && pIndex < GetDirectArray().GetCount() )
1710  {
1711  switch( mDataTypes[pIndex].GetType() )
1712  {
1713  case eFbxBool: return FbxGetDirectArray<bool>(this,pIndex).GetCount();
1714  case eFbxInt: return FbxGetDirectArray<int>(this,pIndex).GetCount();
1715  case eFbxFloat: return FbxGetDirectArray<float>(this,pIndex).GetCount();
1716  case eFbxDouble: return FbxGetDirectArray<double>(this,pIndex).GetCount();
1717  //case eFbxDouble3: return GetDirectArray< FbxDouble3 >(pIndex).GetCount();
1718  //case eFbxDouble4: return GetDirectArray< FbxDouble4 >(pIndex).GetCount();
1719  //case eFbxDouble4x4: return GetDirectArray< FbxDouble4x4>(pIndex).GetCount();
1720  default:
1721  FBX_ASSERT_NOW("Unknown type" ); break;
1722  }
1723  }
1724 
1725  return -1;
1726  }
32 bit signed integer.
Double width floating point value.
Boolean.
FbxLayerElementArrayTemplate< void * > & GetDirectArray() const
Returns the direct array of Layer Elements.
Definition: fbxlayer.h:1030
Floating point value.

◆ GetId()

int GetId ( ) const
inline

Queries the this layer element's ID.

Returns
The ID expressed as an int

Definition at line 1731 of file fbxlayer.h.

1731 { return mId; }

◆ GetDirectArrayCount()

int GetDirectArrayCount ( ) const
inline

Returns this layer element's direct array count.

Returns
The direct array count expressed as an int.
Remarks
This count should be equal to the count of user data attributes.

Definition at line 1737 of file fbxlayer.h.

1737 { return GetDirectArray().GetCount(); }
FbxLayerElementArrayTemplate< void * > & GetDirectArray() const
Returns the direct array of Layer Elements.
Definition: fbxlayer.h:1030

◆ operator=()

FbxLayerElementUserData& operator= ( FbxLayerElementUserData const &  pOther)
inline

Assignment operator which performs a deep copy.

Parameters
pOtherOther FbxLayerElementUserData from which to perform a deep copy.
Returns
This FbxLayerElementUserData.

Definition at line 1743 of file fbxlayer.h.

1744  {
1745  if (this == &pOther)
1746  return *this;
1747 
1748  Clear();
1749 
1750  mId = pOther.mId;
1751  mDataTypes = pOther.mDataTypes;
1752  mDataNames.Resize(pOther.mDataNames.GetCount());
1753  for(int i = 0; i < pOther.mDataNames.GetCount(); ++i)
1754  mDataNames.SetAt(i, FbxNew< FbxString >( *pOther.mDataNames[i] ) );
1755 
1756  Init();
1757  for(int i = 0; i < pOther.GetDirectArrayCount(); ++i)
1758  {
1759  switch (mDataTypes[i].GetType())
1760  {
1761  case eFbxBool:
1762  FbxGetDirectArray<bool>(this, i) = FbxGetDirectArray<bool>(&pOther, i);
1763  break;
1764 
1765  case eFbxInt:
1766  FbxGetDirectArray<int>(this, i) = FbxGetDirectArray<int>(&pOther, i);
1767  break;
1768 
1769  case eFbxFloat:
1770  FbxGetDirectArray<float>(this, i) = FbxGetDirectArray<float>(&pOther, i);
1771  break;
1772 
1773  case eFbxDouble:
1774  FbxGetDirectArray<double>(this, i) = FbxGetDirectArray<double>(&pOther, i);
1775  break;
1776 
1777  default:
1778  FBX_ASSERT_NOW("Unknown type" );
1779  break;
1780  }
1781  }
1782 
1783  if ( ( mReferenceMode == FbxLayerElement::eIndex ||
1784  mReferenceMode == FbxLayerElement::eIndexToDirect) &&
1785  ( pOther.GetReferenceMode() == FbxLayerElement::eIndex ||
1786  pOther.GetReferenceMode() == FbxLayerElement::eIndexToDirect))
1787  {
1788  GetIndexArray() = pOther.GetIndexArray();
1789  }
1790 
1791  return *this;
1792  }
32 bit signed integer.
Double width floating point value.
Boolean.
FbxLayerElementArrayTemplate< int > & GetIndexArray() const
Returns the index array of Layer Elements.
Definition: fbxlayer.h:1050
bool Clear()
Removes all data from this layer element.
Definition: fbxlayer.h:1797
Floating point value.

◆ Clear()

bool Clear ( )
inlinevirtual

Removes all data from this layer element.

Returns
True always

Reimplemented from FbxLayerElement.

Definition at line 1797 of file fbxlayer.h.

1798  {
1799  int i;
1800  const int lCount = GetDirectArray().GetCount();
1801  FbxLayerElementArray** directArray = NULL;
1802  directArray = GetDirectArray().GetLocked(directArray);
1803  for( i = 0; directArray != NULL && i < lCount; ++i )
1804  {
1805  if( directArray[i] )
1806  FbxDelete(directArray[i]);
1807  }
1808  FbxLayerElementArray*** ptr = &directArray;
1809  GetDirectArray().Release((void**)ptr);
1810  for( i = 0; i < mDataNames.GetCount(); ++i )
1811  {
1812  FBX_SAFE_DELETE(mDataNames[i]);
1813  }
1814  mDataNames.Clear();
1815  mDataTypes.Clear();
1816 
1818 
1819  return true;
1820  }
bool Clear()
Removes all elements from the direct and the index arrays.
Definition: fbxlayer.h:1070
#define NULL
Definition: fbxarch.h:210
void FbxDelete(T *p)
Deletion policy for pointer template classes that uses the FbxDelete() function.
Definition: fbxnew.h:341
FbxLayerElementArray is the base class for FbxLayerElementArrayTemplate, it provides lock handling an...
Definition: fbxlayer.h:332
FbxLayerElementArrayTemplate< void * > & GetDirectArray() const
Returns the direct array of Layer Elements.
Definition: fbxlayer.h:1030
#define FBX_SAFE_DELETE(p)
Definition: fbxsdk_def.h:50

◆ MemorySize()

virtual int MemorySize ( ) const
inlinevirtual

Queries the amount of memory used by this object as well as its content.

It does not consider the content pointed.

Returns
The amount of memory used.

Definition at line 1826 of file fbxlayer.h.

1827  {
1829  size += sizeof(mId);
1830 
1831  for(int i = 0; i < mDataTypes.GetCount(); i++)
1832  {
1833  size += sizeof(mDataTypes[i]);
1834  }
1835  size += (mDataNames.GetCount() * sizeof(FbxString*));
1836 
1837  return size;
1838  }
Utility class to manipulate strings.
Definition: fbxstring.h:66
This class complements the FbxLayerElement class.
Definition: fbxlayer.h:1022

Friends And Related Function Documentation

◆ fbxsdk ::FbxNew [1/47]

T* fbxsdk ::FbxNew ( )
friend

◆ fbxsdk ::FbxNew [2/47]

T* fbxsdk ::FbxNew ( T1 &  p1)
friend

◆ fbxsdk ::FbxNew [3/47]

T* fbxsdk ::FbxNew ( const T1 &  p1)
friend

◆ fbxsdk ::FbxNew [4/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
T2 &  p2 
)
friend

◆ fbxsdk ::FbxNew [5/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
const T2 &  p2 
)
friend

◆ fbxsdk ::FbxNew [6/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2 
)
friend

◆ fbxsdk ::FbxNew [7/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2 
)
friend

◆ fbxsdk ::FbxNew [8/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
T2 &  p2,
T3 &  p3 
)
friend

◆ fbxsdk ::FbxNew [9/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
T2 &  p2,
const T3 &  p3 
)
friend

◆ fbxsdk ::FbxNew [10/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
const T2 &  p2,
T3 &  p3 
)
friend

◆ fbxsdk ::FbxNew [11/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
const T2 &  p2,
const T3 &  p3 
)
friend

◆ fbxsdk ::FbxNew [12/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2,
T3 &  p3 
)
friend

◆ fbxsdk ::FbxNew [13/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2,
const T3 &  p3 
)
friend

◆ fbxsdk ::FbxNew [14/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
T3 &  p3 
)
friend

◆ fbxsdk ::FbxNew [15/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3 
)
friend

◆ fbxsdk ::FbxNew [16/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
T2 &  p2,
T3 &  p3,
T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [17/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
T2 &  p2,
T3 &  p3,
const T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [18/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
T2 &  p2,
const T3 &  p3,
T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [19/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
T2 &  p2,
const T3 &  p3,
const T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [20/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
const T2 &  p2,
T3 &  p3,
T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [21/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
const T2 &  p2,
T3 &  p3,
const T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [22/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
const T2 &  p2,
const T3 &  p3,
T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [23/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
const T2 &  p2,
const T3 &  p3,
const T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [24/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2,
T3 &  p3,
T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [25/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2,
T3 &  p3,
const T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [26/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2,
const T3 &  p3,
T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [27/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2,
const T3 &  p3,
const T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [28/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
T3 &  p3,
T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [29/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
T3 &  p3,
const T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [30/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3,
T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [31/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3,
const T4 &  p4 
)
friend

◆ fbxsdk ::FbxNew [32/47]

T* fbxsdk ::FbxNew ( T1 &  p1,
T2 &  p2,
T3 &  p3,
T4 &  p4,
T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [33/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2,
T3 &  p3,
T4 &  p4,
T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [34/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
T3 &  p3,
T4 &  p4,
T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [35/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2,
const T3 &  p3,
T4 &  p4,
T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [36/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2,
T3 &  p3,
const T4 &  p4,
T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [37/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
T2 &  p2,
T3 &  p3,
T4 &  p4,
const T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [38/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3,
T4 &  p4,
T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [39/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
T3 &  p3,
const T4 &  p4,
T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [40/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
T3 &  p3,
T4 &  p4,
const T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [41/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3,
const T4 &  p4,
T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [42/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3,
T4 &  p4,
const T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [43/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3,
const T4 &  p4,
const T5 &  p5 
)
friend

◆ fbxsdk ::FbxNew [44/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3,
const T4 &  p4,
const T5 &  p5,
const T6 &  p6 
)
friend

◆ fbxsdk ::FbxNew [45/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3,
const T4 &  p4,
const T5 &  p5,
const T6 &  p6,
const T7 &  p7 
)
friend

◆ fbxsdk ::FbxNew [46/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3,
const T4 &  p4,
const T5 &  p5,
const T6 &  p6,
const T7 &  p7,
const T8 &  p8 
)
friend

◆ fbxsdk ::FbxNew [47/47]

T* fbxsdk ::FbxNew ( const T1 &  p1,
const T2 &  p2,
const T3 &  p3,
const T4 &  p4,
const T5 &  p5,
const T6 &  p6,
const T7 &  p7,
const T8 &  p8,
const T9 &  p9 
)
friend

◆ fbxsdk ::FbxDelete [1/2]

void fbxsdk ::FbxDelete ( T *  p)
friend

◆ fbxsdk ::FbxDelete [2/2]

void fbxsdk ::FbxDelete ( const T *  p)
friend

◆ fbxsdk ::FbxNewArray

T* fbxsdk ::FbxNewArray ( const int  n)
friend

◆ fbxsdk ::FbxDeleteArray

void fbxsdk ::FbxDeleteArray ( T *  p)
friend

The documentation for this class was generated from the following file: