I have figured out to give an object url to a local file selected through an input type file. If this file is glb it is appended to the scene as I want. If it is a gltf it cannot be appended, and an error on console says:
BJS - [15:03:01]: Unable to load from blob:http://127.0.0.1:8887/ca4a2c45-95e1-40a3-8488-1d3a33a0f0c5: Unexpected magic: 1969300091
I think this can be due to its accompanying files. How to load a local gltf file which has a .bin file and possibly other assets too.
Note: all of the files are in the local file system.
I have changed input element to multiple. But I have textures in a texture directory. Only the .bin file is next to .gltf file. These are coming like that and also encoded like that inside the .gltf file.
It definitely is. Anyways. I will try to hack it out. I have an idea. When I am done I will share it here.
Hint: involves modified version of a babylon/gltf scene object and object URLs with a bunch of caveats.