Amplification Shader

This little OSL shader applies an amplification factor to another shader. The factor can be more than 1, so for example you can create a material that reflects more light than impinges on it!

That may sound physically impossible, but it could be used for example to fake real-world fluorescence effects, like high-visibility vests and the like. These materials reflect visible light which is augmented by the energy of incoming (invisible) ultraviolet light, which is why they can look so bright, without actually being emissive.

shader amplify
  (
    closure color In = 0,
    float Factor = 1.0,
    output closure color Out = 0
  )
  /* multiplies In by Factor. */
  {
    Out = In * Factor;
  } /*amplify*/

You can do this without OSL. Just set your material colour RGB values to > 1.0 (or use a math nodes set to multiply between a split RGB node and your colour input)

I have used just such an approach on fluorescent materials in the past.

Can you upload a screenshot of the node setup you mention?

Not specifically the material I was talking about - but here is another application where I used RGB values above 1.

Basically, scaling a Closure Color is the same as scaling the color you feed into the closure. No other magic here, and this script is only usefull if we want to scale lots of closures together (as Closure Color can be an array of [Closure*Color])!

Ok, thanks for the answers! :slightly_smiling_face: