I create models in Blender and import the .glb to Babylon. In the past, I used the SceneLoader.ImportMesh function but I wanted to move to the SceneLoader.ImportMeshAsync.
Here is a Playground with both methods: https://playground.babylonjs.com/#SFW46K#1035
If you run the bottom one, the old way, it will work. The garment is framed up tight in the window.
If you run the top one with the camera limits in the async, they don’t work at all. If you move them outside the async it does work, the zooming up feature is good but the garment is not centered.
This process only highlights that the async is more accurate because the old code seems to depend on the camera limits being set before the model is completely loaded. That’s a bit dangerous.
How can I use the async method and keep the garment squared and zoomed up to the camera? I would really like to understand what is going on too, if someone could explain.
Thank you for your consideration and time.