diff options
Diffstat (limited to 'io_scene_gltf2/blender/exp/gltf2_blender_gather_primitive_attributes.py')
-rwxr-xr-x | io_scene_gltf2/blender/exp/gltf2_blender_gather_primitive_attributes.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/io_scene_gltf2/blender/exp/gltf2_blender_gather_primitive_attributes.py b/io_scene_gltf2/blender/exp/gltf2_blender_gather_primitive_attributes.py index 8912d921..61adea89 100755 --- a/io_scene_gltf2/blender/exp/gltf2_blender_gather_primitive_attributes.py +++ b/io_scene_gltf2/blender/exp/gltf2_blender_gather_primitive_attributes.py @@ -161,9 +161,12 @@ def __gather_skins(blender_primitive, export_settings): # joints internal_joint = blender_primitive["attributes"][joint_id] + component_type = gltf2_io_constants.ComponentType.UnsignedShort + if max(internal_joint) < 256: + component_type = gltf2_io_constants.ComponentType.UnsignedByte joint = array_to_accessor( internal_joint, - component_type=gltf2_io_constants.ComponentType.UnsignedShort, + component_type, data_type=gltf2_io_constants.DataType.Vec4, ) attributes[joint_id] = joint |