Blender  V3.3
eevee_private.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later
2  * Copyright 2016 Blender Foundation. */
3 
8 #pragma once
9 
10 #include "DRW_render.h"
11 
12 #include "BLI_bitmap.h"
13 
14 #include "DNA_lightprobe_types.h"
15 
16 #include "GPU_viewport.h"
17 
18 #include "BKE_camera.h"
19 
20 #ifdef __cplusplus
21 extern "C" {
22 #endif
23 
25 struct GPUFrameBuffer;
26 struct Object;
27 struct RenderLayer;
28 
30 
31 /* Minimum UBO is 16384 bytes */
32 #define MAX_PROBE 128 /* TODO: find size by dividing UBO max size by probe data size. */
33 #define MAX_GRID 64 /* TODO: find size by dividing UBO max size by grid data size. */
34 #define MAX_PLANAR 16 /* TODO: find size by dividing UBO max size by grid data size. */
35 #define MAX_LIGHT 128 /* TODO: find size by dividing UBO max size by light data size. */
36 #define MAX_CASCADE_NUM 4
37 #define MAX_SHADOW 128 /* TODO: Make this depends on #GL_MAX_ARRAY_TEXTURE_LAYERS. */
38 #define MAX_SHADOW_CASCADE 8
39 #define MAX_SHADOW_CUBE (MAX_SHADOW - MAX_CASCADE_NUM * MAX_SHADOW_CASCADE)
40 #define MAX_BLOOM_STEP 16
41 #define MAX_AOVS 64
42 
43 /* Special value chosen to not be altered by depth of field sample count. */
44 #define TAA_MAX_SAMPLE 10000926
45 
46 // #define DEBUG_SHADOW_DISTRIBUTION
47 
48 /* Only define one of these. */
49 // #define IRRADIANCE_SH_L2
50 #define IRRADIANCE_HL2
51 
52 #if defined(IRRADIANCE_SH_L2)
53 # define SHADER_IRRADIANCE "#define IRRADIANCE_SH_L2\n"
54 #elif defined(IRRADIANCE_HL2)
55 # define SHADER_IRRADIANCE "#define IRRADIANCE_HL2\n"
56 #endif
57 
58 /* Macro causes over indentation. */
59 /* clang-format off */
60 #define SHADER_DEFINES \
61  "#define EEVEE_ENGINE\n" \
62  "#define MAX_PROBE " STRINGIFY(MAX_PROBE) "\n" \
63  "#define MAX_GRID " STRINGIFY(MAX_GRID) "\n" \
64  "#define MAX_PLANAR " STRINGIFY(MAX_PLANAR) "\n" \
65  "#define MAX_LIGHT " STRINGIFY(MAX_LIGHT) "\n" \
66  "#define MAX_SHADOW " STRINGIFY(MAX_SHADOW) "\n" \
67  "#define MAX_SHADOW_CUBE " STRINGIFY(MAX_SHADOW_CUBE) "\n" \
68  "#define MAX_SHADOW_CASCADE " STRINGIFY(MAX_SHADOW_CASCADE) "\n" \
69  "#define MAX_CASCADE_NUM " STRINGIFY(MAX_CASCADE_NUM) "\n" \
70  SHADER_IRRADIANCE
71 /* clang-format on */
72 
73 #define EEVEE_PROBE_MAX min_ii(MAX_PROBE, GPU_max_texture_layers() / 6)
74 #define EEVEE_VELOCITY_TILE_SIZE 32
75 #define USE_VOLUME_OPTI (GPU_shader_image_load_store_support())
76 
77 #define SWAP_DOUBLE_BUFFERS() \
78  { \
79  if (effects->swap_double_buffer) { \
80  SWAP(struct GPUFrameBuffer *, fbl->main_fb, fbl->double_buffer_fb); \
81  SWAP(struct GPUFrameBuffer *, fbl->main_color_fb, fbl->double_buffer_color_fb); \
82  SWAP(GPUTexture *, txl->color, txl->color_double_buffer); \
83  effects->swap_double_buffer = false; \
84  } \
85  } \
86  ((void)0)
87 
88 #define SWAP_BUFFERS() \
89  { \
90  if (effects->target_buffer == fbl->effect_color_fb) { \
91  SWAP_DOUBLE_BUFFERS(); \
92  effects->source_buffer = txl->color_post; \
93  effects->target_buffer = fbl->main_color_fb; \
94  } \
95  else { \
96  SWAP_DOUBLE_BUFFERS(); \
97  effects->source_buffer = txl->color; \
98  effects->target_buffer = fbl->effect_color_fb; \
99  } \
100  } \
101  ((void)0)
102 
103 #define SWAP_BUFFERS_TAA() \
104  { \
105  if (effects->target_buffer == fbl->effect_color_fb) { \
106  SWAP(struct GPUFrameBuffer *, fbl->effect_fb, fbl->taa_history_fb); \
107  SWAP(struct GPUFrameBuffer *, fbl->effect_color_fb, fbl->taa_history_color_fb); \
108  SWAP(GPUTexture *, txl->color_post, txl->taa_history); \
109  effects->source_buffer = txl->taa_history; \
110  effects->target_buffer = fbl->effect_color_fb; \
111  } \
112  else { \
113  SWAP(struct GPUFrameBuffer *, fbl->main_fb, fbl->taa_history_fb); \
114  SWAP(struct GPUFrameBuffer *, fbl->main_color_fb, fbl->taa_history_color_fb); \
115  SWAP(GPUTexture *, txl->color, txl->taa_history); \
116  effects->source_buffer = txl->taa_history; \
117  effects->target_buffer = fbl->main_color_fb; \
118  } \
119  } \
120  ((void)0)
121 
123 {
124  /* Only show the HDRI Preview in Shading Preview in the Viewport. */
125  if (v3d == NULL || v3d->shading.type != OB_MATERIAL) {
126  return false;
127  }
128 
129  /* Only show the HDRI Preview when viewing the Combined render pass */
130  if (v3d->shading.render_pass != SCE_PASS_COMBINED) {
131  return false;
132  }
133 
134  return ((v3d->flag2 & V3D_HIDE_OVERLAYS) == 0) && (v3d->overlay.flag & V3D_OVERLAY_LOOK_DEV);
135 }
136 
137 #define USE_SCENE_LIGHT(v3d) \
138  ((!v3d) || \
139  ((v3d->shading.type == OB_MATERIAL) && (v3d->shading.flag & V3D_SHADING_SCENE_LIGHTS)) || \
140  ((v3d->shading.type == OB_RENDER) && (v3d->shading.flag & V3D_SHADING_SCENE_LIGHTS_RENDER)))
141 #define LOOK_DEV_STUDIO_LIGHT_ENABLED(v3d) \
142  ((v3d) && (((v3d->shading.type == OB_MATERIAL) && \
143  ((v3d->shading.flag & V3D_SHADING_SCENE_WORLD) == 0)) || \
144  ((v3d->shading.type == OB_RENDER) && \
145  ((v3d->shading.flag & V3D_SHADING_SCENE_WORLD_RENDER) == 0))))
146 
147 #define MIN_CUBE_LOD_LEVEL 3
148 #define MAX_SCREEN_BUFFERS_LOD_LEVEL 6
149 
150 /* All the renderpasses that use the GPUMaterial for accumulation */
151 #define EEVEE_RENDERPASSES_MATERIAL \
152  (EEVEE_RENDER_PASS_EMIT | EEVEE_RENDER_PASS_DIFFUSE_COLOR | EEVEE_RENDER_PASS_DIFFUSE_LIGHT | \
153  EEVEE_RENDER_PASS_SPECULAR_COLOR | EEVEE_RENDER_PASS_SPECULAR_LIGHT | \
154  EEVEE_RENDER_PASS_ENVIRONMENT | EEVEE_RENDER_PASS_AOV)
155 #define EEVEE_AOV_HASH_ALL -1
156 #define EEVEE_AOV_HASH_COLOR_TYPE_MASK 1
157 #define MAX_CRYPTOMATTE_LAYERS 3
158 
159 /* Material shader variations */
160 enum {
161  VAR_MAT_MESH = (1 << 0),
162  VAR_MAT_VOLUME = (1 << 1),
163  VAR_MAT_HAIR = (1 << 2),
164  VAR_MAT_POINTCLOUD = (1 << 3),
165  VAR_MAT_BLEND = (1 << 4),
166  VAR_MAT_LOOKDEV = (1 << 5),
167  VAR_MAT_HOLDOUT = (1 << 6),
168  VAR_MAT_HASH = (1 << 7),
169  VAR_MAT_DEPTH = (1 << 8),
170  VAR_MAT_REFRACT = (1 << 9),
171  VAR_WORLD_BACKGROUND = (1 << 10),
172  VAR_WORLD_PROBE = (1 << 11),
173  VAR_WORLD_VOLUME = (1 << 12),
174  VAR_DEFAULT = (1 << 13),
175 };
176 
177 /* Material shader cache keys */
178 enum {
179  /* HACK: This assumes the struct GPUShader will never be smaller than our variations.
180  * This allow us to only keep one #GHash and avoid bigger keys comparisons/hashing.
181  * We combine the #GPUShader pointer with the key. */
182  KEY_CULL = (1 << 0),
183  KEY_REFRACT = (1 << 1),
184  KEY_HAIR = (1 << 2),
185  KEY_SHADOW = (1 << 3),
186 };
187 
188 /* DOF Gather pass shader variations */
189 typedef enum EEVEE_DofGatherPass {
193 
196 
197 #define DOF_TILE_DIVISOR 16
198 #define DOF_BOKEH_LUT_SIZE 32
199 #define DOF_GATHER_RING_COUNT 5
200 #define DOF_DILATE_RING_COUNT 3
201 #define DOF_FAST_GATHER_COC_ERROR 0.05
202 
203 #define DOF_SHADER_DEFINES \
204  "#define DOF_TILE_DIVISOR " STRINGIFY(DOF_TILE_DIVISOR) "\n" \
205  "#define DOF_BOKEH_LUT_SIZE " STRINGIFY(DOF_BOKEH_LUT_SIZE) "\n" \
206  "#define DOF_GATHER_RING_COUNT " STRINGIFY(DOF_GATHER_RING_COUNT) "\n" \
207  "#define DOF_DILATE_RING_COUNT " STRINGIFY(DOF_DILATE_RING_COUNT) "\n" \
208  "#define DOF_FAST_GATHER_COC_ERROR " STRINGIFY(DOF_FAST_GATHER_COC_ERROR) "\n"
209 
210 /* ************ PROBE UBO ************* */
211 
212 /* They are the same struct as their Cache siblings.
213  * typedef'ing just to keep the naming consistent with
214  * other eevee types. */
217 
218 typedef struct EEVEE_PlanarReflection {
219  float plane_equation[4];
225  float reflectionmat[4][4]; /* Used for sampling the texture. */
226  float mtx[4][4]; /* Not used in shader. TODO: move elsewhere. */
228 
229 /* --------------------------------------- */
230 
231 typedef struct EEVEE_BoundBox {
232  float center[3], halfdim[3];
234 
235 typedef struct EEVEE_PassList {
236  /* Shadows */
239 
240  /* Probes */
248 
249  /* Effects */
298 
299  /* HiZ */
303 
304  /* Render-pass Accumulation. */
308 
309  struct DRWPass *depth_ps;
330 
331 typedef struct EEVEE_FramebufferList {
332  /* Effects */
376 
378 
381 
393 
394 typedef struct EEVEE_TextureList {
395  /* Effects */
396  struct GPUTexture *color_post; /* R16_G16_B16 */
412  /* Could not be pool texture because of mipmapping. */
415 
426 
429 
432 
435 
437 
438  struct GPUTexture *color; /* R16_G16_B16 */
442 
443 typedef struct EEVEE_StorageList {
444  /* Effects */
446 
448 
454 
455 /* ************ RENDERPASS UBO ************* */
456 typedef struct EEVEE_RenderPassData {
466  int _pad[3];
468 
469 /* ************ LIGHT UBO ************* */
470 typedef struct EEVEE_Light {
471  float position[3], invsqrdist;
474  float rightvec[3], sizex;
475  float upvec[3], sizey;
479 
480 /* Special type for elliptic area lights, matches lamps_lib.glsl */
481 #define LAMPTYPE_AREA_ELLIPSE 100.0f
482 
483 typedef struct EEVEE_Shadow {
487 
488 typedef struct EEVEE_ShadowCube {
489  float shadowmat[4][4];
490  float position[3], _pad0[1];
492 
493 typedef struct EEVEE_ShadowCascade {
494  /* World->Light->NDC->Tex : used for sampling the shadow map. */
496  float split_start[4];
497  float split_end[4];
498  float shadow_vec[3], tex_id;
500 
502  /* World->Light->NDC : used for rendering the shadow map. */
503  float projmat[MAX_CASCADE_NUM][4][4];
504  float viewmat[4][4], viewinv[4][4];
512 
518 
522  16384,
523  "Shadow UBO is too big!!!")
524 
525 typedef struct EEVEE_ShadowCasterBuffer {
526  struct EEVEE_BoundBox *bbox;
528  uint alloc_count;
529  uint count;
531 
532 /* ************ LIGHT DATA ************* */
533 typedef struct EEVEE_LightsInfo {
540  /* UBO Storage : data used by UBO */
545  /* Additional rendering info for cascade. */
547  /* Back index in light_data. */
550  /* Update bitmap. */
552  /* Lights tracking */
553  struct BoundSphere shadow_bounds[MAX_LIGHT]; /* Tightly packed light bounds. */
554  /* List of bbox and update bitmap. Double buffered. */
556  /* AABB of all shadow casters combined. */
557  struct {
558  float min[3], max[3];
561 
562 /* ************ PROBE DATA ************* */
563 typedef struct EEVEE_LightProbeVisTest {
564  struct Collection *collection; /* Skip test if NULL */
565  bool invert;
566  bool cached; /* Reuse last test results */
568 
569 typedef struct EEVEE_LightProbesInfo {
573  int total_irradiance_samples; /* Total for all grids */
579  /* Update */
582  /* For rendering probes */
583  float probemat[6][4][4];
584  int layer;
585  float texel_size;
587  float samples_len;
588  float near_clip;
589  float far_clip;
590  float roughness;
591  float firefly_fac;
592  float lodfactor;
597  int shres;
599  /* UBO Storage : data used by UBO */
603  /* Probe Visibility Collection */
606 
607 /* EEVEE_LightProbesInfo->update_flag */
608 enum {
609  PROBE_UPDATE_CUBE = (1 << 0),
610  PROBE_UPDATE_GRID = (1 << 1),
611  PROBE_UPDATE_ALL = 0xFFFFFF,
612 };
613 
614 /* ************** MOTION BLUR ************ */
615 
616 #define MB_PREV 0
617 #define MB_NEXT 1
618 #define MB_CURR 2
619 
620 typedef struct EEVEE_MotionBlurData {
624  struct GHash *object;
637 
638  struct {
639  float viewmat[4][4];
640  float persmat[4][4];
641  float persinv[4][4];
642  } camera[3];
645 
646 typedef struct EEVEE_ObjectKey {
650  void *ob;
652  struct Object *parent;
654  int id[8]; /* MAX_DUPLI_RECUR */
656 
657 typedef enum eEEVEEMotionData {
661 
662 typedef struct EEVEE_HairMotionStepData {
666 
667 typedef struct EEVEE_HairMotionData {
672  int psys_len;
673  struct {
674  /* The VBO's and textures are not owned. */
675  EEVEE_HairMotionStepData step_data[2]; /* Data for time = t +/- step. */
676  } psys[0];
678 
679 typedef struct EEVEE_GeometryMotionData {
684 
685  /* The batch and VBOs are not owned. */
686  struct GPUBatch *batch; /* Batch for time = t. */
687  struct GPUVertBuf *vbo[2]; /* VBO for time = t +/- step. */
689 
690 typedef struct EEVEE_ObjectMotionData {
691  float obmat[3][4][4];
692 
696 
697 /* ************ EFFECTS DATA ************* */
698 
699 typedef enum EEVEE_EffectsFlag {
700  EFFECT_MOTION_BLUR = (1 << 0),
701  EFFECT_BLOOM = (1 << 1),
702  EFFECT_DOF = (1 << 2),
703  EFFECT_VOLUMETRIC = (1 << 3),
704  EFFECT_SSR = (1 << 4),
705  EFFECT_DOUBLE_BUFFER = (1 << 5), /* Not really an effect but a feature */
706  EFFECT_REFRACT = (1 << 6),
707  EFFECT_GTAO = (1 << 7),
708  EFFECT_TAA = (1 << 8),
709  EFFECT_POST_BUFFER = (1 << 9), /* Not really an effect but a feature */
710  EFFECT_NORMAL_BUFFER = (1 << 10), /* Not really an effect but a feature */
711  EFFECT_RADIANCE_BUFFER = (1 << 10), /* Not really an effect but a feature */
712  EFFECT_SSS = (1 << 11),
713  EFFECT_VELOCITY_BUFFER = (1 << 12), /* Not really an effect but a feature */
714  EFFECT_TAA_REPROJECT = (1 << 13), /* should be mutually exclusive with EFFECT_TAA */
715  EFFECT_DEPTH_DOUBLE_BUFFER = (1 << 14), /* Not really an effect but a feature */
717 
718 typedef struct EEVEE_EffectsInfo {
721  /* SSSS */
724  struct GPUTexture *sss_irradiance; /* Textures from pool */
729  /* Volumetrics */
734  /* SSR */
738  struct GPUTexture *ssr_normal_input; /* Textures from pool */
742  /* Temporal Anti Aliasing */
747  float taa_alpha;
751  float prev_drw_persmat[4][4]; /* Used for checking view validity and reprojection. */
752  struct DRWView *taa_view;
753  /* Ambient Occlusion */
754  struct GPUTexture *gtao_horizons; /* Textures from pool */
755  struct GPUTexture *gtao_horizons_renderpass; /* Texture when rendering render pass */
757  /* Motion Blur */
758  float current_ndc_to_world[4][4];
759  float current_world_to_ndc[4][4];
761  float past_world_to_ndc[4][4];
762  float past_world_to_view[4][4];
765  char motion_blur_step; /* Which step we are evaluating. */
766  int motion_blur_max; /* Maximum distance in pixels a motion-blurred pixel can cover. */
767  float motion_blur_near_far[2]; /* Camera near/far clip distances (positive). */
769  /* TODO(fclem): Only used in render mode for now.
770  * This is because we are missing a per scene persistent place to hold this. */
772  /* Velocity Pass */
773  struct GPUTexture *velocity_tx; /* Texture from pool */
776  /* Depth Of Field */
795  struct GPUTexture *dof_bg_color_tx; /* All textures from pool... */
814  struct GPUTexture *dof_reduce_input_coc_tx; /* Just references to actual textures. */
816  /* Other */
817  float prev_persmat[4][4];
818  /* Size used by all fullscreen buffers using mipmaps. */
819  int hiz_size[2];
820  /* Lookdev */
823  int anchor[2];
825  /* Bloom */
828  float blit_texel_size[2];
830  float bloom_color[3];
831  float bloom_clamp;
835  struct GPUTexture *bloom_blit; /* Textures from pool */
838  struct GPUTexture *unf_source_buffer; /* pointer copy */
839  struct GPUTexture *unf_base_buffer; /* pointer copy */
840  /* Not alloced, just a copy of a *GPUtexture in EEVEE_TextureList. */
841  struct GPUTexture *source_buffer; /* latest updated texture */
842  struct GPUFrameBuffer *target_buffer; /* next target to render to */
843  struct GPUTexture *final_tx; /* Final color to transform to display color space. */
844  struct GPUFrameBuffer *final_fb; /* Frame-buffer with final_tx as attachment. */
846 
847 /* ***************** COMMON DATA **************** */
848 
849 /* Common uniform buffer containing all "constant" data over the whole drawing pipeline. */
850 /* !! CAUTION !!
851  * - [i]vec3 need to be padded to [i]vec4 (even in ubo declaration).
852  * - Make sure that [i]vec4 start at a multiple of 16 bytes.
853  * - Arrays of vec2/vec3 are padded as arrays of vec4.
854  * - sizeof(bool) == sizeof(int) in GLSL so use int in C */
856  float prev_persmat[4][4]; /* mat4 */
857  float hiz_uv_scale[2], ssr_uv_scale[2]; /* vec4 */
858  /* Ambient Occlusion */
859  /* -- 16 byte aligned -- */
860  float ao_dist, pad1, ao_factor, pad2; /* vec4 */
862  /* Volumetric */
863  /* -- 16 byte aligned -- */
864  int vol_tex_size[3], pad3; /* ivec3 */
865  float vol_depth_param[3], pad4; /* vec3 */
866  float vol_inv_tex_size[3], pad5; /* vec3 */
867  float vol_jitter[3], pad6; /* vec3 */
868  float vol_coord_scale[4]; /* vec4 */
869  /* -- 16 byte aligned -- */
870  float vol_history_alpha; /* float */
871  float vol_shadow_steps; /* float */
872  int vol_use_lights; /* bool */
873  int vol_use_soft_shadows; /* bool */
874  /* Screen Space Reflections */
875  /* -- 16 byte aligned -- */
876  float ssr_quality, ssr_thickness, ssr_pixelsize[2]; /* vec4 */
877  float ssr_border_fac; /* float */
878  float ssr_max_roughness; /* float */
879  float ssr_firefly_fac; /* float */
880  float ssr_brdf_bias; /* float */
881  int ssr_toggle; /* bool */
882  int ssrefract_toggle; /* bool */
883  /* SubSurface Scattering */
884  float sss_jitter_threshold; /* float */
885  int sss_toggle; /* bool */
886  /* Specular */
887  int spec_toggle; /* bool */
888  /* Lights */
889  int la_num_light; /* int */
890  /* Probes */
891  int prb_num_planar; /* int */
892  int prb_num_render_cube; /* int */
893  int prb_num_render_grid; /* int */
894  int prb_irradiance_vis_size; /* int */
895  float prb_irradiance_smooth; /* float */
896  float prb_lod_cube_max; /* float */
897  /* Misc */
898  int ray_type; /* int */
899  float ray_depth; /* float */
900  float alpha_hash_offset; /* float */
901  float alpha_hash_scale; /* float */
902  float pad7; /* float */
903  float pad8; /* float */
904  float pad9; /* float */
905  float pad10; /* float */
907 
909 
910 /* ray_type (keep in sync with rayType) */
911 #define EEVEE_RAY_CAMERA 0
912 #define EEVEE_RAY_SHADOW 1
913 #define EEVEE_RAY_DIFFUSE 2
914 #define EEVEE_RAY_GLOSSY 3
915 
916 /* ************** SCENE LAYER DATA ************** */
917 typedef struct EEVEE_ViewLayerData {
918  /* Lights */
920 
924 
926 
929 
931 
932  /* Probes */
934 
938 
939  /* Material Render passes */
940  struct {
950 
951  /* Common Uniform Buffer */
954 
956 
959 
960 /* ************ OBJECT DATA ************ */
961 
962 /* These are the structs stored inside Objects.
963  * It works even if the object is in multiple layers
964  * because we don't get the same "Object *" for each layer. */
965 typedef struct EEVEE_LightEngineData {
967 
970 
973 
976 
977 typedef struct EEVEE_ObjectEngineData {
979 
980  Object *ob; /* self reference */
983 
988 
989 typedef struct EEVEE_WorldEngineData {
992 
993 typedef struct EEVEE_CryptomatteSample {
994  float hash;
995  float weight;
997 
998 /* *********************************** */
999 
1000 typedef struct EEVEE_Data {
1007 
1010 
1011 typedef struct EEVEE_PrivateData {
1016  float background_alpha; /* TODO: find a better place for this. */
1018  /* Chosen lightcache: can come from Lookdev or the viewlayer. */
1020  /* For planar probes */
1022  /* For double buffering */
1026  /* Render Matrices */
1027  float studiolight_matrix[3][3];
1029  float camtexcofac[4];
1030  float size_orig[2];
1031 
1032  /* Cached original camera when rendering for motion blur (see T79637). */
1034 
1035  /* Mist Settings */
1037 
1038  /* Color Management */
1040 
1041  /* Compiling shaders count. This is to track if a shader has finished compiling. */
1044 
1045  /* LookDev Settings */
1052 
1053  /* Render-passes */
1054  /* Bitmask containing the active render_passes */
1062 
1063  /* Uniform references that are referenced inside the `renderpass_pass`. They are updated
1064  * to reuse the drawing pass and the shading group. */
1072  /* Render-pass UBO reference used by material pass. */
1075  struct DRWView *cube_views[6];
1077  struct DRWView *bake_views[6];
1079  struct DRWView *world_views[6];
1082 
1085 } EEVEE_PrivateData; /* Transient data */
1086 
1087 /* eevee_data.c */
1088 
1099  Object *ob,
1100  bool is_psys);
1110 
1111 void eevee_id_update(void *vedata, ID *id);
1112 
1113 /* eevee_materials.c */
1114 
1115 struct GPUTexture *EEVEE_materials_get_util_tex(void); /* XXX */
1117  EEVEE_Data *vedata,
1118  EEVEE_StorageList *stl,
1119  EEVEE_FramebufferList *fbl);
1122  EEVEE_ViewLayerData *sldata,
1123  Object *ob,
1124  bool *cast_shadow);
1126  EEVEE_ViewLayerData *sldata,
1127  Object *ob,
1128  bool *cast_shadow);
1130  EEVEE_ViewLayerData *sldata,
1131  Object *ob,
1132  bool *cast_shadow);
1134 void EEVEE_materials_free(void);
1135 void EEVEE_update_noise(EEVEE_PassList *psl, EEVEE_FramebufferList *fbl, const double offsets[3]);
1137 void EEVEE_material_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples);
1143  struct GPUMaterial *gpumat,
1144  EEVEE_ViewLayerData *sldata,
1145  EEVEE_Data *vedata,
1146  const int *ssr_id,
1147  const float *refract_depth,
1148  const float alpha_clip_threshold,
1149  bool use_ssrefraction,
1150  bool use_alpha_blend);
1151 /* eevee_lights.c */
1152 
1156 void eevee_light_matrix_get(const EEVEE_Light *evli, float r_mat[4][4]);
1158 void EEVEE_lights_cache_add(EEVEE_ViewLayerData *sldata, struct Object *ob);
1160 
1161 /* eevee_shadows.c */
1162 
1163 void eevee_contact_shadow_setup(const Light *la, EEVEE_Shadow *evsh);
1169 void EEVEE_shadows_caster_register(EEVEE_ViewLayerData *sldata, struct Object *ob);
1170 void EEVEE_shadows_update(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata);
1171 void EEVEE_shadows_cube_add(EEVEE_LightsInfo *linfo, EEVEE_Light *evli, struct Object *ob);
1175 bool EEVEE_shadows_cube_setup(EEVEE_LightsInfo *linfo, const EEVEE_Light *evli, int sample_ofs);
1176 void EEVEE_shadows_cascade_add(EEVEE_LightsInfo *linfo, EEVEE_Light *evli, struct Object *ob);
1180 void EEVEE_shadows_draw(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, struct DRWView *view);
1181 void EEVEE_shadows_draw_cubemap(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, int cube_index);
1183  EEVEE_Data *vedata,
1184  DRWView *view,
1185  int cascade_index);
1186 void EEVEE_shadow_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples);
1188 
1189 /* eevee_sampling.c */
1190 
1197 void EEVEE_sample_ball(int sample_ofs, float radius, float rsample[3]);
1198 void EEVEE_sample_rectangle(int sample_ofs,
1199  const float x_axis[3],
1200  const float y_axis[3],
1201  float size_x,
1202  float size_y,
1203  float rsample[3]);
1204 void EEVEE_sample_ellipse(int sample_ofs,
1205  const float x_axis[3],
1206  const float y_axis[3],
1207  float size_x,
1208  float size_y,
1209  float rsample[3]);
1210 void EEVEE_random_rotation_m4(int sample_ofs, float scale, float r_mat[4][4]);
1211 
1212 /* eevee_shaders.c */
1213 
1216 struct GPUShader *EEVEE_shaders_bloom_blit_get(bool high_quality);
1217 struct GPUShader *EEVEE_shaders_bloom_downsample_get(bool high_quality);
1218 struct GPUShader *EEVEE_shaders_bloom_upsample_get(bool high_quality);
1219 struct GPUShader *EEVEE_shaders_bloom_resolve_get(bool high_quality);
1225 struct GPUShader *EEVEE_shaders_depth_of_field_reduce_get(bool is_copy_pass);
1228 struct GPUShader *EEVEE_shaders_depth_of_field_scatter_get(bool is_foreground, bool bokeh_tx);
1229 struct GPUShader *EEVEE_shaders_depth_of_field_resolve_get(bool use_bokeh_tx, bool use_hq_gather);
1253 struct GPUShader *EEVEE_shaders_cryptomatte_sh_get(bool is_hair);
1297  EEVEE_Data *vedata, struct Scene *scene, Material *ma, World *wo, int options);
1298 void EEVEE_shaders_free(void);
1299 
1300 void eevee_shader_extra_init(void);
1301 void eevee_shader_extra_exit(void);
1303  GPUCodegenOutput *codegen,
1304  char *frag,
1305  char *vert,
1306  char *geom,
1307  char *defines);
1309  const char *vert_name,
1310  const char *frag_name,
1311  const char *defines,
1312  bool use_layered_rendering);
1313 
1314 /* eevee_lightprobes.c */
1315 
1316 bool EEVEE_lightprobes_obj_visibility_cb(bool vis_in, void *user_data);
1323 void EEVEE_lightprobes_free(void);
1324 
1329  EEVEE_Data *vedata,
1330  GPUTexture *rt_color,
1331  GPUTexture *rt_depth);
1333  EEVEE_Data *vedata,
1334  struct GPUFrameBuffer *face_fb[6]);
1339  EEVEE_Data *vedata,
1340  struct GPUFrameBuffer *face_fb[6],
1341  const float pos[3],
1342  float near_clip,
1343  float far_clip);
1348  EEVEE_Data *vedata,
1349  struct GPUTexture *rt_color,
1350  struct GPUFrameBuffer *fb,
1351  int probe_idx,
1352  float intensity,
1353  int maxlevel,
1354  float filter_quality,
1355  float firefly_fac);
1360  EEVEE_Data *vedata,
1361  struct GPUTexture *rt_color,
1362  struct GPUFrameBuffer *fb,
1363  int grid_offset,
1364  float intensity);
1369  EEVEE_Data *vedata,
1370  struct GPUTexture *rt_depth,
1371  struct GPUFrameBuffer *fb,
1372  int grid_offset,
1373  float clipsta,
1374  float clipend,
1375  float vis_range,
1376  float vis_blur,
1377  int vis_size);
1378 
1382  EEVEE_PlanarReflection *eplanar,
1383  EEVEE_LightProbeVisTest *vis_test);
1384 
1385 /* eevee_depth_of_field.c */
1386 
1391  float r_jitter[2],
1392  float *r_focus_distance);
1394  int sample_count,
1395  int *r_ring_count);
1396 
1397 /* eevee_bloom.c */
1398 
1401 void EEVEE_bloom_draw(EEVEE_Data *vedata);
1402 void EEVEE_bloom_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples);
1404 
1405 /* eevee_cryptomatte.c */
1406 
1409  EEVEE_Data *vedata,
1410  int tot_samples);
1414  EEVEE_ViewLayerData *sldata,
1415  Object *ob);
1417  EEVEE_ViewLayerData *sldata,
1418  Object *ob);
1425 void EEVEE_cryptomatte_update_passes(struct RenderEngine *engine,
1426  struct Scene *scene,
1427  struct ViewLayer *view_layer);
1429  const char *viewname,
1430  const rcti *rect,
1431  EEVEE_Data *vedata,
1432  EEVEE_ViewLayerData *sldata);
1433 void EEVEE_cryptomatte_store_metadata(EEVEE_Data *vedata, struct RenderResult *render_result);
1434 void EEVEE_cryptomatte_free(EEVEE_Data *vedata);
1435 
1436 /* eevee_occlusion.c */
1437 
1440  EEVEE_Data *vedata,
1441  uint tot_samples);
1446 void EEVEE_occlusion_free(void);
1447 
1448 /* eevee_screen_raytrace.c */
1449 
1455  EEVEE_Data *vedata,
1456  uint tot_samples);
1458 
1459 /* eevee_subsurface.c */
1460 
1465  EEVEE_Data *vedata,
1466  uint tot_samples);
1468  EEVEE_Data *vedata,
1469  Material *ma,
1470  DRWShadingGroup *shgrp,
1471  struct GPUMaterial *gpumat);
1475 
1476 /* eevee_motion_blur.c */
1477 
1479 void EEVEE_motion_blur_step_set(EEVEE_Data *vedata, int step);
1483  EEVEE_Data *vedata,
1484  Object *ob,
1485  struct ParticleSystem *psys,
1486  struct ModifierData *md);
1488  EEVEE_Data *vedata,
1489  Object *ob);
1492 void EEVEE_motion_blur_draw(EEVEE_Data *vedata);
1493 
1494 /* eevee_mist.c */
1495 
1498 
1499 /* eevee_renderpasses.c */
1500 
1501 void EEVEE_renderpasses_init(EEVEE_Data *vedata);
1503  EEVEE_Data *vedata,
1504  uint tot_samples);
1507  EEVEE_Data *vedata,
1508  bool post_effect);
1521  EEVEE_Data *vedata,
1522  eViewLayerEEVEEPassType renderpass_type,
1523  int aov_index);
1532 
1533 /* eevee_temporal_sampling.c */
1534 
1539 void EEVEE_temporal_sampling_offset_calc(const double ht_point[2],
1540  float filter_size,
1541  float r_offset[2]);
1542 void EEVEE_temporal_sampling_matrices_calc(EEVEE_EffectsInfo *effects, const double ht_point[2]);
1550 
1551 /* eevee_volumes.c */
1552 
1553 void EEVEE_volumes_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata);
1554 void EEVEE_volumes_set_jitter(EEVEE_ViewLayerData *sldata, uint current_sample);
1557  EEVEE_Data *vedata,
1558  struct Scene *scene,
1559  Object *ob);
1564 void EEVEE_volumes_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples);
1566 void EEVEE_volumes_free(void);
1567 
1568 /* eevee_effects.c */
1569 
1571  EEVEE_Data *vedata,
1572  Object *camera,
1573  bool minimal);
1579 void EEVEE_effects_downsample_radiance_buffer(EEVEE_Data *vedata, struct GPUTexture *texture_src);
1580 void EEVEE_create_minmax_buffer(EEVEE_Data *vedata, struct GPUTexture *depth_src, int layer);
1584 void EEVEE_downsample_cube_buffer(EEVEE_Data *vedata, struct GPUTexture *texture_src, int level);
1585 void EEVEE_draw_effects(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata);
1586 
1587 /* eevee_render.c */
1588 
1592 bool EEVEE_render_init(EEVEE_Data *vedata,
1593  struct RenderEngine *engine,
1594  struct Depsgraph *depsgraph);
1595 void EEVEE_render_view_sync(EEVEE_Data *vedata,
1596  struct RenderEngine *engine,
1597  struct Depsgraph *depsgraph);
1599  struct RenderEngine *engine,
1600  struct Depsgraph *depsgraph);
1605 void EEVEE_render_cache(void *vedata,
1606  struct Object *ob,
1607  struct RenderEngine *engine,
1608  struct Depsgraph *depsgraph);
1610  struct RenderEngine *engine,
1611  struct RenderLayer *rl,
1612  const struct rcti *rect);
1614  struct RenderEngine *engine,
1615  struct RenderLayer *rl,
1616  const rcti *rect);
1617 void EEVEE_render_update_passes(struct RenderEngine *engine,
1618  struct Scene *scene,
1619  struct ViewLayer *view_layer);
1620 
1622 void EEVEE_lookdev_init(EEVEE_Data *vedata);
1624  EEVEE_ViewLayerData *sldata,
1625  DRWPass *pass,
1626  EEVEE_LightProbesInfo *pinfo,
1627  DRWShadingGroup **r_shgrp);
1628 void EEVEE_lookdev_draw(EEVEE_Data *vedata);
1629 
1631 void EEVEE_cache_populate(void *vedata, Object *ob);
1632 
1634 float *EEVEE_lut_update_ggx_brdf(int lut_size);
1635 float *EEVEE_lut_update_ggx_btdf(int lut_size, int lut_depth);
1636 
1637 /* Shadow Matrix */
1638 static const float texcomat[4][4] = {
1639  /* From NDC to TexCo */
1640  {0.5f, 0.0f, 0.0f, 0.0f},
1641  {0.0f, 0.5f, 0.0f, 0.0f},
1642  {0.0f, 0.0f, 0.5f, 0.0f},
1643  {0.5f, 0.5f, 0.5f, 1.0f},
1644 };
1645 
1646 /* Cube-map Matrices */
1647 static const float cubefacemat[6][4][4] = {
1648  /* Pos X */
1649  {{0.0f, 0.0f, -1.0f, 0.0f},
1650  {0.0f, -1.0f, 0.0f, 0.0f},
1651  {-1.0f, 0.0f, 0.0f, 0.0f},
1652  {0.0f, 0.0f, 0.0f, 1.0f}},
1653  /* Neg X */
1654  {{0.0f, 0.0f, 1.0f, 0.0f},
1655  {0.0f, -1.0f, 0.0f, 0.0f},
1656  {1.0f, 0.0f, 0.0f, 0.0f},
1657  {0.0f, 0.0f, 0.0f, 1.0f}},
1658  /* Pos Y */
1659  {{1.0f, 0.0f, 0.0f, 0.0f},
1660  {0.0f, 0.0f, -1.0f, 0.0f},
1661  {0.0f, 1.0f, 0.0f, 0.0f},
1662  {0.0f, 0.0f, 0.0f, 1.0f}},
1663  /* Neg Y */
1664  {{1.0f, 0.0f, 0.0f, 0.0f},
1665  {0.0f, 0.0f, 1.0f, 0.0f},
1666  {0.0f, -1.0f, 0.0f, 0.0f},
1667  {0.0f, 0.0f, 0.0f, 1.0f}},
1668  /* Pos Z */
1669  {{1.0f, 0.0f, 0.0f, 0.0f},
1670  {0.0f, -1.0f, 0.0f, 0.0f},
1671  {0.0f, 0.0f, -1.0f, 0.0f},
1672  {0.0f, 0.0f, 0.0f, 1.0f}},
1673  /* Neg Z */
1674  {{-1.0f, 0.0f, 0.0f, 0.0f},
1675  {0.0f, -1.0f, 0.0f, 0.0f},
1676  {0.0f, 0.0f, 1.0f, 0.0f},
1677  {0.0f, 0.0f, 0.0f, 1.0f}},
1678 };
1679 
1680 #ifdef __cplusplus
1681 }
1682 #endif
Camera data-block and utility functions.
#define BLI_STATIC_ASSERT_ALIGN(st, align)
Definition: BLI_assert.h:86
#define BLI_BITMAP_SIZE(_num)
Definition: BLI_bitmap.h:35
unsigned int BLI_bitmap
Definition: BLI_bitmap.h:16
#define BLI_INLINE
unsigned char uchar
Definition: BLI_sys_types.h:70
unsigned int uint
Definition: BLI_sys_types.h:67
struct Depsgraph Depsgraph
Definition: DEG_depsgraph.h:35
eViewLayerEEVEEPassType
@ OB_MATERIAL
@ SCE_PASS_COMBINED
@ V3D_OVERLAY_LOOK_DEV
#define V3D_HIDE_OVERLAYS
static AppView * view
GPUBatch
Definition: GPU_batch.h:78
struct GPUFrameBuffer GPUFrameBuffer
struct GPUShader GPUShader
Definition: GPU_shader.h:20
struct GPUTexture GPUTexture
Definition: GPU_texture.h:17
eGPUTextureFormat
Definition: GPU_texture.h:83
struct GPUUniformBuf GPUUniformBuf
struct GPUVertBuf GPUVertBuf
in reality light always falls off quadratically Particle Retrieve the data of the particle that spawned the object for example to give variation to multiple instances of an object Point Retrieve information about points in a point cloud Retrieve the edges of an object as it appears to Cycles topology will always appear triangulated Convert a blackbody temperature to an RGB value Normal Generate a perturbed normal from an RGB normal map image Typically used for faking highly detailed surfaces Generate an OSL shader from a file or text data block Image Sample an image file as a texture Sky Generate a procedural sky texture Noise Generate fractal Perlin noise Wave Generate procedural bands or rings with noise Voronoi Generate Worley noise based on the distance to random points Typically used to generate textures such as or biological cells Brick Generate a procedural texture producing bricks Texture Retrieve multiple types of texture coordinates nTypically used as inputs for texture nodes Vector Convert a or normal between camera
CCL_NAMESPACE_BEGIN struct Options options
Scene scene
const Depsgraph * depsgraph
void * user_data
eDRWLevelOfDetail
Definition: draw_cache.h:28
#define GPU_INFO_SIZE
struct GPUTexture * depth_src
Definition: eevee_effects.c:22
EEVEE_DofGatherPass
@ DOF_GATHER_HOLEFILL
@ DOF_GATHER_FOREGROUND
@ DOF_GATHER_BACKGROUND
@ DOF_GATHER_MAX_PASS
void EEVEE_occlusion_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_depth_of_field_setup_get(void)
#define MAX_AOVS
Definition: eevee_private.h:41
struct EEVEE_CommonUniformBuffer EEVEE_CommonUniformBuffer
void EEVEE_cryptomatte_output_accumulate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_subsurface_translucency_sh_get(void)
struct EEVEE_GeometryMotionData EEVEE_GeometryMotionData
void EEVEE_volumes_cache_finish(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_refraction_compute(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct EEVEE_Shadow EEVEE_Shadow
struct GPUShader * EEVEE_shaders_effect_motion_blur_sh_get(void)
struct DrawEngineType draw_engine_eevee_type
Definition: eevee_engine.c:618
struct GPUShader * EEVEE_shaders_effect_color_copy_sh_get(void)
void EEVEE_shadows_update(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
#define MAX_SHADOW_CASCADE
Definition: eevee_private.h:38
float * EEVEE_lut_update_ggx_brdf(int lut_size)
Definition: eevee_lut_gen.c:23
EEVEE_LightProbeEngineData * EEVEE_lightprobe_data_get(Object *ob)
Definition: eevee_data.c:308
void EEVEE_occlusion_free(void)
struct EEVEE_WorldEngineData EEVEE_WorldEngineData
void EEVEE_shadows_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
Definition: eevee_shadows.c:81
void EEVEE_motion_blur_cache_finish(EEVEE_Data *vedata)
void EEVEE_renderpasses_output_accumulate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, bool post_effect)
void EEVEE_downsample_cube_buffer(EEVEE_Data *vedata, struct GPUTexture *texture_src, int level)
void EEVEE_volumes_set_jitter(EEVEE_ViewLayerData *sldata, uint current_sample)
Definition: eevee_volumes.c:48
void EEVEE_lightprobes_free(void)
void EEVEE_shaders_free(void)
int EEVEE_depth_of_field_sample_count_get(EEVEE_EffectsInfo *effects, int sample_count, int *r_ring_count)
LightGridCache EEVEE_LightGrid
void EEVEE_cryptomatte_particle_hair_cache_populate(EEVEE_Data *vedata, EEVEE_ViewLayerData *sldata, Object *ob)
struct GPUShader * EEVEE_shaders_cryptomatte_sh_get(bool is_hair)
void EEVEE_cryptomatte_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, int tot_samples)
void EEVEE_sample_ellipse(int sample_ofs, const float x_axis[3], const float y_axis[3], float size_x, float size_y, float rsample[3])
EEVEE_LightEngineData * EEVEE_light_data_get(Object *ob)
Definition: eevee_data.c:334
struct GPUShader * EEVEE_shaders_probe_planar_display_sh_get(void)
struct EEVEE_PassList EEVEE_PassList
void EEVEE_lights_cache_finish(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
Definition: eevee_lights.c:230
@ VAR_WORLD_BACKGROUND
@ VAR_MAT_HOLDOUT
@ VAR_WORLD_VOLUME
@ VAR_MAT_BLEND
@ VAR_MAT_HASH
@ VAR_MAT_DEPTH
@ VAR_DEFAULT
@ VAR_WORLD_PROBE
@ VAR_MAT_LOOKDEV
@ VAR_MAT_VOLUME
@ VAR_MAT_REFRACT
@ VAR_MAT_POINTCLOUD
@ VAR_MAT_MESH
@ VAR_MAT_HAIR
void EEVEE_lightprobes_cache_finish(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_effect_maxz_downlevel_sh_get(void)
struct GPUShader * EEVEE_shaders_shadow_accum_sh_get(void)
void EEVEE_effects_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, Object *camera, bool minimal)
Definition: eevee_effects.c:56
struct GPUShader * EEVEE_shaders_velocity_resolve_sh_get(void)
struct GPUShader * EEVEE_shaders_effect_maxz_downdepth_sh_get(void)
void EEVEE_lightbake_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, GPUTexture *rt_color, GPUTexture *rt_depth)
void EEVEE_bloom_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_effect_maxz_copydepth_sh_get(void)
void EEVEE_update_noise(EEVEE_PassList *psl, EEVEE_FramebufferList *fbl, const double offsets[3])
void EEVEE_lightbake_filter_visibility(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, struct GPUTexture *rt_depth, struct GPUFrameBuffer *fb, int grid_offset, float clipsta, float clipend, float vis_range, float vis_blur, int vis_size)
struct GPUShader * EEVEE_shaders_probe_grid_fill_sh_get(void)
EEVEE_ViewLayerData * EEVEE_view_layer_data_get(void)
Definition: eevee_data.c:236
void EEVEE_subsurface_compute(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_cryptomatte_object_curves_cache_populate(EEVEE_Data *vedata, EEVEE_ViewLayerData *sldata, Object *ob)
void EEVEE_screen_raytrace_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_material_bind_resources(DRWShadingGroup *shgrp, struct GPUMaterial *gpumat, EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, const int *ssr_id, const float *refract_depth, const float alpha_clip_threshold, bool use_ssrefraction, bool use_alpha_blend)
void EEVEE_lookdev_init(EEVEE_Data *vedata)
Definition: eevee_lookdev.c:84
void EEVEE_motion_blur_cache_populate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, Object *ob)
struct EEVEE_LightsInfo EEVEE_LightsInfo
struct GPUShader * EEVEE_shaders_subsurface_first_pass_sh_get(void)
struct EEVEE_ShadowCascade EEVEE_ShadowCascade
bool EEVEE_shadows_cube_setup(EEVEE_LightsInfo *linfo, const EEVEE_Light *evli, int sample_ofs)
void EEVEE_shadows_draw_cascades(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, DRWView *view, int cascade_index)
int EEVEE_temporal_sampling_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_lightprobes_cube_data_from_object(Object *ob, EEVEE_LightProbe *eprobe)
EEVEE_ViewLayerData * EEVEE_view_layer_data_ensure(void)
Definition: eevee_data.c:259
void EEVEE_lights_cache_add(EEVEE_ViewLayerData *sldata, struct Object *ob)
Definition: eevee_lights.c:200
void EEVEE_materials_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_volumes_resolve(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_cache_populate(void *vedata, Object *ob)
Definition: eevee_engine.c:99
EEVEE_ShadowCasterBuffer
void EEVEE_volumes_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_effect_minz_copydepth_sh_get(void)
void eevee_shader_extra_exit(void)
bool EEVEE_lightprobes_obj_visibility_cb(bool vis_in, void *user_data)
void EEVEE_temporal_sampling_matrices_calc(EEVEE_EffectsInfo *effects, const double ht_point[2])
struct GPUShader * EEVEE_shaders_depth_of_field_bokeh_get(void)
void EEVEE_render_modules_init(EEVEE_Data *vedata, struct RenderEngine *engine, struct Depsgraph *depsgraph)
Definition: eevee_render.c:120
EEVEE_ObjectEngineData * EEVEE_object_data_ensure(Object *ob)
Definition: eevee_data.c:290
struct EEVEE_PlanarReflection EEVEE_PlanarReflection
World * EEVEE_world_default_get(void)
void EEVEE_render_view_sync(EEVEE_Data *vedata, struct RenderEngine *engine, struct Depsgraph *depsgraph)
Definition: eevee_render.c:141
void EEVEE_render_read_result(EEVEE_Data *vedata, struct RenderEngine *engine, struct RenderLayer *rl, const rcti *rect)
Definition: eevee_render.c:658
void EEVEE_lightprobes_refresh(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_lightprobes_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_reflection_compute(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_lightprobes_planar_data_from_object(Object *ob, EEVEE_PlanarReflection *eplanar, EEVEE_LightProbeVisTest *vis_test)
GPUShader * eevee_shaders_sh_create_helper(const char *name, const char *vert_name, const char *frag_name, const char *defines, bool use_layered_rendering)
void EEVEE_volumes_cache_object_add(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, struct Scene *scene, Object *ob)
void EEVEE_volumes_free(void)
struct EEVEE_CryptomatteSample EEVEE_CryptomatteSample
void EEVEE_shadow_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples)
void EEVEE_temporal_sampling_reset(EEVEE_Data *vedata)
void EEVEE_motion_blur_swap_data(EEVEE_Data *vedata)
void EEVEE_volumes_compute(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
@ PROBE_UPDATE_CUBE
@ PROBE_UPDATE_ALL
@ PROBE_UPDATE_GRID
static const float texcomat[4][4]
EEVEE_WorldEngineData * EEVEE_world_data_ensure(World *wo)
Definition: eevee_data.c:365
struct GPUShader * EEVEE_shaders_studiolight_background_sh_get(void)
void EEVEE_shadows_cube_add(EEVEE_LightsInfo *linfo, EEVEE_Light *evli, struct Object *ob)
void EEVEE_occlusion_draw_debug(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_lightprobes_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void eevee_id_update(void *vedata, ID *id)
Definition: eevee_engine.c:414
void EEVEE_bloom_output_accumulate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct EEVEE_HairMotionData EEVEE_HairMotionData
void eevee_shader_material_create_info_amend(GPUMaterial *gpumat, GPUCodegenOutput *codegen, char *frag, char *vert, char *geom, char *defines)
struct GPUShader * EEVEE_shaders_effect_motion_blur_velocity_tiles_sh_get(void)
void EEVEE_reflection_output_accumulate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_occlusion_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples)
int EEVEE_bloom_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_render_cache(void *vedata, struct Object *ob, struct RenderEngine *engine, struct Depsgraph *depsgraph)
Definition: eevee_render.c:182
void EEVEE_renderpasses_init(EEVEE_Data *vedata)
struct EEVEE_LightProbeVisTest EEVEE_LightProbeVisTest
void EEVEE_effects_downsample_radiance_buffer(EEVEE_Data *vedata, struct GPUTexture *texture_src)
struct GPUShader * EEVEE_shaders_volumes_scatter_sh_get(void)
struct GPUShader * EEVEE_shaders_depth_of_field_dilate_tiles_get(bool pass)
void EEVEE_motion_blur_data_init(EEVEE_MotionBlurData *mb)
Definition: eevee_data.c:81
struct EEVEE_MotionBlurData EEVEE_MotionBlurData
void EEVEE_render_update_passes(struct RenderEngine *engine, struct Scene *scene, struct ViewLayer *view_layer)
Definition: eevee_render.c:682
void EEVEE_depth_of_field_draw(EEVEE_Data *vedata)
Material * EEVEE_material_default_diffuse_get(void)
void EEVEE_effects_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_effect_downsample_cube_sh_get(void)
void EEVEE_lookdev_draw(EEVEE_Data *vedata)
void EEVEE_materials_cache_populate(EEVEE_Data *vedata, EEVEE_ViewLayerData *sldata, Object *ob, bool *cast_shadow)
struct GPUShader * EEVEE_shaders_effect_minz_downdepth_sh_get(void)
struct GPUShader * EEVEE_shaders_effect_reflection_trace_sh_get(void)
void EEVEE_random_rotation_m4(int sample_ofs, float scale, float r_mat[4][4])
void EEVEE_effects_draw_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
#define MAX_BLOOM_STEP
Definition: eevee_private.h:40
void EEVEE_lights_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
Definition: eevee_lights.c:192
void EEVEE_cryptomatte_cache_populate(EEVEE_Data *vedata, EEVEE_ViewLayerData *sldata, Object *ob)
void EEVEE_subsurface_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
EEVEE_GeometryMotionData * EEVEE_motion_blur_geometry_data_get(EEVEE_ObjectMotionData *mb_data)
Definition: eevee_data.c:153
struct GPUShader * EEVEE_shaders_ggx_lut_sh_get(void)
struct GPUShader * EEVEE_shaders_probe_filter_visibility_sh_get(void)
EEVEE_ObjectEngineData * EEVEE_object_data_get(Object *ob)
Definition: eevee_data.c:282
void EEVEE_cryptomatte_update_passes(struct RenderEngine *engine, struct Scene *scene, struct ViewLayer *view_layer)
struct EEVEE_LightEngineData EEVEE_LightEngineData
Material * EEVEE_material_default_glossy_get(void)
void EEVEE_depth_of_field_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_lightbake_render_world(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, struct GPUFrameBuffer *face_fb[6])
void EEVEE_renderpasses_draw(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_effect_reflection_resolve_sh_get(void)
void EEVEE_renderpasses_draw_debug(EEVEE_Data *vedata)
void EEVEE_render_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
Definition: eevee_render.c:164
struct bNodeTree * EEVEE_shader_default_surface_nodetree(Material *ma)
int EEVEE_motion_blur_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct EEVEE_ObjectEngineData EEVEE_ObjectEngineData
#define MAX_SHADOW_CUBE
Definition: eevee_private.h:39
void EEVEE_draw_effects(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_effect_minz_downlevel_sh_get(void)
struct GPUShader * EEVEE_shaders_effect_downsample_sh_get(void)
void EEVEE_reflection_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples)
void EEVEE_bloom_draw(EEVEE_Data *vedata)
Definition: eevee_bloom.c:234
void eevee_light_matrix_get(const EEVEE_Light *evli, float r_mat[4][4])
Definition: eevee_lights.c:16
struct GPUShader * EEVEE_shaders_probe_filter_diffuse_sh_get(void)
struct GPUShader * EEVEE_shaders_bloom_blit_get(bool high_quality)
void EEVEE_subsurface_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct EEVEE_TextureList EEVEE_TextureList
BLI_STATIC_ASSERT(sizeof(EEVEE_Shadow) *MAX_SHADOW+sizeof(EEVEE_ShadowCascade) *MAX_SHADOW_CASCADE+sizeof(EEVEE_ShadowCube) *MAX_SHADOW_CUBE< 16384, "Shadow UBO is too big!!!") typedef struct EEVEE_ShadowCasterBuffer
void eevee_shader_extra_init(void)
int EEVEE_temporal_sampling_sample_count_get(const Scene *scene, const EEVEE_StorageList *stl)
struct GPUShader * EEVEE_shaders_effect_motion_blur_hair_sh_get(void)
void EEVEE_subsurface_add_pass(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, Material *ma, DRWShadingGroup *shgrp, struct GPUMaterial *gpumat)
void EEVEE_subsurface_output_accumulate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_lightprobes_grid_data_from_object(Object *ob, EEVEE_LightGrid *egrid, int *offset)
struct EEVEE_ShadowCascadeRender EEVEE_ShadowCascadeRender
struct EEVEE_ObjectKey EEVEE_ObjectKey
void EEVEE_renderpasses_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples)
void EEVEE_temporal_sampling_draw(EEVEE_Data *vedata)
void EEVEE_cryptomatte_render_result(struct RenderLayer *rl, const char *viewname, const rcti *rect, EEVEE_Data *vedata, EEVEE_ViewLayerData *sldata)
void EEVEE_motion_blur_step_set(EEVEE_Data *vedata, int step)
struct GPUMaterial * EEVEE_material_default_get(struct Scene *scene, Material *ma, int options)
struct GPUShader * EEVEE_shaders_probe_cube_display_sh_get(void)
struct GPUShader * EEVEE_shaders_volumes_integration_sh_get(void)
void EEVEE_create_minmax_buffer(EEVEE_Data *vedata, struct GPUTexture *depth_src, int layer)
void EEVEE_lightbake_render_scene(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, struct GPUFrameBuffer *face_fb[6], const float pos[3], float near_clip, float far_clip)
void EEVEE_sample_ball(int sample_ofs, float radius, float rsample[3])
struct bNodeTree * EEVEE_shader_default_world_nodetree(World *wo)
void EEVEE_shadows_cascade_add(EEVEE_LightsInfo *linfo, EEVEE_Light *evli, struct Object *ob)
struct GPUShader * EEVEE_shaders_effect_maxz_copydepth_layer_sh_get(void)
struct GPUShader * EEVEE_shaders_taa_resolve_sh_get(EEVEE_EffectsFlag enabled_effects)
uint EEVEE_renderpasses_aov_hash(const ViewLayerAOV *aov)
void EEVEE_cryptomatte_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
eEEVEEMotionData
@ EEVEE_MOTION_DATA_HAIR
@ EEVEE_MOTION_DATA_MESH
void EEVEE_motion_hair_step_free(EEVEE_HairMotionStepData *step_data)
Definition: eevee_data.c:74
void EEVEE_render_draw(EEVEE_Data *vedata, struct RenderEngine *engine, struct RenderLayer *rl, const struct rcti *rect)
#define MAX_PLANAR
Definition: eevee_private.h:34
void EEVEE_shadows_caster_register(EEVEE_ViewLayerData *sldata, struct Object *ob)
void EEVEE_renderpasses_cache_finish(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
#define MAX_PROBE
Definition: eevee_private.h:32
void EEVEE_motion_blur_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct EEVEE_ViewLayerData EEVEE_ViewLayerData
void EEVEE_lightbake_filter_diffuse(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, struct GPUTexture *rt_color, struct GPUFrameBuffer *fb, int grid_offset, float intensity)
struct GPUShader * EEVEE_shaders_volumes_accum_sh_get(void)
struct GPUShader * EEVEE_shaders_subsurface_second_pass_sh_get(void)
void EEVEE_cryptomatte_free(EEVEE_Data *vedata)
struct EEVEE_PrivateData EEVEE_PrivateData
void EEVEE_motion_blur_draw(EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_effect_minz_downdepth_layer_sh_get(void)
struct GPUShader * EEVEE_shaders_probe_planar_downsample_sh_get(void)
void EEVEE_lightprobes_cache_add(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, Object *ob)
void EEVEE_shadows_init(EEVEE_ViewLayerData *sldata)
Definition: eevee_shadows.c:26
void EEVEE_mist_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
Definition: eevee_mist.c:20
struct EEVEE_HairMotionStepData EEVEE_HairMotionStepData
int EEVEE_depth_of_field_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, Object *camera)
EEVEE_EffectsFlag
@ EFFECT_TAA_REPROJECT
@ EFFECT_RADIANCE_BUFFER
@ EFFECT_DOUBLE_BUFFER
@ EFFECT_MOTION_BLUR
@ EFFECT_SSS
@ EFFECT_GTAO
@ EFFECT_DOF
@ EFFECT_BLOOM
@ EFFECT_VELOCITY_BUFFER
@ EFFECT_DEPTH_DOUBLE_BUFFER
@ EFFECT_REFRACT
@ EFFECT_POST_BUFFER
@ EFFECT_NORMAL_BUFFER
@ EFFECT_SSR
@ EFFECT_TAA
@ EFFECT_VOLUMETRIC
static const float cubefacemat[6][4][4]
float * EEVEE_lut_update_ggx_btdf(int lut_size, int lut_depth)
Definition: eevee_lut_gen.c:60
void EEVEE_materials_cache_finish(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_temporal_sampling_cache_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
int EEVEE_occlusion_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct EEVEE_EffectsInfo EEVEE_EffectsInfo
void EEVEE_lightprobes_refresh_planar(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct EEVEE_ShadowCube EEVEE_ShadowCube
void EEVEE_materials_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, EEVEE_StorageList *stl, EEVEE_FramebufferList *fbl)
struct GPUShader * EEVEE_shaders_effect_ambient_occlusion_debug_sh_get(void)
struct GPUShader * EEVEE_shaders_depth_of_field_scatter_get(bool is_foreground, bool bokeh_tx)
#define MAX_GRID
Definition: eevee_private.h:33
struct EEVEE_LightProbesInfo EEVEE_LightProbesInfo
struct GPUShader * EEVEE_shaders_effect_motion_blur_velocity_tiles_expand_sh_get(void)
struct GPUShader * EEVEE_shaders_depth_of_field_gather_get(EEVEE_DofGatherPass pass, bool bokeh_tx)
EEVEE_LightEngineData * EEVEE_light_data_ensure(Object *ob)
Definition: eevee_data.c:342
int EEVEE_screen_raytrace_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_volumes_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
Definition: eevee_volumes.c:63
EEVEE_HairMotionData * EEVEE_motion_blur_curves_data_get(EEVEE_ObjectMotionData *mb_data)
Definition: eevee_data.c:177
struct GPUShader * EEVEE_shaders_studiolight_probe_sh_get(void)
void EEVEE_volumes_output_accumulate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_shadows_draw(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, struct DRWView *view)
struct GPUMaterial * EEVEE_material_get(EEVEE_Data *vedata, struct Scene *scene, Material *ma, World *wo, int options)
#define MAX_LIGHT
Definition: eevee_private.h:35
struct GPUShader * EEVEE_shaders_bloom_upsample_get(bool high_quality)
struct GPUShader * EEVEE_shaders_effect_mist_sh_get(void)
Material * EEVEE_material_default_error_get(void)
struct GPUShader * EEVEE_shaders_update_noise_sh_get(void)
struct GPUShader * EEVEE_shaders_bloom_resolve_get(bool high_quality)
struct EEVEE_Data EEVEE_Data
EEVEE_HairMotionData * EEVEE_motion_blur_hair_data_get(EEVEE_ObjectMotionData *mb_data, Object *ob)
Definition: eevee_data.c:163
void EEVEE_bloom_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples)
struct GPUShader * EEVEE_shaders_ggx_refraction_lut_sh_get(void)
struct GPUShader * EEVEE_shaders_depth_of_field_flatten_tiles_get(void)
void EEVEE_sample_rectangle(int sample_ofs, const float x_axis[3], const float y_axis[3], float size_x, float size_y, float rsample[3])
void EEVEE_motion_blur_hair_cache_populate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, Object *ob, struct ParticleSystem *psys, struct ModifierData *md)
void EEVEE_material_renderpasses_init(EEVEE_Data *vedata)
void EEVEE_temporal_sampling_create_view(EEVEE_Data *vedata)
void EEVEE_volumes_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples)
BLI_INLINE bool eevee_hdri_preview_overlay_enabled(const View3D *v3d)
void EEVEE_temporal_sampling_update_matrices(EEVEE_Data *vedata)
void EEVEE_shadow_output_accumulate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_volumes_scatter_with_lights_sh_get(void)
struct GPUShader * EEVEE_shaders_effect_ambient_occlusion_sh_get(void)
void EEVEE_material_output_accumulate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_volumes_clear_sh_get(void)
struct EEVEE_FramebufferList EEVEE_FramebufferList
struct GPUShader * EEVEE_shaders_depth_of_field_resolve_get(bool use_bokeh_tx, bool use_hq_gather)
#define MAX_CASCADE_NUM
Definition: eevee_private.h:36
bool EEVEE_depth_of_field_jitter_get(EEVEE_EffectsInfo *effects, float r_jitter[2], float *r_focus_distance)
struct EEVEE_RenderPassData EEVEE_RenderPassData
struct GPUShader * EEVEE_shaders_depth_of_field_reduce_get(bool is_copy_pass)
EEVEE_ViewLayerData * EEVEE_view_layer_data_ensure_ex(struct ViewLayer *view_layer)
Definition: eevee_data.c:246
void EEVEE_materials_free(void)
struct EEVEE_Light EEVEE_Light
void EEVEE_view_layer_data_free(void *storage)
Definition: eevee_data.c:191
struct GPUShader * EEVEE_shaders_volumes_resolve_sh_get(bool accum)
@ KEY_HAIR
@ KEY_CULL
@ KEY_SHADOW
@ KEY_REFRACT
void EEVEE_motion_blur_data_free(EEVEE_MotionBlurData *mb)
Definition: eevee_data.c:98
struct GPUShader * EEVEE_shaders_shadow_sh_get(void)
void EEVEE_cryptomatte_store_metadata(EEVEE_Data *vedata, struct RenderResult *render_result)
struct EEVEE_BoundBox EEVEE_BoundBox
struct GPUShader * EEVEE_shaders_effect_maxz_downdepth_layer_sh_get(void)
struct GPUShader * EEVEE_shaders_effect_motion_blur_object_sh_get(void)
void EEVEE_shadows_draw_cubemap(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, int cube_index)
void EEVEE_particle_hair_cache_populate(EEVEE_Data *vedata, EEVEE_ViewLayerData *sldata, Object *ob, bool *cast_shadow)
#define MAX_SHADOW
Definition: eevee_private.h:37
struct EEVEE_StorageList EEVEE_StorageList
void EEVEE_subsurface_draw_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_material_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples)
struct DRWShaderLibrary * EEVEE_shader_lib_get(void)
struct EEVEE_ObjectMotionData EEVEE_ObjectMotionData
struct GPUShader * EEVEE_shaders_probe_filter_glossy_sh_get(void)
struct GPUShader * EEVEE_shaders_probe_grid_display_sh_get(void)
void EEVEE_lightbake_filter_glossy(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, struct GPUTexture *rt_color, struct GPUFrameBuffer *fb, int probe_idx, float intensity, int maxlevel, float filter_quality, float firefly_fac)
void EEVEE_subsurface_output_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, uint tot_samples)
void EEVEE_renderpasses_postprocess(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, eViewLayerEEVEEPassType renderpass_type, int aov_index)
void EEVEE_object_curves_cache_populate(EEVEE_Data *vedata, EEVEE_ViewLayerData *sldata, Object *ob, bool *cast_shadow)
void EEVEE_temporal_sampling_offset_calc(const double ht_point[2], float filter_size, float r_offset[2])
void EEVEE_lookdev_cache_init(EEVEE_Data *vedata, EEVEE_ViewLayerData *sldata, DRWPass *pass, EEVEE_LightProbesInfo *pinfo, DRWShadingGroup **r_shgrp)
void EEVEE_cryptomatte_renderpasses_init(EEVEE_Data *vedata)
bool EEVEE_renderpasses_only_first_sample_pass_active(EEVEE_Data *vedata)
EEVEE_ObjectMotionData * EEVEE_motion_blur_object_data_get(EEVEE_MotionBlurData *mb, Object *ob, bool is_psys)
Definition: eevee_data.c:117
void EEVEE_motion_blur_curves_cache_populate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata, Object *ob)
struct GPUShader * EEVEE_shaders_renderpasses_post_process_sh_get(void)
void EEVEE_shaders_material_shaders_init(void)
EEVEE_LightProbeEngineData * EEVEE_lightprobe_data_ensure(Object *ob)
Definition: eevee_data.c:316
LightProbeCache EEVEE_LightProbe
bool EEVEE_render_init(EEVEE_Data *vedata, struct RenderEngine *engine, struct Depsgraph *depsgraph)
Definition: eevee_render.c:35
struct EEVEE_LightProbeEngineData EEVEE_LightProbeEngineData
struct GPUShader * EEVEE_shaders_bloom_downsample_get(bool high_quality)
void EEVEE_occlusion_output_accumulate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUShader * EEVEE_shaders_depth_of_field_downsample_get(void)
void EEVEE_subsurface_data_render(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_mist_output_accumulate(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
struct GPUTexture * EEVEE_materials_get_util_tex(void)
void EEVEE_occlusion_compute(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
void EEVEE_volumes_draw_init(EEVEE_ViewLayerData *sldata, EEVEE_Data *vedata)
EEVEE_WorldEngineData * EEVEE_world_data_get(World *wo)
Definition: eevee_data.c:360
struct GPUShader * EEVEE_shaders_depth_of_field_filter_get(void)
void eevee_contact_shadow_setup(const Light *la, EEVEE_Shadow *evsh)
Definition: eevee_shadows.c:19
uint pos
BLI_INLINE float fb(float length, float L)
int count
ccl_gpu_kernel_postfix ccl_global float int int int int float bool int offset
static void update(bNodeTree *ntree)
ViewInfos storage
Definition: draw_manager.h:436
float halfdim[3]
EEVEE_TextureList * txl
EEVEE_StorageList * stl
void * instance_data
EEVEE_PassList * psl
EEVEE_FramebufferList * fbl
void * engine_type
char info[GPU_INFO_SIZE]
float blit_texel_size[2]
struct GPUTexture * dof_scatter_src_tx
struct GPUTexture * gtao_horizons_renderpass
float downsamp_texel_size[MAX_BLOOM_STEP][2]
struct GPUTexture * dof_coc_dilated_tiles_bg_tx
struct GPUTexture * source_buffer
float prev_drw_persmat[4][4]
struct GPUTexture * sss_irradiance
struct GPUTexture * gtao_horizons
struct GPUTexture * dof_bokeh_scatter_lut_tx
struct GPUTexture * dof_reduce_input_color_tx
struct GPUTexture * dof_coc_dilated_tiles_fg_tx
struct GPUTexture * dof_fg_holefill_weight_tx
float motion_blur_near_far[2]
struct GPUTexture * velocity_tiles_x_tx
float bloom_curve_threshold[4]
struct GPUTexture * final_tx
struct GPUTexture * dof_fg_color_tx
float dof_scatter_color_threshold
struct GPUTexture * ssr_hit_output
struct GPUTexture * dof_bg_color_tx
float unf_source_texel_size[2]
struct GPUTexture * bloom_blit
struct GPUFrameBuffer * target_buffer
struct GPUTexture * dof_coc_tiles_bg_tx
bool ssr_was_valid_double_buffer
struct GPUTexture * bloom_upsample[MAX_BLOOM_STEP - 1]
float current_world_to_ndc[4][4]
float dof_bokeh_aniso[2]
struct GPUTexture * ssr_specrough_input
eDRWLevelOfDetail sphere_lod
struct GPUTexture * sss_blur
struct GPUTexture * sss_radius
struct GPUTexture * volume_transmit
struct GPUTexture * velocity_tiles_tx
float dof_bokeh_aniso_inv[2]
struct GPUTexture * volume_scatter
struct GPUTexture * dof_downsample_tx
struct GPUTexture * dof_fg_weight_tx
struct GPUTexture * bloom_downsample[MAX_BLOOM_STEP]
struct GPUTexture * dof_fg_occlusion_tx
float source_texel_size[2]
CameraParams current_cam_params
EEVEE_EffectsFlag enabled_effects
struct GPUTexture * unf_base_buffer
struct GPUTexture * sss_stencil
struct GPUTexture * velocity_tx
struct GPUTexture * gtao_horizons_debug
struct GPUTexture * dof_half_res_color_tx
struct GPUTexture * dof_bokeh_resolve_lut_tx
float prev_persmat[4][4]
float dof_scatter_coc_threshold
struct GPUFrameBuffer * final_fb
struct GPUTexture * ssr_normal_input
struct GPUTexture * dof_reduce_input_coc_tx
struct DRWView * lookdev_view
struct GPUTexture * dof_fg_holefill_color_tx
struct GPUTexture * dof_coc_tiles_fg_tx
float dof_coc_params[2]
struct DRWView * taa_view
eGPUTextureFormat dof_color_format
int dof_dilate_ring_width_multiplier
float current_world_to_view[4][4]
struct GPUTexture * unf_source_buffer
float dof_scatter_neighbor_max_color
struct GPUTexture * dof_bg_occlusion_tx
struct GPUTexture * dof_bokeh_gather_lut_tx
struct GPUTexture * ssr_hit_depth
struct EEVEE_MotionBlurData motion_blur
struct GPUTexture * dof_half_res_coc_tx
float past_world_to_ndc[4][4]
float past_world_to_view[4][4]
struct GPUTexture * sss_albedo
CameraParams past_cam_params
float current_ndc_to_world[4][4]
struct GPUTexture * dof_bg_weight_tx
struct GPUFrameBuffer * volumetric_fb
struct GPUFrameBuffer * main_fb
struct GPUFrameBuffer * volumetric_scat_fb
struct GPUFrameBuffer * sss_resolve_fb
struct GPUFrameBuffer * bloom_blit_fb
struct GPUFrameBuffer * taa_history_color_fb
struct GPUFrameBuffer * radiance_filtered_fb
struct GPUFrameBuffer * screen_tracing_fb
struct GPUFrameBuffer * velocity_tiles_fb[2]
struct GPUFrameBuffer * mist_accum_fb
struct GPUFrameBuffer * planar_downsample_fb
struct GPUFrameBuffer * dof_gather_fg_fb
struct GPUFrameBuffer * dof_reduce_copy_fb
struct GPUFrameBuffer * double_buffer_color_fb
struct GPUFrameBuffer * gtao_fb
struct GPUFrameBuffer * update_noise_fb
struct GPUFrameBuffer * sss_translucency_fb
struct GPUFrameBuffer * velocity_resolve_fb
struct GPUFrameBuffer * cryptomatte_fb
struct GPUFrameBuffer * dof_flatten_tiles_fb
struct GPUFrameBuffer * sss_blit_fb
struct GPUFrameBuffer * material_accum_fb
struct GPUFrameBuffer * ao_accum_fb
struct GPUFrameBuffer * dof_filter_fg_fb
struct GPUFrameBuffer * double_buffer_depth_fb
struct GPUFrameBuffer * dof_bokeh_fb
struct GPUFrameBuffer * sss_accum_fb
struct GPUFrameBuffer * volumetric_integ_fb
struct GPUFrameBuffer * downsample_fb
struct GPUFrameBuffer * sss_clear_fb
struct GPUFrameBuffer * shadow_accum_fb
struct GPUFrameBuffer * dof_setup_fb
struct GPUFrameBuffer * taa_history_fb
struct GPUFrameBuffer * main_color_fb
struct GPUFrameBuffer * bloom_pass_accum_fb
struct GPUFrameBuffer * dof_downsample_fb
struct GPUFrameBuffer * dof_reduce_fb
struct GPUFrameBuffer * double_buffer_fb
struct GPUFrameBuffer * sss_blur_fb
struct GPUFrameBuffer * effect_fb
struct GPUFrameBuffer * dof_gather_bg_fb
struct GPUFrameBuffer * dof_scatter_bg_fb
struct GPUFrameBuffer * planarref_fb
struct GPUFrameBuffer * velocity_fb
struct GPUFrameBuffer * bloom_accum_fb[MAX_BLOOM_STEP - 1]
struct GPUFrameBuffer * renderpass_fb
struct GPUFrameBuffer * volumetric_accum_fb
struct GPUFrameBuffer * gtao_debug_fb
struct GPUFrameBuffer * dof_dilate_tiles_fb
struct GPUFrameBuffer * maxzbuffer_fb
struct GPUFrameBuffer * dof_gather_fg_holefill_fb
struct GPUFrameBuffer * dof_scatter_fg_fb
struct GPUFrameBuffer * ssr_accum_fb
struct GPUFrameBuffer * dof_filter_bg_fb
struct GPUFrameBuffer * bloom_down_fb[MAX_BLOOM_STEP]
struct GPUFrameBuffer * effect_color_fb
struct GPUVertBuf * vbo[2]
eEEVEEMotionData type
struct GPUBatch * batch
eEEVEEMotionData type
EEVEE_HairMotionStepData step_data[2]
struct EEVEE_HairMotionData::@209 psys[0]
struct GPUTexture * hair_pos_tx
struct GPUVertBuf * hair_pos
struct Collection * collection
EEVEE_LightProbeVisTest vis_data
float probemat[6][4][4]
EEVEE_LightProbeVisTest planar_vis_tests[MAX_PLANAR]
EEVEE_LightGrid grid_data[MAX_GRID]
EEVEE_LightProbe probe_data[MAX_PROBE]
EEVEE_PlanarReflection planar_data[MAX_PLANAR]
float rightvec[3]
float color[3]
float forwardvec[3]
float upvec[3]
float light_type
float invsqrdist
float invsqrdist_volume
float volume_radius
float position[3]
struct EEVEE_Light light_data[MAX_LIGHT]
struct EEVEE_LightsInfo::@207 shcaster_aabb
struct EEVEE_ShadowCasterBuffer * shcaster_frontbuffer
uchar shadow_cascade_light_indices[MAX_SHADOW_CASCADE]
struct EEVEE_Shadow shadow_data[MAX_SHADOW]
struct EEVEE_ShadowCube shadow_cube_data[MAX_SHADOW_CUBE]
struct BoundSphere shadow_bounds[MAX_LIGHT]
BLI_bitmap sh_cube_update[BLI_BITMAP_SIZE(MAX_SHADOW_CUBE)]
struct EEVEE_ShadowCascadeRender shadow_cascade_render[MAX_SHADOW_CASCADE]
uchar shadow_cube_light_indices[MAX_SHADOW_CUBE]
struct EEVEE_ShadowCasterBuffer * shcaster_backbuffer
struct EEVEE_ShadowCascade shadow_cascade_data[MAX_SHADOW_CASCADE]
struct GHash * hair_motion_step_cache[2]
struct EEVEE_MotionBlurData::@208 camera[3]
struct GHash * position_vbo_cache[2]
struct GHash * object
DRWShadingGroup * hair_grp
EEVEE_LightProbeVisTest * test_data
struct Object * parent
float obmat[3][4][4]
EEVEE_GeometryMotionData * geometry_data
EEVEE_HairMotionData * hair_data
struct DRWPass * material_sss_ps
struct DRWPass * dof_reduce_copy
struct DRWPass * bloom_resolve
struct DRWPass * probe_planar_downsample_ps
struct DRWPass * velocity_object
struct DRWPass * dof_setup
struct DRWPass * transparent_pass
struct DRWPass * dof_gather_bg
struct DRWPass * lookdev_diffuse_pass
struct DRWPass * sss_resolve_ps
struct DRWPass * depth_cull_ps
struct DRWPass * ao_accum_ps
struct DRWPass * dof_bokeh
struct DRWPass * dof_gather_fg
struct DRWPass * depth_refract_ps
struct DRWPass * depth_clip_ps
struct DRWPass * sss_blur_ps
struct DRWPass * bloom_upsample
struct DRWPass * material_accum_ps
struct DRWPass * depth_ps
struct DRWPass * sss_translucency_ps
struct DRWPass * alpha_checker
struct DRWPass * velocity_tiles
struct DRWPass * depth_clip_cull_ps
struct DRWPass * material_refract_ps
struct DRWPass * dof_gather_fg_holefill
struct DRWPass * maxz_copydepth_ps
struct DRWPass * depth_refract_clip_cull_ps
struct DRWPass * motion_blur
struct DRWPass * velocity_tiles_expand[2]
struct DRWPass * maxz_copydepth_layer_ps
struct DRWPass * material_sss_cull_ps
struct DRWPass * probe_background
struct DRWPass * dof_scatter_fg
struct DRWPass * dof_scatter_bg
struct DRWPass * volumetric_objects_ps
struct DRWPass * probe_diffuse_compute
struct DRWPass * volumetric_integration_ps
struct DRWPass * velocity_resolve
struct DRWPass * ssr_resolve
struct DRWPass * velocity_tiles_x
struct DRWPass * dof_reduce
struct DRWPass * depth_refract_cull_ps
struct DRWPass * shadow_accum_pass
struct DRWPass * material_ps
struct DRWPass * depth_refract_clip_ps
struct DRWPass * renderpass_pass
struct DRWPass * maxz_downlevel_ps
struct DRWPass * bloom_downsample_first
struct DRWPass * probe_display
struct DRWPass * probe_glossy_compute
struct DRWPass * volumetric_world_ps
struct DRWPass * bloom_blit
struct DRWPass * color_copy_ps
struct DRWPass * dof_downsample
struct DRWPass * lookdev_glossy_pass
struct DRWPass * bloom_accum_ps
struct DRWPass * dof_flatten_tiles
struct DRWPass * mist_accum_ps
struct DRWPass * background_accum_ps
struct DRWPass * probe_grid_fill
struct DRWPass * ao_horizon_search
struct DRWPass * velocity_hair
struct DRWPass * dof_resolve
struct DRWPass * update_noise_pass
struct DRWPass * cryptomatte_ps
struct DRWPass * taa_resolve
struct DRWPass * ssr_raytrace
struct DRWPass * shadow_pass
struct DRWPass * ao_horizon_debug
struct DRWPass * color_downsample_cube_ps
struct DRWPass * material_cull_ps
struct DRWPass * probe_visibility_compute
struct DRWPass * dof_dilate_tiles_minmax
struct DRWPass * dof_dilate_tiles_minabs
struct DRWPass * volumetric_scatter_ps
struct DRWPass * material_refract_cull_ps
struct DRWPass * volumetric_resolve_ps
struct DRWPass * volumetric_accum_ps
struct DRWPass * dof_filter
struct DRWPass * background_ps
struct DRWPass * color_downsample_ps
struct DRWPass * bloom_downsample
float planar_texel_size[2]
struct DRWView * bake_views[6]
struct GPUUniformBuf * renderpass_ubo
eViewLayerEEVEEPassType render_passes
EEVEE_CryptomatteSample * cryptomatte_accum_buffer
float studiolight_glossy_clamp
struct DRWView * cube_views[6]
struct DRWShadingGroup * shadow_accum_shgrp
struct DRWView * world_views[6]
struct DRWShadingGroup * shadow_shgrp
GPUTexture * renderpass_light_input
struct CryptomatteSession * cryptomatte_session
struct LightCache * light_cache
struct GHash * material_hash
struct Object * cam_original_ob
float * cryptomatte_download_buffer
GPUTexture * renderpass_input
struct DRWView * planar_views[MAX_PLANAR]
float studiolight_filter_quality
GPUTexture * renderpass_col_input
int render_sample_count_per_timestep
float studiolight_matrix[3][3]
struct DRWCallBuffer * planar_display_shgrp
GPUTexture * renderpass_transmittance_input
float projmat[MAX_CASCADE_NUM][4][4]
float radius[MAX_CASCADE_NUM]
float shadowmat[MAX_CASCADE_NUM][4][4]
float shadowmat[4][4]
float contact_bias
float type_data_id
float contact_thickness
float contact_spread
float contact_dist
LightCacheTexture * lookdev_cube_mips
EEVEE_LightProbe * lookdev_cube_data
struct EEVEE_PrivateData * g_data
struct EEVEE_EffectsInfo * effects
EEVEE_LightGrid * lookdev_grid_data
struct LightCache * lookdev_lightcache
struct GPUTexture * filtered_radiance
struct GPUTexture * depth_double_buffer
struct GPUTexture * planar_depth
struct GPUTexture * sss_accum
struct GPUTexture * color_double_buffer
struct GPUTexture * spec_color_accum
struct GPUTexture * volume_scatter_history
struct GPUTexture * dof_reduced_coc
struct GPUTexture * maxzbuffer
struct GPUTexture * color_post
struct GPUTexture * volume_prop_extinction
struct GPUTexture * diff_light_accum
struct GPUTexture * emit_accum
struct GPUTexture * planar_pool
struct GPUTexture * renderpass
struct GPUTexture * lookdev_cube_tx
struct GPUTexture * volume_scatter_accum
struct GPUTexture * diff_color_accum
struct GPUTexture * dof_reduced_color
struct GPUTexture * ao_accum
struct GPUTexture * bloom_accum
struct GPUTexture * spec_light_accum
struct GPUTexture * lookdev_grid_tx
struct GPUTexture * volume_transmittance_accum
struct GPUTexture * volume_prop_emission
struct GPUTexture * volume_transmit
struct GPUTexture * taa_history
struct GPUTexture * color
struct GPUTexture * cryptomatte
struct GPUTexture * shadow_accum
struct GPUTexture * mist_accum
struct GPUTexture * volume_transmit_history
struct GPUTexture * volume_prop_phase
struct GPUTexture * env_accum
struct GPUTexture * aov_surface_accum[MAX_AOVS]
struct GPUTexture * volume_prop_scattering
struct GPUTexture * volume_scatter
struct GPUTexture * ssr_accum
struct EEVEE_CommonUniformBuffer common_data
struct GPUTexture * shadow_cube_pool
struct GPUUniformBuf * combined
struct GPUUniformBuf * diff_light
struct GPUUniformBuf * shadow_ubo
struct GPUUniformBuf * probe_ubo
struct GPUUniformBuf * shadow_samples_ubo
struct GPUUniformBuf * grid_ubo
struct GPUUniformBuf * emit
struct GPUFrameBuffer * shadow_fb
struct GPUUniformBuf * planar_ubo
struct EEVEE_ViewLayerData::@210 renderpass_ubo
struct GPUUniformBuf * spec_color
struct GPUUniformBuf * environment
struct LightCache * fallback_lightcache
struct GPUUniformBuf * diff_color
struct GPUUniformBuf * spec_light
struct GPUUniformBuf * common_ubo
struct BLI_memblock * material_cache
struct GPUUniformBuf * light_ubo
struct GPUUniformBuf * aovs[MAX_AOVS]
struct GPUTexture * shadow_cascade_pool
struct EEVEE_ShadowCasterBuffer shcasters_buffers[2]
struct EEVEE_LightsInfo * lights
struct EEVEE_LightProbesInfo * probes
Material * ma
Definition: gpu_material.c:71
char name[64]
Definition: gpu_material.c:93
GPUPass * pass
Definition: gpu_material.c:53
Definition: DNA_ID.h:368
View3DOverlay overlay
View3DShading shading