我使用three.js editor file中的import功能导入fbx模型为黑色,不知道为什么....
// Import
var fileInput = document.createElement( 'input' );
fileInput.type = 'file';
fileInput.addEventListener( 'change', function ( event ) {
editor.loader.loadFile( fileInput.files[ 0 ] );
} );
var option = new UI.Row();
option.setClass( 'option' );
option.setTextContent( 'Import' );
option.onClick( function () {
fileInput.click();
} );
options.add( option );
//
options.add( new UI.HorizontalRule() );
源代码是这样的
加灯光就好了,一开始都是黑的