Fixed doesn't property load when 1 frame animation. (#5561)

This commit is contained in:
Yui Kinomoto / きのもと 結衣 2026-02-16 04:15:25 +09:00 committed by GitHub
parent 059ebaa6ad
commit 6564cea6a3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -6244,7 +6244,10 @@ static bool GetPoseAtTimeGLTF(cgltf_interpolation_type interpolationType, cgltf_
}
// Constant animation, no need to interpolate
if (FloatEquals(tend, tstart)) return true;
if (FloatEquals(tend, tstart))
{
interpolationType = cgltf_interpolation_type_step;
}
float duration = fmaxf((tend - tstart), EPSILON);
float t = (time - tstart)/duration;