More Model animations management functions.

This commit is contained in:
jussi
2023-12-08 22:40:04 +02:00
parent eb7873be2b
commit 93b5b2eb37
8 changed files with 342 additions and 72 deletions

68
API.md
View File

@@ -6605,16 +6605,16 @@ Set model transform matrix
> success = RL.SetModelMesh( Model model, int meshId, Mesh mesh )
Get model mesh. Return as lightuserdata
Set model mesh.
- Failure return false
- Success return true
---
> success = RL.SetModelMaterial( Model model, int modelMaterialId, Material material )
> success = RL.SetModelMaterial( Model model, int materialId, Material material )
Copies material to model material
Set material to model material
- Failure return false
- Success return true
@@ -7057,6 +7057,18 @@ Update model animation pose
---
> RL.UnloadModelAnimation( ModelAnimation animation )
Unload animation data
---
> RL.UnloadModelAnimations( ModelAnimation{} animations )
Unload animation table data
---
> valid = RL.IsModelAnimationValid( Model model, ModelAnimation animation )
Check model animation skeleton match
@@ -7065,6 +7077,30 @@ Check model animation skeleton match
---
> success = RL.SetModelAnimationBone( ModelAnimation animation, int boneId, BoneInfo bone )
Set modelAnimation bones information (skeleton)
- Failure return false
- Success return true
---
> success = RL.SetModelAnimationFramePose( ModelAnimation animation, int frame, int boneId, Transform pose )
Set modelAnimation bones base transformation (pose)
- Failure return false
- Success return true
---
> RL.SetModelAnimationName( ModelAnimation animation, string name )
Set modelAnimation name
---
> boneCount = RL.GetModelAnimationBoneCount( ModelAnimation animation )
Return modelAnimation bone count
@@ -7081,6 +7117,32 @@ Return modelAnimation frame count
---
> bone = RL.GetModelAnimationBone( ModelAnimation animation, int boneId )
Get modelAnimation bones information (skeleton)
- Failure return nil
- Success return BoneInfo
---
> pose = RL.GetModelAnimationFramePose( ModelAnimation animation, int frame, int boneId )
Get modelAnimation bones base transformation (pose)
- Failure return nil
- Success return Transform
---
> name = RL.GetModelAnimationName( ModelAnimation animation )
Get modelAnimation name
- Success return string
---
## Model - Collision detection functions
---