[Bf-extensions-cvs] [0bfa31e] master: FBX import: minor fixes (mostly, could try to load an image with None path...).
Bastien Montagne
noreply at git.blender.org
Fri Feb 20 12:11:09 CET 2015
Commit: 0bfa31efd96f0c213f67446631ee13c7574e1e42
Author: Bastien Montagne
Date: Fri Feb 20 12:10:32 2015 +0100
Branches: master
https://developer.blender.org/rBA0bfa31efd96f0c213f67446631ee13c7574e1e42
FBX import: minor fixes (mostly, could try to load an image with None path...).
===================================================================
M io_scene_fbx/import_fbx.py
===================================================================
diff --git a/io_scene_fbx/import_fbx.py b/io_scene_fbx/import_fbx.py
index 534cc73..ea8af76 100644
--- a/io_scene_fbx/import_fbx.py
+++ b/io_scene_fbx/import_fbx.py
@@ -1312,6 +1312,8 @@ def blen_read_texture_image(fbx_tmpl, fbx_obj, basedir, settings):
filepath = elem_find_first_string(fbx_obj, b'Filename')
if not filepath:
print("Error, could not find any file path in ", fbx_obj)
+ print(" Falling back to: ", elem_name_utf8)
+ filepath = elem_name_utf8
else :
filepath = filepath.replace('\\', '/') if (os.sep == '/') else filepath.replace('/', '\\')
@@ -2055,7 +2057,8 @@ def load(operator, context, filepath="",
from . import parse_fbx
from .fbx_utils import RIGHT_HAND_AXES, FBX_FRAMERATES
- start_time = time.process_time()
+ start_time_proc = time.process_time()
+ start_time_sys = time.time()
# detect ascii files
if is_ascii(filepath, 24):
@@ -2889,5 +2892,6 @@ def load(operator, context, filepath="",
material.use_raytrace = False
_(); del _
- print('Import finished in %.4f sec.' % (time.process_time() - start_time))
+ print('Import finished in %.4f sec (process time: %.4f sec).' %
+ (time.time() - start_time_sys, time.process_time() - start_time_proc))
return {'FINISHED'}
More information about the Bf-extensions-cvs
mailing list