Ver código fonte

LDrawLoader: Make lines honor material opacity

yomboprime 6 anos atrás
pai
commit
51a9f30c4a
1 arquivos alterados com 5 adições e 1 exclusões
  1. 5 1
      examples/js/loaders/LDrawLoader.js

+ 5 - 1
examples/js/loaders/LDrawLoader.js

@@ -1288,7 +1288,11 @@ THREE.LDrawLoader = ( function () {
 			if ( ! edgeMaterial ) {
 
 				// This is the material used for edges
-				edgeMaterial = new THREE.LineBasicMaterial( { color: edgeColour } );
+				edgeMaterial = new THREE.LineBasicMaterial( {
+					color: edgeColour,
+					transparent: isTransparent,
+					opacity: alpha
+				} );
 				edgeMaterial.userData.code = code;
 				edgeMaterial.name = name + " - Edge";
 				edgeMaterial.userData.canHaveEnvMap = false;