Browse Source

Add error message

Paul Masson 7 years ago
parent
commit
03cdce0108
1 changed files with 6 additions and 0 deletions
  1. 6 0
      src/core/DirectGeometry.js

+ 6 - 0
src/core/DirectGeometry.js

@@ -139,6 +139,12 @@ Object.assign( DirectGeometry.prototype, {
 		var hasSkinWeights = skinWeights.length === vertices.length;
 
 		//
+		
+		if ( faces.length === 0 ) {
+
+			console.error( 'THREE.DirectGeometry: Faceless geometries are not supported.' );
+
+		}
 
 		for ( var i = 0; i < faces.length; i ++ ) {