R2 Shaders
Functions | Variables
R2LightDirectionalDebugConstant.h File Reference

A trivial directional light that simply ignores the surface and applies a constant color. More...

#include "R2LightShaderMain.h"
#include "R2LightDirectional.h"
Include dependency graph for R2LightDirectionalDebugConstant.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

R2_light_output_t R2_deferredLightMain (const R2_reconstructed_surface_t surface)
 

Variables

uniform R2_light_directional_t R2_light_directional
 

Detailed Description

A trivial directional light that simply ignores the surface and applies a constant color.

Definition in file R2LightDirectionalDebugConstant.h.

Function Documentation

§ R2_deferredLightMain()

R2_light_output_t R2_deferredLightMain ( const R2_reconstructed_surface_t  surface)

Calculate light values for the current light, based on the current contents of the G-buffer.

Parameters
surfaceReconstructed surface data taken from the G-Buffer
Returns
Calculated light values

Definition at line 13 of file R2LightDirectionalDebugConstant.h.

15 {
16  return R2_light_output_t(
17  R2_light_directional.color,
18  R2_light_directional.color);
19 }
vec3 color
The light color. The components are assumed to be in the range [0, 1].
The type of light values that all deferred light shaders calculate.
Definition: R2LightOutput.h:9