I have created a scene with a few custom mesh objects. My scene with custom meshes reloads and crashes when I open the application on my phone browsers (chrome, safari, brave). My scene loads my 3d objects one at a time. My scene utilizes Assets Manager, my objects are added as tasks to Assets Manager, and Assets Manager loads after each object is added as a task. For my iPhone 8, the crash happens when I load my 3rd object. For my iPhone 12, the crash happens with I load my 5th object. My desktop have no problems loading all my objects one after another.
I believe I have narrowed down the problem to the rendering of the objects after the load. I created a simple scene utilizing one Assets Manager load function execution. My scene crashes on iPhone 8 browsers when I call Assets Manager to load 3 tasks. My scene crashes on iPhone 12 browsers when I call Assets Manager to load 5 tasks. The browser window reloads and/or crashes after those objects are added to the scene. My scene will some times load all the objects, but crashes on interaction.
At first, I suspected that it had to do with the size of the objects and created a scene to load small babylon mesh objects. My scene was able to handle the loading of the small babylon mesh objects and not crash on my iPhone 8. I replaced the small babylon mesh objects with much large babylon assets in my scene and was able to load the scene with the large babylon assets(total size of large babylon assets 2x the total of my custom mesh objects). I was able to interact with the scene with large babylon assets. This led me to believe that it is not precisely a size different issue.
I also tried a few optimization techniques from Optimizing Your Scene | Babylon.js Documentation. I implemented scene.freezeActiveMeshes() and mesh.freezeWorldMatrix() on my objects after the loading. I also assigned scene.autoClear = false and scene.autoClearDepthAndStencil = false. This was not effective in preventing the crash on my iPhone 8.
I was able to load https://playground.babylonjs.com/#0K8EYN#0 on my iPhone 8, but cannot load my scene with my custom mesh objects.
May I have some help identifying what issues the mobile browsers may have with our scene?