forked from blender/blender
main sync #3
@ -671,6 +671,7 @@ class ShaderImageTextureWrapper():
|
||||
tree.links.new(node_image.outputs["Alpha" if self.use_alpha else "Color"], self.socket_dst)
|
||||
if self.use_alpha:
|
||||
self.owner_shader.material.blend_method = 'BLEND'
|
||||
self.owner_shader.material.show_transparent_back = False
|
||||
|
||||
self._node_image = node_image
|
||||
return self._node_image
|
||||
|
@ -315,6 +315,7 @@ static void set_bsdf_socket_values(bNode *bsdf, Material *mat, const MTLMaterial
|
||||
}
|
||||
if (do_tranparency || (alpha >= 0.0f && alpha < 1.0f)) {
|
||||
mat->blend_method = MA_BM_BLEND;
|
||||
mat->blend_flag |= MA_BL_HIDE_BACKFACE;
|
||||
}
|
||||
|
||||
if (mtl_mat.sheen >= 0) {
|
||||
@ -393,6 +394,7 @@ static void add_image_textures(Main *bmain,
|
||||
else if (key == int(MTLTexMapType::Alpha)) {
|
||||
link_sockets(ntree, image_node, "Alpha", bsdf, tex_map_type_to_socket_id[key]);
|
||||
mat->blend_method = MA_BM_BLEND;
|
||||
mat->blend_flag |= MA_BL_HIDE_BACKFACE;
|
||||
}
|
||||
else {
|
||||
link_sockets(ntree, image_node, "Color", bsdf, tex_map_type_to_socket_id[key]);
|
||||
|
Loading…
Reference in New Issue
Block a user