浏览代码

Bug fix for OBJLoader.js

For vertex color, we should parse it as long as we have more than 7 elements in the line that starts with `"v "`.
Peihong 6 年之前
父节点
当前提交
e97e6614d7
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      examples/js/loaders/OBJLoader.js

+ 1 - 1
examples/js/loaders/OBJLoader.js

@@ -459,7 +459,7 @@ THREE.OBJLoader = ( function () {
 								parseFloat( data[ 2 ] ),
 								parseFloat( data[ 3 ] )
 							);
-							if ( data.length === 8 ) {
+							if ( data.length >= 7 ) {
 
 								state.colors.push(
 									parseFloat( data[ 4 ] ),