Преглед изворни кода

fix set automatic .transparent NodeMaterial (#9243)

* fix set automatic .transparent NodeMaterial

* minimalist optimization
sunag пре 9 година
родитељ
комит
8deb302295
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      examples/js/nodes/NodeMaterial.js

+ 1 - 1
examples/js/nodes/NodeMaterial.js

@@ -210,7 +210,7 @@ THREE.NodeMaterial.prototype.build = function() {
 	}
 	}
 
 
 	this.lights = this.requestAttrib.light;
 	this.lights = this.requestAttrib.light;
-	this.transparent = this.requestAttrib.transparent;
+	this.transparent = this.requestAttrib.transparent || (this.blendMode !== THREE.NormalBlending && this.blendMode !== THREE.NoBlending);
 
 
 	this.vertexShader = [
 	this.vertexShader = [
 		this.prefixCode,
 		this.prefixCode,