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

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Letwory <nathan@letworyinteractive.com>2010-09-13 00:24:15 +0400
committerNathan Letwory <nathan@letworyinteractive.com>2010-09-13 00:24:15 +0400
commit4038ca3e71602283e4b8b5cc2856e15b91368180 (patch)
treeec512697810029015dd1e9342ad247d34ca203e6 /release/scripts
parent396aece4733adb7baf38ef652b60715a9ab3b759 (diff)
Fix import of material with z transp enabled.
Reported by Heikki Lehikoinen in #blender.fi
Diffstat (limited to 'release/scripts')
-rw-r--r--release/scripts/op/io_scene_obj/import_obj.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/release/scripts/op/io_scene_obj/import_obj.py b/release/scripts/op/io_scene_obj/import_obj.py
index c91eb02f4d9..cbc4c57e56d 100644
--- a/release/scripts/op/io_scene_obj/import_obj.py
+++ b/release/scripts/op/io_scene_obj/import_obj.py
@@ -344,11 +344,9 @@ def create_materials(filepath, material_libs, unique_materials, unique_material_
mtex.texture = texture
mtex.texture_coords = 'UV'
mtex.use_map_alpha = True
- blender_material.z_transparency = True
+ blender_material.use_transparency = True
+ blender_material.transparency_method = 'Z_TRANSPARENCY'
blender_material.alpha = 0.0
-# blender_material.setTexture(4, texture, Texture.TexCo.UV, Texture.MapTo.ALPHA)
-# blender_material.mode |= Material.Modes.ZTRANSP
-# blender_material.alpha = 0.0
# Todo, unset deffuse material alpha if it has an alpha channel
elif type == 'refl':