diff options
author | Julien Duroure <julien.duroure@gmail.com> | 2022-04-29 09:22:37 +0300 |
---|---|---|
committer | Julien Duroure <julien.duroure@gmail.com> | 2022-04-29 09:22:37 +0300 |
commit | dbb9b62991b35d7f6285419460f3e829e076fd96 (patch) | |
tree | fa26de5b33095ca3bf51f1a09f82496b21dc40d8 /io_scene_gltf2/blender/exp | |
parent | 599a8db33c45c2ad94f8d482f01b281252799770 (diff) |
glTF exporter: fix animation baking bug when sampling is off, and limited to selection only
Diffstat (limited to 'io_scene_gltf2/blender/exp')
-rwxr-xr-x | io_scene_gltf2/blender/exp/gltf2_blender_gather_animations.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/io_scene_gltf2/blender/exp/gltf2_blender_gather_animations.py b/io_scene_gltf2/blender/exp/gltf2_blender_gather_animations.py index 2b8a0682..20a919dc 100755 --- a/io_scene_gltf2/blender/exp/gltf2_blender_gather_animations.py +++ b/io_scene_gltf2/blender/exp/gltf2_blender_gather_animations.py @@ -63,7 +63,9 @@ def gather_animations( obj_uuid: int, if len([a for a in blender_actions if a[2] == "OBJECT"]) == 0: # No TRS animation are found for this object. # But we need to bake, in case we export selection - if export_settings['gltf_selected'] is True and blender_object.type != "ARMATURE": + # (Only when force sampling is ON) + # If force sampling is OFF, can lead to inconsistant export anyway + if export_settings['gltf_selected'] is True and blender_object.type != "ARMATURE" and export_settings['gltf_force_sampling'] is True: channels = __gather_channels_baked(obj_uuid, export_settings) if channels is not None: animation = gltf2_io.Animation( |