274 const float pMin[3],
const float pMax[3],
275 const float pPreQ[4],
const float pPostQ[4],
bool HIKCreatureSetStateTransformTQS(const HIKCreature *pCreature, HIKCreatureState *pCreatureState, const HIKDataDescription *pDataDescription, const void *pDataSet)
Set the translation (T), quaternion rotation (Q) and scaling (S) of multiple Nodes from data set pDat...
The solving involves all nodes in the chain, freely rotating - approximation only.
void HIKCreatureGetChainLastChainErrQ(HIKCreature *pCreature, int pChainId, int pIter, float pQ[4])
bool HIKCreatureSetCharacterizeNodeStateTQSfv(HIKCreature *pCreature, int pElementId, int pNodeId, const float pT[4], const float pQ[4], const float pS[4])
Set the translation, orientation and scaling for the Node pNodeId when the character is standing in t...
bool HIKCreatureCharacterizeGeometry(HIKCreature *pCreature)
Set up and initialize creature pCreature for solving.
The solving involves all nodes in the chain, freely rotating, constrained with orienation reach...
int mNbChains
The number of IK chains for this creature.
Defines how DOFs are applied along the chain.
struct sHIKCreatureSectionDefinition HIKCreatureSectionDefinition
void HIKCreatureEnableTorque(HIKCreatureEffectorSetState *pEffectorSetState, bool pValue)
Enable or disable torque solving on the creature (* Only relevant when doing FBIK) ...
void(* HIKFree)(void *)
Memory de-allocator function.
void HIKCreatureSetEffectorStateTQSfv(HIKCreatureEffectorSetState *pEffectorSetState, int pEffectorIndex, const float pT[4], const float pQ[4], const float pS[4])
Set the translation (T), quaternion rotation (Q) and scaling (S) in global space of Effector pEffecto...
bool HIKCreatureSetLimitsfv(HIKCreature *pCreature, int pElementId, int pNodeId, const float pMin[3], const float pMax[3], const float pPreQ[4], const float pPostQ[4], int pActiveMask, eHIKRotationOrder pRotationOrder)
Set up limits for Node pNodeId.
float HIKCreatureGetChainLastChainWeightsT(HIKCreature *pCreature, int pChainId)
void HIKCreatureGetEffectorStateTQSfv(const HIKCreatureEffectorSetState *pEffectorSetState, int pEffectorIndex, float pT[4], float pQ[4], float pS[4])
Retrieve the translation (T), quaternion rotation (Q) and scaling (S) in global space of Effector pEf...
float HIKCreatureGetChainLastPullLength(HIKCreature *pCreature, int pChainId)
bool HIKCreatureGetParentOffsetfv(const HIKCreature *pCreature, int pElementId, int pNodeId, float pT[4], float pQ[4], float pS[4])
Retrieve the parent offset set for Node pNodeId.
void HIKCreatureSetPull(HIKCreatureEffectorSetState *pEffectorSetState, int pEffectorIndex, float pValue)
Set the Pull constraint for Effector pEffectorIndex.
The solving involves all nodes in the chain, potentially DOF constrained, re-ordered, all folding on the same plane.
HIKCreatureState * HIKCreatureStateCreate(const HIKCreature *pCreature, HIKMalloc pMalloc)
Create a new HIKCreatureState.
The solving only involves the chain root + all intermediary nodes, all folding on the same plane...
void HIKCreatureEffectorSetStateDestroy(HIKCreatureEffectorSetState *pEffectorSetState, HIKFree pFree)
Destroy HIKCreatureEffectorSetState pEffectorSetState.
void HIKCreatureSetChainCompressionResistance(HIKCreature *pCreature, int pChainId, float pValue)
Sets how resistant a chain should behave when being compressed (* Only relevant when doing FBIK) ...
A description of a data set that contains separate translation, quaternion rotation, and scaling values for multiple different Nodes in an HIKCharacterState.
float HIKCreatureGetSectionLastSectionErrWeightT(HIKCreature *pCreature, int pSectionId, int pIter)
Number of iterations for the CCD algorithm; default is 32.
HIKCreatureEffectorSetState * HIKCreatureEffectorSetStateCreate(const HIKCreature *pCreature, HIKMalloc pMalloc)
Create a new HIKCreatureEffectorSetState.
Defines an HIKCreatureEffectorSetState.
Defines a pose for a creature.
struct sHIKCreatureChainDefinition HIKCreatureChainDefinition
int HIKCreatureGetChainParentSectionIndex(HIKCreature *pCreature, int pChainId)
Get parent section index for a chain.
struct sHIKCreatureDefinition HIKCreatureDefinition
bool HIKCreatureGetStateTransformTQS(const HIKCreature *pCreature, HIKCreatureState *pCreatureState, const HIKDataDescription *pDataDescription, void *pDataSet)
Retrieve the translation (T), quaternion rotation (Q) and scaling (S) of multiple Nodes from HIKCreat...
float HIKCreatureGetChainLastPull(HIKCreature *pCreature, int pChainId)
void HIKCreatureSetNodeStateTQSfv(const HIKCreature *pCreature, HIKCreatureState *pCreatureState, int pElementId, int pNodeId, const float pT[4], const float pQ[4], const float pS[4])
Set the translation (T), quaternion rotation (Q) and scaling (S) in global space of Node pNodeId from...
void HIKCreatureSetRotationActive(HIKCreatureEffectorSetState *pEffectorSetState, int pEffectorIndex, float pValue)
Set the Reach Rotation constraint for Effector pEffectorIndex.
void HIKCreatureSetTranslationActive(HIKCreatureEffectorSetState *pEffectorSetState, int pEffectorIndex, float pValue)
Set the Reach Translation constraint for Effector pEffectorIndex.
enum HIKRotationOrder eHIKRotationOrder
see enum HIKRotationOrder
float HIKCreatureGetSectionLastSectionWeights(HIKCreature *pCreature, int pSectionId, int pIter)
void HIKCreatureGetChainLastChainPullDir(HIKCreature *pCreature, int pChainId, int pIter, float pT[4])
void HIKCreatureStateDestroy(HIKCreatureState *pCreatureState, HIKFree pFree)
Destroy HIKCreatureState pCreatureState.
void HIKCreatureGetDefaultState(const HIKCreature *pCreature, HIKCreatureState *pCreatureState)
Retrieve the default natural stance for creature pCreature, storing it in HIKCreatureState pCreatureS...
void HIKCreatureSetChainStiffness(HIKCreature *pCreature, int pChainId, float pValue)
Sets how stiff a chain should behave (* Only relevant when doing FBIK)
bool HIKCreatureSetHasParentOffset(HIKCreature *pCreature, int pChainId, int pNodeId)
Only relevant when working in local coordinates.
bool HIKCreatureSetParentOffsetfv(HIKCreature *pCreature, int pElementId, int pNodeId, const float pT[4], const float pQ[4], const float pS[4])
Only relevant when working in local coordinates.
void HIKCreatureSetSectionExtraPull(HIKCreature *pCreature, int pSectionId, float pValue)
Sets how a section should emphasizes its pull (* Only relevant when doing FBIK)
void HIKCreatureSetChainProperty(HIKCreature *pCreature, int pChainId, int pPropertyIndex, float pValue)
Set property for a specific chain in the creature.
float HIKCreatureGetChainLastChainErrT(HIKCreature *pCreature, int pChainId, int pIter)
void HIKCreatureGetSectionLastSectionErrQReach(HIKCreature *pCreature, int pSectionId, int pIter, float pQ[4])
void HIKCreatureDestroy(HIKCreature *pCreature, HIKFree pFree)
Destroy HIKCreature pCreature.
void HIKEffectorSetFromCreature(const HIKCreature *pCreature, HIKCreatureEffectorSetState *pEffectorSetState, const HIKCreatureState *pCreatureState)
Set up HIKCreatureEffectorSetState pEffectorSetState to match creature pCreature in HIKCreatureState ...
void HIKCreatureGetSectionLastSectionErrQPull(HIKCreature *pCreature, int pSectionId, int pIter, float pQ[4])
void HIKCreatureGetSectionLastSumErr(HIKCreature *pCreature, int pSectionId, int pIter, float pT[4])
Defines how many joints in chain (from the end) should contribute to end orientation reach; default i...
HIKCreatureSectionDefinition * mSections
void HIKCreatureSolveForEffectorSet(HIKCreature *pCreature, HIKCreatureState *pCreatureState, HIKCreatureEffectorSetState *pEffectorSetState)
Solve creature pCreature with HIKCreatureEffectorSetState pEffectorSetState and initial HIKCreatureSt...
Index of the joint to fold in the chain (top = 0); default is 1.
void *(* HIKMalloc)(size_t)
Memory allocator function.
bool HIKCreatureSetHasLimits(HIKCreature *pCreature, int pChainId, int pNodeId)
Declares a chain node implements limits.
Maximal joint rotation in radians; default is 0.157f.
void HIKCreatureEnableFBIK(HIKCreatureEffectorSetState *pEffectorSetState, bool pValue)
Enable or disable FullBodyIK solving on the creature.
void HIKCreatureSetChainSolvingType(HIKCreature *pCreature, int pChainId, HIKChainSolvingType pValue)
Set solving type for a specific chain in the creature.
HIKCreature * HIKCreatureCreate(const HIKCreatureDefinition *pCreatureDefinition, HIKMalloc pMalloc, const char *pValidationString)
Create a new HIKCreature.
HIKCreatureChainDefinition * mChains
void HIKCreatureGetNodeStateTQSfv(const HIKCreature *pCreature, const HIKCreatureState *pCreatureState, int pElementId, int pNodeId, float pT[4], float pQ[4], float pS[4])
Retrieve the translation (T), quaternion rotation (Q) and scaling (S) in global space of Node pNodeId...
Defines a Creature to be used with HumanIK.