[Bf-extensions-cvs] [20e4c80] master: Fix T43279: FBX exporter would fail on 'used' valid texslots with None texture.

Bastien Montagne noreply at git.blender.org
Sun Jan 25 12:38:46 CET 2015


Commit: 20e4c8056c3c7f107169c80e4fd7b316acc7747d
Author: Bastien Montagne
Date:   Sun Jan 25 12:37:07 2015 +0100
Branches: master
https://developer.blender.org/rBA20e4c8056c3c7f107169c80e4fd7b316acc7747d

Fix T43279: FBX exporter would fail on 'used' valid texslots with None texture.

I’m quite not sure whether such a situation is supposed to happen, but does not hurt
protecting against it anyway.

===================================================================

M	io_scene_fbx/export_fbx_bin.py

===================================================================

diff --git a/io_scene_fbx/export_fbx_bin.py b/io_scene_fbx/export_fbx_bin.py
index 5cc4d5a..c7f004a 100644
--- a/io_scene_fbx/export_fbx_bin.py
+++ b/io_scene_fbx/export_fbx_bin.py
@@ -2182,7 +2182,7 @@ def fbx_data_from_scene(scene, settings):
         if check_skip_material(mat):
             continue
         for tex, use_tex in zip(mat.texture_slots, mat.use_textures):
-            if tex is None or not use_tex:
+            if tex is None or tex.texture is None or not use_tex:
                 continue
             # For now, only consider image textures.
             # Note FBX does has support for procedural, but this is not portable at all (opaque blob),



More information about the Bf-extensions-cvs mailing list