[Bf-extensions-cvs] [e7c7ef6] master: Fix T50235, wireframe transparency in UV layout export

Henrik Aarnio noreply at git.blender.org
Fri Dec 16 19:38:10 CET 2016


Commit: e7c7ef6be466111196c283f48b51c372e4167a88
Author: Henrik Aarnio
Date:   Fri Dec 16 19:37:20 2016 +0100
Branches: master
https://developer.blender.org/rBAe7c7ef6be466111196c283f48b51c372e4167a88

Fix T50235, wireframe transparency in UV layout export

Wireframes rendered over the solid mesh object in UV layout export would still have some transparency,
probably due to transparency sampling errors when solid object with transparency
would be rendered behind a wire object without transparency enabled.

Enabling transparency on the wire object but leaving it at the default alpha of 1 fixes this,
forcing better transparency sampling. Simple issue of changing render settings,
as UV layouts are actually rendered with Blender Internal.

Differential Revision: https://developer.blender.org/D2414

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

M	io_mesh_uv_layout/export_uv_png.py

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

diff --git a/io_mesh_uv_layout/export_uv_png.py b/io_mesh_uv_layout/export_uv_png.py
index 51daeb7..b556c98 100644
--- a/io_mesh_uv_layout/export_uv_png.py
+++ b/io_mesh_uv_layout/export_uv_png.py
@@ -110,6 +110,7 @@ def write(fw, mesh_source, image_width, image_height, opacity, face_iter_func):
     material_wire.type = 'WIRE'
     material_wire.use_shadeless = True
     material_wire.diffuse_color = 0, 0, 0
+    material_wire.use_transparency = True
 
     # scene render settings
     scene.render.use_raytrace = False



More information about the Bf-extensions-cvs mailing list