Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gpu_shader_material_output_world.glsl « material « shaders « gpu « blender « source - git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 5eb853a4c1a12ece8741e86948e24289fff4fa63 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
uniform float backgroundAlpha;

void node_output_world(Closure surface, Closure volume, out Closure result)
{
#ifndef VOLUMETRICS
  float alpha = renderPassEnvironment ? 1.0 : backgroundAlpha;
  result = CLOSURE_DEFAULT;
  result.radiance = surface.radiance * alpha;
  result.transmittance = vec3(0.0);
  result.holdout = (1.0 - alpha);
#else
  result = volume;
#endif /* VOLUMETRICS */
}