Load Unity toolkit into Viewer?

Is there a way to load the babylon.toolkit.js into the Viewer to use Unity exported scenes ?

I know that you can change the exporter settings in Unity to Right Hand, disable Unity meta and change submesh to Primitives and it work but if possible I would like to be able to export cameras from the unity scenes to be able to switch the viewer to different scene cameras.

Here is what I did and here is what happen.

If not possible, what alternative do I have to set the viewer to view specific screne object ?

cc @MackeyK24

I re-installed everything using the ES6 NPM packages and initialised everything (canvas, engine, scene, camera, renderer)

Also managed to target specific exported mesh from the Unity Scene in that way (this is hardcoded for testing) :

However, I would still like to know why I can’t manage to load the toolkit even after including ALL files from exported engine.html

image

Still get the error Required extension CVTOLLS_BABYLON_MESH

Probably this thread may be helpful - Require extension CVTOOLS_babylon_mesh is not available

What viewer are you talking about. You should be able to load the babylon.toolkit.js on your host page or at runtime.

Here is an Example Starter Playground with Babylon Toolkit loaded. So I dont know why your environment would not load

I read the post mentioned above and I saw your example and I don’t understand either what I am missing. I exported all libraries from Engine.html in the unity export folder to my Web application, I load them in my angular App. I added all ES6 libraries and setuped the engine and scene as you can see in my second post but when I try to load GLTF that has unity meta enabled I get the NO_TOOLKIT error.

You must not be loading the babylon.toolkit.js properly or at the correct time.

IF you wanna hop on a call and show me your project setup, i am sure i can find the issue.

Send me a google meet invite, ill will be available for next few hours

FYI… You only need the one file for my toolkit… that is babylon.toolkit.js

All the other scripts loaded in the engine.html is for when you using the built-in web project deployment options… An i am generating an entire web viewer project for you that you can deploy
out the box

Thanks i will be at the office in 20 minutes and send meet