From 7747d4cecf078589f614813d0e5e0a753d4e10b5 Mon Sep 17 00:00:00 2001 From: Jeroen Bakker Date: Mon, 18 Jun 2018 15:17:46 +0200 Subject: Workbench: increased Quality of the diffuse lighting model - implemented Spherical Harmonics L2 for diffuse shading. TODO: caching the precalculated harmonics so it won't take soo long to open the popover --- source/blender/blenkernel/BKE_studiolight.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/blender/blenkernel/BKE_studiolight.h') diff --git a/source/blender/blenkernel/BKE_studiolight.h b/source/blender/blenkernel/BKE_studiolight.h index 36de1e4d22f..0e94411030b 100644 --- a/source/blender/blenkernel/BKE_studiolight.h +++ b/source/blender/blenkernel/BKE_studiolight.h @@ -60,7 +60,7 @@ struct GPUTexture; enum StudioLightFlag { - STUDIOLIGHT_DIFFUSE_LIGHT_CALCULATED = (1 << 0), + STUDIOLIGHT_SPHERICAL_HARMONICS_COEFFICIENTS_CALCULATED = (1 << 0), STUDIOLIGHT_LIGHT_DIRECTION_CALCULATED = (1 << 1), STUDIOLIGHT_INTERNAL = (1 << 2), STUDIOLIGHT_EXTERNAL_FILE = (1 << 3), @@ -91,7 +91,7 @@ typedef struct StudioLight { int icon_id_matcap; int icon_id_matcap_flipped; int index; - float diffuse_light[6][3]; + float spherical_harmonics_coefs[9][3]; float light_direction[3]; ImBuf *equirectangular_radiance_buffer; ImBuf *equirectangular_irradiance_buffer; -- cgit v1.2.3