Browse Source

Merge pull request #58779 from techiepriyansh/forward-mobile-ambient-accum

Rémi Verschelde 3 năm trước cách đây
mục cha
commit
f488a841c7

+ 6 - 0
servers/rendering/renderer_rd/shaders/scene_forward_mobile.glsl

@@ -1054,6 +1054,12 @@ void main() {
 		if (reflection_accum.a > 0.0) {
 			specular_light = reflection_accum.rgb / reflection_accum.a;
 		}
+
+#if !defined(USE_LIGHTMAP)
+		if (ambient_accum.a > 0.0) {
+			ambient_light = ambient_accum.rgb / ambient_accum.a;
+		}
+#endif
 	} //Reflection probes
 
 	// finalize ambient light here