Avoid voxel cone trace from going full 180 degrees, fixes #20716

This commit is contained in:
Juan Linietsky 2018-11-23 08:42:35 -03:00
parent 8ba0d513fa
commit a397d3a46a

View file

@ -1504,7 +1504,7 @@ void gi_probe_compute(mediump sampler3D probe, mat4 probe_xform, vec3 bounds, ve
//irradiance
vec3 irr_light = voxel_cone_trace(probe, cell_size, probe_pos, environment, blend_ambient, ref_vec, max(min_ref_tan, tan(roughness * 0.5 * M_PI)), max_distance, p_bias);
vec3 irr_light = voxel_cone_trace(probe, cell_size, probe_pos, environment, blend_ambient, ref_vec, max(min_ref_tan, tan(roughness * 0.5 * M_PI * 0.99)), max_distance, p_bias);
irr_light *= multiplier;
//irr_light=vec3(0.0);