Open Reality Reference Guide
 
Loading...
Searching...
No Matches
FBProperty Class Reference

Property: Base property class. More...

#include <fbproperties.h>

Inheritance diagram for FBProperty:

Public Member Functions

 FBProperty ()
 Constructor.
 
void SetEnable (bool pValue)
 Set property enable status.
 
const char * GetName ()
 Get the property's name.
 
void SetName (const char *pName)
 Set the property's name.
 
virtual FBPropertyType GetPropertyType ()
 Get the property's type.
 
const char * GetPropertyTypeName ()
 Get the property's type name.
 
virtual KDataType * GetDataType ()
 Get the property datatype pointer.
 
virtual void SetData (void *pData)
 Set the value of the property, passing the type as an argument.
 
virtual void GetData (void *pData, int pSize, FBEvaluateInfo *pEvalInfo=NULL) const
 Get the value of a property.
 
int AsInt ()
 Get the property as an integer.
 
bool SetInt (int pInt)
 Set the property from an integer.
 
virtual const char * AsString (FBDataAsStringFlag pFlag=kFBDataAsStringUI)
 Get the property value as a string.
 
virtual bool SetString (const char *pString)
 Set the property value from a string.
 
const char * OriValueAsString ()
 Get the property original value (before any modification) as string.
 
bool IsAnimated () const
 Get the property animated flag status.
 
bool OriIsAnimated () const
 Get the property original animated flag status (before any modification)
 
virtual bool IsList ()
 Verify if property is of this type.
 
virtual bool IsAnimatable ()
 
bool IsInternal () const
 
bool IsUserProperty ()
 
bool IsTextureConnectableProperty ()
 
bool IsReferenceProperty ()
 
bool IsMinClamp ()
 Indicate if minimum value clamping will be applied on user input value.
 
bool IsMaxClamp ()
 Indicate if maximum value clamping will be applied on user input value.
 
bool IsTemporaryProperty ()
 Indicate if a property was created on retrieve because it didn't exist.
 
bool AcceptTemporaryProperty (const char *pEnumList[]=NULL, fbExternalGetSetHandler pGet=NULL, fbExternalGetSetHandler pSet=NULL)
 Accept a temporary property as a dynamic property.
 
bool IsObjectList ()
 Indicate if is an instance of FBPropertyListObject.
 
virtual bool IsReadOnly ()
 Is property read-only?
 
virtual const char * EnumList (int pIndex)
 Return the string of an enum value.
 
FBStringListGetEnumStringList (bool pCreateIt=false)
 String list for enum properties.
 
void NotifyEnumStringListChanged ()
 Notify system that the enum list was modified.
 
void ModifyPropertyFlag (FBPropertyFlag pFlag, bool pValue)
 ModifyPropertyFlag.
 
FBPropertyFlag GetPropertyFlags ()
 GetPropertyFlags.
 
bool GetPropertyFlag (FBPropertyFlag pFlag)
 GetPropertyFlag.
 
void SetMinMax (double pMin, double pMax, bool pForceMinClamp=false, bool pForceMaxClamp=false)
 SetMinMax.
 
void SetMin (double pMin, bool pForceMinClamp=false)
 SetMin.
 
void SetMax (double pMax, bool pForceMaxClamp=false)
 SetMax.
 
double GetMin ()
 GetMin.
 
double GetMax ()
 GetMax.
 
void * GetParent ()
 Get the parent of the object.
 
Interface for property locking mechanism.

Locking a property or any number of its channel(s) prevents the user from modifying animation on this property.


This means that the user can't add, remove or edit any key on any layer of a locked property/channel. It also means that the user can't change the current value of the property. However, a locked property allows existing animation to flow through. This means that the value of a locked property can change through time as its being driven by existing animation and/or constraints.

int GetSubMemberCount () const
 GetSubMemberCount.
 
bool AllowsLocking () const
 AllowsLocking.
 
bool HasSomethingLocked () const
 HasSomethingLocked.
 
bool IsLocked () const
 IsLocked.
 
bool IsMemberLocked (int pIndex) const
 IsMemberLocked.
 
void SetLocked (bool pLocked)
 SetLocked.
 
void SetMemberLocked (int pIndex, bool pLocked)
 SetMemberLocked.
 
FBPropertyGetReferencedProperty ()
 Get the referenced property, in the case of this property is a reference property (see the IsReferenceProperty() method).
 
- Public Member Functions inherited from FBWrapperHolder
FBScriptWrapperGetWrapper ()
 Return the wrapper interface of this FBObject.
 
void AddWrapper (FBScriptWrapper *)
 
void RemoveWrapper (FBScriptWrapper *)
 

Protected Attributes

FBString mName
 
void * mParent
 
- Protected Attributes inherited from FBPlug
bool mAllocated
 Contain the Allocation State of the Component.
 
HIObject mObject
 Handle on the Plug.
 
bool mSDKComponent
 bool Plug is an SDK component.

 

Additional Inherited Members

- Protected Member Functions inherited from FBPlug
bool IsSDKComponent ()
 Return whether or not item is an SDK component.
 
bool ConnectSrc (FBPlug *pSrc, FBConnectionType pConnectionType=kFBConnectionTypeNone)
 Add a source connection.
 
bool ConnectDst (FBPlug *pDst, FBConnectionType pConnectionType=kFBConnectionTypeNone)
 Add a destination connection.
 
bool ConnectSrcAt (int pDst_SrcIndex, FBPlug *pSrc, FBConnectionType pConnectionType=kFBConnectionTypeNone)
 Add a source connection.
 
bool ConnectDstAt (int pSrc_DstIndex, FBPlug *pDst, FBConnectionType pConnectionType=kFBConnectionTypeNone)
 Add a destination connection.
 
bool DisconnectDst (FBPlug *pDst)
 Remove a destination connection.
 
bool DisconnectSrc (FBPlug *pSrc)
 Remove a source connection.
 
void DisconnectAllSrc ()
 Remove all source connections.
 
void DisconnectAllDst ()
 Remove all destination connections.
 
bool DisconnectDstAt (int pIndex)
 Remove a destination connection at a specified index.
 
bool DisconnectSrcAt (int pIndex)
 Remove a source connection at a specified index.
 
bool ReplaceDstAt (int pIndex, FBPlug *pDst)
 Replace a destination connection at a specified index.
 
bool ReplaceSrcAt (int pIndex, FBPlug *pSrc)
 Replace a source connection at a specified index.
 
bool SwapSrc (int pIndexA, int pIndexB)
 Swap source connection at index A with source connection at index B.
 
bool MoveSrcAt (int pIndex, int pAtIndex)
 Move source connection at pIndex to pAtIndex.
 
bool MoveSrcAt (FBPlug *pSrc, FBPlug *pAtSrc)
 Move source connection pSrc to the position of pAtSrc.
 
int GetSrcCount ()
 Get source connection count.
 
FBPlugGetSrc (int pIndex)
 Get a source connection's plug at specified index.
 
FBConnectionType GetSrcType (int pIndex)
 Get a source connection's type at specified index.
 
int GetDstCount ()
 Get destination connection count.
 
FBPlugGetDst (int pIndex)
 Get a destination connection's plug at specified index.
 
FBConnectionType GetDstType (int pIndex)
 Get a destination connection's type at specified index.
 
bool BeginChange ()
 Begins a change on multiple plugs.
 
void EndChange ()
 Ends a change on multiple plugs.
 
void SetSelfModified (FBPlugModificationFlag pFlag, bool pBool)
 Set the plug's self modification flag.
 
bool GetSelfModified (FBPlugModificationFlag pFlag)
 Tell if the plug's self has changed.
 
void SetContentModified (FBPlugModificationFlag pFlag, bool pBool)
 Set the plug's owned property/object's modification flag.
 
bool GetContentModified (FBPlugModificationFlag pFlag)
 Tell if the plug's content has changed.
 
int GetPlugConnectionModifiedList (FBPlugList &pPlugList, FBPlugModificationFlag pConnectionModificatonFlag, bool pAddRemove)
 Get plug's modified src/dst property/object connection added/removed List.
 
bool RevertModification (FBPlugModificationFlag pFlag=kFBAllModifiedMask)
 Revert the plug's modification to original status.
 
void SetStatusFlag (FBPlugStatusFlag pStatus, bool pValue)
 Set the plug's status flag.
 
bool GetStatusFlag (FBPlugStatusFlag pStatus) const
 Tell if the plug's status has changed.
 
FBPlugGetOwner ()
 Get the owner of this plug.
 
FBPlugGetOwned (int pIndex)
 Get the owned plug at specified index.
 
int GetOwnedCount ()
 Get the owned plug count.
 
virtual const char * ClassName ()
 internal System vars.
 
virtual bool Is (int pTypeId)
 Is( int pTypeId )
 
virtual int GetTypeId ()
 GetTypeId( int pTypeId )
 
virtual bool PlugDataNotify (FBConnectionAction pAction, FBPlug *pThis, void *pData=NULL, void *pDataOld=NULL, int pDataSize=0)
 PlugDataNotify when overloaded is equivalent of FBSystem.OnConnectionDataNotify but in the context of the derived object only.
 
virtual bool PlugStateNotify (FBConnectionAction pAction, FBPlug *pThis, void *pData=NULL, void *pDataOld=NULL, int pDataSize=0)
 PlugStateNotify when overloaded is equivalent of FBSystem.OnConnectionStateNotify but in the context of the derived object only.
 
virtual bool PlugNotify (FBConnectionAction pAction, FBPlug *pThis, int pIndex, FBPlug *pPlug=NULL, FBConnectionType pConnectionType=kFBConnectionTypeNone, FBPlug *pNewPlug=NULL)
 PlugNotify when overloaded is equivalent of FBSystem.OnConnectionNotify but in the context of the derived object only.
 
virtual void FBDelete ()
 Actual destructor for a FBPlug.
 
- Static Protected Member Functions inherited from FBPlug
static int GetInternalClassId ()
 Internal class Id.
 
- Static Protected Attributes inherited from FBPlug
static const char * ClassGroupName
 ClassGroupName of the object.
 
static int TypeInfo
 TypeInfo.
 
static int mGlobalTypeInfo
 Represente the Type Index.
 

Detailed Description

Property: Base property class.

A property is a holder for function callbacks into the internals of the application.

You cannot instantiate FBProperty objects. To reference a property:

  • Use an instance of an FBComponent object. The methods FBComponent::PropertyCreate and FBComponent::PropertyRemove can be used to modify an object's set of properties. When accessing a FBProperty object via its containing object, you can get or set (assuming it is not read-only) its value directly, for example in Python: myObject.Visibility = True.
  • FBPropertyManager exists in all FBComponent objects, and contains an array of all the registered properties. Use FBProperty::Find to find a property by name. When accessing a property reference directly, its value is obtained via its 'Data' member.
    myProp = myObject.PropertyList.Find( 'Visibility' )
    if myProp: myProp.Data = True

To see how to create a custom property in Python, see CustomProperty.py.

Definition at line 194 of file fbproperties.h.

Constructor & Destructor Documentation

◆ FBProperty()

Constructor.

Member Function Documentation

◆ AcceptTemporaryProperty()

bool AcceptTemporaryProperty ( const char *  pEnumList[] = NULL,
fbExternalGetSetHandler  pGet = NULL,
fbExternalGetSetHandler  pSet = NULL 
)

Accept a temporary property as a dynamic property.

Warning
if there is no call to AcceptTemporaryProperty(), is will be converted to a user property after the file is retrieved.
Returns
true if property was temporary and converted to a user property.

◆ AllowsLocking()

bool AllowsLocking ( ) const

AllowsLocking.

Returns
true if property can be locked

◆ AsInt()

int AsInt ( )

Get the property as an integer.

Returns
The integer version of the property.

Referenced by FBPropertyBaseEnum< tType >::AsString().

◆ AsString()

virtual const char * AsString ( FBDataAsStringFlag  pFlag = kFBDataAsStringUI)
virtual

Get the property value as a string.

Parameters
pFlagIndicates the returned string to be used for UI or storage. It defaults to kFBDataAsStringUI.
Returns
The string version of the property.

Reimplemented in FBPropertyBaseEnum< tType >, FBPropertyBaseEnum< EAreaLightShapes >, FBPropertyBaseEnum< EKeyPropertyBehavior >, FBPropertyBaseEnum< ELengthUnitType >, FBPropertyBaseEnum< EPathEndCapStyle >, FBPropertyStringList, and FBPropertyBaseAnimatableEnum< tType >.

◆ EnumList()

virtual const char * EnumList ( int  pIndex)
virtual

◆ GetData()

◆ GetDataType()

virtual KDataType * GetDataType ( )
virtual

Get the property datatype pointer.

Returns
Datatype of property (NULL in the case of the FBProperty is not internal).

Reimplemented in FBPropertyAnimatable.

◆ GetEnumStringList()

FBStringList * GetEnumStringList ( bool  pCreateIt = false)

String list for enum properties.

Parameters
pCreateItCreate a new list if necessary.
Returns
the pointer to the string list..

◆ GetMax()

double GetMax ( )

GetMax.

Returns
Maximum value for the property.

◆ GetMin()

double GetMin ( )

GetMin.

Returns
Minimum value for the property.

◆ GetName()

const char * GetName ( )

Get the property's name.

Returns
The property's name.

◆ GetParent()

void * GetParent ( )
inline

Get the parent of the object.

Returns
Parent object.

Definition at line 422 of file fbproperties.h.

◆ GetPropertyFlag()

bool GetPropertyFlag ( FBPropertyFlag  pFlag)

GetPropertyFlag.

Parameters
pFlagFlag to test if it is True or False.
Returns
If the flag is True, the function returns True and vice-versa.
Warning
Flags are not saved into or read from a FBX file.

◆ GetPropertyFlags()

FBPropertyFlag GetPropertyFlags ( )

GetPropertyFlags.

Returns
Return all flags at once.

◆ GetPropertyType()

virtual FBPropertyType GetPropertyType ( )
virtual

◆ GetPropertyTypeName()

const char * GetPropertyTypeName ( )

Get the property's type name.

Returns
The property's type name.

◆ GetReferencedProperty()

FBProperty * GetReferencedProperty ( )

Get the referenced property, in the case of this property is a reference property (see the IsReferenceProperty() method).

Returns
The referenced property, or a null pointer if this property is not a reference property.

◆ GetSubMemberCount()

int GetSubMemberCount ( ) const

GetSubMemberCount.

Returns
Number of sub-members.

◆ HasSomethingLocked()

bool HasSomethingLocked ( ) const

HasSomethingLocked.

Returns
true if property or any of its members is locked

◆ IsAnimatable()

virtual bool IsAnimatable ( )
virtual

Reimplemented in FBPropertyAnimatable.

◆ IsAnimated()

bool IsAnimated ( ) const

Get the property animated flag status.

◆ IsList()

virtual bool IsList ( )
virtual

Verify if property is of this type.

Returns
true if property is of type.

Reimplemented in FBPropertyBasicList, and FBPropertyStringList.

◆ IsLocked()

bool IsLocked ( ) const

IsLocked.

Returns
true if property is locked

◆ IsMaxClamp()

bool IsMaxClamp ( )

Indicate if maximum value clamping will be applied on user input value.

Returns
true if property the value will be clamped to a maximum value.

◆ IsMemberLocked()

bool IsMemberLocked ( int  pIndex) const

IsMemberLocked.

Parameters
pIndexIndex of the sub-member of the property to check.
Returns
true if property sub-member is locked

◆ IsMinClamp()

bool IsMinClamp ( )

Indicate if minimum value clamping will be applied on user input value.

Returns
true if property the value will be clamped to a minimum value.

◆ IsObjectList()

bool IsObjectList ( )

Indicate if is an instance of FBPropertyListObject.

Warning
A FBPropertyListObject will also return true on a call to 'IsList()'.

◆ IsReadOnly()

◆ IsTemporaryProperty()

bool IsTemporaryProperty ( )

Indicate if a property was created on retrieve because it didn't exist.

Warning
if there is no call to AcceptTemporaryProperty(), is will be converted to a user property after the file is retrieved.
Returns
true if property is temporary.

◆ ModifyPropertyFlag()

void ModifyPropertyFlag ( FBPropertyFlag  pFlag,
bool  pValue 
)

ModifyPropertyFlag.

Parameters
pFlagThe flag to switch to True or False.
pValueThe value to set about this flag.
Warning
Flags are not saved into or read from a FBX file.

◆ NotifyEnumStringListChanged()

void NotifyEnumStringListChanged ( )

Notify system that the enum list was modified.

◆ OriIsAnimated()

bool OriIsAnimated ( ) const

Get the property original animated flag status (before any modification)

◆ OriValueAsString()

const char * OriValueAsString ( )

Get the property original value (before any modification) as string.

Returns
returns the original value of the property in string with format same as AsString(kDataAsStringPersistence)

◆ SetData()

◆ SetEnable()

void SetEnable ( bool  pValue)

Set property enable status.

◆ SetInt()

bool SetInt ( int  pInt)

Set the property from an integer.

Parameters
pIntInt to set property from.
Returns
True if it was possible.

◆ SetLocked()

void SetLocked ( bool  pLocked)

SetLocked.

Parameters
pLockedTrue if the property is to be locked, false if it is to be unlocked.

◆ SetMax()

void SetMax ( double  pMax,
bool  pForceMaxClamp = false 
)

SetMax.

Parameters
pMaxMaximum value of the property.
pForceMaxClampForce clamping to maximum value of the property.

◆ SetMemberLocked()

void SetMemberLocked ( int  pIndex,
bool  pLocked 
)

SetMemberLocked.

Parameters
pIndexIndex of the sub-member of the property to lock or unlock.
pLockedTrue if the sub-member is to be locked, false if it is to be unlocked.

◆ SetMin()

void SetMin ( double  pMin,
bool  pForceMinClamp = false 
)

SetMin.

Parameters
pMinMinimum value of the property.
pForceMinClampForce clamping to minimum value of the property.

◆ SetMinMax()

void SetMinMax ( double  pMin,
double  pMax,
bool  pForceMinClamp = false,
bool  pForceMaxClamp = false 
)

SetMinMax.

Parameters
pMinMinimum value of the property.
pMaxMaximum value of the property.
pForceMinClampForce clamping to minimum value of the property.
pForceMaxClampForce clamping to maximum value of the property.

◆ SetName()

void SetName ( const char *  pName)

Set the property's name.

Parameters
pNameNew name for the property.

◆ SetString()

virtual bool SetString ( const char *  pString)
virtual

Set the property value from a string.

Parameters
pStringString to set property value from, with format same as AsString(kFBDataAsStringPersistence)
Returns
True if it was possible.

Reimplemented in FBPropertyBaseEnum< tType >, FBPropertyBaseEnum< EAreaLightShapes >, FBPropertyBaseEnum< EKeyPropertyBehavior >, FBPropertyBaseEnum< ELengthUnitType >, FBPropertyBaseEnum< EPathEndCapStyle >, FBPropertyStringList, and FBPropertyBaseAnimatableEnum< tType >.

Member Data Documentation

◆ mName

FBString mName
protected

mName Property unique name.

Definition at line 200 of file fbproperties.h.

◆ mParent

void* mParent
protected

mParent Parent of the property.

Definition at line 202 of file fbproperties.h.


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