Forum: Poser - OFFICIAL


Subject: Please help me get reflection : (

jjroland opened this issue on May 08, 2007 · 212 posts


bagginsbill posted Sun, 08 March 2009 at 7:53 AM

If you have been reading the thread "Nodes for Dummies", you'd have heard me discussing hyper-colors and hypo-colors. A hyper-color is one with an RGB component that is more than 1, which is what you're asking for here.

Now there are many ways to produce hyper-colors in Poser, although you cannot directly SEE any of them. The simplest way is to take an existing color and multiply it with a big number. For example, if you start with RED  RGB(255, 0, 0), which is numerically [1, 0, 0] and you multiply by 5, you will get [5, 0, 0], a hyper color. And when you look at that in a slightly reflective surface, such as plastic, with a 2% reflectivity, you will see the red reflection at .02 * 5 = .1.

The easiest way to get a self-lit hyper-colored ball is to put the color or node you want into the Ambient_Color, and set the Ambient_Value to a high number. (Because the output of that channel is the product of color and value - just what you need.) The effective color is Ambient_Color * Ambient_Value.

You did not say whether this ball is to be self-lit or lit by other things. If self-lit, the red ball should have Diffuse_Value = 0 and Specular_Value = 0.

As for how to handle reflections the GC way, that is simple. If we assume that all surfaces in the scene are GC, that means they are sRGB and not linear. So you need to convert to linear for the calculation.

Add a Reflect node. Connect that to a Color_Math:Pow.Value_1. Connect Value_2 to a gamma number, such as the 2.2 I usually have. This two-node combo gives you linear reflections, even though everything in the scene is using non-linear shaders now.

Once you have that, you add it to your diffuse and specular as usual, using Color_Math:Add nodes, or by using a Blender. Your choice, how to connect. (When doing the Fresnel effect, remember that we need reflection_strength + diffusion_strength = a constant less than 1)

Once the Diffuse + Specular + Reflection has been combined in the right ratios, you gamma-correct the result (power 1/2.2) and plug into Alternate_Diffuse.
 
The general form looks something like this:

( Blender(Diffuse(...), Reflect(...), fresnelValue) + Blinn(...) ) ** (1 / 2.2)


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)