浏览代码

Mesh/Line/Points: Always use white as default color.

Mugen87 5 年之前
父节点
当前提交
ec0a08c3a2
共有 3 个文件被更改,包括 3 次插入3 次删除
  1. 1 1
      src/objects/Line.js
  2. 1 1
      src/objects/Mesh.js
  3. 1 1
      src/objects/Points.js

+ 1 - 1
src/objects/Line.js

@@ -30,7 +30,7 @@ function Line( geometry, material, mode ) {
 	this.type = 'Line';
 
 	this.geometry = geometry !== undefined ? geometry : new BufferGeometry();
-	this.material = material !== undefined ? material : new LineBasicMaterial( { color: Math.random() * 0xffffff } );
+	this.material = material !== undefined ? material : new LineBasicMaterial();
 
 }
 

+ 1 - 1
src/objects/Mesh.js

@@ -47,7 +47,7 @@ function Mesh( geometry, material ) {
 	this.type = 'Mesh';
 
 	this.geometry = geometry !== undefined ? geometry : new BufferGeometry();
-	this.material = material !== undefined ? material : new MeshBasicMaterial( { color: Math.random() * 0xffffff } );
+	this.material = material !== undefined ? material : new MeshBasicMaterial();
 
 	this.updateMorphTargets();
 

+ 1 - 1
src/objects/Points.js

@@ -22,7 +22,7 @@ function Points( geometry, material ) {
 	this.type = 'Points';
 
 	this.geometry = geometry !== undefined ? geometry : new BufferGeometry();
-	this.material = material !== undefined ? material : new PointsMaterial( { color: Math.random() * 0xffffff } );
+	this.material = material !== undefined ? material : new PointsMaterial();
 
 	this.updateMorphTargets();