[Closed] Opacity Mask Shadow with Pixel Depth Problem
I'm trying to achieve the same result of Uncharted 4 with the foliage so that the camera doesn't clip with it. I did a material with a pixel depth node (even try the perInstanceFadeAmount with a different problem). The result I want is there as the foliage is dithering as the camera get close but the problem is there's no shadow. As soon as I remove the pixel depth part the shadow is there? Is there a problem with using pixel depth and the shadow pass of the directional light?
the third image is the material function with the pixel depth and I multiply that to the opacity mask of the foliage
Any idea on the problem?
The question has been closed Jul 13 '16 at 07:47 PM by AndrewHurley for the following reason:
The question is answered, right answer was accepted
It seems like the shadow depth pixel shader is also multiplying the opacity mask by the pixel depth from the point of view of the light, and this is completely clipping the shadow away.
Instead of modifying the opacity mask, if you use the pixel depth to say tint the foliage a different color, does that work with the shadows? If so we'll have to find a way to exclude the pixel depth addition for the shadow depth pixel shader.
answered Jul 13 '16 at 07:41 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here