Hi all, I’m new here and 99% noob to Babylon. I’ve played a little with the sandbox and playground and a little with the desktop app. Here’s my challenge:
I create .GLB and .OBJ content in Photoshop and Sketchup, upload it to my domain in order to share it with others through a simple URL. I think the Babylon Viewer would be great to enable that. So what I need is a an HTML-index file (to share) with Babylon js code that I can use over and over by only changing the url of my .GLB file.
My question: are there templates available that I can use for that?
It’s probably very simple code to produce, but it’s not working for me.
Thanks. When I tried and replaced the example boombox model with my own model it gave me an “error loading the model”.
Should the viewer and the model be in the same directory?
restructured case sensitivity. I uploaded the boombox example to my domain, same error.
It may be my domain settings. I’ll contact my provider. Thank you so much. Highly appreciated. Link
I had to add AddType application/babylon .babylon
to my .htaccess to get the .babylon files loaded into my website without errors. Maybe you try to add AddType model/gltf-binary .glb
or AddType model/gltf-bin .glb
in your .htaccess file?
Please dont rely on the pages cause I am new to babylon, too, and still learn how to do things, so there might be bugs and stupidness in my solution. And the pages might change soon… Anyway, take a peek and let me know how it works for you.
Thanks! It’s working. I copied and pasted your code on to my domain and it worked. Then I replaced the parts with my own code and it kept working! Happy as a clam!
Now I need to optimize my glb models… link
Thanks bud, highly appreciated