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

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClément Foucault <foucault.clem@gmail.com>2018-11-08 21:17:41 +0300
committerClément Foucault <foucault.clem@gmail.com>2018-11-08 21:20:40 +0300
commit4f114419137e76acde2d60d256d470c5a7a4232b (patch)
tree2ebba925659d9e4ece39cdcc5ff68f5908751e91 /source/blender/draw/engines/eevee/eevee_private.h
parent9d12a5aa9e20c33c49bd86e956d0b3d5fbf6fd46 (diff)
Eevee: Add partial support for the Light Path Node
This makes it possible to tweak indirect lighting in the shader. Only a subset of the outputs is supported and the ray depth has not exactly the same meaning: Is Camera : Supported. Is Shadow : Supported. Is Diffuse : Supported. Is Glossy : Supported. Is Singular : Not supported. Same as Is Glossy. Is Reflection : Not supported. Same as Is Glossy. Is Transmission : Not supported. Same as Is Glossy. Ray Length : Not supported. Defaults to 1.0. Ray Depth : Indicate the current bounce when baking the light cache. Diffuse Depth : Same as Ray Depth but only when baking diffuse light. Glossy Depth : Same as Ray Depth but only when baking specular light. Transparent Depth : Not supported. Defaults to 0. Transmission Depth : Not supported. Same as Glossy Depth. Caveat: Is Glossy does not work with Screen Space Reflections but does work with reflection planes (when used with SSR or not). We have to render the world twice for that to work.
Diffstat (limited to 'source/blender/draw/engines/eevee/eevee_private.h')
-rw-r--r--source/blender/draw/engines/eevee/eevee_private.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/draw/engines/eevee/eevee_private.h b/source/blender/draw/engines/eevee/eevee_private.h
index e732bc8d40d..1c04dc81aad 100644
--- a/source/blender/draw/engines/eevee/eevee_private.h
+++ b/source/blender/draw/engines/eevee/eevee_private.h
@@ -656,8 +656,16 @@ typedef struct EEVEE_CommonUniformBuffer {
float prb_lod_planar_max; /* float */
/* Misc */
int hiz_mip_offset; /* int */
+ int ray_type; /* int */
+ float ray_depth; /* float */
} EEVEE_CommonUniformBuffer;
+/* ray_type (keep in sync with rayType) */
+#define EEVEE_RAY_CAMERA 0
+#define EEVEE_RAY_SHADOW 1
+#define EEVEE_RAY_DIFFUSE 2
+#define EEVEE_RAY_GLOSSY 3
+
/* ***************** CLIP PLANES DATA **************** */
typedef struct EEVEE_ClipPlanesUniformBuffer {