Commit Graph

369 Commits

Author SHA1 Message Date
chris kulla
8946c56eb6 Material Instance changes should cause path tracer to restart accumulation
FMaterialRenderProxy doesn't appear to know which FScene it belongs to, so I had to go through the global render module and flag all scenes instead

#rb Ben.Ingram, Jason.Nadro

[CL 16704202 by chris kulla in ue5-main branch]
2021-06-17 10:01:01 -04:00
tiago costa
7503b52da0 Updated most of distance field ambient occlusion codepath to use RDG.
- Resource state transitions handled by RDG.
- FDistanceFieldObjectBufferResource replaced by FDistanceFieldCulledObjectBufferParameters to use RDG.
- FTileIntersectionResources replaced by FTileIntersectionParameters to use RDG.
- FAOScreenGridResources replaced by FAOScreenGridParameters to use RDG.
- Don't store DFAO resources in View.State.
- Split FDeferredShadingSceneRenderer::RenderDistanceFieldAOScreenGrid() into multiple passes.
- Split BuildTileObjectLists() into multiple passes.

#rb daniel.wright

[CL 16660080 by tiago costa in ue5-main branch]
2021-06-14 12:45:34 -04:00
ola olsson
5560667259 Tracking GPU-Scene dirty state and specialize Primitive Id only updates to avoid redundant uploads.
- Added instance data validation
- Added general load balancer for instance processing on GPU (will move to own files later)
- Added initial GPU-side write access API for GPU scene.
- Addded specialized kernel to update primitive IDs in instances when that is the only change.

#rb graham.wihlidal
#jira UE-116671
#preflight 60c25d7b1264df0001aab80b


#ROBOMERGE-SOURCE: CL 16628528
#ROBOMERGE-BOT: (v831-16623017)

[CL 16628539 by ola olsson in ue5-main branch]
2021-06-10 15:46:35 -04:00
aurel cordonnier
e0ad4e25df Merge from Release-Engine-Test @ 16624776 to UE5/Main
This represents UE4/Main @ 16579691 and Dev-PerfTest @ 16579576

[CL 16625248 by aurel cordonnier in ue5-main branch]
2021-06-10 13:13:24 -04:00
charles derousiers
fefffd2c70 Move shader draw debug lock data onto the view state.
#rb none


#ROBOMERGE-SOURCE: CL 16606068
#ROBOMERGE-BOT: (v828-16531559)

[CL 16606075 by charles derousiers in ue5-main branch]
2021-06-09 11:32:39 -04:00
ola olsson
131fbfdb66 Moved Allocate/Free of GPU-Scene Instance out of AddToScene/RemoveFromScene as these are called for primitive transform updates.
#preflight 60bf262b0c76f90001ddb21d
#rb rune.stubbe,Krzysztof.Narkowicz


#ROBOMERGE-OWNER: ola.olsson
#ROBOMERGE-AUTHOR: ola.olsson
#ROBOMERGE-SOURCE: CL 16589643
#ROBOMERGE-BOT: (v828-16531559)
#ROBOMERGE-CONFLICT from-shelf

[CL 16590284 by ola olsson in ue5-main branch]
2021-06-08 14:33:44 -04:00
Wei Liu
de5a48902e 1. Fix a bug of missing velocity due to wrong LoadAction for parallel rendering.
2. Add a project setting option to avoid generating velocity and TAA shader unexpectly for mobile platform.

#jira none

#rb Dmitriy.Dyomin, Guillaume.Abadie

[CL 16584354 by Wei Liu in ue5-main branch]
2021-06-08 06:01:07 -04:00
peter knepley
9938808ec4 Fix build break caused by not wrapping code using PrimitivesSelected with WITH_EDITOR
#ROBOMERGE-SOURCE: CL 16548238
#ROBOMERGE-BOT: (v828-16531559)

[CL 16548245 by peter knepley in ue5-main branch]
2021-06-03 11:53:36 -04:00
peter knepley
66b62daa60 UPrimitiveComponent::PushSelectionToProxy() should not call MarkRenderStateDirty() for perf reasons. Fix up FScene::PrimitivesSelected array that came in with 15937150
#ROBOMERGE-SOURCE: CL 16547899
#ROBOMERGE-BOT: (v828-16531559)

[CL 16547920 by peter knepley in ue5-main branch]
2021-06-03 11:25:45 -04:00
Jeremy Moore
88a92a1acd Add compute.RebuildComputeGraphs console command for live updating compute framework.
#jira none
#rb none

[CL 16473665 by Jeremy Moore in ue5-main branch]
2021-05-26 15:25:07 -04:00
Sebastien Hillaire
baed13200f AtmosphericFog component removal from UE5.
Clean up atmospheric fog and have it instaciate a sky atmosphere by default instead
AtmosphericFog now inherits from SkyAtmosphere and looks vaguely similar. Serialisation is handled with a serialisation enum + ue5 version.
"ClassRedirects" could not be used because parameters are not compatible and also due to different serialisation on both component.

So instead Skyamtosphere now has a bool bIsAtmosphericFog (false by default).
AtmosphericFog component now inheriting from Skyatmosphere is setting that to true so that serialisation can be properly handled for both cases : pure Skyatmosphere or SkyAtmosphere replacing a AtmosphericFog with loading/saving. This also supports StaticLightingGUID once converted, see USkyAtmosphereComponent::Serialize.

SkyAtmosphere aerial perspective is now properly gated behind the base pass vertex shader designed for that using BASEPASS_SKYATMOSPHERE_AERIALPERSPECTIVE.

Removed all AtmosphericFog related render code.
Renamed a bunch of shader permutation.

UActorFactoryAtmosphericFog is removed so that the actor is no longer visible and instanciable from menu (existing actors in levels are still created correctly)
UAtmosphericFogComponent is made notplaceable.

ShooterGame compiled and ran succesfuly.
Colton Daniels (QA) will upate reference screneshot in a later CL.

#rb Charles.derousiers, Marc.Audy, Kevin.Ortegren

[CL 16455741 by Sebastien Hillaire in ue5-main branch]
2021-05-25 16:33:27 -04:00
jamie hayes
9389c3eb1e Add another optional separate translucency pass that gets composited after motion blur. Has no depth test (due to TAA color upsample with no upsampled depth), and is intended to work around reprojection and motion blur artifacts with translucency.
#rb zach.bethel, michal.valient
#jira none

[CL 16381727 by jamie hayes in ue5-main branch]
2021-05-19 02:09:02 -04:00
Charles deRousiers
e2e2ca2936 Add adaptive voxel allocation to avoid overallocation.
This CL adds GPU->CPU readback back to adpat voxel size based on previous frame allocated page count. If we run out of page, we increase voxel size, so that next allocations fit into the memory constraint. This approach is not perfect as at least one /two frames will have glitches (over allocation not-compensated) and continuous change, can create oscillation which are not so easy to counter balance due to latency.

Manual port of CL 16346703
#rb none
#jira UE-112274

[CL 16364797 by Charles deRousiers in ue5-main branch]
2021-05-18 04:16:02 -04:00
Jeremy Moore
6d2b42f0d0 ComputeGraph graph based compilation.
More work to do but this is a minimal functional starting point.
#rb halfdan.ingvarsson
#preflight 609da63e046b9d00010b8246

[CL 16321681 by Jeremy Moore in ue5-main branch]
2021-05-13 19:17:49 -04:00
aurel cordonnier
8eebe8841f Merge UE5/RET @ 16305968 to UE5/Main
This represents UE4/Main @ 16261013 and Dev-PerfTest @ 16259937

[CL 16306996 by aurel cordonnier in ue5-main branch]
2021-05-12 18:10:03 -04:00
Krzysztof Narkowicz
7cf4c5f5b8 Refactored Lumen Surface Cache lookup. DF and HWRT surface cache lookups are now unified into a single array, which translates SceneInstanceIndex into a LumenMeshCardsIndex. Later it could become a part of GPUScene if needed.
#fyi Patrick.Kelly, Daniel.Wright

[CL 16306367 by Krzysztof Narkowicz in ue5-main branch]
2021-05-12 17:17:39 -04:00
chris kulla
383c4dfeef Fix compile errors on non-raytracing platforms
#rb none

[CL 16251756 by chris kulla in ue5-main branch]
2021-05-10 14:39:52 -04:00
chris kulla
6df4146582 Make sure we pick the no-lightmap shader permutation when using the path tracer
This is another small step towards enabling path tracing specific shader permutations.

This requires re-caching the raytracing mesh commands when we flip to and from path traced rendering.

Cleanup some flag handling by removing the redundant ERayTracingRenderMode enum since it is already capture by show flags.

Avoid checking the path tracing flag per view since it is always common to all views

Re-introduce the deduplication over views for the non-path tracing case since ray tracing effects can be enabled in a view dependent fashion.

Rename CanOverlayRayTracingOutput to HasRayTracedOverlay which I think is a bit clearer. Note that the meaning has flipped - it now returns true when path tracing or ray tracing debug modes are enabled.

Remove leftovers of GAveragePathTracedMRays (which wasn't hooked up to anything anymore)

Refactor static variables used to store path tracing state into a pimpl object off of the ViewState

#rb Patrick.Kelly, Yuriy.ODonnell, Juan.Canada

[CL 16249998 by chris kulla in ue5-main branch]
2021-05-10 12:22:42 -04:00
Jeremy Moore
69408ed606 Fix submit of incorrect file.
#rb none

[CL 16247422 by Jeremy Moore in ue5-main branch]
2021-05-10 08:37:12 -04:00
Jeremy Moore
7e1f10ac1d #jira UE-114353
Fix one texel border of non black values in mask texture.
#rb none

[CL 16247389 by Jeremy Moore in ue5-main branch]
2021-05-10 08:33:11 -04:00
Yujiang Wang
4ac294d584 Fix PrimitiveId doesn't get updated during primitive array swapping
#rb none

[CL 16226814 by Yujiang Wang in ue5-main branch]
2021-05-06 18:08:31 -04:00
Andrew Davidson
3ddc3a4da3 Merge up from //UE5/Dev-LargeWorldCoordinates
#rb none

[CL 16211417 by Andrew Davidson in ue5-main branch]
2021-05-05 15:07:25 -04:00
brandon dawson
4da77d6fab Fix for major frame hitches when adding levels to a world. Previously, adding a level to the world would trigger a linear loop through all primitives in the scene, testing to see if they were in the current level, and calling OnLevelAddedToWorld() if they were flagged to do so. The more primitives in the scene, the larger the hitch.
Now, proxiess can register for needing an on added/removed from level call.  If this is requested, they are added to a map, which maintains a list of primitives that need the add/remove call, per level.

The only component that currently utilizes this is the Landscape component.  To facilitate it's needs, the generic flags used to determine if it should be visible have been removed from FPrimitiveSceneProxy, bRequiresVisibleLevelToRender bIsComponentLevelVisible, and replaced with bForceHidden.  The landscape component will now set that flag under the same circumstances as before.

[REVIEW] [at]sebastien.lussier [at]Nick.Whiting [at]patrick.enfedaque
#jira UE-UE-114943
#lockdown nick.whiting

#ROBOMERGE-SOURCE: CL 16207473 in //UE5/Release-5.0-EarlyAccess/...
#ROBOMERGE-BOT: STARSHIP (Release-5.0-EarlyAccess -> Main) (v796-16191650)

[CL 16207501 by brandon dawson in ue5-main branch]
2021-05-05 10:47:54 -04:00
Wei Liu
a0f4c7a293 Support CSM Caching.
#jira none

#rb Ola.Olsson, Dmitriy.Dyomin, Jack.Porter, Mi.Wang

[CL 16204572 by Wei Liu in ue5-main branch]
2021-05-05 04:18:08 -04:00
Krzysztof Narkowicz
d60cd46489 Fixed ray tracing primitive index. PrimitiveIndex was cached in CachedRayTracingInstance, but wasn't updated inside FScene_SwapPrimitiveSceneInfos leading to stale indices.
#rb Patrick.Kelly

[CL 16171318 by Krzysztof Narkowicz in ue5-main branch]
2021-04-30 14:37:59 -04:00