How does a 'map to' texture affect shader BDRF values?

I’ve always wondered how the grey values of a texture affect the BRDF values used in the ‘Shaders’ panel. I’m talking about textures used in a ‘Map to’ channel that affects BRDF values (Ref, Spec, Hard). Yesterday I was doing some tests with a black & white texture, and I’ve come to the conclusions I explain with the graphics below. I’ve used the REF chanel as example.

The texture affects only the range between the value set in the ‘Shaders’ panel and the maximun available for that BRDF model, therefore the value defined in ‘shaders’ act as bottom limit.

(using Var and Dvar default values)

http://img147.imageshack.us/img147/925/maptopn3.png

I’ve always used these settings intuitively, but I think it is about time to understand how these things really work.

b-u-m-p b-u-m-p

That’s pretty cool to know.

How about if you inverse map it (the two-click yellow-text thing on the REF button or whatever); would that make this example range from 50% for white and 0% for black?

That’s what the Destination Value (Dvar) is for. The texture tells you how much it is achied to reach this value. If you really want the full range of values, you have to set (e.g.) the Ref-Value to zero in the shaders panel. Or set it to 1 and the Dvar to 0.

Yes, as I have concluded in the first post, the part afected by black remains invariable. Only parts textured with white are affecting the shader REF percentages.

This is the same texture and material, but with DVar = 0.50 and DVar = 0

http://img408.imageshack.us/img408/7571/mapto50ye9.png
http://img408.imageshack.us/img408/2158/mapto00et7.png

In this case, it is the white part which remains invariable. Black and White parts just exchange functions (Dvar =1)

http://img457.imageshack.us/img457/5751/mapto100inversepu7.png

My last image on this serie, I wanted somewhat to get the experiment finished.
This time is the ‘Var’ value that changes, and the result is that the range of shader values affected by the texture is shortened.

When ‘Var’ is equal to 1, the white part of the texture results in the maximun value available of REF. The range of REF affected by the texture is from 50% to 100%, 50 points (post nº 1)

When ‘Var’ is equal to 0.50, the white part of the texture results only in a 75% of REF, which means that the range of REF affected by the texture is shortened by half (from 50% to 75%, 25 points)

Shader REF value is not affected by the black part, like in the previous cases when the texture is not ‘inverted’ (previous post)

To understand the serie, check the images in order, from the first post to this one.
These cases should be applicable to the other ‘Map to’ channels when shader values are affected (Spec, Hard)
You can extrapolate these results to common textures applied to those channels.

http://img528.imageshack.us/img528/4249/maptovargm7.png

I hope you have enjoyed the experience. :stuck_out_tongue: :eyebrowlift: