I have a project where I load multiple single .glb files into a single scene. Inside a for-loop (in which I iterate over every file) I load every single file with BABYLON.SceneLoader.LoadAssetContainer("path", "file.glb", scene, function (container) { }); into a container. After the for loop is completed i add all Eelemnts inside the container with container.addAllToScene();
My Problem is now that the files get loaded all really slow into the scene and not as a complete mesh but as a single mesh each single one. The process of the loading takes up to much time.
What is the optimal way of loading multiple single .glb files?
Is it possible that the reason for the slow loading process is that i try to load multiple single meshes?
After some resarches we realised that the solution for it probably will be merging multiple gltf arrays into one big array. Now what is the easiest solution for that?
As opposed to SceneLoader.LoadAssetContainer, which blocks your application thread until a single mesh has loaded before beginning loading the next one.
Don’t listen to me, both apis behave identically under the hood.