FBX IO: Speed up animation import using NumPy #104856

Merged
Thomas Barlow merged 12 commits from Mysteryem/blender-addons:fbx_import_anim_numpy_p1 into main 2023-09-04 22:07:45 +02:00

12 Commits

Author SHA1 Message Date
464e036073 Cleanup: Remove explicit iter use in frame_values_it and add comments 2023-08-31 23:56:17 +01:00
ae09d491d8 Cleanup: comments 2023-08-31 13:38:24 +01:00
cf782b4b21 Cleanup 2023-08-31 05:31:02 +01:00
d83d71e45b Combine use of _combine_same_property_curves and blen_read_single_animation_curve into a single function 2023-08-31 04:56:24 +01:00
fded8b6eb5 Small optimisations and more documentation for _transformation_curves_gen 2023-08-31 04:56:24 +01:00
3332d1936a Cleanup 2023-08-31 04:56:24 +01:00
b3c8b483d8 Move fbx to Blender keyframe time conversion into blen_store_keyframes
Add faster blen_store_keyframes_multi for when multiple fcurves have the same keyframe times.
2023-08-31 04:56:24 +01:00
285fea09d6 Faster generator for yielding indices of invalid animation curves 2023-08-31 04:56:24 +01:00
6124ee60af Remove the expansive information on how other interpolation can be set up 2023-08-31 04:56:24 +01:00
ff192f6f3f Optimise and tidy up combining curves with interpolation 2023-08-31 04:56:24 +01:00
f91d576625 initial implementation (and revert only using the first anim curve per channel) 2023-08-31 04:56:24 +01:00
2ffbeeb8e7 Use only the first anim curve per property channel
The FBX SDK documentation specifies that the FBX animation system's default implementation only uses the first curve assigned to a channel. Additional curves per channel are supported by the FBX specification, but the handling of these extra curves is considered the responsibility of the application that created them.

This patch changes animation imports to discard extra animation curves for each property channel after the first curve has been found. When this has occurred, a warning is printed to the system console.
2023-08-31 04:53:31 +01:00