This is a simple shader that applies a gamma and a gain (multiplication) of a color or map. It provides an alternative way of controlling gamma in 3ds Max. Many similar shaders exist in various OEM integrations of mental ray, so you also can use this shader for standalone mental ray and for cross-platform phenomena development.
The shader can also be used as a simple gamma lens shader, in which case the input is not used, but the eye ray (cast directly from the camera; one per pixel) color is used instead. Thus, while the Gamma & Gain shader generally applies the gamma tweak to the color you put into it, if you use it as a lens shader, it will become a "gamma tweaker" shader for the picture itself, not just the input color (which is ignored).
Specifies the input color or map.
The gamma applied to the input.
The multiplier for the input.
When off, the shader takes the input, multiplies it by the Gain value, and then applies a gamma correction of Gamma to the color. When on, the shader takes the input, applies a reverse gamma correction of Gamma to the color, and then divides it by the Gain value.