diff --git a/examples/js/exporters/GLTFExporter.js b/examples/js/exporters/GLTFExporter.js index c19474fc94076a675ca1950398ec7368f64bab28..c4cb3b2e5f62cbbd0d96a959b640caaf9a0cb2cd 100644 --- a/examples/js/exporters/GLTFExporter.js +++ b/examples/js/exporters/GLTFExporter.js @@ -1007,10 +1007,10 @@ THREE.GLTFExporter.prototype = { var forceIndices = options.forceIndices; var isMultiMaterial = Array.isArray( mesh.material ); - if ( ! forceIndices && isMultiMaterial ) { + if ( ! forceIndices && geometry.index === null && isMultiMaterial ) { // temporal workaround. - console.warn( 'THREE.GLTFExporter: Force index for a mesh with multi-material.', mesh ); + console.warn( 'THREE.GLTFExporter: Creating index for non-indexed multi-material mesh.' ); forceIndices = true; }