Problem with Safari - mesh not visible

Hi there,
i’ve found a strange behaviour when i run my application on Safari (with Chrome and Chromium all work fine).
I tried to reproduce the issue in PG but without success, so i try to explain what’s the problem.
I’ve a scene in which first i load some environment and then meshes with materials made with node mterial with some textures.
When i run the scene i got no errors but these meshes are invisible!


As you can see i use some glow effects to higlight meshes: meshes are there, i can get them using scene.getMeshByID and all the properties for visibility are set to true (isVisibile, setEnabled, etc).
What i don’t understand is that, if i rebuild the scene (only the scene), it works. If i start the app from the beginning (build the engine, the scene, etc) it fails.
All the textures and external meshes are hard coded in base64 to avoid CORS issues.

The correct scene should be displayed like that:

I know is very difficult to help without a repro, but can you figure out what could be the problem? Any idea on parameters to double check?
Thank you in advance!

It can be some async problems: are you sure you have downloaded all of your assets before working with them?

If you use SceneLoader.ImportMesh or SceneLoader.Append, make sure you are using the onSuccess callback to start working with your scene and not do it from the main flow of code.

Hi @Evgeni_Popov and thank you for your quick reply.
I use Async functions but always with await-async keywords.
This is the function i use to import external mesh hard coded in base64 and i always call it with await:

async __insertNewMesh(scene,ext,model,option){
        const url = URL.createObjectURL(await this.__b64ToBlob(model));                
        const fileExtension = ext;
        let impMesh = await BABYLON.SceneLoader.ImportMeshAsync(
            "",
            url,
            "",
            scene,
            null,
            fileExtension
        );           
        ....
        other code
        ....
}

in the main flow i call it in this way:

await __insertNewMesh(...)

I also suspect is an async problem, but why on Safari only?

It could be that Safari is doing some things slower/faster than other browers, so an async problem would show up in this browser but not in others.