Hi,
we were trying to create the shader for a river, and for more realism the fog was a great parameter to play with for the water, but then, when rendering the shallow parts, we realized that the objects underneath the water were not casting shadows on the riverbed.
We found out two things: the plane used for the water was casting shadows (no idea why, we disabled the cast shadow render stat in the shape, even though raytracing was supposed to get rid of that), and then we realized that the fog made the direct light completely disappear under the water, even in the shallow parts. We tried different values. High and low value in color, high and low in saturation, high and really low in the fog multiplier and in the bias. If we have fog there's no direct light. The only thing we saw was that if we used a really saturated color, then the direct light would appear in the render with that color, independent of the depth underneath the water.
We would want a water shader that gets foggier depending on the depth of the riverbed underneath, so having the shallow parts cristal clear, and with the objects underneath casting shadows.
For the fog, is the affect all channels the way to go? or color only?
Probably we are using the parameters in the wrong way or expecting results that don't work with that parameters.
Any ideas?
Thanks!
Gianluca
we were trying to create the shader for a river, and for more realism the fog was a great parameter to play with for the water, but then, when rendering the shallow parts, we realized that the objects underneath the water were not casting shadows on the riverbed.
We found out two things: the plane used for the water was casting shadows (no idea why, we disabled the cast shadow render stat in the shape, even though raytracing was supposed to get rid of that), and then we realized that the fog made the direct light completely disappear under the water, even in the shallow parts. We tried different values. High and low value in color, high and low in saturation, high and really low in the fog multiplier and in the bias. If we have fog there's no direct light. The only thing we saw was that if we used a really saturated color, then the direct light would appear in the render with that color, independent of the depth underneath the water.
We would want a water shader that gets foggier depending on the depth of the riverbed underneath, so having the shallow parts cristal clear, and with the objects underneath casting shadows.
For the fog, is the affect all channels the way to go? or color only?
Probably we are using the parameters in the wrong way or expecting results that don't work with that parameters.
Any ideas?
Thanks!
Gianluca
Comment