Browse Source

LDrawLoader: Make lines honor material opacity

yomboprime 6 years ago
parent
commit
51a9f30c4a
1 changed files with 5 additions and 1 deletions
  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;