Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilipp Oeser <info@graphics-engineer.com>2018-10-15 11:12:04 +0300
committerPhilipp Oeser <info@graphics-engineer.com>2018-10-15 11:12:04 +0300
commitaf3ad31ba4a21cf8849061301032cea4a915a73f (patch)
treef586bd27fe9c9b22d8461516e465028a13af1010 /io_scene_obj
parentc2ad54f3ccd5a801d1a0e07f478086e4dc45510b (diff)
parent3aa692ee44df29670b4a03e29ab1f546b3b0c553 (diff)
Merge branch 'master' into blender2.8
Diffstat (limited to 'io_scene_obj')
-rw-r--r--io_scene_obj/import_obj.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/io_scene_obj/import_obj.py b/io_scene_obj/import_obj.py
index 2bf4ac94..916ff313 100644
--- a/io_scene_obj/import_obj.py
+++ b/io_scene_obj/import_obj.py
@@ -318,7 +318,7 @@ def create_materials(filepath, relpath,
# rgb, filter color, blender has no support for this.
print("WARNING, currently unsupported 'tf' filter color option, skipped.")
elif line_id == b'illum':
- illum = int(line_split[1])
+ illum = get_int(line_split[1])
# inline comments are from the spec, v4.2
if illum == 0:
@@ -835,6 +835,12 @@ def get_float_func(filepath):
return float
+def get_int(svalue):
+ if b',' in svalue:
+ return int(float(svalue.replace(b',', b'.')))
+ return int(float(svalue))
+
+
def load(context,
filepath,
*,