Change boneCount field type from int to unsigned int (#5955)
This commit is contained in:
parent
65abee1cba
commit
2e03c9c266
2 changed files with 4 additions and 4 deletions
|
|
@ -409,7 +409,7 @@ typedef struct BoneInfo {
|
||||||
|
|
||||||
// Skeleton, animation bones hierarchy
|
// Skeleton, animation bones hierarchy
|
||||||
typedef struct ModelSkeleton {
|
typedef struct ModelSkeleton {
|
||||||
int boneCount; // Number of bones
|
unsigned int boneCount; // Number of bones
|
||||||
BoneInfo *bones; // Bones information (skeleton)
|
BoneInfo *bones; // Bones information (skeleton)
|
||||||
ModelAnimPose bindPose; // Bones base transformation (Transform[])
|
ModelAnimPose bindPose; // Bones base transformation (Transform[])
|
||||||
} ModelSkeleton;
|
} ModelSkeleton;
|
||||||
|
|
@ -436,7 +436,7 @@ typedef struct Model {
|
||||||
typedef struct ModelAnimation {
|
typedef struct ModelAnimation {
|
||||||
char name[32]; // Animation name
|
char name[32]; // Animation name
|
||||||
|
|
||||||
int boneCount; // Number of bones (per pose)
|
unsigned int boneCount; // Number of bones (per pose)
|
||||||
int keyframeCount; // Number of animation key frames
|
int keyframeCount; // Number of animation key frames
|
||||||
ModelAnimPose *keyframePoses; // Animation sequence keyframe poses [keyframe][pose]
|
ModelAnimPose *keyframePoses; // Animation sequence keyframe poses [keyframe][pose]
|
||||||
} ModelAnimation;
|
} ModelAnimation;
|
||||||
|
|
|
||||||
|
|
@ -5369,9 +5369,9 @@ static Image LoadImageFromCgltfImage(cgltf_image *cgltfImage, const char *texPat
|
||||||
}
|
}
|
||||||
|
|
||||||
// Load bone info from GLTF skin data
|
// Load bone info from GLTF skin data
|
||||||
static BoneInfo *LoadBoneInfoGLTF(cgltf_skin skin, int *boneCount)
|
static BoneInfo *LoadBoneInfoGLTF(cgltf_skin skin, unsigned int *boneCount)
|
||||||
{
|
{
|
||||||
*boneCount = (int)skin.joints_count;
|
*boneCount = skin.joints_count;
|
||||||
BoneInfo *bones = (BoneInfo *)RL_CALLOC(skin.joints_count, sizeof(BoneInfo));
|
BoneInfo *bones = (BoneInfo *)RL_CALLOC(skin.joints_count, sizeof(BoneInfo));
|
||||||
|
|
||||||
for (unsigned int i = 0; i < skin.joints_count; i++)
|
for (unsigned int i = 0; i < skin.joints_count; i++)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue