Open Reality Reference Guide
|
|
Go to the documentation of this file. 1 #ifndef __FBCHARACTERMANIPULATOR_H__
2 #define __FBCHARACTERMANIPULATOR_H__
43 #include <kaydaradef.h>
48 #define FBSDK_DLL K_DLLIMPORT
55 #ifdef FBSDKUseNamespace
56 namespace FBSDKNamespace {
298 #define FBCharacterManipulatorCtrlSetDeclare( ClassName, Parent ) \
299 FBClassDeclare( ClassName, Parent ); \
301 ClassName(const char* pName):Parent(pName) { FBClassInit; } \
307 #define FBCharacterManipulatorCtrlSetImplementation( ThisComponent ) \
308 FBClassImplementation( ThisComponent )
482 #ifdef FBSDKUseNamespace
@ FBManipPivotObjectScaling
Consider the scaling of the pivot.
FBEffectorSetID GetEffectorSet()
Find the index of the currently manipulated effector set.
bool IsDescendantPulling(FBEffectorId pEffectorId)
Determine if one of the effector's child has a IK Pull value bigger than 0.5 on the current manipulat...
FBCharacterManipulatorCtrlSet(const char *pName, HIObject pObject=NULL)
Constructor.
@ FBRefTypeSumLayers
Global additive rotation.
float GetEffectorPullValue(int pEffectorId)
Get the pull (IK Pull since MotionBuilder 2013) value for a specified effector on the current manipul...
@ kFBManipulationOKNoUndo
This value means that the manipulation will be done, but the manipulation will not be undoable.
@ FBRefTypeParent
Parenting mode.
@ kFBManipulationGetFail
Return this value to prevent other manipulator to handle the request.
virtual FBManipulationSetResult ScalingSet(FBSVector &pS, FBReferencialType pRefType, FBSetType pSetType, FBSetWhat pSetWhat) override
Set the value of the scale to the manipulated model.
@ FBManip_EditorScaling
Scaling Manipulation Mode.
FBEffectorId GetDescendantEffector(FBEffectorId pEffectorId, int pIndex)
Return the child effector for the provided effector.
FBReferencialType
Specify the referential when a manipulation function is called.
virtual FBManipulationGetResult TranslationIsEditable(bool &pEditable, FBReferencialType pRefType) override
Returned value will indicate if a translation manipulation can be done.
bool IsFullBodyNoPull()
Determine if the character is in Full Body - No Pull keying mode.
@ FBSetWhatY
Set only the Y component of the value.
void TranslationSetLocal(FBTVector pVector, int pEffectorId)
Set the translation for the specified effector on the current manipulated character in local coordina...
FBManipPivot
Specify how the pivot should be interpreted.
virtual FBManipulationStartResult TranslationStartManipulation(FBReferencialType pRefType, const FBTime *pTime=NULL) override
Called to determine if the manipulation can be done.
virtual FBManipulationStartResult RotationStartManipulation(FBReferencialType pRefType)=0
Called to determine if the manipulation can be done.
void SetEffectorReachTValue(int pEffectorId, float pValue)
Set the reach T (IK Blend T since MotionBuilder 2013) value for a specified effector on the current m...
__FB_FORWARD(FBCharacterManipulator)
Used to translate, rotate or scale a character.
virtual FBManipulationGetResult RotationIsEditable(bool &pEditable, FBReferencialType pRefType) override
Returned value will indicate if a rotation manipulation can be done.
@ FBSetTypeCumulative
Add the provided value to the original value.
@ FBSetWhatXYZ
Set the XYZ components of the value.
virtual FBManipulationStartResult TranslationStartManipulation(FBReferencialType pRefType, const FBTime *pTime=NULL)=0
Called to determine if the manipulation can be done.
#define FBSDK_DLL
Be sure that FBSDK_DLL is defined only once...
@ FBSetWhatX
Set only the X component of the value.
@ FBManipPivotObjectTranslation
Consider the translation of the pivot.
@ FBSetTypeNone
Do nothing with the value.
@ FBSetWhatZ
Set only the Z component of the value.
@ FBRefTypeNone
No type specified.
@ kFBManipulationOK
This is the default value to return, means that you will handle the manipulation.
@ kFBManipulationSetContinue
Return this value when you don't want handle the request, another manipulator will try to handle it.
bool IsReleasePinPressed()
Call this to know if the Button Release is on when manipulating.
@ FBRefTypeGlobal
Referential is in global coordinate.
virtual FBManipulationGetResult TranslationGet(FBTVector &pT, FBReferencialType pRefType, FBManipPivot pPivot=FBManipPivotObjectTranslation)=0
Get the translation manipulator position.
virtual FBManipulationGetResult TranslationIsEditable(bool &pEditable, FBReferencialType pRefType)=0
Returned value will indicate if a translation manipulation can be done.
@ FBManipPivotObjectRotation
Consider the rotation of the pivot.
FBEffectorId GetManipulatedEffectorIdForTranslation()
Find the index of the currently manipulated effector For Translation.
virtual FBManipulationStartResult ScalingStartManipulation(FBReferencialType pRefType) override
Called to determine if the manipulation can be done.
virtual FBManipulationGetResult ScalingIsEditable(bool &pEditable)=0
Returned value will indicate if a scaling manipulation can be done.
virtual void AllocateState(FBCharacter *pCharacter)
Override this method to allocate the necessary state requires when manipulating a character.
virtual FBManipulationGetResult TranslationGet(FBTVector &pT, FBReferencialType pRefType, FBManipPivot pPivot=FBManipPivotObjectTranslation) override
Get the translation manipulator position.
@ kFBManipulationRefuse
Manipulation will be skipped.
A character is the link between a motion source and a character model.
@ FBSetWhatNone
Do nothing with the value.
@ FBManip_EditorTranslation
Translation Manipulation Mode.
virtual FBManipulationGetResult RotationIsEditable(bool &pEditable, FBReferencialType pRefType)=0
Returned value will indicate if a rotation manipulation can be done.
virtual FBManipulationSetResult TranslationSet(FBTVector &pT, FBReferencialType pRefType, FBSetType pSetType, FBSetWhat pSetWhat)=0
Set the value of the translation to the manipulated model.
FBEffectorId GetManipulatedEffectorIdForRotation()
Find the index of the currently manipulated effector for Rotation Only.
virtual void RotationStopManipulation() override
Called when the manipulation is finished.
FBModel * GetManipulatedNode()
return the manipulated Model
#define __FBClassDeclare(Name, Parent)
For internal use only.
bool IsFullBody()
Determine if the character is in Full Body keying mode.
@ FBRefTypeLocal
Referential is in local coordinate.
virtual void ScalingStopManipulation()=0
Called when the manipulation is finished.
bool IsIKPivotUse()
Determine if IK pivot are used when manipualting a character.
virtual void SyncCharacter(FBEvaluateInfo *pEvalInfo)
Synchronize the character after doing a manipulation using this function.
FBManipulationSetResult
Manipulation Set Result.
virtual FBManipulationStartResult RotationStartManipulation(FBReferencialType pRefType) override
Called to determine if the manipulation can be done.
FBCharacter * GetCharacter()
Returns the character being manipulated.
FBManipMode
Manipulator Mode.
void SetEffectorPullValue(int pEffectorId, float pValue)
Set the pull (IK Pull since MotionBuilder 2013) value for a specified effector on the current manipul...
virtual FBManipulationGetResult ScalingIsEditable(bool &pEditable) override
Returned value will indicate if a scaling manipulation can be done.
FBSetWhat
Specify what part of the provided value should be used.
bool IsReachOverride()
Determine if the reach override option is enable for the manipulated character.
virtual FBManipulationSetResult ScalingSet(FBSVector &pS, FBReferencialType pRefType, FBSetType pSetType, FBSetWhat pSetWhat)=0
Set the value of the scale to the manipulated model.
FBManipMode GetManipulatorMode()
return the manipulator Mode
virtual FBManipulationSetResult RotationSet(FBMatrix &pRM, FBReferencialType pRefType, FBSetType pSetType, bool pOnlyRoot=false)=0
Set the value of the translation to the manipulated model.
Four x Four (double) Matrix.
float GetEffectorReachTValue(int pEffectorId)
Get the reach T (IK Blend T since MotionBuilder 2013) value for a specified effector on the current m...
virtual void TranslationStopManipulation()=0
Called when the manipulation is finished.
virtual FBManipulationSetResult TranslationSet(FBTVector &pT, FBReferencialType pRefType, FBSetType pSetType, FBSetWhat pSetWhat) override
Set the value of the translation to the manipulated model.
@ kFBManipulationSetFail
Return this value when you have set the value.
FBEffectorId
All effector nodes.
void TranslationSetGlobal(FBTVector pVector, int pEffectorId)
Set the translation for the specified effector on the current manipulated character in global coordin...
FBBodyNodeId
All body nodes.
@ FBManip_EditorOther
Unknown Manipulation Mode.
FBBodyNodeId GetManipulatedBodyNode()
Find the index of the currently manipulated effector set.
FBSetType
Specify what to do with the provided value.
@ FBManipPivotObjectUnknown
Don't consider the pivot.
@ FBSetWhatAll
Set all components of the value.
FBManipulationGetResult
Manipulation Get Result.
@ FBManip_EditorRotation
Rotation Manipulation Mode.
Contains definitions for devices, boxes and models.
int GetDescendantEffectorCount(FBEffectorId pEffectorId)
Return the child effector count of the provided effector based on the skeleton hierarchy.
void TranslationStopManipulation() override
Called when the manipulation is finished.
virtual void RotationStopManipulation()=0
Called when the manipulation is finished.
FBCharacterManipulator(const char *pName, HIObject pObject=NULL)
Constructor.
Three dimensional scaling vector.
virtual void ScalingStopManipulation() override
Called when the manipulation is finished.
virtual FBManipulationGetResult ScalingGet(FBSVector &pS, FBReferencialType pRefType) override
Get the scale manipulator position.
@ FBSetTypeExact
Set the value directly.
FB_DEFINE_COMPONENT(K_DLLIMPORT, AnimationNode)
Animation node class.
Character Manipulator class.
FBEffectorId GetManipulatedEffectorId()
Find the index of the currently manipulated effector for Translation or Rotation depending of Mode.
@ kFBManipulationGetContinue
Return this value when you cannot provided the requested value, another manipulator will try to provi...
virtual FBManipulationGetResult RotationGet(FBMatrix &pRM, FBReferencialType pRefType) override
Get the rotation manipulator position.
virtual FBManipulationStartResult ScalingStartManipulation(FBReferencialType pRefType)=0
Called to determine if the manipulation can be done.
AnimationNodeNotify evaluation information.
virtual void DeallocateState()
Override this method to deallocate the state allocate in the AllocateState() function.
bool IsStiffnessOverride()
Determine if the stiffness override option is enable for the manipulated character.
MotionBuilder SDK base class.
bool IsBodyPart()
Determine if the character is in Body Part keying mode.
FBManipulationStartResult
Manipulation Start Result.
@ FBRefTypeLayer
Local additive rotation.
virtual FBManipulationSetResult RotationSet(FBMatrix &pRM, FBReferencialType pRefType, FBSetType pSetType, bool pOnlyRoot=false) override
Set the value of the translation to the manipulated model.
Contains definitions for actors, characters, and marker sets In Development.
FBEffectorSetID
Effector ID identifier.
virtual FBManipulationGetResult RotationGet(FBMatrix &pRM, FBReferencialType pRefType)=0
Get the rotation manipulator position.
virtual FBManipulationGetResult ScalingGet(FBSVector &pS, FBReferencialType pRefType)=0
Get the scale manipulator position.
@ kFBManipulationGetDone
Return this value when you can provided the requested value.