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:
authorBastien Montagne <montagne29@wanadoo.fr>2015-03-21 14:20:57 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2015-03-24 18:04:23 +0300
commit06adc998b17cc6505b22ff3ade04c559693aea29 (patch)
treefccccfb37cae514649272caaef57251d36506e2b
parent0b2806d722ab1e5e1a3daee924afdcc66c4d2372 (diff)
Fix T44060: 2.74RC2: Import Images as Plane: no alpha when open an image with Cycles engine.
UseAlpha & co are image settings, they are not bound to any specific render engine. To be backported to final 2.74.
-rw-r--r--io_import_images_as_planes.py13
1 files changed, 8 insertions, 5 deletions
diff --git a/io_import_images_as_planes.py b/io_import_images_as_planes.py
index df727a6b..4940ebce 100644
--- a/io_import_images_as_planes.py
+++ b/io_import_images_as_planes.py
@@ -19,8 +19,8 @@
bl_info = {
"name": "Import Images as Planes",
"author": "Florian Meyer (tstscr), mont29, matali",
- "version": (2, 0, 0),
- "blender": (2, 73, 0),
+ "version": (2, 0, 1),
+ "blender": (2, 74, 0),
"location": "File > Import > Images as Planes or Add > Mesh > Images as Planes",
"description": "Imports images and creates planes with the appropriate aspect ratio. "
"The images are mapped to the planes.",
@@ -271,6 +271,11 @@ class IMPORT_OT_image_to_plane(Operator, AddObjectHelper):
row.active = bpy.data.is_saved
row.prop(self, "relative")
box.prop(self, "match_len")
+ row = box.row()
+ row.prop(self, "use_transparency")
+ sub = row.row()
+ sub.active = self.use_transparency
+ sub.prop(self, "alpha_mode", text="")
box.prop(self, "use_fields")
box.prop(self, "use_auto_refresh")
@@ -278,8 +283,6 @@ class IMPORT_OT_image_to_plane(Operator, AddObjectHelper):
if engine == 'BLENDER_RENDER':
box.label("Material Settings: (Blender)", icon='MATERIAL')
box.prop(self, "use_shadeless")
- box.prop(self, "use_transparency")
- box.prop(self, "alpha_mode")
row = box.row()
row.prop(self, "transparency_method", expand=True)
box.prop(self, "use_transparent_shadows")
@@ -442,6 +445,7 @@ class IMPORT_OT_image_to_plane(Operator, AddObjectHelper):
return material
def set_image_options(self, image):
+ image.use_alpha = self.use_transparency
image.alpha_mode = self.alpha_mode
image.use_fields = self.use_fields
@@ -452,7 +456,6 @@ class IMPORT_OT_image_to_plane(Operator, AddObjectHelper):
pass
def set_texture_options(self, context, texture):
- texture.image.use_alpha = self.use_transparency
texture.image_user.use_auto_refresh = self.use_auto_refresh
if self.match_len:
texture.image_user.frame_duration = texture.image.frame_duration