First Image → Normal working
Second Image → When clicking replace chair with image
Replace function steps:
- disable the previous mesh
- dispose the previous mesh
- import a new mesh and place it at the required position
Third Image → Replace mesh function
Fourth Image → On moving the surrounding with the mouse control, the room mesh gets flickered. This does not happen that often. But it does.
Question1: Why does the first table flicker like that seen on the second image on replacing another mesh ?
Question2: Why does the room mesh flicker ?
Any answers or suggestions are welcome.
Unfortunately, I could not make up a playground because the assets are private.
That’s hard to say without a reproduction.
If you can reproduce that with any other asset it means that this is something we can help with for sure! If it only happens with this one single model, it might be related to the model itself (though I am pretty sure it is not a model-related issue only).
Could you try making a playground with a publicly-available asset?
I will try and get a playground url @RaananW
I agree. Looks more like an issue related to env or reflection coordinates/matrix. May be you have somehow linked these to your mesh or material and next when you move or dispose of the mesh or material, it breaks?
Unfortunately, I could not reproduce it in a playground. But I fixed it using setTimeout().
Just settimeout the required functions with time=0 for easy loading.