diff options
author | Julien Duroure <julien.duroure@gmail.com> | 2019-10-16 08:25:30 +0300 |
---|---|---|
committer | Julien Duroure <julien.duroure@gmail.com> | 2019-10-16 08:25:30 +0300 |
commit | 88333d082f38439a6dfdfcb6758b88e5cac3e43c (patch) | |
tree | db13ccdcea5ae2e8381b3c0738a67221a79a92fc | |
parent | d892f8a96e6b87e0e31dd4ce79deafee0a6a060c (diff) |
glTF importer: Fix T70863 metallic texture transform fix after api change
-rwxr-xr-x | io_scene_gltf2/blender/imp/gltf2_blender_pbrMetallicRoughness.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/io_scene_gltf2/blender/imp/gltf2_blender_pbrMetallicRoughness.py b/io_scene_gltf2/blender/imp/gltf2_blender_pbrMetallicRoughness.py index 86eb4be4..af529090 100755 --- a/io_scene_gltf2/blender/imp/gltf2_blender_pbrMetallicRoughness.py +++ b/io_scene_gltf2/blender/imp/gltf2_blender_pbrMetallicRoughness.py @@ -305,11 +305,11 @@ class BlenderPbr(): metallic_mapping.location = -1000, 0 metallic_mapping.vector_type = 'POINT' tex_transform = metallic_text.image['tex_transform'][str(pypbr.metallic_roughness_texture.index)] - metallic_mapping.translation[0] = texture_transform_gltf_to_blender(tex_transform)['offset'][0] - metallic_mapping.translation[1] = texture_transform_gltf_to_blender(tex_transform)['offset'][1] - metallic_mapping.rotation[2] = texture_transform_gltf_to_blender(tex_transform)['rotation'] - metallic_mapping.scale[0] = texture_transform_gltf_to_blender(tex_transform)['scale'][0] - metallic_mapping.scale[1] = texture_transform_gltf_to_blender(tex_transform)['scale'][1] + metallic_mapping.inputs['Location'].default_value[0] = texture_transform_gltf_to_blender(tex_transform)['offset'][0] + metallic_mapping.inputs['Location'].default_value[1] = texture_transform_gltf_to_blender(tex_transform)['offset'][1] + metallic_mapping.inputs['Rotation'].default_value[2] = texture_transform_gltf_to_blender(tex_transform)['rotation'] + metallic_mapping.inputs['Scale'].default_value[0] = texture_transform_gltf_to_blender(tex_transform)['scale'][0] + metallic_mapping.inputs['Scale'].default_value[1] = texture_transform_gltf_to_blender(tex_transform)['scale'][1] metallic_uvmap = node_tree.nodes.new('ShaderNodeUVMap') metallic_uvmap.location = -1500, 0 |