I found this PG example of how to load a file from disk like the sandbox does it using FileInput
my question is if I use use file button to pick the file how do i use FileInput with this? do I need to convert the file to a blob first?
I found this PG example of how to load a file from disk like the sandbox does it using FileInput
my question is if I use use file button to pick the file how do i use FileInput with this? do I need to convert the file to a blob first?
Do you mean HTML <input type="file">
element?
Here is the example how it can be done.
@labris this seems to work as long as I include the babylon inspector as a dev dependency. Which is super weird. Without the inspector I get this error:
webRequest.ts:185 Not allowed to load local resource: file:///SimpleBox.glb
Here is the PG - https://playground.babylonjs.com/#BN1ASL#3
Probably the error you have is related to your environment?
think I solved it. I needed to import the gltf plugin and seraizlizer when not using the inspector . (the inspector has that build in).