Animation3DClips Module
Functions and values
| Function or value |
Description
|
|
Skeleton bone names of a loaded
raylib 6 clips carry no bone names — a file's animation keyframe poses
follow the bone order of that file's model skeleton, which is what this
reads. Needed per source file when merging clips from multiple files (see
|
Full Usage:
buildBoneRemap sourceBoneNames targetBoneNames
Parameters:
string[]
targetBoneNames : string[]
Returns: int[] voption
|
Build the remap that lets a clip authored against one skeleton bone order (sourceBoneNames) be sampled against another (targetBoneNames), matching bones by name.
Returns
|
|
|
Full Usage:
fromModelAnimations anims
Parameters:
ModelAnimation[]
Returns: Animation3DClips
|
Create a clip set from an array of loaded
Use this after loading animations with
|
|
|
Full Usage:
merge targetBoneNames sources
Parameters:
string[]
sources : (string[] * ModelAnimation[])[]
Returns: Animation3DClips
|
Merge animations loaded from different files into one clip set that samples correctly against the target skeleton's bone order.
Asset packs may split clips across rig files whose skeletons order the
same bones differently (e.g. KayKit's Rig_Medium_MovementBasic.glb orders
right-side joints first, Rig_Medium_General.glb left-side first). raylib
keyframe poses are index-based, so a clip from a differently-ordered file
would drive the wrong bones (mirrored limbs). Each entry in
sources pairs one file's skeleton bone names (see
|
|
|
Full Usage:
tryGetClipIndex name clips
Parameters:
string
clips : Animation3DClips
Returns: int voption
Modifiers: inline |
Try to get the index for an animation name. Use at load time to resolve animation names to indices for zero-allocation playback.
|
Mibo