blender/release/scripts/templates_osl/temperature_to_rgb.osl
Thomas Dinges 0440d77dbc Cycles / OSL:
* Add a few more OSL templates to the Text Editor, so people can use some of the OSL only shaders and closures.

* Temperature (Kelvin) to RGB converter
* Wavelength to RGB converter
* Ramp closure (Phong and Diffuse)
* Toon closure (Diffuse and Specular)
2013-05-01 13:21:15 +00:00

10 lines
136 B
Plaintext

shader temperature_to_rgb(
float Kelvin = 1200.0,
output color Color = 0.8)
{
/* Kelvin to RGB */
Color = blackbody(Kelvin);
}