fbcore.h

Go to the documentation of this file.
00001 #ifndef __FBCORE_H__
00002 #define __FBCORE_H__
00003 /**************************************************************************
00004  Copyright (c) 1994 - 2009 Autodesk, Inc. and/or its licensors.
00005  All Rights Reserved.
00006  
00007  The coded instructions, statements, computer programs, and/or related 
00008  material (collectively the "Data") in these files contain unpublished 
00009  information proprietary to Autodesk, Inc. and/or its licensors, which is 
00010  protected by Canada and United States of America federal copyright law 
00011  and by international treaties.
00012  
00013  The Data may not be disclosed or distributed to third parties, in whole 
00014  or in part, without the prior written consent of Autodesk, Inc. 
00015  ("Autodesk").
00016  
00017  THE DATA IS PROVIDED "AS IS" AND WITHOUT WARRANTY.
00018  ALL WARRANTIES ARE EXPRESSLY EXCLUDED AND DISCLAIMED. AUTODESK MAKES NO 
00019  WARRANTY OF ANY KIND WITH RESPECT TO THE DATA, EXPRESS, IMPLIED OR 
00020  ARISING BY CUSTOM OR TRADE USAGE, AND DISCLAIMS ANY IMPLIED WARRANTIES 
00021  OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR 
00022  PURPOSE OR USE. WITHOUT LIMITING THE FOREGOING, AUTODESK DOES NOT 
00023  WARRANT THAT THE OPERATION OF THE DATA WILL BE UNINTERRUPTED OR ERROR 
00024  FREE.
00025  
00026  IN NO EVENT SHALL AUTODESK, ITS AFFILIATES, PARENT COMPANIES, LICENSORS 
00027  OR SUPPLIERS ("AUTODESK GROUP") BE LIABLE FOR ANY LOSSES, DAMAGES OR 
00028  EXPENSES OF ANY KIND (INCLUDING WITHOUT LIMITATION PUNITIVE OR MULTIPLE 
00029  DAMAGES OR OTHER SPECIAL, DIRECT, INDIRECT, EXEMPLARY, INCIDENTAL, LOSS 
00030  OF PROFITS, REVENUE OR DATA, COST OF COVER OR CONSEQUENTIAL LOSSES OR 
00031  DAMAGES OF ANY KIND), HOWEVER CAUSED, AND REGARDLESS OF THE THEORY OF 
00032  LIABILITY, WHETHER DERIVED FROM CONTRACT, TORT (INCLUDING, BUT NOT 
00033  LIMITED TO, NEGLIGENCE), OR OTHERWISE, ARISING OUT OF OR RELATING TO THE 
00034  DATA OR ITS USE OR ANY OTHER PERFORMANCE, WHETHER OR NOT AUTODESK HAS 
00035  BEEN ADVISED OF THE POSSIBILITY OF SUCH LOSS OR DAMAGE.
00036  
00037 **************************************************************************/
00038 
00043 #include <kaydaradef.h>
00044 #ifndef FBSDK_DLL 
00045 
00048     #define FBSDK_DLL K_DLLIMPORT
00049 #endif
00050 
00051 #include <fbsdk/fbcomponent.h>
00052 #include <fbsdk/fbfbx.h>
00053 #include <fbsdk/fbtime.h>
00054 #include <fbsdk/fbdata.h>
00055 #include <fbsdk/fbevaluateinfo.h>
00056 
00057 
00058 // somebody at SGI defined this in their include files
00059 // until we find which one, we remove it
00060 #undef Status
00061 
00062 #ifdef FBSDKUseNamespace
00063     namespace FBSDKNamespace {
00064 #endif
00065 
00066 FB_DEFINE_COMPONENT( FBSDK_DLL, ModelTemplate   );
00067 FB_DEFINE_COMPONENT( FBSDK_DLL, Device          );
00068 FB_DEFINE_COMPONENT( FBSDK_DLL, Path3D          );
00069 FB_DEFINE_COMPONENT( FBSDK_DLL, Scene           );
00070 FB_DEFINE_COMPONENT( FBSDK_DLL, Model           );
00071 FB_DEFINE_COMPONENT( FBSDK_DLL, Device          );
00072 
00073 // ========================================================================================== 
00074 // Global definition
00075 // ==========================================================================================
00081 typedef HIObject (* kFBObjectCreatorFnc)(HIObject pOwner,char * pName,void *pData);
00082 
00083 // ==========================================================================================
00084 // Declaration definition
00085 // ==========================================================================================
00090 #define FBBoxDeclare( ClassName, Parent ) \
00091     FBClassDeclare( ClassName,Parent ); \
00092   public: \
00093   ClassName(char * pName):Parent(pName) { FBClassInit; } \
00094   private:
00095 
00099 #define FBBoxImplementation( ThisComponent ) \
00100     FBClassImplementation( ThisComponent )
00101 
00106 #define FBDeviceDeclare( ClassName, Parent ) \
00107     FBClassDeclare( ClassName,Parent ); \
00108   public: \
00109     ClassName(char * pName):Parent(pName) { FBClassInit; } \
00110   private:
00111 
00115 #define FBDeviceImplementation( ThisComponent ) \
00116     FBClassImplementation( ThisComponent )
00117 
00118 // ==========================================================================================
00119 // Register definition
00120 // ==========================================================================================
00129 #define FBRegisterBox( UniqueNameStr, ClassName, FolderName, Label, Description, IconFilename ) \
00130     HIObject RegisterBox##ClassName##Create( HIObject /*pOwner*/,char * pName,void * /*pData*/) \
00131     { \
00132       ClassName *Class = new ClassName(pName); \
00133         Class->mAllocated = true; \
00134         Class->UniqueName = UniqueNameStr; \
00135         if (Class->FBCreate()) { \
00136             return Class->GetHIObject(); \
00137         } else { \
00138             delete Class; \
00139             return NULL; \
00140         } \
00141     } \
00142 \
00143     FBLibraryModule( ClassName )    \
00144     {\
00145         FBRegisterObject(ClassName##R1,"Boxes",UniqueNameStr,Description,RegisterBox##ClassName##Create,true, IconFilename );\
00146         FBRegisterObject(ClassName##R2,"Boxes/Functions/"FolderName,Label,Description,RegisterBox##ClassName##Create,true, IconFilename );\
00147         FBRegisterObject(ClassName##R3,"FbxStorable/Box",UniqueNameStr,Description,RegisterBox##ClassName##Create,true, IconFilename ); \
00148     }
00149 
00157 #define FBRegisterDevice( UniqueNameStr, ClassName, Label, Description, IconFilename ) \
00158     HIObject RegisterDevice##ClassName##Create( HIObject /*pOwner*/,char * pName,void * /*pData*/) \
00159     { \
00160       ClassName *Class = new ClassName(pName); \
00161         Class->mAllocated = true; \
00162         Class->UniqueName = UniqueNameStr; \
00163         if (Class->FBCreate()) { \
00164             return Class->GetHIObject(); \
00165         } else { \
00166             delete Class; \
00167             return NULL; \
00168         } \
00169     } \
00170 \
00171     FBLibraryModule( ClassName )    \
00172     {   \
00173         FBRegisterObject(ClassName##R1,"Boxes/Devices",Label,Description,RegisterDevice##ClassName##Create,true, IconFilename );\
00174         FBRegisterObject(ClassName##R2,"FbxStorable/Device",UniqueNameStr,Description,RegisterDevice##ClassName##Create,true, IconFilename ); \
00175     }
00176 
00184 #define FBRegisterOnlineDevice( UniqueNameStr, ClassName, Label, Description, IconFilename ) \
00185     HIObject RegisterDevice##ClassName##Create( HIObject /*pOwner*/,char * pName,void * /*pData*/) \
00186     { \
00187       ClassName *Class = new ClassName(pName); \
00188         Class->mAllocated = true; \
00189         Class->UniqueName = UniqueNameStr; \
00190         if (Class->FBCreate()) { \
00191             return Class->GetHIObject(); \
00192         } else { \
00193             delete Class; \
00194             return NULL; \
00195         } \
00196     } \
00197 \
00198     FBLibraryModule( ClassName )    \
00199     {   \
00200         if( FBGetLicense() >= kFBLicenseOnline )    \
00201         {   \
00202             FBRegisterObject(ClassName##R1,"Boxes/Devices",Label,Description,RegisterDevice##ClassName##Create, true, IconFilename );\
00203             FBRegisterObject(ClassName##R2,"FbxStorable/Device",UniqueNameStr,Description,RegisterDevice##ClassName##Create, true, IconFilename ); \
00204         }   \
00205     }
00206 
00207 
00209 // FBBox
00211 __FB_FORWARD( FBBox );
00212 FB_FORWARD( FBFbxObject );
00213 
00219 class FBSDK_DLL FBBox : public FBComponent {
00220     __FBClassDeclare( FBBox,FBComponent );
00221 public:
00226     FBBox(char *pName, HIObject pObject=NULL);
00227 
00229 
00239     virtual HFBAnimationNode AnimationNodeInCreate  (kReference pUserId,char * pName ,char * pDataType,bool pIsPublic=false,double *pMin=NULL,double *pMax=NULL,bool pUserData=false);
00240     virtual HFBAnimationNode AnimationNodeOutCreate (kReference pUserId,char * pName ,char * pDataType,bool pIsPublic=false,double *pMin=NULL,double *pMax=NULL,bool pUserData=false);
00242 
00248     virtual bool EvaluateAnimationNodes( HFBEvaluateInfo pEvaluateInfo );
00249 
00256     virtual bool AnimationNodeNotify( HFBAnimationNode pAnimationNode, HFBEvaluateInfo pEvaluateInfo );
00257 
00259 
00264     virtual bool FbxStore(  HFBFbxObject pFbxObject, kFbxObjectStore pStoreWhat );
00265     virtual bool FbxRetrieve(HFBFbxObject pFbxObject, kFbxObjectStore pStoreWhat );
00267 
00272     virtual bool AnimationNodeDestroy( HFBAnimationNode pAnimationNode );
00273 
00278     virtual bool AnimationNodeIsUserData( HFBAnimationNode pAnimationNode );
00279 
00281 
00284     virtual HFBAnimationNode AnimationNodeInGet();
00285     virtual HFBAnimationNode AnimationNodeOutGet();
00287 
00288     char* UniqueName;                   
00289     virtual char* FbxGetObjectSubType();
00290     virtual char* FbxGetObjectType();   
00291 
00292     IObject_Declare(Implementation);    // Interface to IObject.
00293 
00294     FBPropertyBool Animatable;          
00295     FBPropertyBool Live;                
00296     FBPropertyBool RecordMode;          
00297 };
00298 
00299 
00300 #ifndef FB_KERNEL 
00301 
00303 // FBHandle
00305 __FB_FORWARD( FBHandle );
00306 
00311 class FBSDK_DLL FBHandle : public FBBox {
00312     __FBClassDeclare( FBHandle, FBBox );
00313 
00314 public:
00320     FBHandle( char* pName, HIObject pObject = NULL );
00321 
00326     void Select();
00327 
00328     FBPropertyListObject Follow;                
00329     FBPropertyListObject Manipulate;            
00330     FBPropertyListObject ManipulateTranslation; 
00331     FBPropertyListObject ManipulateRotation;    
00332     FBPropertyListObject ManipulateScaling;     
00333     FBPropertyListObject Image;                 
00334 
00335 private:
00337 
00341     FBHandle( const FBHandle& );
00342     FBHandle& operator=( const FBHandle& );
00344 };
00345 
00346 
00348 // FBPropertyListHandle
00350 FB_DEFINE_LIST( FBSDK_DLL, Handle );
00351 FB_FORWARD( FBPropertyListHandle );
00352 
00354 class FBSDK_DLL FBPropertyListHandle : public FBPropertyListComponent
00355 {
00356 public:
00357     FBPropertyListHandle();
00362     FBHandle* operator[](int pIndex);
00363 };
00364 
00365 #endif
00366 
00368 // FBPropertyListModelTemplate
00370 __FB_FORWARD    ( FBModelTemplate   );
00371 __FB_FORWARD    ( FBPropertyListModelTemplate   );
00372 FB_DEFINE_LIST  ( FBSDK_DLL, ModelTemplate      );
00373 
00375 class FBSDK_DLL FBPropertyListModelTemplate : public FBPropertyListComponentBase
00376 {
00377 public:
00382     int  Add    ( HFBModelTemplate pItem );
00386     virtual void RemoveAt( int pIndex );
00391     FBModelTemplate* operator[](int pIndex);
00395     virtual int GetCount();
00396 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00397     inline virtual FBComponent* GetAt(int pIndex) { return (FBComponent*)operator[](pIndex); }
00398 private:
00399     inline virtual int Add  ( FBComponent* pItem ) { return Add((FBModelTemplate*)pItem); }
00400 #endif
00401 };
00402 
00404 // FBPropertyListModelTemplateBinding
00406 __FB_FORWARD( FBModelTemplateBinding );
00407 __FB_FORWARD( FBPropertyListModelTemplateBinding );
00409 typedef class FBSDK_DLL FBPropertyBaseList< HFBAnimationNode > FBPropertyBaseListModelTemplateBinding;
00410 
00412 class FBSDK_DLL FBPropertyListModelTemplateBinding : public FBPropertyListComponentBase
00413 {
00414 public:
00419     virtual int Add( HFBAnimationNode pItem );
00420     
00424     virtual void RemoveAt( int pIndex );
00429     FBAnimationNode* operator[](int pIndex);
00430 
00434     virtual int  GetCount();
00435 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00436     inline virtual FBComponent* GetAt(int pIndex) { return (FBComponent*)operator[](pIndex); }
00437 private:
00438     inline virtual int Add  ( FBComponent* pItem ) { return Add((FBAnimationNode*)pItem); }
00439 #endif
00440 };
00441 
00443 // FBModelTemplate
00445 __FB_FORWARD( FBModelTemplate);
00446 
00452 enum FBModelTemplateStyle { 
00453     kFBModelTemplateNone,               
00454     kFBModelTemplateNull,               
00455     kFBModelTemplateMarker,             
00456     kFBModelTemplateRoot,               
00457     kFBModelTemplateSensor,             
00458     kFBModelTemplateSkeleton,           
00459     kFBModelTemplateCamera,             
00460     kFBModelTemplateGeometry,           
00461     kFBModelTemplateCameraInterest,     
00462     kFBModelTemplateLight,              
00463     kFBModelTemplateOptical             
00464  };
00465 
00472 class FBSDK_DLL FBModelTemplate : public FBComponent {
00473     __FBClassDeclare( FBModelTemplate,FBComponent );
00474 
00477     void Init();
00478 public:
00483     FBModelTemplate(HIObject pObject=NULL);
00484 
00490     FBModelTemplate(char *pPrefix,char *pName, FBModelTemplateStyle pStyle);
00491 
00492     FBPropertyListModelTemplate         Children;               
00493     FBPropertyListModelTemplateBinding  Bindings;               
00494 
00495     FBPropertyString                    Prefix;                 
00496     FBPropertyModel                     Model;                  
00497     FBPropertyVector3d                  DefaultTranslation;     
00498     FBPropertyVector3d                  DefaultRotation;        
00499     FBPropertyVector3d                  DefaultScaling;         
00500 
00501     friend class FBDevice;
00502 };
00503 
00505 // FBPropertyListDevice
00507 __FB_FORWARD    ( FBDevice );
00508 __FB_FORWARD    ( FBPropertyListDevice );
00509 
00511 class FBSDK_DLL FBPropertyListDevice : public FBPropertyListComponent
00512 {
00513 public:
00514     FBPropertyListDevice();
00519     FBDevice* operator[](int pIndex);
00520 };
00521 
00523 // FBDeviceNotifyInfo
00525 FB_FORWARD( FBDeviceNotifyInfo );
00526 
00533 class FBSDK_DLL FBDeviceNotifyInfo 
00534 {
00535 public:
00539     FBTime &GetSystemTime();
00540 
00544     FBTime &GetLocalTime();
00545 
00551     void SetLocalTime( const FBTime & ); 
00552     
00556     int GetSyncCount();
00557 
00561     FBEvaluateInfo& GetEvaluateInfo();
00562 };
00563 
00565 // FBDeviceInstrument
00567 __FB_FORWARD( FBDeviceInstrument );
00570 class FBSDK_DLL FBDeviceInstrument : public FBComponent
00571 {
00572     __FBClassDeclare( FBDeviceInstrument, FBComponent );
00573   public:
00577     FBDeviceInstrument(HFBDevice pDevice);
00584     virtual bool InstrumentWriteData( HFBEvaluateInfo pEvaluateInfo );
00589     virtual void InstrumentRecordFrame( FBTime pRecordTime, FBDeviceNotifyInfo& pNotifyInfo );
00591 
00596     virtual bool FbxStore( HFBFbxObject pFbxObject, kFbxObjectStore pStoreWhat );
00597     virtual bool FbxRetrieve( HFBFbxObject pFbxObject, kFbxObjectStore pStoreWhat );
00599 
00600     FBPropertyDevice            Device;         
00601     FBPropertyBool              Active;         
00602     FBPropertyModelTemplate     ModelTemplate;  
00603 };
00604 FB_DEFINE_COMPONENT( FBSDK_DLL, DeviceInstrument );
00605 
00607 // FBPropertyListDeviceInstrument
00609 __FB_FORWARD( FBPropertyListDeviceInstrument );
00610 FB_DEFINE_LIST( FBSDK_DLL, DeviceInstrument );
00613 class FBSDK_DLL FBPropertyListDeviceInstrument : public FBPropertyListComponentBase
00614 {
00615   public:
00620     virtual int  Add    ( HFBDeviceInstrument pItem );
00624     virtual void RemoveAt( int pIndex );
00629     FBDeviceInstrument* operator[](int pIndex);
00633     virtual int GetCount();
00634 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00635     inline virtual FBComponent* GetAt(int pIndex) { return (FBComponent*)operator[](pIndex); }
00636 private:
00637     inline virtual int Add  ( FBComponent* pItem ) { return Add((FBDeviceInstrument*)pItem); }
00638 #endif
00639 };
00640 
00642 // FBDevice
00644 
00654 enum FBDeviceSamplingMode   { 
00655     kFBHardwareTimestamp,       
00656     kFBHardwareFrequency,       
00657     kFBAutoFrequency,           
00658     kFBSoftwareTimestamp        
00659 };
00660 FB_DEFINE_ENUM( FBSDK_DLL, DeviceSamplingMode );
00661 
00666 enum FBCommType {
00667     kFBCommTypeNone         = 0,        
00668     kFBCommTypeSerial       = 1<<0,     
00669     kFBCommTypeNetworkTCP   = 1<<1,     
00670     kFBCommTypeNetworkUDP   = 1<<2,     
00671     kFBCommTypeSharedMemory = 1<<3,     
00672     kFBCommTypeSimulator    = 1<<4,     
00673     kFBCommTypeOther        = 1<<5      
00674 };
00675 
00676 __FB_FORWARD( FBDevice );
00677 
00679 class FBSDK_DLL FBDevice : public FBBox {
00680     __FBClassDeclare( FBDevice,FBBox );
00681 public:
00685     enum kDeviceOperations { 
00686         kOpInit,            
00687         kOpStart,           
00688         kOpAutoDetect,      
00689         kOpStop,            
00690         kOpReset,           
00691         kOpDone             
00692     };
00693 
00697     enum kDeviceIOs { 
00698         kIOStopModeRead,    
00699         kIOPlayModeRead,    
00700         kIOStopModeWrite,   
00701         kIOPlayModeWrite    
00702     };
00703 
00707     enum kTransportMode    {        
00708         kPreparePlay,       
00709         kPlayReady,         
00710         kPlayStop,          
00711         kStop,              
00712         kPlay,              
00713         kJog                
00714     };
00715 
00720     FBDevice(char * pName,HIObject pObject=NULL);
00721 
00722     // See FBBox class
00723     virtual bool FBCreate   ();
00724     virtual void FBDestroy  ();
00725 
00726     // See FBBox class
00727     virtual HFBAnimationNode AnimationNodeInCreate (kReference pUserId,char * pName ,char * pDataType,bool pIsPublic=true,double *pMin=NULL,double *pMax=NULL,bool pUserData=false);
00728     virtual HFBAnimationNode AnimationNodeOutCreate(kReference pUserId,char * pName ,char * pDataType,bool pIsPublic=true,double *pMin=NULL,double *pMax=NULL,bool pUserData=false);
00729 
00735     virtual bool DeviceOperation( kDeviceOperations pOperation );
00736 
00743     virtual void DeviceTransportNotify( kTransportMode pMode, FBTime pTime, FBTime pSystem );
00744 
00751     virtual void DeviceIONotify( kDeviceIOs  pAction, FBDeviceNotifyInfo& pDeviceNotifyInfo );
00752 
00758     virtual bool DeviceEvaluationNotify( kTransportMode pMode,HFBEvaluateInfo pEvaluateInfo );
00759 
00766     virtual bool ModelTemplateBindNotify( HFBModel pModel,int pIndex, HFBModelTemplate pModelTemplate );
00767 
00773     virtual bool ModelTemplateUnBindNotify( int pIndex, HFBModelTemplate pModelTemplate );
00774 
00781     virtual bool AnimationNodeNotify( HFBAnimationNode pAnimationNode, HFBEvaluateInfo pEvaluateInfo ) override;
00782 
00783     virtual char* FbxGetObjectType() override;  
00784 
00786 
00791     virtual bool FbxStore   ( HFBFbxObject pFbxObject, kFbxObjectStore pStoreWhat ) override;
00792     virtual bool FbxRetrieve( HFBFbxObject pFbxObject, kFbxObjectStore pStoreWhat ) override;
00794 
00799     virtual void DeviceSendCommand( kDeviceOperations pOperation );
00800 
00801     IObject_Declare( Implementation );              // Interface to IObject
00802 
00803     FBPropertyString                IconFilename;           
00804     FBPropertyString                Status;                 
00805     FBPropertyString                Information;            
00806     FBPropertyString                HardwareVersionInfo;    
00807     FBPropertyTime                  SamplingPeriod;         
00808     FBPropertyBool                  Online;                 
00809                                     
00810     FBPropertyEvent                 OnStatusChange;         
00811                                     
00812     FBModelTemplate                 ModelTemplate;          
00813 
00814     FBPropertyDeviceSamplingMode    SamplingMode;           
00815     FBPropertyInt                   CommType;               
00816                                     
00817     FBPropertyListDeviceInstrument  Instruments;    
00818 
00819     FBPropertyTime                  RecordingStartTime;     
00820     FBPropertyTime                  RecordingStopTime;      
00821 
00823     void AckOneSampleReceived();
00824 
00826     void AckOneBadSampleReceived();
00827 
00829     void AckOneSampleSent();
00830 
00834     virtual void RecordingInitAnimation(HFBAnimationNode pAnimationNode);
00835 
00839     virtual void RecordingDoneAnimation(HFBAnimationNode pAnimationNode);
00840 
00841     friend class __FBDevice;
00842     friend class DataFBDeviceOptical;
00843 };
00844 
00845 #ifndef FBSDK_LEAN_AND_MEAN
00846 
00847 __FB_FORWARD( FBDeviceGlove );
00848 
00850 class FBSDK_DLL FBDeviceGlove : public FBDevice {
00851     __FBClassDeclare( FBDeviceGlove, FBDevice );
00852 public:
00855     enum kHandModelPart {   // Parents :
00856         
00857         kPartRoot,          // No parent
00858         kPartPalm,          // kPartRoot
00859 
00860         // Thumb
00861         kPartThumbA,        // kPartPalm
00862         kPartThumbB,        // kPartThumbA
00863         kPartThumbC,        // kPartThumbB
00864         kPartThumbD,        // kPartThumbC
00865 
00866         // Index
00867         kPartIndexA,        // kPartPalm
00868         kPartIndexB,        // kPartIndexA
00869         kPartIndexC,        // kPartIndexB
00870         kPartIndexD,        // kPartIndexC
00871 
00872         // Middle
00873         kPartMiddleA,       // kPartPalm
00874         kPartMiddleB,       // kPartMiddleA
00875         kPartMiddleC,       // kPartMiddleB
00876         kPartMiddleD,       // kPartMiddleC
00877 
00878         // Ring
00879         kPartRingA,         // kPartPalm
00880         kPartRingB,         // kPartRingA
00881         kPartRingC,         // kPartRingB
00882         kPartRingD,         // kPartRingC
00883 
00884         // Little
00885         kPartLittleA,       // kPartPalm
00886         kPartLittleB,       // kPartLittleA
00887         kPartLittleC,       // kPartLittleB
00888         kPartLittleD,       // kPartLittleC
00889 
00890         kPartMax
00891     };
00892 
00896     class FBSDK_DLL GloveChannel
00897     {   
00898     public:
00902         GloveChannel( HFBAnimationNode pAnimNode );
00903         
00906         virtual ~GloveChannel();
00907     
00911         FBString        GetName ();
00912 
00916         void            SetName ( FBString pName );
00917     
00918     protected:
00919         FBString                Name;              
00920     
00921     public:
00922         bool                    Enabled;           
00923         HFBAnimationNode        AnimNode;          
00924     };
00925 
00926 
00931     FBDeviceGlove( char* pName, HIObject pObject=NULL );
00932 
00936     virtual void RecordingInitAnimation( HFBAnimationNode pAnimationNode );
00937 
00941     virtual void RecordingDoneAnimation( HFBAnimationNode pAnimationNode );
00942     
00943 protected:
00948     void InitializeModelGeometry();
00949 
00958     void VectorToModelPartAngle( kHandModelPart pPartIndex, FBVector3d& pVector );
00959 
00964     HFBAnimationNode GetModelRotationNode( kHandModelPart pPartIndex );
00965 
00966 public:
00967     FBArrayTemplate<GloveChannel*>      Channels;       
00968     
00969     FBPropertyBool                      LeftHand;       
00970 };
00971 
00972 #endif
00973 
00974 #ifdef FBSDKUseNamespace
00975     }
00976 #endif
00977 #endif