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:
authorCampbell Barton <ideasman42@gmail.com>2010-09-03 19:05:18 +0400
committerCampbell Barton <ideasman42@gmail.com>2010-09-03 19:05:18 +0400
commit4faf39673a6ecbfcee13ff73ff41434b35285a76 (patch)
tree9041b3cae43c74725d01605f5ab5b5185d7942ce /io_import_images_as_planes.py
parent3c4c1ed512c84ab06ec74fba5151b36062d639ec (diff)
update for changes in rna io_import_scene_mhx.py mapto isnt working as it should since this can now only be accessed as many bools
Diffstat (limited to 'io_import_images_as_planes.py')
-rw-r--r--io_import_images_as_planes.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/io_import_images_as_planes.py b/io_import_images_as_planes.py
index 61c88c46..50dd2cff 100644
--- a/io_import_images_as_planes.py
+++ b/io_import_images_as_planes.py
@@ -231,7 +231,11 @@ def getMaterial(tex, mapping):
# ... otherwise create new one and apply mapping.
if not mat:
mat = bpy.data.materials.new(name=tex.name)
- mat.add_texture(tex, texture_coordinates='UV', map_to='COLOR')
+ mtex = mat.texture_slots.add()
+ mtex.texture = tex
+ mtex.texture_coords = 'UV'
+ mtex.use_map_color_diffuse = True
+
mat.mapping = mapping
mat.name = tex.name