Explorar el Código

LDrawLoader: Make lines honor material opacity

yomboprime hace 6 años
padre
commit
51a9f30c4a
Se han modificado 1 ficheros con 5 adiciones y 1 borrados
  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;