BabylonJS / Exporters

Exporters for Babylon.js and gltf file formats
Other
613 stars 313 forks source link

Maya to GLTF exporter always resamples animation #1021

Open garynull opened 2 years ago

garynull commented 2 years ago

Expected behavior: Exported animation curves will use CUBICSPLINE where appropriate when "Bake Animation Frames" is not checked.

Actual behavior: Animation is always broken up into single frames and the GLTF samplers have no interpolation value set (defaults to LINEAR). The "Bake Animation Frames" checkbox appears to have no effect on output.

Version used: 20211115.1

pandaGaume commented 2 years ago

Hello, could you elaborate on "where appropriate" . Seems a feature request and not issue.

garynull commented 2 years ago

My memory is hazy but I think Maya only stores animation curves using Bezier splines, so you can probably ignore "where appropriate" and just use CUBICSPLINE for everything.

This is definitely a bug, at least because the "Bake Animation Frames" checkbox doesn't work: animation frames are always baked instead of the animation curves being properly exported as they appear in Maya.

pandaGaume commented 2 years ago

Maya has many way to store animation, from linear to curve. We only support linear interpolation actually, which, i'm agree, is a limitation. If you send me a repro, i may have a check on how to introduce this behavior into the exporter.