[Bf-extensions-cvs] [f50a11f] blender-v2.78-release: Fix T49338: Export to OBJ add extra space to the texture file name on MTL file
Sergey Sharybin
noreply at git.blender.org
Wed Sep 14 10:23:12 CEST 2016
Commit: f50a11ff30e785bf4dcf7746d23b507e4314bbd3
Author: Sergey Sharybin
Date: Tue Sep 13 12:26:05 2016 +0200
Branches: blender-v2.78-release
https://developer.blender.org/rBAf50a11ff30e785bf4dcf7746d23b507e4314bbd3
Fix T49338: Export to OBJ add extra space to the texture file name on MTL file
===================================================================
M io_scene_obj/export_obj.py
===================================================================
diff --git a/io_scene_obj/export_obj.py b/io_scene_obj/export_obj.py
index 9418cc6..3933abf 100644
--- a/io_scene_obj/export_obj.py
+++ b/io_scene_obj/export_obj.py
@@ -188,7 +188,10 @@ def write_mtl(scene, filepath, path_mode, copy_set, mtl_dict):
options.append('-o %.6f %.6f %.6f' % mtex.offset[:])
if mtex.scale != Vector((1.0, 1.0, 1.0)):
options.append('-s %.6f %.6f %.6f' % mtex.scale[:])
- fw('%s %s %s\n' % (key, " ".join(options), repr(filepath)[1:-1]))
+ if options:
+ fw('%s %s %s\n' % (key, " ".join(options), repr(filepath)[1:-1]))
+ else:
+ fw('%s %s\n' % (key, repr(filepath)[1:-1]))
def test_nurbs_compat(ob):
More information about the Bf-extensions-cvs
mailing list