donmccurdy / three-gltf-viewer

Drag-and-drop preview for glTF 2.0 models in WebGL using three.js.
https://gltf-viewer.donmccurdy.com/
MIT License
2.09k stars 534 forks source link

how to show certain file #293

Closed mliris closed 2 years ago

mliris commented 2 years ago

Hi, you project is amaizing, I have a set of glb files on server, how can I send link to show the certain file, already uploded?

donmccurdy commented 2 years ago

Hi! If your GLB files are hosted with the correct CORS headers, you can create links to them with the #model=$URL parameter:

https://gltf-viewer.donmccurdy.com/#model=https://raw.githack.com/KhronosGroup/glTF-Sample-Models/master/2.0/DamagedHelmet/glTF-Binary/DamagedHelmet.glb