added glb support

This commit is contained in:
Leon van Kammen 2023-04-21 17:42:13 +02:00
parent fcf6fa973b
commit 0198bbba93

View file

@ -210,7 +210,7 @@
let fileLoaders = loadFile({
".gltf": (file) => file.arrayBuffer().then( (data) => loader.parse( data, '', loadGLTF, console.error ) ),
".glb": (file) => loader.parse( file.arrayBuffer(), '', loadGLTF, console.error )
".glb": (file) => file.arrayBuffer().then( (data) => loader.parse( data, '', loadGLTF, console.error ) )
})
document.querySelector("#overlay > input").addEventListener("click", fileLoaders )