Open Reality Reference Guide
fbproperties.h
Go to the documentation of this file.
1 #ifndef __FBPROPERTIES_H__
2 #define __FBPROPERTIES_H__
3 /**************************************************************************
4 Copyright (c) 1994 - 2009 Autodesk, Inc. and/or its licensors.
5 All Rights Reserved.
6 
7 The coded instructions, statements, computer programs, and/or related
8 material (collectively the "Data") in these files contain unpublished
9 information proprietary to Autodesk, Inc. and/or its licensors, which is
10 protected by Canada and United States of America federal copyright law
11 and by international treaties.
12 
13 The Data may not be disclosed or distributed to third parties, in whole
14 or in part, without the prior written consent of Autodesk, Inc.
15 ("Autodesk").
16 
17 THE DATA IS PROVIDED "AS IS" AND WITHOUT WARRANTY.
18 ALL WARRANTIES ARE EXPRESSLY EXCLUDED AND DISCLAIMED. AUTODESK MAKES NO
19 WARRANTY OF ANY KIND WITH RESPECT TO THE DATA, EXPRESS, IMPLIED OR
20 ARISING BY CUSTOM OR TRADE USAGE, AND DISCLAIMS ANY IMPLIED WARRANTIES
21 OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR
22 PURPOSE OR USE. WITHOUT LIMITING THE FOREGOING, AUTODESK DOES NOT
23 WARRANT THAT THE OPERATION OF THE DATA WILL BE UNINTERRUPTED OR ERROR
24 FREE.
25 
26 IN NO EVENT SHALL AUTODESK, ITS AFFILIATES, PARENT COMPANIES, LICENSORS
27 OR SUPPLIERS ("AUTODESK GROUP") BE LIABLE FOR ANY LOSSES, DAMAGES OR
28 EXPENSES OF ANY KIND (INCLUDING WITHOUT LIMITATION PUNITIVE OR MULTIPLE
29 DAMAGES OR OTHER SPECIAL, DIRECT, INDIRECT, EXEMPLARY, INCIDENTAL, LOSS
30 OF PROFITS, REVENUE OR DATA, COST OF COVER OR CONSEQUENTIAL LOSSES OR
31 DAMAGES OF ANY KIND), HOWEVER CAUSED, AND REGARDLESS OF THE THEORY OF
32 LIABILITY, WHETHER DERIVED FROM CONTRACT, TORT (INCLUDING, BUT NOT
33 LIMITED TO, NEGLIGENCE), OR OTHERWISE, ARISING OUT OF OR RELATING TO THE
34 DATA OR ITS USE OR ANY OTHER PERFORMANCE, WHETHER OR NOT AUTODESK HAS
35 BEEN ADVISED OF THE POSSIBILITY OF SUCH LOSS OR DAMAGE.
36 
37 **************************************************************************/
38 
45 #include <kaydaradef.h>
46 
47 #ifndef FBSDK_DLL
48 
51 #define FBSDK_DLL K_DLLIMPORT
52 #endif
53 
54 #include <assert.h>
55 #include <stdio.h>
56 #include <stdlib.h>
57 
58 #include <fbsdk/fbplug.h>
59 #include <fbsdk/fbarray.h>
60 #include <fbsdk/fbstring.h>
61 #include <fbsdk/fbtime.h>
62 #include <fbsdk/fbevaluateinfo.h>
63 
64 K_FORWARD( KEventBase );
65 K_FORWARD( KObject );
66 K_FORWARD( KProperty );
67 K_FORWARD( KEvaluationProperty );
68 K_FORWARD( KDataType );
69 K_FORWARD( IFBObject );
70 K_FORWARD( IRegister );
71 
72 #ifdef FBSDKUseNamespace
73 namespace FBSDKNamespace {
74 #endif
75 
77 
80  {
104  };
105 
107 
110  {
113  };
114 
119  {
120  kFBPropertyFlagNotSet = 0,
122  kFBPropertyFlagForceStaticProperty = (1 << 1),
123  kFBPropertyFlagDisableProperty = (1 << 2),
126  kFBPropertyFlagAnimated = (1 << 4),
128  kFBPropertyFlagReadOnly = (1 << 6),
129  kFBPropertyFlagNotUserDeletable = (1 << 7),
130  kFBValueAllocated = (1 << 8),
131  kFBDynamicHidden = (1 << 9),
132  kFBDrivenSetByMain = (1 << 10),
133  /*K_DEPRECATED_2022*/ kFBSlaveSetByMaster = kFBDrivenSetByMain,
134  kFBLoadedUserProperty = (1 << 11)
135  };
136 
141 #define FB_DEFINE_COMPONENT( DllTag, Type ) \
142  class FB##Type; \
143  typedef class DllTag FBPropertyBase< FB##Type*,kFBPT_object > FBPropertyBase##Type; \
144  typedef class DllTag FBPropertyBaseComponent< FB##Type* > FBProperty##Type
145 
150 #define FB_DEFINE_ENUM( DllTag, Type ) \
151  typedef class DllTag FBPropertyBaseEnum< enum FB##Type > FBProperty##Type;
152 
156 #define FB_DEFINE_CLASS_ENUM( EnumName ) \
157  typedef class FBPropertyBaseEnum< enum __FBClassType::e##EnumName > Property##EnumName;
158 
163 #define FB_DEFINE_LIST( DllTag, Type ) \
164  typedef class DllTag FBPropertyBaseList< FB##Type* > FBPropertyBaseList##Type;
165 
167  typedef void (*fbGetSetHandler)(void);
169  typedef void (*fbExternalGetSetHandler)(HIObject pObject);
170 
173 
194  class FBSDK_DLL FBProperty : public FBPlug
195  {
197 
198  protected:
202  void* mParent;
203 
204  public:
207 
208 #ifndef DOXYGEN_SHOULD_SKIP_THIS
209  IObject_Declare(override);
211 
213  FBProperty* InitInternal( KProperty* pProperty );
214 
216  KProperty* GetInternal() const;
217 
219  void* GetValuePtr() const;
220 
222  FBProperty* CreateInternal( FBComponent* pParent, const char* pName, fbExternalGetSetHandler pGet = NULL, fbExternalGetSetHandler pSet = NULL);
223 
225  FBProperty* CreateTextureConnectable( FBComponent* pParent, const char* pName );
226 
228  void SetInternal( KProperty* pInternal );
229 #endif
230 
232  void SetEnable( bool pValue );
233 
237  const char* GetName();
238 
242  void SetName(const char *pName);
243 
248 
252  const char* GetPropertyTypeName();
253 
257  virtual KDataType* GetDataType();
258 
260 
263  virtual void SetData( void* pData );
265 
267 
272  virtual void GetData( void* pData, int pSize, FBEvaluateInfo *pEvalInfo = NULL ) const;
274 
278  int AsInt();
279 
284  bool SetInt(int pInt);
285 
290  virtual const char* AsString( FBDataAsStringFlag pFlag = kFBDataAsStringUI );
291 
296  virtual bool SetString( const char* pString );
297 
301  const char* OriValueAsString();
302 
304  bool IsAnimated() const;
305 
308  bool OriIsAnimated() const;
309 
311 
314  virtual bool IsList();
315  virtual bool IsAnimatable();
316  bool IsInternal() const;
317  bool IsUserProperty();
318  bool IsTextureConnectableProperty();
319  bool IsReferenceProperty();
321 
325  bool IsMinClamp();
326 
330  bool IsMaxClamp();
331 
337 
342  bool AcceptTemporaryProperty(const char* pEnumList[] = NULL, fbExternalGetSetHandler pGet=NULL, fbExternalGetSetHandler pSet=NULL);
343 
347  bool IsObjectList();
348 
352  virtual bool IsReadOnly();
353 
358  virtual const char* EnumList( int pIndex );
359 
364  FBStringList* GetEnumStringList(bool pCreateIt = false);
365 
369 
375  void ModifyPropertyFlag(FBPropertyFlag pFlag, bool pValue);
376 
381 
388 
395  void SetMinMax( double pMin, double pMax, bool pForceMinClamp = false, bool pForceMaxClamp = false );
396 
401  void SetMin( double pMin, bool pForceMinClamp = false );
402 
407  void SetMax( double pMax, bool pForceMaxClamp = false );
408 
412  double GetMin();
413 
417  double GetMax();
418 
422  inline void* GetParent() { return mParent; }
423 
433 
437  int GetSubMemberCount() const;
438 
442  bool AllowsLocking() const;
443 
447  bool HasSomethingLocked() const;
448 
452  bool IsLocked() const;
453 
458  bool IsMemberLocked( int pIndex ) const;
459 
463  void SetLocked( bool pLocked );
464 
469  void SetMemberLocked( int pIndex , bool pLocked );
470 
472 
477 
478  private:
479  // FBProperty(FBProperty&); // Make sure no copy constructor is use
480  };
481 
487  template<class T> inline T* FBCast(FBProperty* pProperty, bool pAutoCreate = false)
488  {
489  HIObject lProperty = pProperty ? FBGetFBObject(pProperty->GetHIObject(), pAutoCreate) : NULL;
490  // Should also validate type but not available for now
491  return (T*)lProperty;
492  }
493 
495  FB_FORWARD( FBBox );
497  FB_FORWARD( FBTake );
498 
500  // PropertyEvent
503 
515  {
516  protected:
517 #ifndef DOXYGEN_SHOULD_SKIP_THIS
518 
519  HIRegister mParentRegister;
521  int mType;
523  int mSubType;
524 #endif
525  public:
528 
537  FBPropertyEvent *Init( FBComponent* pComponent, HIRegister pParent,const char *pName, int pType, int pSubType=K_INT_MAX );
538 
544  FBPropertyEvent *InitGlobal( const char* pName, const char* pGlobalEventName );
545 
547  virtual ~FBPropertyEvent();
548 
550 
554  virtual void Add ( HICallback pOwner, kICallbackHandler pHandler );
555  virtual void Remove ( HICallback pOwner, kICallbackHandler pHandler );
557 
559  virtual void InvalidateParent();
560 
564  virtual FBPropertyType GetPropertyType() override { return kFBPT_event; }
565 
566  private:
567 
568  DataFBPropertyEvent* mLocalPtr;
569  };
570 
573  {
574  public:
575  virtual void Add ( HICallback pOwner, kICallbackHandler pHandler );
576  virtual void Remove ( HICallback pOwner, kICallbackHandler pHandler );
577  };
578 
581  {
582  public:
583  virtual void Add ( HICallback pOwner, kICallbackHandler pHandler );
584  virtual void Remove ( HICallback pOwner, kICallbackHandler pHandler );
585  };
586 
589  {
590  public:
591  virtual void Add ( HICallback pOwner, kICallbackHandler pHandler );
592  virtual void Remove ( HICallback pOwner, kICallbackHandler pHandler );
593  };
594 
597  {
598  public:
599  virtual void Add ( HICallback pOwner, kICallbackHandler pHandler );
600  virtual void Remove ( HICallback pOwner, kICallbackHandler pHandler );
601  };
602 
605  {
606  public:
607  virtual void Add ( HICallback pOwner, kICallbackHandler pHandler );
608  virtual void Remove ( HICallback pOwner, kICallbackHandler pHandler );
609  };
610 
613  {
614  public:
615  virtual void Add ( HICallback pOwner, kICallbackHandler pHandler );
616  virtual void Remove ( HICallback pOwner, kICallbackHandler pHandler );
617  };
618 
622  template <class tType, FBPropertyType pPT> class FBPropertyBase : public FBProperty
623  {
624  protected:
625 #ifndef DOXYGEN_SHOULD_SKIP_THIS
626  void (* Set)(void *, tType);
627  tType (* Get)(void *);
628 #endif
629  public:
630 
632  typedef tType ValueType;
633 
635  inline FBPropertyBase() { Set = NULL; Get = NULL; }
636 
640  inline FBPropertyBase(const FBPropertyBase<tType,pPT> &pValue) { operator=((tType)pValue ); }
641 
644  {
645  }
646 
654  inline FBPropertyBase *Init( void* pParent, const char *pName,tType (* pGet)(void *)=NULL,void (* pSet)(void *,tType)=NULL )
655  {
656  mParent = pParent;
657  mName = pName ;
658  Get = pGet;
659  Set = pSet;
660  return this;
661  }
662 
664 
668  inline void operator=(tType pValue) { SetData( &pValue ); }
670 
672 
676  inline void operator=(const FBPropertyBase<tType,pPT> &pProperty) { operator=((tType)pProperty ); }
678 
683  inline operator tType() const { tType Value; GetData( &Value,sizeof(Value) ); return Value; }
684 
688  virtual FBPropertyType GetPropertyType( ) override { return pPT; }
689 
693  inline virtual void SetPropertyValue( tType pValue )
694  {
695  if(IsInternal() && GetValuePtr())
696  {
697  *(tType*)GetValuePtr() = pValue;
698  }
699  }
700 
704  inline tType GetPropertyValue( )
705  {
706  if(IsInternal() && GetValuePtr())
707  {
708  return *(tType*)GetValuePtr();
709  } else
710  {
711  return (tType)0;
712  }
713  }
714 
719  inline virtual bool IsReadOnly() override { return IsInternal() ? (FBProperty::IsReadOnly()) : (Set == NULL); }
720 
724  inline virtual void GetData(void* pData, int pSize, FBEvaluateInfo *pEvalInfo = NULL) const override
725  {
726  if(Get)
727  {
728  *((tType*)pData) = (*Get)(mParent);
729  }
730  else if (IsInternal())
731  {
732  FBProperty::GetData( pData, pSize, pEvalInfo );
733  }
734  else
735  {
736  assert(Get != NULL || IsInternal());
737  *((tType*)pData) = (tType)0;
738  }
739  }
743  inline virtual void SetData(void* pData) override
744  {
745  if(Set)
746  {
747  (*Set)( mParent,*(tType*)pData );
748  }
749  else if (IsInternal())
750  {
751  FBProperty::SetData( pData );
752  }
753  else
754  {
755  assert( Set != NULL || IsInternal() );
756  }
757  }
758  };
759 
764  template <class tType> class FBPropertyBaseEnum : public FBPropertyBase<tType,kFBPT_enum>
765  {
766  public:
767 #ifndef DOXYGEN_SHOULD_SKIP_THIS
768 
769  static const char *mStrings[];
770 #endif
771  FBPropertyBaseEnum()=default;
773 
775  inline ~FBPropertyBaseEnum()=default;
776 
781  FBPropertyBase<tType,kFBPT_enum>(pValue)
782  { operator=((tType)pValue ); }
783 
785 
789  inline void operator=(tType pValue) { this->SetData( &pValue ); }
791 
796  inline operator tType() const { tType Value; this->GetData( &Value,sizeof(Value) ); return Value; }
797 
798  virtual const char* EnumList( int pIndex ) override
799  {
800  if( FBPropertyBaseEnum::IsInternal() )
801  {
802  return FBProperty::EnumList( pIndex );
803  }
804  // NOTE:
805  // --> replacing test for if(mStrings) by if(mStrings[0])
806  // This is safe to do as we should always have at least 1 item
807  // in the list based on our base class implementation. And
808  // the compiler should throw a linker error if mStrings is not found.
809  // mStrings[0] == NULL for enum kDefaultEnum but mStrings can never be NULL
810  else if(mStrings[0])
811  {
812  return mStrings[pIndex];
813  }
814  else
815  {
816  assert(mStrings[0] || FBPropertyBaseEnum::IsInternal());
817  return NULL;
818  }
819  }
820 
825  virtual const char* AsString( FBDataAsStringFlag pFlag = kFBDataAsStringUI ) override { return EnumList( FBPropertyBaseEnum::AsInt() );}
826 
831  virtual bool SetString( const char *pString ) override
832  {
833  int count=0;
834  const char * tmpstr;
835  while ((tmpstr=EnumList( count ))!=NULL) {
836  if (strcmp(tmpstr,pString)==0) {
837  FBPropertyBaseEnum::SetData( &count );
838  return true;
839  }
840  count++;
841  }
842  return false;
843  }
844 
845  };
846 
847 
852  {
853  public:
861  FBPropertyBasicList( HIObject pParent, const char *pName );
866  FBProperty* Init( void* pParent, const char *pName );
867 
869  void RemoveAll();
870 
875  virtual int GetCount()=0;
876 
881  virtual void RemoveAt( int pIndex )=0;
882 
886  virtual bool IsList();
887  };
888 
892  template <class tType> class FBPropertyBaseList : public FBPropertyBasicList
893  {
894  public:
897 
900  {
901 
902  }
907  FBPropertyBaseList( HIObject pParent, const char *pName ):FBPropertyBasicList( pParent, pName ) {}
908 
909  public:
910  //***
911  //--- These functions require overloads in derived classes.
912  //***
913 
919  virtual int Add( tType pItem )=0;
920 
926  virtual tType operator[]( int pIndex )=0;
927 
928  public:
929  //***
930  //--- These functions can be optionally overloaded in derived classes.
931  //***
932 
937  inline virtual int Find( tType pItem )
938  {
939  int Index;
940  for(Index=0; Index<GetCount(); Index++ )
941  {
942  if( operator[](Index)==pItem )
943  {
944  return Index;
945  }
946  }
947  return -1;
948  }
949 
954  inline virtual int Remove( tType pItem )
955  {
956  int Index = Find( pItem );
957  if (Index!=-1)
958  {
959  RemoveAt( Index );
960  }
961  return Index;
962  }
963 
968  inline virtual tType GetAt(int pIndex)
969  {
970  return operator[](pIndex);
971  }
972  };
973 
975  enum kDefaultEnum {
977  };
978 
979 
986 
989  {
990  public:
993 
996 
1002  FBPropertyStringList* Init( FBComponent* pComponent, const char *pName );
1003 
1004  public:
1009  kReference GetReferenceAt( int pIndex );
1014  void SetReferenceAt( int pIndex,kReference pRef );
1015 
1020  int Find( kReference pRef );
1021 
1026  int Find( const char *S );
1027 
1032  virtual const char *GetAt( int pIndex );
1033 
1039  const char *operator[](int pIndex);
1040 
1042  void Sort( );
1043 
1047  int GetCount();
1048 
1053  int Remove( const char *S );
1054 
1055  public: // Needs to be overriden for special behaviors
1061  virtual int Add( const char *S,kReference pRef = 0 );
1062 
1064  virtual void Clear();
1065 
1069  virtual void RemoveAt( int pIndex );
1070 
1075  virtual int IndexOf(const char *S);
1076 
1082  virtual void InsertAt( int pIndex, const char *S,kReference pRef = 0 );
1083 
1089  virtual bool SetAt( int pIndex,const char *pString );
1090 
1094  virtual bool IsList() override;
1095 
1100  virtual const char* AsString( FBDataAsStringFlag pFlag = kFBDataAsStringUI ) override;
1101 
1106  virtual bool SetString( const char *pString ) override;
1107 
1111  virtual FBPropertyType GetPropertyType() override { return kFBPT_stringlist; }
1112  };
1113 
1115  // FBPropertyManager
1118 
1125  {
1126  public:
1129 
1132 
1137  int Add( FBProperty* Property );
1138 
1144  FBProperty* operator[](int pIndex);
1145 
1149  int GetCount();
1150 
1157  FBProperty* Find( const char *pPropertyName, bool pMultilangLookup=true );
1158 
1165  void FindPropertiesByName( const char* pPropertyNamePattern, FBArrayTemplate<FBProperty*>& pPropList, bool pMultilangLookup=true );
1166 
1171  int Remove( FBProperty* pProperty );
1172 
1177  void AddToCache( FBProperty* pProperty );
1178 
1183  void RemoveFromCache( KProperty* pProperty );
1184 
1190  FBProperty* FindInCache( KProperty* pProperty );
1191 
1192  private:
1196  void ClearCache();
1197 
1202  void SetParent( HIObject pParent );
1203 
1204 #ifndef DOXYGEN_SHOULD_SKIP_THIS
1205  KObject* mObject;
1206  FBArrayTemplate< FBProperty* > mPropertyCache;
1207  FBArrayTemplate< FBProperty* > mPropertyLocal;
1208 #endif
1209  friend class FBComponent;
1210  friend class FBVisualComponent;
1211  };
1212 
1216  template <class tType> class FBPropertyBaseComponent : public FBPropertyBase< tType, kFBPT_object >
1217  {
1218  public:
1220  int *TypeInfo;
1221  public:
1224 
1229  FBPropertyBase< tType, kFBPT_object >(pValue)
1231 
1234  {
1235  }
1236 
1238 
1241  inline void operator=(tType pValue) { FBPropertyBase< tType,kFBPT_object >::operator=(pValue); }
1243 
1247  inline tType operator -> () { return FBPropertyBase< tType,kFBPT_object >::operator tType(); }
1248 
1252  inline operator tType() const { return FBPropertyBase< tType,kFBPT_object >::operator tType(); }
1253  };
1254 
1259 #define FBImplementPropertyComponent( DllTag, Type ) \
1260  template class DllTag FBSDKNamespaceFunc(FBPropertyBase)< FB##Type*,kFBPT_object >; \
1261  template class DllTag FBSDKNamespaceFunc(FBPropertyBaseComponent)< FB##Type* >;
1262 
1267 #define FBImplementPropertyEnum( DllTag, Type ) \
1268  template class DllTag FBSDKNamespaceFunc(FBPropertyBaseEnum)< enum FB##Type >
1269 #define FBImplementClassPropertyEnum( DllTag, Class, EnumName ) \
1270  template class DllTag FBSDKNamespaceFunc(FBPropertyBaseEnum)< enum Class::E##EnumName >
1271 
1276 #define FBImplementPropertyList( DllTag, Type ) \
1277  template class DllTag FBSDKNamespaceFunc(FBPropertyBaseList) < FB##Type* >
1278 
1280  class FBSDK_DLL FBPropertyString : public FBPropertyBase< const char *, kFBPT_charptr >
1281  {
1282  public:
1283 
1285 
1289  inline void operator=(const char* pValue) { SetData( &pValue ); }
1291 
1296  inline operator const char* () const { char* Value; GetData( &Value,sizeof(Value) ); return Value; }
1297 
1298  inline bool operator==(const char* pValue) const { char* Value; GetData( &Value,sizeof(Value) ); return (Value == pValue) || (strcmp(Value, pValue) == 0); }
1299  inline bool operator!=(const char* pValue) const { return ! operator==(pValue); }
1300 
1304  virtual void SetPropertyValue( const char* pValue ) override;
1305  };
1306 
1308  typedef class FBSDK_DLL FBPropertyBase< bool,kFBPT_bool > FBPropertyBool;
1309 
1313  class FBSDK_DLL FBPropertyAction : public FBPropertyBase< bool, kFBPT_Action >
1314  {
1315  public:
1317  inline FBPropertyAction() {}
1318 
1321  {
1322  }
1323 
1327  bool operator ()();
1328  };
1329 
1331  typedef class FBSDK_DLL FBPropertyBase< int,kFBPT_int > FBPropertyInt;
1332 
1334  typedef class FBSDK_DLL FBPropertyBase< long long,kFBPT_int64 > FBPropertyInt64;
1335 
1337  typedef class FBSDK_DLL FBPropertyBase< unsigned long long,kFBPT_uint64 > FBPropertyUInt64;
1338 
1340  typedef class FBSDK_DLL FBPropertyBase< double,kFBPT_double > FBPropertyDouble;
1341 
1343  typedef class FBSDK_DLL FBPropertyBase< float,kFBPT_float > FBPropertyFloat;
1344 
1347 
1350 
1353 
1355  typedef class FBSDK_DLL FBPropertyBase< kReference,kFBPT_kReference > FBPropertykReference;
1356 
1366  typedef class FBPropertyBaseComponent< FBPlug* > FBPropertyPlug;
1367 
1375 #define FBPropertyInit( Param,Type,PropName,Get,Set ) \
1376  { \
1377  PropertyAdd(PropName.Init( (void*)Param,#PropName,(Type (*)(void *))Get,(void (*)(void *,Type))Set )); \
1378  }
1379 
1384 #define FBPropertyInitList( Param,PropName ) \
1385  { \
1386  PropertyAdd(PropName.Init( Param,#PropName )); \
1387  }
1388 
1393 #define FBPropertyInitStringList( Param,PropName ) \
1394  { \
1395  PropertyAdd(PropName.Init( Param, #PropName )); \
1396  }
1397 
1404 #define FBPropertyInitEvent( Param,Type,SubType,PropName ) \
1405  { \
1406  PropertyAdd(PropName.Init( this, IQ(Param,IRegister),#PropName,Type,SubType )); \
1407  }
1408 
1413 #define FBPropertyInitEventGlobal( GlobalEventName,PropName ) \
1414  { \
1415  PropertyAdd(PropName.InitGlobal( #PropName,GlobalEventName )); \
1416  }
1417 
1419 #define FBPropertyInitInternal( Parent, PropName, MBProperty ) \
1420  {\
1421  PropertyAdd(PropName.InitInternal( MBProperty ));\
1422  }
1423 
1425 #define FBPropertyInitInternalEnum( Param,Type,PropName,MBProperty,Get,Set ) \
1426  {\
1427  PropName.InitInternal( MBProperty ); \
1428  PropertyAdd(PropName.Init( (void*)Param,#PropName,(Type (*)(void *))Get,(void (*)(void *,Type))Set )); \
1429  }
1430 
1438 #define FBPropertyPublish( Parent,Prop,PropName,Get,Set ) \
1439  { \
1440  PropertyAdd(Prop.CreateInternal( Parent,PropName,(fbExternalGetSetHandler)Get,(fbExternalGetSetHandler)Set )); \
1441  }
1442 
1449 #define FBPropertyInitTextureConnectable( Parent,Prop,PropName ) \
1450  { \
1451  PropertyAdd(Prop.CreateTextureConnectable( Parent,PropName )); \
1452  }
1453 
1482  {
1483  public:
1487 
1491 
1492  public:
1493 #ifndef DOXYGEN_SHOULD_SKIP_THIS
1494  FBPropertyAnimatable* InitInternal( KEvaluationProperty* pProperty );
1496 #endif
1497 
1504  FBPropertyAnimatable* Init( FBBox* pOwner, const char* pName, const char* pType, double* pInit );
1505 
1509  void Destroy();
1510 
1514  virtual KDataType* GetDataType() override;
1515 
1519  const char* GetDataTypeName();
1520 
1524  bool IsFocused();
1525 
1529  void SetFocus( bool pState );
1530 
1533  void Key();
1534 
1538  void KeyAt( FBTime pTime );
1539 
1543  void KeyRemoveAt( FBTime pTime );
1544 
1548  int GetDataSize() const;
1549 
1551 
1554  virtual bool IsAnimatable() override { return true; }
1555 
1560  bool IsAnimated();
1561 
1566  void SetAnimated( bool pState, bool pCheckLocked = false );
1567 
1573 
1578 
1582  virtual void SetData( void* pData ) override;
1583 
1587  virtual void GetData( void* pData, int pSize, FBEvaluateInfo* pEvalInfo = NULL ) const override;
1588 
1594  void SetCandidate( void* pData, int pSize, FBEvaluateInfo* pEvalInfo = NULL );
1595 
1601  void SetGlobalCandidate( void* pData, int pSize, FBEvaluateInfo* pEvalInfo = NULL );
1602 
1603 
1612 
1616  bool AllowsMuting() const;
1617 
1621  bool HasSomethingMuted() const;
1622 
1626  bool IsMuted() const;
1627 
1632  bool IsMemberMuted( int pIndex ) const;
1633 
1637  void SetMuted( bool pMuted );
1638 
1643  void SetMemberMuted( int pIndex , bool pMuted );
1644 
1650  bool SetColor(const FBColor& pColor, int pIndex);
1651 
1656  FBColor GetColor(int pIndex);
1657 
1662  bool ResetColor(int pIndex);
1663 
1668  bool IsFocusedChild(int pIndex);
1669 
1675  bool SetFocusChild(int pIndex, bool pState);
1676 
1678 
1679  };
1680 
1684  template <class tType, FBPropertyType pPT> class FBSDK_DLL FBPropertyBaseAnimatable : public FBPropertyAnimatable
1685  {
1686  public:
1687 
1689  typedef tType ValueType;
1690 
1694  {
1696  }
1697 
1700 
1702 
1705  void operator=(tType pValue)
1706  {
1708  }
1710 
1714  operator tType() const
1715  {
1716  tType val;
1717  FBPropertyAnimatable::GetData(&val,sizeof(val));
1718  return val;
1719  }
1720 
1724  virtual FBPropertyType GetPropertyType( ) override { return pPT; }
1725  };
1726 
1727 
1744  typedef class FBSDK_DLL FBPropertyBaseAnimatable< unsigned long long,kFBPT_uint64 > FBPropertyAnimatableUInt64;
1789  template <class tType> class FBPropertyBaseAnimatableEnum : public FBPropertyBaseAnimatable<int,kFBPT_enum>
1790  {
1791  public:
1792 #ifndef DOXYGEN_SHOULD_SKIP_THIS
1793 
1794  static const char *mStrings[];
1795 #endif
1796 
1799 
1802  {
1803  }
1804 
1808  inline FBPropertyBaseAnimatableEnum(const FBPropertyBaseAnimatableEnum<tType> &pValue) { operator=((tType)pValue ); }
1809 
1811 
1815  inline void operator=(tType pValue) { SetData( &pValue ); }
1817 
1822  inline operator tType() const { tType Value; GetData( &Value,sizeof(Value) ); return Value; }
1823 
1824  virtual const char* EnumList( int pIndex ) override
1825  {
1826  if( IsInternal() )
1827  {
1828  return FBProperty::EnumList( pIndex );
1829  }
1830  // NOTE:
1831  // --> replacing test for if(mStrings) by if(mStrings[0])
1832  // This is safe to do as we should always have at least 1 item
1833  // in the list based on our base class implementation. And
1834  // the compiler should throw a linker error if mStrings is not found.
1835  // mStrings[0] == NULL for enum kDefaultEnum but mStrings can never be NULL
1836  else if(mStrings[0])
1837  {
1838  return mStrings[pIndex];
1839  }
1840  else
1841  {
1842  assert(mStrings[0] || IsInternal());
1843  return NULL;
1844  }
1845  }
1846 
1851  virtual const char* AsString( FBDataAsStringFlag pFlag = kFBDataAsStringUI ) override { return EnumList( AsInt() );}
1852 
1857  virtual bool SetString( const char *pString ) override
1858  {
1859  int Count=0;
1860  const char * tmpstr;
1861  while ((tmpstr=EnumList( Count ))!=NULL) {
1862  if (strcmp(tmpstr,pString)==0) {
1863  SetData( &Count );
1864  return true;
1865  }
1866  Count++;
1867  }
1868  return false;
1869  }
1870 
1871 
1872  };
1873 
1875  // Global
1877 #ifdef FBSDKUseNamespace
1878 }
1879 #endif
1880 
1881 #endif
FBPropertyStringList::RemoveAt
virtual void RemoveAt(int pIndex)
Remove an entry at pIndex.
FBPropertyStringList::FBPropertyStringList
FBPropertyStringList()
Constructor.
FBPropertyVector2d
class K_DLLIMPORT FBPropertyBase< FBVector2d, kFBPT_Vector2D > FBPropertyVector2d
FBPropertyVector2d type definition.
Definition: fbproperties.h:1464
FBPropertyBaseComponent::FBPropertyBaseComponent
FBPropertyBaseComponent(const FBPropertyBaseComponent< tType > &pValue)
Constructor.
Definition: fbproperties.h:1228
FBClassDeclare
#define FBClassDeclare(Name, Parent)
Class declaration.
Definition: fbdefines.h:85
FBPropertyManager::FBPropertyManager
FBPropertyManager()
Constructor.
kFBPT_charptr
@ kFBPT_charptr
charptr.
Definition: fbproperties.h:88
FBPropertyAnimatableVector2d
class K_DLLIMPORT FBPropertyBaseAnimatable< FBVector2d, kFBPT_Vector2D > FBPropertyAnimatableVector2d
FBPropertyAnimatableVector2D type definition.
Definition: fbproperties.h:1764
FBPropertyAnimatable::IsMuted
bool IsMuted() const
IsMuted.
FBProperty::SetMemberLocked
void SetMemberLocked(int pIndex, bool pLocked)
SetMemberLocked.
FBPropertyStringList::Remove
int Remove(const char *S)
Remove a string from the list.
FBVector2d
class K_DLLIMPORT FBVector2< double > FBVector2d
2D vector.
Definition: fbtypes.h:435
FBProperty::GetPropertyTypeName
const char * GetPropertyTypeName()
Get the property's type name.
FBProperty::IsMinClamp
bool IsMinClamp()
Indicate if minimum value clamping will be applied on user input value.
FBPropertyStringList::GetPropertyType
virtual FBPropertyType GetPropertyType() override
Get the property's type.
Definition: fbproperties.h:1111
FBPropertyEventConnectionStateNotify::Add
virtual void Add(HICallback pOwner, kICallbackHandler pHandler)
Add/Remove a callback.
FBPropertyStringList::operator[]
const char * operator[](int pIndex)
[] operator overload.
FBProperty::mName
FBString mName
Definition: fbproperties.h:200
kFBPT_double
@ kFBPT_double
double.
Definition: fbproperties.h:87
kFBPT_unknown
@ kFBPT_unknown
unknow.
Definition: fbproperties.h:81
FBProperty::GetName
const char * GetName()
Get the property's name.
FBPropertyManager::GetCount
int GetCount()
Get the number of properties stored in property manager.
FBGetFBObject
K_DLLIMPORT HIObject FBGetFBObject(HIObject pObject, bool pAutoCreate=false)
Get the SDK object from an Internal Object.
FBPropertyComponent
class K_DLLIMPORT FBPropertyBaseComponent< FBComponent * > FBPropertyComponent
Property: FBPropertyBaseComponent(FBComponent*)
Definition: fbproperties.h:1362
FBPropertyBaseAnimatable::GetPropertyType
virtual FBPropertyType GetPropertyType() override
Get the property's type.
Definition: fbproperties.h:1724
FBPropertyAnimatable::SetFocusChild
bool SetFocusChild(int pIndex, bool pState)
Set the focus (keyable) state of child component.
FBProperty::GetParent
void * GetParent()
Get the parent of the object.
Definition: fbproperties.h:422
FBPropertyBase::operator=
void operator=(const FBPropertyBase< tType, pPT > &pProperty)
Overloaded = operator.
Definition: fbproperties.h:676
FBPropertyBasicList::GetCount
virtual int GetCount()=0
Get the number of properties in the list.
FBPropertyAnimatable::GetAnimationNode
FBAnimationNode * GetAnimationNode(FBTake *pTake=NULL)
Get the animation node for the property.
FBPropertyStringList::IndexOf
virtual int IndexOf(const char *S)
Get the index of a string.
kFBPT_uint64
@ kFBPT_uint64
unsigned int 64 bits.
Definition: fbproperties.h:84
FBPropertykReference
class K_DLLIMPORT FBPropertyBase< kReference, kFBPT_kReference > FBPropertykReference
Property: kReference
Definition: fbproperties.h:1355
FBAnimationNode
Definition: fbdata.h:1047
FBPropertyBase
Definition: fbproperties.h:623
FBPropertyInt
class K_DLLIMPORT FBPropertyBase< int, kFBPT_int > FBPropertyInt
Property: int
Definition: fbproperties.h:1331
FBTimeSpan
TimeSpan class.
Definition: fbtime.h:384
FBPropertyManager::Remove
int Remove(FBProperty *pProperty)
Remove a property.
FBPropertyAnimatableVector4d
class K_DLLIMPORT FBPropertyBaseAnimatable< FBVector4d, kFBPT_Vector4D > FBPropertyAnimatableVector4d
FBPropertyAnimatableVector4D type definition.
Definition: fbproperties.h:1772
kFBPT_object
@ kFBPT_object
object.
Definition: fbproperties.h:92
FBPropertyBaseAnimatableEnum::FBPropertyBaseAnimatableEnum
FBPropertyBaseAnimatableEnum(const FBPropertyBaseAnimatableEnum< tType > &pValue)
FBPropertyBaseAnimatableEnum.
Definition: fbproperties.h:1808
FBPropertyEventConnectionStateNotify
PropertyEvent: Global ConnectionStateNotify event.
Definition: fbproperties.h:605
FBProperty::GetMin
double GetMin()
GetMin.
FBPropertyAnimatableColor
class K_DLLIMPORT FBPropertyBaseAnimatable< FBColor, kFBPT_ColorRGB > FBPropertyAnimatableColor
FBPropertyAnimatableColor type definition.
Definition: fbproperties.h:1776
FBPropertyAction::FBPropertyAction
FBPropertyAction()
Constructor.
Definition: fbproperties.h:1317
FBPropertyBaseAnimatable::FBPropertyBaseAnimatable
FBPropertyBaseAnimatable()
Constructors.
Definition: fbproperties.h:1692
FBPropertyTimeCode
class K_DLLIMPORT FBPropertyBase< FBTimeCode, kFBPT_TimeCode > FBPropertyTimeCode
Property: FBTimeCode
Definition: fbproperties.h:1349
FBProperty::IsAnimated
bool IsAnimated() const
Get the property animated flag status.
FBProperty::NotifyEnumStringListChanged
void NotifyEnumStringListChanged()
Notify system that the enum list was modified.
kFBPT_enum
@ kFBPT_enum
enum.
Definition: fbproperties.h:89
kFBPT_Vector4D
@ kFBPT_Vector4D
vector4d.
Definition: fbproperties.h:95
FBBox
A box is a fundamental building block in the application architecture.
Definition: fbcore.h:218
FBPropertyAnimatable::KeyAt
void KeyAt(FBTime pTime)
Key the property at time (t).
FBStringList
String list.
Definition: fbstring.h:208
FBPropertyAnimatable::SetFocus
void SetFocus(bool pState)
Set the property's focus (keyable) state.
FBDataAsStringFlag
FBDataAsStringFlag
FBDataAsStringFlag.
Definition: fbproperties.h:110
FBPropertyManager::Find
FBProperty * Find(const char *pPropertyName, bool pMultilangLookup=true)
Find a property, based on its name.
FBPropertyStringList::Init
FBPropertyStringList * Init(FBComponent *pComponent, const char *pName)
Property initialization function.
FBPropertyBaseList::~FBPropertyBaseList
~FBPropertyBaseList()
Destructor.
Definition: fbproperties.h:899
FBPropertyAnimatable::GetColor
FBColor GetColor(int pIndex)
Get the color of a particular FCurve of the property.
FBPropertyAnimatableAction
class K_DLLIMPORT FBPropertyBaseAnimatable< bool, kFBPT_Action > FBPropertyAnimatableAction
FBPropertyAnimatableAction type definition.
Definition: fbproperties.h:1728
FBProperty::GetPropertyFlag
bool GetPropertyFlag(FBPropertyFlag pFlag)
GetPropertyFlag.
FBPropertyBaseAnimatable::ValueType
tType ValueType
Property Value Type.
Definition: fbproperties.h:1689
FBPropertyBase::ValueType
tType ValueType
Property Value Type.
Definition: fbproperties.h:632
FBPropertyManager::operator[]
FBProperty * operator[](int pIndex)
Overloaded [] operator.
FBPropertyEventConnectionKeyingNotify
PropertyEvent: Global KeyingNotify event.
Definition: fbproperties.h:613
FBProperty::SetData
virtual void SetData(void *pData)
Set the value of the property, passing the type as an argument.
FBProperty::SetMinMax
void SetMinMax(double pMin, double pMax, bool pForceMinClamp=false, bool pForceMaxClamp=false)
SetMinMax.
FBPropertyFlag
FBPropertyFlag
Available flags for FBProperty objects.
Definition: fbproperties.h:119
FBPropertyAnimatable::SetColor
bool SetColor(const FBColor &pColor, int pIndex)
Set the color of the FCurves for the property.
FBSDK_DLL
#define FBSDK_DLL
Be sure that FBSDK_DLL is defined only once...
Definition: fbproperties.h:51
kFBLoadedUserProperty
@ kFBLoadedUserProperty
This property is loaded from file.
Definition: fbproperties.h:134
FBPropertyBaseEnum::EnumList
virtual const char * EnumList(int pIndex) override
Return the string of an enum value.
Definition: fbproperties.h:798
FBProperty::IsList
virtual bool IsList()
Verify if property is of this type.
FBPropertyEvent::Add
virtual void Add(HICallback pOwner, kICallbackHandler pHandler)
Add/Remove a callback.
FBPropertyBaseComponent::~FBPropertyBaseComponent
~FBPropertyBaseComponent()
Destructor.
Definition: fbproperties.h:1233
FBPropertyEventConnectionNotify
PropertyEvent: Global ConnectionNotify event.
Definition: fbproperties.h:589
kFBValueAllocated
@ kFBValueAllocated
The value has been allocated and must be delete in destructor.
Definition: fbproperties.h:130
FBPropertyBaseAnimatableEnum::SetString
virtual bool SetString(const char *pString) override
Set string as enum value.
Definition: fbproperties.h:1857
FBPropertyDouble
class K_DLLIMPORT FBPropertyBase< double, kFBPT_double > FBPropertyDouble
Property: double
Definition: fbproperties.h:1340
kDefaultEnum
kDefaultEnum
Patch to use the base enum for casting values .
Definition: fbproperties.h:975
kFBPropertyFlagSlavedProperty
@ kFBPropertyFlagSlavedProperty
Definition: fbproperties.h:125
FBPropertyBasicList::RemoveAt
virtual void RemoveAt(int pIndex)=0
Remove property at pIndex.
kFBPropertyFlagHideProperty
@ kFBPropertyFlagHideProperty
This flag is used to show/hide the property in the propertiview. However, when turn on/off HideProper...
Definition: fbproperties.h:121
FBPropertyBasicList::IsList
virtual bool IsList()
Is this a list?
FBTime
Time data structure.
Definition: fbtime.h:88
FBPropertyAnimatable::SetMemberMuted
void SetMemberMuted(int pIndex, bool pMuted)
SetMemberMuted.
FBPropertyEnum
class K_DLLIMPORT FBPropertyBaseEnum< enum kDefaultEnum > FBPropertyEnum
A typedef Definition.
Definition: fbproperties.h:980
fbtime.h
Time classes.
FBProperty::SetName
void SetName(const char *pName)
Set the property's name.
kFBPT_float
@ kFBPT_float
float.
Definition: fbproperties.h:86
FBPropertyManager::FindPropertiesByName
void FindPropertiesByName(const char *pPropertyNamePattern, FBArrayTemplate< FBProperty * > &pPropList, bool pMultilangLookup=true)
This function will query the property list for properties fulfilling a particular name pattern.
_FBPropertyBaseComponent
class K_DLLIMPORT FBPropertyBase< FBComponent *, kFBPT_object > _FBPropertyBaseComponent
Property: FBPropertyBase(FBComponent*)
Definition: fbproperties.h:1360
FBTimeCode
TimeCode data structure.
Definition: fbtime.h:282
FBPropertyManager::Add
int Add(FBProperty *Property)
Add a property to the property manager.
FBPropertyBasicList::FBPropertyBasicList
FBPropertyBasicList(HIObject pParent, const char *pName)
Constructor.
FBPropertyAnimatable::IsFocusedChild
bool IsFocusedChild(int pIndex)
Get the focus (keyable) state of child component.
FBPropertyColor
class K_DLLIMPORT FBPropertyBase< FBColor, kFBPT_ColorRGB > FBPropertyColor
FBPropertyColor type definition.
Definition: fbproperties.h:1454
FBPropertyString::operator=
void operator=(const char *pValue)
Overloaded = operator.
Definition: fbproperties.h:1289
FBPropertyBaseComponent::FBPropertyBaseComponent
FBPropertyBaseComponent()
Constructor.
Definition: fbproperties.h:1223
FBPropertyAnimatableInt64
class K_DLLIMPORT FBPropertyBaseAnimatable< long long, kFBPT_int64 > FBPropertyAnimatableInt64
FBPropertyAnimatableInt64 type definition.
Definition: fbproperties.h:1740
kFBPT_Reference
@ kFBPT_Reference
reference.
Definition: fbproperties.h:100
FBPropertyStringList::GetCount
int GetCount()
Get the number of items in the list.
FBPropertyBase::IsReadOnly
virtual bool IsReadOnly() override
Is this class read-only? If there is an existing set function, this class is read/write,...
Definition: fbproperties.h:719
FBPropertyManager
Property Manager.
Definition: fbproperties.h:1125
FBPropertyEventUIIdle::Add
virtual void Add(HICallback pOwner, kICallbackHandler pHandler)
Add/Remove a callback.
FBPropertyBaseAnimatableEnum::operator=
void operator=(tType pValue)
Overloaded = operator.
Definition: fbproperties.h:1815
kFBPT_Vector2D
@ kFBPT_Vector2D
vector2d.
Definition: fbproperties.h:103
FBPropertyAnimatableVector3d
class K_DLLIMPORT FBPropertyBaseAnimatable< FBVector3d, kFBPT_Vector3D > FBPropertyAnimatableVector3d
FBPropertyAnimatableVector3D type definition.
Definition: fbproperties.h:1768
FBProperty::HasSomethingLocked
bool HasSomethingLocked() const
HasSomethingLocked.
FBTake
A take is a container for animation in a scene.
Definition: fbdata.h:1692
FBProperty::mParent
void * mParent
Definition: fbproperties.h:202
FBProperty::FBProperty
FBProperty()
Constructor.
kFBPT_Vector3D
@ kFBPT_Vector3D
vector3d.
Definition: fbproperties.h:96
FBPropertyAnimatable::ResetColor
bool ResetColor(int pIndex)
Revert the FCurves to their default color.
kFBPT_ColorRGB
@ kFBPT_ColorRGB
colorrgb.
Definition: fbproperties.h:97
FBPropertyStringList::Sort
void Sort()
Sort list ascending.
FBPropertyBasicList::Init
FBProperty * Init(void *pParent, const char *pName)
Initialization function.
FBCast
T * FBCast(FBProperty *pProperty, bool pAutoCreate=false)
Cast property using it's IObject interface into the proper type.
Definition: fbproperties.h:487
FBPropertyStringList
Property: StringList
Definition: fbproperties.h:989
FBPropertyBaseAnimatableEnum::FBPropertyBaseAnimatableEnum
FBPropertyBaseAnimatableEnum()
Constructor.
Definition: fbproperties.h:1798
FBPropertyEvent::InvalidateParent
virtual void InvalidateParent()
Invalidate parent, removing internal register parent.
FBPropertyAnimatable::SetGlobalCandidate
void SetGlobalCandidate(void *pData, int pSize, FBEvaluateInfo *pEvalInfo=NULL)
Set the global candidate (useful for model TRS).
FBProperty::AsString
virtual const char * AsString(FBDataAsStringFlag pFlag=kFBDataAsStringUI)
Get the property value as a string.
fbGetSetHandler
void(* fbGetSetHandler)(void)
function pointer
Definition: fbproperties.h:167
FBPropertyBaseAnimatable::operator=
void operator=(tType pValue)
Overloaded = operator.
Definition: fbproperties.h:1705
FBPropertyBaseComponent::TypeInfo
int * TypeInfo
< Type information.
Definition: fbproperties.h:1220
FBProperty::GetEnumStringList
FBStringList * GetEnumStringList(bool pCreateIt=false)
String list for enum properties.
FBPropertyAnimatable
Animatable property base class.
Definition: fbproperties.h:1482
FBProperty::IsMemberLocked
bool IsMemberLocked(int pIndex) const
IsMemberLocked.
FBPropertyColorAndAlpha
class K_DLLIMPORT FBPropertyBase< FBColorAndAlpha, kFBPT_ColorRGBA > FBPropertyColorAndAlpha
FBPropertyColorAndAlpha type definition.
Definition: fbproperties.h:1459
kFBPT_Action
@ kFBPT_Action
action.
Definition: fbproperties.h:99
FBProperty::OriIsAnimated
bool OriIsAnimated() const
Get the property original animated flag status (before any modification)
kFBPT_event
@ kFBPT_event
event.
Definition: fbproperties.h:93
FBProperty::SetEnable
void SetEnable(bool pValue)
Set property enable status.
FBProperty::GetData
virtual void GetData(void *pData, int pSize, FBEvaluateInfo *pEvalInfo=NULL) const
Get the value of a property.
FBPropertyTime
class K_DLLIMPORT FBPropertyBase< FBTime, kFBPT_Time > FBPropertyTime
Property: FBTime
Definition: fbproperties.h:1346
FBString
Basic string class.
Definition: fbstring.h:67
FBProperty::IsTemporaryProperty
bool IsTemporaryProperty()
Indicate if a property was created on retrieve because it didn't exist.
FBPropertyAnimatableDouble
class K_DLLIMPORT FBPropertyBaseAnimatable< double, kFBPT_double > FBPropertyAnimatableDouble
FBPropertyBaseAnimatableDouble type definition.
Definition: fbproperties.h:1752
FBPropertyAnimatable::IsAnimated
bool IsAnimated()
Is the property animated.
FBProperty::IsObjectList
bool IsObjectList()
Indicate if is an instance of FBPropertyListObject.
FBProperty::SetString
virtual bool SetString(const char *pString)
Set the property value from a string.
FBPropertyBasicList::RemoveAll
void RemoveAll()
Remove all properties from the list.
kFBPT_TimeCode
@ kFBPT_TimeCode
timecode.
Definition: fbproperties.h:91
FBPropertyAnimatable::AllowsMuting
bool AllowsMuting() const
AllowsMuting.
FBProperty
Property: Base property class.
Definition: fbproperties.h:195
FBPropertyBase::Init
FBPropertyBase * Init(void *pParent, const char *pName, tType(*pGet)(void *)=NULL, void(*pSet)(void *, tType)=NULL)
Initialization function.
Definition: fbproperties.h:654
__FB_FORWARD
#define __FB_FORWARD(ClassName)
Forwarding of class and typedef declaration.
Definition: fbtypes.h:68
FBPropertyBaseList::operator[]
virtual tType operator[](int pIndex)=0
[] operator overload.
FBPropertyBaseList
Definition: fbproperties.h:893
FBPropertyBase::GetData
virtual void GetData(void *pData, int pSize, FBEvaluateInfo *pEvalInfo=NULL) const override
Get value.
Definition: fbproperties.h:724
FBPropertyBase::SetPropertyValue
virtual void SetPropertyValue(tType pValue)
Set the value of the internal property.
Definition: fbproperties.h:693
fbarray.h
A template class for arrays.
FBPropertyEvent::~FBPropertyEvent
virtual ~FBPropertyEvent()
Destructor.
FBPropertyAnimatableTimeCode
class K_DLLIMPORT FBPropertyBaseAnimatable< FBTimeCode, kFBPT_TimeCode > FBPropertyAnimatableTimeCode
FBPropertyBaseAnimatableTimeCode type definition.
Definition: fbproperties.h:1760
FBProperty::SetMax
void SetMax(double pMax, bool pForceMaxClamp=false)
SetMax.
FBPropertyVector3d
class K_DLLIMPORT FBPropertyBase< FBVector3d, kFBPT_Vector3D > FBPropertyVector3d
FBPropertyVector3d type definition.
Definition: fbproperties.h:1469
FBPropertyUInt64
class K_DLLIMPORT FBPropertyBase< unsigned long long, kFBPT_uint64 > FBPropertyUInt64
Property: int
Definition: fbproperties.h:1337
kFBPropertyFlagNotSavable
@ kFBPropertyFlagNotSavable
Should not be saved to or loaded from an FBX file.
Definition: fbproperties.h:127
FBPropertyBaseList::Find
virtual int Find(tType pItem)
Locate a property in the list.
Definition: fbproperties.h:937
FBPropertyEventVideoFrameRendering::Add
virtual void Add(HICallback pOwner, kICallbackHandler pHandler)
Add/Remove a callback.
FBPropertyStringList::IsList
virtual bool IsList() override
Is this class a list?
FBPropertyBase::GetPropertyType
virtual FBPropertyType GetPropertyType() override
Get the property's type.
Definition: fbproperties.h:688
FBPropertyStringList::GetAt
virtual const char * GetAt(int pIndex)
Get the string stored at pIndex.
kFBSlaveSetByMaster
@ kFBSlaveSetByMaster
Definition: fbproperties.h:133
FBProperty::AllowsLocking
bool AllowsLocking() const
AllowsLocking.
FBPropertyAnimatable::GetDataType
virtual KDataType * GetDataType() override
Get the property datatype pointer.
FBPropertyAnimatable::GetBox
FBBox * GetBox()
Get the owner box.
FBVector4d
class K_DLLIMPORT FBVector4< double > FBVector4d
4D vector
Definition: fbtypes.h:441
FBPropertyBaseList::Add
virtual int Add(tType pItem)=0
Add a property to the list.
FBProperty::GetPropertyType
virtual FBPropertyType GetPropertyType()
Get the property's type.
FBPropertyBaseEnum::operator=
void operator=(tType pValue)
Overloaded = operator.
Definition: fbproperties.h:789
FBPropertyAnimatable::SetMuted
void SetMuted(bool pMuted)
SetMuted.
FBProperty::SetInt
bool SetInt(int pInt)
Set the property from an integer.
FBProperty::SetLocked
void SetLocked(bool pLocked)
SetLocked.
FBPropertyVector4d
class K_DLLIMPORT FBPropertyBase< FBVector4d, kFBPT_Vector4D > FBPropertyVector4d
FBPropertyVector4d type definition.
Definition: fbproperties.h:1475
FBPropertyStringList::SetAt
virtual bool SetAt(int pIndex, const char *pString)
Set the string at pIndex.
FBPropertyAction::~FBPropertyAction
~FBPropertyAction()
Destructor.
Definition: fbproperties.h:1320
FBPropertyEventConnectionKeyingNotify::Add
virtual void Add(HICallback pOwner, kICallbackHandler pHandler)
Add/Remove a callback.
FBProperty::GetReferencedProperty
FBProperty * GetReferencedProperty()
Get the referenced property, in the case of this property is a reference property (see the IsReferenc...
FBPropertyStringList::InsertAt
virtual void InsertAt(int pIndex, const char *S, kReference pRef=0)
Insert an entry at pIndex.
FBPropertyReference
class K_DLLIMPORT FBPropertyBase< FBProperty *, kFBPT_Reference > FBPropertyReference
Property: FBProperty *
Definition: fbproperties.h:1358
FBProperty::IsReadOnly
virtual bool IsReadOnly()
Is property read-only?
FBPropertyBase::FBPropertyBase
FBPropertyBase(const FBPropertyBase< tType, pPT > &pValue)
Constructor.
Definition: fbproperties.h:640
FBPropertyStringList::AsString
virtual const char * AsString(FBDataAsStringFlag pFlag=kFBDataAsStringUI) override
Get as string.
FBPropertyStringList::SetString
virtual bool SetString(const char *pString) override
Set string for list.
FBPropertyAnimatableTime
class K_DLLIMPORT FBPropertyBaseAnimatable< FBTime, kFBPT_Time > FBPropertyAnimatableTime
FBPropertyBaseAnimatableTime type definition.
Definition: fbproperties.h:1756
kDefaultItemNone
@ kDefaultItemNone
None.
Definition: fbproperties.h:976
FBPropertyAnimatableInt
class K_DLLIMPORT FBPropertyBaseAnimatable< int, kFBPT_int > FBPropertyAnimatableInt
FBPropertyAnimatableInt type definition.
Definition: fbproperties.h:1736
FBPropertyEvent
PropertyEvent: Base event class.
Definition: fbproperties.h:515
FBPropertyFloat
class K_DLLIMPORT FBPropertyBase< float, kFBPT_float > FBPropertyFloat
Property: float
Definition: fbproperties.h:1343
FBProperty::AsInt
int AsInt()
Get the property as an integer.
FBPropertyAnimatable::KeyRemoveAt
void KeyRemoveAt(FBTime pTime)
Remove the key at time (t).
FBPropertyAnimatable::FBPropertyAnimatable
FBPropertyAnimatable()
Constructor.
FBPropertyEvent::GetPropertyType
virtual FBPropertyType GetPropertyType() override
Get the property's type.
Definition: fbproperties.h:564
FBProperty::GetDataType
virtual KDataType * GetDataType()
Get the property datatype pointer.
FBPropertyStringList::Find
int Find(const char *S)
Find the index of a string.
FBPropertyBool
class K_DLLIMPORT FBPropertyBase< bool, kFBPT_bool > FBPropertyBool
Property: bool
Definition: fbproperties.h:1308
fbstring.h
String class.
FBPropertyStringList::SetReferenceAt
void SetReferenceAt(int pIndex, kReference pRef)
Set reference at pIndex.
kFBDataAsStringUI
@ kFBDataAsStringUI
Convert data to string type for UI display.
Definition: fbproperties.h:111
FBProperty::IsLocked
bool IsLocked() const
IsLocked.
FBPropertyBaseAnimatableEnum::EnumList
virtual const char * EnumList(int pIndex) override
Return the string of an enum value.
Definition: fbproperties.h:1824
FBPropertyAnimatable::GetData
virtual void GetData(void *pData, int pSize, FBEvaluateInfo *pEvalInfo=NULL) const override
Get the value of a property.
kFBDataAsStringPersistence
@ kFBDataAsStringPersistence
Convert data to string type for storage.
Definition: fbproperties.h:112
FBPropertyType
FBPropertyType
Property types.
Definition: fbproperties.h:80
kFBPropertyFlagDrivenProperty
@ kFBPropertyFlagDrivenProperty
This is property is connected and driven by other same type of main property, and it always ask value...
Definition: fbproperties.h:124
fbExternalGetSetHandler
void(* fbExternalGetSetHandler)(HIObject pObject)
function pointer
Definition: fbproperties.h:169
FBPropertyBase::~FBPropertyBase
~FBPropertyBase()
Destructor.
Definition: fbproperties.h:643
FBPropertyBaseEnum::~FBPropertyBaseEnum
~FBPropertyBaseEnum()=default
Destructor.
FBProperty::IsMaxClamp
bool IsMaxClamp()
Indicate if maximum value clamping will be applied on user input value.
kFBPT_int64
@ kFBPT_int64
int 64 bits.
Definition: fbproperties.h:83
FBPropertyBasicList::FBPropertyBasicList
FBPropertyBasicList()
Constructor.
FBPropertyEventVideoFrameRendering
PropertyEvent: Video Frame Rendering Event
Definition: fbproperties.h:581
FBPropertyAnimatable::SetCandidate
void SetCandidate(void *pData, int pSize, FBEvaluateInfo *pEvalInfo=NULL)
Set the candidate.
FBArrayTemplate
Template class to contain an array of items.
Definition: fbarray.h:78
FBPropertyAnimatable::GetDataTypeName
const char * GetDataTypeName()
Get the property datatype name.
fbplug.h
Definition of the class FBPlug and related enums and utility functions.
kFBPT_int
@ kFBPT_int
int.
Definition: fbproperties.h:82
FBPropertyBaseAnimatableEnum::~FBPropertyBaseAnimatableEnum
~FBPropertyBaseAnimatableEnum()
Destructor.
Definition: fbproperties.h:1801
_FBPropertyBasePlug
class K_DLLIMPORT FBPropertyBase< FBPlug *, kFBPT_object > _FBPropertyBasePlug
Property: FBPropertyBase(FBPlug*)
Definition: fbproperties.h:1364
FB_FORWARD
#define FB_FORWARD(ClassName)
Forwarding of class and typedef declaration.
Definition: fbtypes.h:62
FBPropertyEvent::FBPropertyEvent
FBPropertyEvent()
Constructor.
FBColor
Color vector.
Definition: fbtypes.h:448
FBPropertyBaseEnum::AsString
virtual const char * AsString(FBDataAsStringFlag pFlag=kFBDataAsStringUI) override
Get as string.
Definition: fbproperties.h:825
FBPropertyBaseComponent::operator=
void operator=(tType pValue)
Overloaded = operator.
Definition: fbproperties.h:1241
FBPropertyAnimatable::SetAnimated
void SetAnimated(bool pState, bool pCheckLocked=false)
Set the animation state of the property.
FBPropertyAnimatable::Init
FBPropertyAnimatable * Init(FBBox *pOwner, const char *pName, const char *pType, double *pInit)
Initialization function (custom).
kFBPT_bool
@ kFBPT_bool
bool.
Definition: fbproperties.h:85
FBPropertyStringList::Find
int Find(kReference pRef)
Find the index of a reference.
FBPropertyBaseList::GetAt
virtual tType GetAt(int pIndex)
Get a property at pIndex.
Definition: fbproperties.h:968
FBPropertyAnimatable::IsAnimatable
virtual bool IsAnimatable() override
Certify that the property is animatable.
Definition: fbproperties.h:1554
FBPropertyEventConnectionDataNotify
PropertyEvent: Global ConnectionDataNotify event.
Definition: fbproperties.h:597
FBProperty::GetPropertyFlags
FBPropertyFlag GetPropertyFlags()
GetPropertyFlags.
kFBDynamicHidden
@ kFBDynamicHidden
This flag is used to show/hide the property in the propertiview. When turn on/ff DynamicHidden flag,...
Definition: fbproperties.h:131
kFBDrivenSetByMain
@ kFBDrivenSetByMain
Driven property can be modified, valid only when the main property is modified.
Definition: fbproperties.h:132
FBPropertyBaseComponent
Definition: fbproperties.h:1217
kFBPT_Time
@ kFBPT_Time
time.
Definition: fbproperties.h:90
FBPropertyStringList::GetReferenceAt
kReference GetReferenceAt(int pIndex)
Get the reference at pIndex.
FBColorAndAlpha
Color and alpha vector.
Definition: fbtypes.h:490
FBProperty::SetMin
void SetMin(double pMin, bool pForceMinClamp=false)
SetMin.
FBPropertyString::SetPropertyValue
virtual void SetPropertyValue(const char *pValue) override
Set the value of the internal property.
FBProperty::GetMax
double GetMax()
GetMax.
FBPropertyBaseList::FBPropertyBaseList
FBPropertyBaseList()
Constructor.
Definition: fbproperties.h:896
FBPropertyAnimatable::HasSomethingMuted
bool HasSomethingMuted() const
HasSomethingMuted.
FBPropertyBaseList::FBPropertyBaseList
FBPropertyBaseList(HIObject pParent, const char *pName)
Constructor.
Definition: fbproperties.h:907
FBPlug
Connections Basic Open Reality SDK Element.
Definition: fbplug.h:222
FBProperty::OriValueAsString
const char * OriValueAsString()
Get the property original value (before any modification) as string.
kFBPT_ColorRGBA
@ kFBPT_ColorRGBA
colorrgba.
Definition: fbproperties.h:98
FBPropertyTimeSpan
class K_DLLIMPORT FBPropertyBase< FBTimeSpan, kFBPT_TimeSpan > FBPropertyTimeSpan
Property: FBTimeSpan
Definition: fbproperties.h:1352
FBPropertyBaseAnimatableEnum::AsString
virtual const char * AsString(FBDataAsStringFlag pFlag=kFBDataAsStringUI) override
Get as string.
Definition: fbproperties.h:1851
kFBPT_stringlist
@ kFBPT_stringlist
stringlist.
Definition: fbproperties.h:94
FBPropertyInt64
class K_DLLIMPORT FBPropertyBase< long long, kFBPT_int64 > FBPropertyInt64
Property: int
Definition: fbproperties.h:1334
FBPropertyAnimatableColorAndAlpha
class K_DLLIMPORT FBPropertyBaseAnimatable< FBColorAndAlpha, kFBPT_ColorRGBA > FBPropertyAnimatableColorAndAlpha
FBPropertyAnimatableColorAndAlpha type definition.
Definition: fbproperties.h:1780
FBPropertyAnimatableEnum
class K_DLLIMPORT FBPropertyBaseAnimatable< int, kFBPT_enum > FBPropertyAnimatableEnum
FBPropertyBaseAnimatableEnum type definition.
Definition: fbproperties.h:1748
FBEvaluateInfo
AnimationNodeNotify evaluation information.
Definition: fbevaluateinfo.h:79
FBPropertyAnimatableUInt64
class K_DLLIMPORT FBPropertyBaseAnimatable< unsigned long long, kFBPT_uint64 > FBPropertyAnimatableUInt64
FBPropertyAnimatableUInt64 type definition.
Definition: fbproperties.h:1744
FBPropertyBaseAnimatable::~FBPropertyBaseAnimatable
~FBPropertyBaseAnimatable()
Destructor.
Definition: fbproperties.h:1699
FBPropertyString
Property class: const char * (String).
Definition: fbproperties.h:1281
FBPropertyEventConnectionDataNotify::Add
virtual void Add(HICallback pOwner, kICallbackHandler pHandler)
Add/Remove a callback.
FBPropertyBaseEnum::FBPropertyBaseEnum
FBPropertyBaseEnum(const FBPropertyBaseEnum< tType > &pValue)
FBPropertyBaseEnum.
Definition: fbproperties.h:780
FBPropertyEventUIIdle
PropertyEvent: UI idle event.
Definition: fbproperties.h:573
FBPropertyBase::GetPropertyValue
tType GetPropertyValue()
Get the value of the internal property.
Definition: fbproperties.h:704
FBProperty::GetSubMemberCount
int GetSubMemberCount() const
GetSubMemberCount.
FBPropertyAnimatable::Key
void Key()
Key the property.
FBPropertyAnimatableBool
class K_DLLIMPORT FBPropertyBaseAnimatable< bool, kFBPT_bool > FBPropertyAnimatableBool
FBPropertyAnimatableBool type definition.
Definition: fbproperties.h:1732
FBComponent
MotionBuilder SDK base class.
Definition: fbcomponent.h:651
FBPropertyEventConnectionNotify::Add
virtual void Add(HICallback pOwner, kICallbackHandler pHandler)
Add/Remove a callback.
FBPropertyBaseList::Remove
virtual int Remove(tType pItem)
Remove pItem from the list.
Definition: fbproperties.h:954
FBPropertyBaseAnimatableEnum
Definition: fbproperties.h:1790
FBProperty::AcceptTemporaryProperty
bool AcceptTemporaryProperty(const char *pEnumList[]=NULL, fbExternalGetSetHandler pGet=NULL, fbExternalGetSetHandler pSet=NULL)
Accept a temporary property as a dynamic property.
FBVisualComponent
Visual Component base class.
Definition: fbcontrols.h:312
FBPropertyPlug
class FBPropertyBaseComponent< FBPlug * > FBPropertyPlug
Property: FBPropertyBaseComponent(FBPlug*)
Definition: fbproperties.h:1366
FBPropertyStringList::Add
virtual int Add(const char *S, kReference pRef=0)
Add a string to the list.
FBPropertyBase::FBPropertyBase
FBPropertyBase()
Constructor.
Definition: fbproperties.h:635
FBPropertyAnimatable::GetDataSize
int GetDataSize() const
Get the data size (number of values) for the connector.
FBPropertyEvent::InitGlobal
FBPropertyEvent * InitGlobal(const char *pName, const char *pGlobalEventName)
Property initialization function, for global events.
FBPropertyAnimatable::SetData
virtual void SetData(void *pData) override
Set the value of the property, passing the type as an argument.
FBProperty::ModifyPropertyFlag
void ModifyPropertyFlag(FBPropertyFlag pFlag, bool pValue)
ModifyPropertyFlag.
FBPropertyStringList::~FBPropertyStringList
virtual ~FBPropertyStringList()
Destructor.
FBPropertyStringList::Clear
virtual void Clear()
Clear the list (remove all the items).
FBPropertyAnimatable::Destroy
void Destroy()
Destruction function, for internal connectors.
FBPropertyBaseAnimatable
Definition: fbproperties.h:1685
FBProperty::EnumList
virtual const char * EnumList(int pIndex)
Return the string of an enum value.
FBPropertyBaseEnum
Definition: fbproperties.h:765
FBVector3d
class K_DLLIMPORT FBVector3< double > FBVector3d
3D vector.
Definition: fbtypes.h:438
FBPropertyAnimatable::~FBPropertyAnimatable
virtual ~FBPropertyAnimatable()
Destructor.
FBPropertyManager::~FBPropertyManager
~FBPropertyManager()
Destructor.
FBPropertyBaseEnum::SetString
virtual bool SetString(const char *pString) override
Set enum value by equivalent string.
Definition: fbproperties.h:831
FBPropertyBase::operator=
void operator=(tType pValue)
Overloaded = operator.
Definition: fbproperties.h:668
FBPropertyAnimatable::IsMemberMuted
bool IsMemberMuted(int pIndex) const
IsMemberMuted.
FBPropertyAction
Property: Action Action property to trigger function.
Definition: fbproperties.h:1314
FBPropertyAnimatable::IsFocused
bool IsFocused()
Is the property focused (keyable).
FBPropertyEvent::Init
FBPropertyEvent * Init(FBComponent *pComponent, HIRegister pParent, const char *pName, int pType, int pSubType=K_INT_MAX)
Property initialization function.
kFBPT_TimeSpan
@ kFBPT_TimeSpan
timespan.
Definition: fbproperties.h:101
kFBPT_kReference
@ kFBPT_kReference
kReference.
Definition: fbproperties.h:102
FBPropertyBasicList
Definition: fbproperties.h:852
FBPropertyBase::SetData
virtual void SetData(void *pData) override
Set value.
Definition: fbproperties.h:743