customDepthMaterial vertex shader

Hello. I have a problem with vertex shader on depth material.
I changed vertex shader on MeshPhongMaterial and also apply this changes on MeshDepthMaterial for correct shadows.
on R142 all works fine. But now I updated to R147 and .onBeforeCompile on MeshDepthMaterial isn’t calls. How it works now?

I just tested onBeforeCompile with R147 on MeshDepthMaterial and it fires. Does it throw any errors?

With this you don’t need to manually replicate the modifications to the shadow material btw. Tested with R147 too.

No any error.
I tried to find in witch version this happens:

I forgot my plugin actually makes that customDepthMaterial can be used on materials instead on the mesh, it might be possible this is now default.

1 Like

customDepthMaterial acts a little strange in r147. Possibly related. Could try this patch and see if it works for you.

1 Like