From d05ccd74d44b595d02d6032c9ed2c0f9ff21f5f0 Mon Sep 17 00:00:00 2001 From: Ptolemy Date: Thu, 14 Jul 2022 19:10:05 -0700 Subject: SL-17765: PBR: Add emissiveRect to class3 light shaders --- indra/newview/app_settings/shaders/class3/deferred/spotLightF.glsl | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'indra/newview/app_settings/shaders/class3/deferred/spotLightF.glsl') diff --git a/indra/newview/app_settings/shaders/class3/deferred/spotLightF.glsl b/indra/newview/app_settings/shaders/class3/deferred/spotLightF.glsl index 8768500682..e70a545a7b 100644 --- a/indra/newview/app_settings/shaders/class3/deferred/spotLightF.glsl +++ b/indra/newview/app_settings/shaders/class3/deferred/spotLightF.glsl @@ -38,6 +38,7 @@ uniform sampler2DRect diffuseRect; uniform sampler2DRect specularRect; uniform sampler2DRect depthMap; uniform sampler2DRect normalMap; +uniform sampler2DRect emissiveRect; // PBR linear packed Occlusion, Roughness, Metal. See: pbropaqueF.glsl uniform samplerCube environmentMap; uniform sampler2DRect lightMap; uniform sampler2D noiseMap; @@ -180,8 +181,10 @@ void main() if (GET_GBUFFER_FLAG(GBUFFER_FLAG_HAS_PBR)) { - vec3 colorDiffuse = vec3(0); - vec3 colorSpec = vec3(0); + vec3 colorDiffuse = vec3(0); + vec3 colorSpec = vec3(0); + vec3 colorEmissive = spec.rgb; // PBR sRGB Emissive. See: pbropaqueF.glsl + vec3 packedORM = texture2DRect(emissiveRect, tc).rgb; // PBR linear packed Occlusion, Roughness, Metal. See: pbropaqueF.glsl final_color = colorDiffuse + colorSpec; } -- cgit v1.2.3