Rendering issue when changing visibility of an alpha tested plane

Hi All,

I recently bumped the nwjs version of a project of mine as a test(0.29 > 0.59) and noticed there was some weird behavior in Babylon after the update:

In this example animation there are two alpha tested planes with a pixel art texture that have their visibility animated over time.
When animating from visibility 0 to 1 and when the plane becomes fully visible again the transparent pixels of the mesh flash black for what seems to be a frame. Oddly this only seems to occur once per plane.

I’m not sure if there’s something I never configured properly that was hidden by the older nwjs version or if there is something deeper going on.
I can always bump the version back down, but it would be nice to be able to properly use the latest version.

Any input would be appreciated.

this probably happens with async shader compilation during shader transition I would suspect ?

Could you repro in the playground it would be really helpful to try out.

I was able to get it to reproduce: Babylon.js Playground

Interestingly the flash does not happen in Firefox, but does in Chrome and Edge.

yup, as a workaround you can disable parallel shader compilation like this:

That works!
Thank you very much!