lighttransport / gltf-insight

C++11 based glTF 2.0 data insight tool
MIT License
27 stars 4 forks source link

Animations channel that move "mesh nodes" aren't played #6

Open Ybalrid opened 5 years ago

Ybalrid commented 5 years ago

https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0/AnimatedCube

This model should be animated, but isn't

cesss commented 5 years ago

I think it's not a bug, but that maybe interpolated animations of transformation matrices is not implemented yet. I mean, I tried all samples that have animated translation/rotation/scale and all of them fail (I suppose such animations are not motion of "mesh nodes", but of transformation matrices (a different transformation matrix for each keyframe).

Take a look at this:

BoxAnimated

InterpolationTest

AnimatedTriangle (this one crashes at load)

And of course, AnimatedCube, as you noticed.

I think these are the only glTF demos with interpolation of transformation matrices.

glTF-Insight does play correctly skinned/morph animations, though, but maybe these other animations are not implemented yet.

Ybalrid commented 5 years ago

@cesss Yes, they are what I called "motion of mesh nodes" what you are describing is the problem in the opening post of the issue.

Animation tracks that moves something that is not the transform of a "joint" node are ignored. (Animation tracks that move weights values are good).