Forum: Poser - OFFICIAL


Subject: Trying to achieve good water

Daeshawn opened this issue on Mar 31, 2009 · 78 posts


bagginsbill posted Fri, 03 April 2009 at 8:10 AM

Quote - i think bounces are for self-reflection.
for example when you have two mirror balls they are reflecting themselfs.

That is one scenario where multiple bounces are needed. But self-reflection is not the only case. For example, the refraction seen through a drinking glass, which has to pass through inner and outer surfaces two times each to see what is behind the glass requires 4 bounces.

The confusion arises from counting the number of effects implemented in a shader as if that is the number of bounces. It is not. That is the number of extra rays that have to be evaluated.

In a single-layer material such as a water plane, the shader will generate a new ray to reflect the sky, and also a new ray to refract and show us what is under the water. That is two rays, but it is only one bounce. The number of bounces needed is the longest single path from the surface we're rendering (the primary surface) to other surfaces that have to be evaluated on behalf of the primary surface.

For example, when we need a reflection of the sky from the water, the water shader must call upon the sky shader to figure that out. So that is one bounce. The water shader must also call upon the ground shader for the refraction. That is also one bounce.

Now suppose we put an airplane flying low across the water. There is glass on the plane. We expect to see the reflection of the sky in the reflection of the glass on the water surface. So the total path length (bounces needed) is based on how many additional shader evaluations are needed IN ONE CHAIN. The water shader calls the airplane glass shader, which calls the sky shader. That's two bounces in one chain. The water shader also calls the sky shader directly in some places.

If the glass on the plane is lined up so that it reflects the metal on the wing, and the metal is reflective too, then the water consults the glass shader, the glass consults the metal shader, the metal consults the sky shader. That's 3 bounces.

If you have water that is displaced instead of just using bump, then you may want to include two bounces for when the ray from one wave strikes another wave, instead of reaching the sky. The wave #1 water shader consults the wave #2 water shader which consults the sky shader. That's two bounces. However, Poser has some flaws regarding ray-tracing and displacement. In most situations, the displacement stuff is ignored by the ray-trace evaluator (not always, but often). The result is that if the water surface is actually flat, it is unusual for the reflected ray to actually hit another spot of water. Usually it doesn't see displaced waves. It might, however, see another spot of un-displaced water plane and generate a reflection of the un-displaced water plane. This usually doesn't look right, but sometimes its ok. We're getting into very specific and unusual situations now, that are not based on physics but rather on the specific ways that Poser mis-behaves.

In my case, I find that the reflections from displaced surfaces are very difficult to get right and require a lot of fudging of ray-bias, even if we only ask for one bounce to get the sky reflected in the water. That's why I usually do not bother with displacement on water, and only use bump. The reflections from a bump-driven surface work much better in Poser than a displacement-driven surface.


Renderosity forum reply notifications are wonky. If I read a follow-up in a thread, but I don't myself reply, then notifications no longer happen AT ALL on that thread. So if I seem to be ignoring a question, that's why. (Updated September 23, 2019)