Workbench Next Volumes #105501
|
@ -209,6 +209,12 @@ vec4 volume_integration(vec3 ray_ori, vec3 ray_dir, float ray_inc, float ray_max
|
||||||
/* accumulate and also take into account the transmittance from previous steps */
|
/* accumulate and also take into account the transmittance from previous steps */
|
||||||
final_scattering += final_transmittance * Lscat;
|
final_scattering += final_transmittance * Lscat;
|
||||||
final_transmittance *= Tr;
|
final_transmittance *= Tr;
|
||||||
|
|
||||||
|
if (final_transmittance <= 0.01) {
|
||||||
|
/* Early out */
|
||||||
|
final_transmittance = 0;
|
||||||
pragma37 marked this conversation as resolved
Outdated
|
|||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return vec4(final_scattering, final_transmittance);
|
return vec4(final_scattering, final_transmittance);
|
||||||
|
|
Loading…
Reference in New Issue
Do not use implicit cast assignment. This is not supported by all drivers.