error: cannot instantiate StructuredBuffer with given packed alignment; 'VK_EXT_scalar_block_layout' not supported
#rb Jamie.Hayes
[CODEREVIEW] Ola.Olsson
#rnx
#preflight 63200f15b602881e8eaee462
[CL 21986761 by marc audy in ue5-main branch]
- bMaterialMayModifyPosition -> bMaterialUsesWorldPositionOffset for non-nanite, we don't want to invalidate due to PDO
- Nanite instance culling records static primitives that invalidate the VSM (so they get cached as dynamic)
- Dirty page flags now store the invalidation as well (static & dynamic) so 3x in size
- Nanite VSM instance/cluster culling uses PRIMITIVE_SCENE_DATA_FLAG_EVALUATE_WORLD_POSITION_OFFSET to drive bHasMoved and invalidaiton.
- Non-nanite instance culling outputs dirty page flags for invalidating instances, with in-group load balancing for large footprints
- Store invalidation flags in physical page metadata flags (removed the cumulative dirty flags buffer).
- Added bAnyMaterialHasWorldPositionOffset (accessor AnyMaterialHasWorldPositionOffset()) to FPrimitiveSceneProxy.
- Driving PRIMITIVE_SCENE_DATA_FLAG_EVALUATE_WORLD_POSITION_OFFSET from bAnyMaterialHasWorldPositionOffset in addition to EvaluateWorldPositionOffset.
- Removed near clip permutation for non-nanite VSM culling shader.
- Non-nanite vsm raster passes are all batched in a single RDG pass to better allow overlap between draws and lower pass overhead.
- Removed old GPU->GPU invalidation logic.
- Removed dynamic caster flags and update the physical page metadata directly
- Renamed PRIMITIVE_SCENE_DATA_FLAG_SHOULD_CACHE_SHADOW -> PRIMITIVE_SCENE_DATA_FLAG_SHOULD_CACHE_SHADOW
#rb andrew.lauritzen,jamie.hayes
#jira UE-147061
#preflight 631b0a18a60c539c98cf1308
[CL 21973831 by ola olsson in ue5-main branch]
- Store cache flag in primitive scene proxy, default based on mobility initially
- When CPU invalidations of primitives that are cached as static happen, invalidate the entire primitive (all instances) and flip the flag to dynamic
- When GPU invalidations of primitives that are cached as static happen, mark a bit in a buffer that is read back to the CPU. In future frames, use the bits to find the associated primitive (if it still exists), swap it to dynamic and invalidate all of its instances
- Dynamic primitives are always cached as dynamic/movable
- Moved instance invalidation buffer ownership to cache manager (we don't need two copies at once)
#rb ola.olsson
#preflight 630d0d88660db81edb749282
#jira UE-133723
[CL 21696465 by andrew lauritzen in ue5-main branch]
Implemented single-page page table support for distant lights
- store only a single page table entry for distant lights
- modify page lookup logic in various places to handle this
Implemented override behavior to render everything to dynamic pages for a light that always invalidates using r.Shadow.Virtual.Cache.ForceInvalidateClipmaps (behave as uncached, despite caching being enabled).
This brings performance to par with uncached rendering by removing various overheads that are not achieving anything for this case.
- Added a new flag to the nanite view to indicate if it is uncached VSM_PROJ_FLAG_UNCACHED, currently driven by the cvar r.Shadow.Virtual.Cache.ForceInvalidateClipmaps
- If this flag is set on a view ShouldCacheInstanceAsStatic, which now takes a nanite view, returns false, causing all rendering to go to the dynamic pages.
- To preserve HZB functionality, the HZB build is modified to load from the dynamic depth pages (normally it uses the static)
- The page initializer (that clears depth) skips static pages for uncached bviews as they will not be used.
- Finally the page merge pass that combines static & dynamic depth into the dynamic page also skips pages from uncached views.
Optimized page allocation pass by storing the actual pages needing allocation from the cache init pass.
Optimized hierarchical page flag generation by dispatching over physical pages instead of virtual.
Fixed dynamic primitive cache invalidation logic.
#jira UE-122102
#rb andrew.lauritzen
#preflight 63087c2592620e5ec3aa3f2f
[CL 21590421 by ola olsson in ue5-main branch]
Focus started on GenerateMips and AddClearUAVPass.
#jira none
#rb mihnea.balta
#preflight 62fe768d200ff87e07c5e1ad
[CL 21448320 by christopher waters in ue5-main branch]
- Also fetch correct light data when the light list is compacted.
#jira UE-160440,FORT-501102
#rb rune.stubbe,kevin.ortegren
[FYI] andrew.lauritzen
#preflight 62fb844dfd15f5152dc15b37
#ROBOMERGE-AUTHOR: ola.olsson
#ROBOMERGE-SOURCE: CL 21404060 via CL 21404063 via CL 21404064
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v975-21357124)
[CL 21407091 by ola olsson in ue5-main branch]
- Added FShadowSceneRenderer to handle shadow rendering (transient) work - intended to take over more responsibility from here on.
- Added cache invalidation when lights are removed from the FScene (required as ID / cache key may change)
- Modified caching scheme to drop cache entries when caching is disabled.
- Changed local light footprint estimation to depend on the scaled resolution (screen percentage)
- Moved light location data and test to per-light cache entry (rather than per-shadow map)
#rb andrew.lauritzen
#jira UE-122102
#preflight 62d820cb4b6d775f5fa9328a
#ROBOMERGE-OWNER: ola.olsson
#ROBOMERGE-AUTHOR: ola.olsson
#ROBOMERGE-SOURCE: CL 21198820 via CL 21198827 via CL 21198864
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v972-20964824)
[CL 21199396 by ola olsson in ue5-main branch]
- Added RangeBasedCullingDistance to Nanite view & NANITE_VIEW_FLAG_DISTANCE_CULL to indicate if used
- Added light radius to VSM projection data and added culling invalidations based on range also.
- Added unrelated flag & flag field to VSM to reduce shader header change churn (VSM_PROJ_FLAG_CURRENT_DISTANT_LIGHT).
- Added light range test in page marking shader.
Simplify Nanite LOD calculations by performing them in world space instead of local space
- This also allows us no longer precalculate ViewPosScaledLocal and ViewForwardScaledLocal in DynamicData
#rb rune.stubbe
#preflight 62beb9303f0d6beee2da98db
#ROBOMERGE-AUTHOR: ola.olsson
#ROBOMERGE-SOURCE: CL 20913913 via CL 20913992 via CL 20913998
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v971-20777995)
[CL 20916199 by ola olsson in ue5-main branch]
- Removed scene render mem-mark among others. MemStack usage is now restricted to local scopes with known marks.
- Render resources with destructors are allocated using the FSceneRenderingBulkObjectAllocator on FSceneRenderer, which is deleted when the scene render is.
#preflight 62b266e20d4d6228de97babe
#rb mihnea.balta, yuriy.odonnell
[CL 20907647 by zach bethel in ue5-main branch]
- Improvements to cube map filtering to eliminate various leaking artifacts at cube edges/corners
- Implement texel dither and optimal bias for local lights
- Remove some half stuff that was causing some sub-optimal compilation
- Fix VSM visualization alignment
- Add a general purpose permutation parameter that can be set for A/B testing projection performance that affects register allocation
- General cleanup
#rb ola.olsson
#preflight 62b350da767c9aaf349e3243
#ROBOMERGE-AUTHOR: andrew.lauritzen
#ROBOMERGE-SOURCE: CL 20779131 via CL 20780276 via CL 20780946
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v970-20704180)
[CL 20782054 by andrew lauritzen in ue5-main branch]
The refactor to get rid of the FSceneTextures and FSceneTexturesConfig global singletons has also been preserved. The FViewFamilyInfo is used to hold those structures, so client facing API functions that lack a scene renderer reference can still pull the FSceneTextures[Config] from the view family pointer. All other scene renderer state has been moved from FViewFamilyInfo back into FSceneRenderer.
#jira none
#rnx
#rb ola.olsson krzysztof.narkowicz zach.bethel
#preflight 629f770e233ae0a8f8fb7f2e
[CL 20540730 by jason hoerner in ue5-main branch]
Clients outside Renderer should use the default view, or the self managed FShaderPrintData (improvements to that incoming).
#preflight 629a384c6879a2ac678a889e
[CL 20488523 by Jeremy Moore in ue5-main branch]