setMaterialForRendering not work after resizing renderTargetTexture

pg: https://playground.babylonjs.com/#NV0C09#1
The problem is renderPassId of renderTargetTexture changes after resizing, so the infos stored on mesh._internalAbstractMeshDataInfo._materialForRenderPass not work anymore.
I noticed this PR only fixed the problem with effectLayer but not renderTargetTexture.

This PR will fix the problem:

1 Like