25 #ifndef RAYLIB_CPP_INCLUDE_MODELANIMATION_HPP_
26 #define RAYLIB_CPP_INCLUDE_MODELANIMATION_HPP_
31 #include "./raylib.hpp"
32 #include "./raylib-cpp-utils.hpp"
52 static std::vector<ModelAnimation>
Load(
const std::string& fileName) {
54 ::ModelAnimation* modelAnimations = ::LoadModelAnimations(fileName.c_str(), &count);
55 return std::vector<ModelAnimation>(modelAnimations, modelAnimations + count);
58 GETTERSETTER(
int, BoneCount, boneCount)
59 GETTERSETTER(::BoneInfo*, Bones, bones)
60 GETTERSETTER(
int, FrameCount, frameCount)
61 GETTERSETTER(::Transform**, FramePoses, framePoses)
72 ::UnloadModelAnimation(*
this);
79 ::UpdateModelAnimation(model, *
this, frame);
86 inline bool IsValid(const ::Model& model)
const {
87 return ::IsModelAnimationValid(model, *
this);
91 inline void set(const ::ModelAnimation& model) {
92 boneCount = model.boneCount;
94 frameCount = model.frameCount;
95 framePoses = model.framePoses;
100 #endif // RAYLIB_CPP_INCLUDE_MODELANIMATION_HPP_