From 9020017a802f693a1b00d28921af1b9b76c514c0 Mon Sep 17 00:00:00 2001 From: Takahiro Date: Sun, 8 Jan 2017 19:44:46 -0800 Subject: [PATCH] Support non-declared buffer.type --- examples/js/loaders/GLTFLoader.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/examples/js/loaders/GLTFLoader.js b/examples/js/loaders/GLTFLoader.js index db614c75c7..08355c4b28 100644 --- a/examples/js/loaders/GLTFLoader.js +++ b/examples/js/loaders/GLTFLoader.js @@ -694,7 +694,7 @@ THREE.GLTFLoader = ( function () { return _each( json.buffers, function ( buffer ) { - if ( buffer.type === 'arraybuffer' ) { + if ( buffer.type === 'arraybuffer' || buffer.type === undefined ) { return new Promise( function ( resolve ) { @@ -708,6 +708,10 @@ THREE.GLTFLoader = ( function () { } ); + } else { + + console.warn( 'THREE.GLTFLoader: ' + buffer.type + ' buffer type is not supported' ); + } } ); -- GitLab