Two pass occlusion for Non-VSM shadows
Changes shadowmap atlas rendering to render into the border, so we have real data for wide shadowmap filtering kernels. Also improves atlas HZB performance.
#rb ola.olsson
#fyi graham.wihlidal, brian.karis, andrew.lauritzen
[CL 14762582 by Rune Stubbe in ue5-main branch]
- Refactor shadow depth rendering high level to clean up passes a bit
- Add back in SnapResolution to allow the complete shadow maps to snap consistently with the shadow that is their copy source (otherwise the projections differ)
- NOTE: Shadow bias for directional lights is technically dependent on resolution, and it is baked into the high resolution map. Thus the copy path has a minor difference in biasing here but it's not major concern for the uses of the complete shadow map.
#rb ola.olsson
#ROBOMERGE-SOURCE: CL 14321491 in //UE5/Release-5.0-M2/...
#ROBOMERGE-BOT: STARSHIP (Release-5.0-M2 -> Main) (v738-14305781)
[CL 14321504 by andrew lauritzen in ue5-main branch]
- Use this shadow map for Lumen and volumetrics so that all geometry is present
- Resolution can be controlled with r.Shadow.CompleteShadowMapResolution (default 256). 0 disables, which will result in missing Nanite geometry in these secondary effects (as before this change)
- NOTE: Currently this shadow map is rendered with another pass over the geometry, but this will be replaced by a copy/resample/composite in a future change
Other changes:
- Some fixes to shadow map caching
- Some initial refactors to sorted projected shadow info lists; more to come to reduce the amount of code that iterates and filters AllProjectedShadows around the engine and centralize it in shadow setup.
- Removed unused parameters from a a few functions
#rb ola.olsson
#fyi krzysztof.narkowicz, daniel.wright, sebastien.hillaire
[CL 14224191 by andrew lauritzen in ue5-main branch]
#rnx
#rb none
#ROBOMERGE-OWNER: ryan.durand
#ROBOMERGE-AUTHOR: ryan.durand
#ROBOMERGE-SOURCE: CL 10869210 via CL 10869511 via CL 10869900
#ROBOMERGE-BOT: (v613-10869866)
[CL 10870549 by ryan durand in Main branch]
[FYI] Chris.Bunner
#ROBOMERGE-SOURCE: CL 8063389 via CL 8063473 via CL 8063708 via CL 8092934
#ROBOMERGE-BOT: (v401-8057353)
[CL 8093049 by jian ru in Main branch]
- Added validation for attempting to invert a non-invertible matrix in InverseFast().
- Band-aid check in volumetric fog code to skip light if it contains NaNs.
#rb Zabir.Hoque
#jira FORT-184135
#ROBOMERGE-SOURCE: CL 7263740 in //UE4/Release-4.23/...
#ROBOMERGE-BOT: RELEASE (Release-4.23 -> Main) (v369-7254125)
[CL 7263741 by zach bethel in Main branch]