demotool/test/lib/fog.glsl
Emmanuel BENOîT 68d01ca42e Shaders - Relative paths
Shaders are no longer found under /shaders in the project; they can be
anywhere. In addition, paths for both (program) instructions in the
script and include directives in shader source code are relative to the
file which contains them.
2017-12-29 11:33:15 +01:00

10 lines
190 B
GLSL

//! type library
vec3 FOG_Apply(
in vec3 color ,
in float dist ,
in float attenuation ,
in vec3 background )
{
return mix( background , color , exp( - dist * dist * attenuation ) );
}