diff options
Diffstat (limited to 'io_scene_gltf2/blender/exp/gltf2_blender_extract.py')
-rwxr-xr-x | io_scene_gltf2/blender/exp/gltf2_blender_extract.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/io_scene_gltf2/blender/exp/gltf2_blender_extract.py b/io_scene_gltf2/blender/exp/gltf2_blender_extract.py index df0552cd..ae79f883 100755 --- a/io_scene_gltf2/blender/exp/gltf2_blender_extract.py +++ b/io_scene_gltf2/blender/exp/gltf2_blender_extract.py @@ -77,6 +77,7 @@ def convert_swizzle_normal(loc, armature, blender_object, export_settings): apply_matrix = (armature.matrix_world.inverted() @ blender_object.matrix_world).to_3x3().inverted()
apply_matrix.transpose()
new_loc = ((armature.matrix_world.to_3x3() @ apply_matrix).to_4x4() @ Matrix.Translation(Vector((loc[0], loc[1], loc[2])))).to_translation()
+ new_loc.normalize()
if export_settings[gltf2_blender_export_keys.YUP]:
return Vector((new_loc[0], new_loc[2], -new_loc[1]))
|