Commit Graph

119 Commits

Author SHA1 Message Date
derek ehrman
8df448566f [Backout] - CL23092056 - causing hangs on PC performance mode startup
[FYI] derek.ehrman
Original CL Desc
-----------------------------------------------------------------
Fix assert on IsInActualRenderingThread() by using IsInParallelRenderingThread() instead and inverting condition

#rnx
#rb Zach.Bethel
#preflight 636d4af5a430c8fbeab23e14
#p4v-cherrypick 23091910
[FYI] James.Doverspike, Danny.Couture, Zach.Bethel

[CL 23119732 by derek ehrman in ue5-main branch]
2022-11-14 11:48:57 -05:00
danny couture
791cf2f40e Fix assert on IsInActualRenderingThread() by using IsInParallelRenderingThread() instead and inverting condition
#rnx
#rb Zach.Bethel
#preflight 636d4af5a430c8fbeab23e14

[CL 23091910 by danny couture in ue5-main branch]
2022-11-10 21:10:56 -05:00
Sebastien Hillaire
4640dbcebe Renamed TPT_Transluceny enum for consistency.
Follow up from https://p4-swarm.epicgames.net/reviews/21888399
#rb none
#preflight https://horde.devtools.epicgames.com/job/6346a1748d665d55d0371e1d
#fyi charles.derousiers

[CL 22476790 by Sebastien Hillaire in ue5-main branch]
2022-10-12 07:30:14 -04:00
Luke Thatcher
91ce45971a Restore changes lost when the DevPR copy-up robomerged back to UE5 Main
#rb none
#preflight skip
#jira none

[CL 22245170 by Luke Thatcher in ue5-main branch]
2022-09-29 06:31:56 -04:00
luke thatcher
0c5c2b3e27 Merging //UE5/Dev-ParallelRendering (up to CL 22203289) to //UE5/Release-5.1
This change includes significant refactor work performed in //UE5/Dev-ParallelRendering. A brief summary of the work is as follows:

Refactored RHI command lists
 - Removal of the "immediate" async compute command list
 - Introduced an "active pipe" on each command list, allowing RHICmdLists to record work for either graphics or async compute. Pipes can be selected using the SwitchPipeline() function, or the FRHICommandListScopedPipeline helper.
 - New explicit command list submission RHI API (RHIFinalizeContext, RHISubmitCommandLists). The IRHICommandContextContainer type has been removed.
 - Explicit GPU submission is automatically appended to the immediate command list when it is dispatched to the RHI thread.

Platform RHI implementations
 - The new submission API has been implemented across all platforms. Some platforms required a significant refactor.

#rb Mihnea.Balta,Kenzo.Terelst
#jira UE-139550
#preflight 6332e3641003050806d802ef

[CL 22239063 by luke thatcher in ue5-main branch]
2022-09-28 21:40:05 -04:00
dmitriy dyomin
d03003c699 Fixed: crash in CitySample related to mobile auto-instancing changes
#jira none
#rb Rob.Krajcarski
#preflight 63324976e11ae0b19ceabaa1

[CL 22203067 by dmitriy dyomin in ue5-main branch]
2022-09-27 06:57:37 -04:00
dmitriy dyomin
0f1ba0cf45 Mobile: Light map artifacts with specific mesh when launched on Android
Supply a mesh LOD index into MDC batching CS so it can fetch a correct lighting information for each instance
#rb ola.olsson
#jira UE-164402
#preflight 632d8688671a1a24b564bd0c

[CL 22163633 by dmitriy dyomin in ue5-main branch]
2022-09-23 20:02:18 -04:00
Sebastien Hillaire
1aa01506dd Fix for translucency before dof to look correct when distortion is enabled (no self refraction or scene color leaking without transmittance).
The separated standard translucent is only ran when distortion is present and enabled with r.Translucency.StandardSeparated=1.
Only executed when distortion is present to avoid self distortion issues.
Modifed bSeparateTranslucencyModulate to be bTranslucencyModulate that then needs to be combined with Normal or Separate translucency tag.

#jira UE-147602
#rb Charles.derousiers
#preflight https://horde.devtools.epicgames.com/job/6319a0e9ec45fbf3d71e276c

[CL 21916998 by Sebastien Hillaire in ue5-main branch]
2022-09-09 04:19:26 -04:00
dmitriy dyomin
ff473f946d Skip caching MobileBasePassCSM commands when deferred shading is enabled
#ROBOMERGE-AUTHOR: dmitriy.dyomin
#ROBOMERGE-SOURCE: CL 21439762 via CL 21439765 via CL 21439796 via CL 21439807
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v981-21435820)

[CL 21440281 by dmitriy dyomin in ue5-main branch]
2022-08-18 08:05:22 -04:00
zach bethel
b3219b1f1e Moved dynamic mesh passes and BeginSceneOcclusion off the render thread.
#preflight 62bf7ac9c941053728a722f5

[CL 20926630 by zach bethel in ue5-main branch]
2022-07-02 12:21:03 -04:00
zach bethel
34623f0321 Replaced thread-local MemStack with ConcurrentLinearAllocator across the renderer.
- 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]
2022-06-30 19:55:24 -04:00
dmitriy dyomin
d61e4c3c44 Improved mesh sorting on mobile. Better front to back sorting inside for meshes that belong to the same PSO
#rb none

#ROBOMERGE-OWNER: dmitriy.dyomin
#ROBOMERGE-AUTHOR: dmitriy.dyomin
#ROBOMERGE-SOURCE: CL 19570287 via CL 19570293 via CL 19570341 via CL 19570347
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v937-19513599)

[CL 19570509 by dmitriy dyomin in ue5-main branch]
2022-03-31 04:42:34 -04:00
charles derousiers
0195d6b7aa Add OIT per-pixel sorting support for translucent material
This technique is guarded with by a projected settings. It is currently only supported on PC Dx12. This is the initial step for fine grain/per-pixel sorting.

#rb sebastien.hillaire
#jira none
#preflight 623a1884bc1cf2803867d8f8

[CL 19470340 by charles derousiers in ue5-main branch]
2022-03-22 15:06:48 -04:00
dmitriy dyomin
d597e31540 Remove HALF_WORLD_MAX dependency in mobile mesh sorting
#rb jack.porter
[FYI] krzysztof.narkowicz
#preflight trivial

#ROBOMERGE-AUTHOR: dmitriy.dyomin
#ROBOMERGE-SOURCE: CL 18615411 in //UE5/Release-5.0/... via CL 18615418 via CL 18615419
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v899-18417669)

[CL 18615420 by dmitriy dyomin in ue5-main branch]
2022-01-14 03:40:42 -05:00
jamie hayes
15da3d166d * Updates to GPU Scene and the GPUSceneCollector to support handling the upload of multiple instances and instance payload data for dynamic primitives
* Updates to the VirtualShadowMapArrayCacheManager to support the invalidation of cache pages upon removal of dynamic primitives
* Various updates and fixes to support writing dynamic primitives' instance scene data and instance payload data from the GPU
* All these changes are needed by a few existing systems that will be using them soon to render via GPU Scene

(NOTE: This change is a resubmit of 18375369 with CIS fixes that caused it to be backed out)

#rb ola.olsson
#preflight 61ae4176353890ce23d75a95

#ROBOMERGE-AUTHOR: jamie.hayes
#ROBOMERGE-SOURCE: CL 18384716 in //UE5/Release-5.0/... via CL 18384780
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v896-18170469)

[CL 18384814 by jamie hayes in ue5-release-engine-test branch]
2021-12-06 13:18:17 -05:00
aurel cordonnier
46a2f40da2 [Backout] - CL18359911 (due to CIS errors)
[FYI] jamie.hayes
Original CL Desc
-----------------------------------------------------------------
* Updates to GPU Scene and the GPUSceneCollector to support handling the upload of multiple instances and instance payload data for dynamic primitives
* Updates to the VirtualShadowMapArrayCacheManager to support the invalidation of cache pages upon removal of dynamic primitives
* Various updates and fixes to support writing dynamic primitives' instance scene data and instance payload data from the GPU
* All these changes are needed by a few existing systems that will be using them soon to render via GPU Scene

#rb ola.olsson

#ROBOMERGE-AUTHOR: aurel.cordonnier
#ROBOMERGE-SOURCE: CL 18375767 via CL 18375771 via CL 18375781
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)

[CL 18375783 by aurel cordonnier in ue5-release-engine-test branch]
2021-12-03 19:54:06 -05:00
jamie hayes
4523c7cecd * Updates to GPU Scene and the GPUSceneCollector to support handling the upload of multiple instances and instance payload data for dynamic primitives
* Updates to the VirtualShadowMapArrayCacheManager to support the invalidation of cache pages upon removal of dynamic primitives
* Various updates and fixes to support writing dynamic primitives' instance scene data and instance payload data from the GPU
* All these changes are needed by a few existing systems that will be using them soon to render via GPU Scene

#rb ola.olsson

#ROBOMERGE-AUTHOR: jamie.hayes
#ROBOMERGE-SOURCE: CL 18359911 via CL 18375369 via CL 18375397
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)

[CL 18375424 by jamie hayes in ue5-release-engine-test branch]
2021-12-03 17:54:14 -05:00
dmitriy dyomin
9a53094474 Fixed couple issues with a mobile path in GPUScene (LWC and compressed instance transforms)
#rb none
[FYI] brian.karis, graham.wihlidal

#ROBOMERGE-AUTHOR: dmitriy.dyomin
#ROBOMERGE-SOURCE: CL 17732436 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v879-17706426)

[CL 17732462 by dmitriy dyomin in ue5-release-engine-test branch]
2021-10-06 02:20:54 -04:00
aurel cordonnier
69fe095547 Merge from Release-Engine-Staging @ 17636544 to Release-Engine-Test
This represents UE4/Main @17638339 and Dev-PerfTest @17636504

[CL 17638842 by aurel cordonnier in ue5-release-engine-test branch]
2021-09-27 19:54:25 -04:00
arciel rekman
63977655d7 Make sure shaders are only created on one thread in DX11 (UE-125050).
(cherry pick of 17507631 including later followup fixes in 17526511 and 17542272)

- Disable RDG parallel execution on D3D11.
- Precreate ClearReplacement shaders
- Also add a check to catch other possible issues before it's too late.

#rb Chris.Waters (in Dev-EMT)
#jira UE-125050

#ushell-cherrypick of 17507631 by Arciel.Rekman

#ROBOMERGE-AUTHOR: arciel.rekman
#ROBOMERGE-SOURCE: CL 17586312 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v871-17566257)

[CL 17586354 by arciel rekman in ue5-release-engine-test branch]
2021-09-21 15:10:29 -04:00
jeremy moore
e0e56ca2c1 #jira UE-125240
Always translate primitive ID for use by mesh draw commands.
Fixes regression from 17093848 which meant that we sometimes earlied out from TranslatePrimitiveId() for a deferred translate that no longer happens.
#preflight 6139374fd9c85a00018dae0e
#rb dmitriy.dyomin

#ROBOMERGE-AUTHOR: jeremy.moore
#ROBOMERGE-SOURCE: CL 17466025 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v870-17433530)

[CL 17466057 by jeremy moore in ue5-release-engine-test branch]
2021-09-08 20:06:34 -04:00
dmitriy dyomin
b0828d6beb Mobile specific implementation for auto-instancing. (disabled by default atm)
Run a compute job that packs most commonly used instance data (LocalToWorld matrix and some other bits - 80 bytes) into per-instance vertex buffer. Vertex shader does not have access to GPUScene and instead loads instance data from a per-instance vertex buffer. If it needs more primitive/instance data than available then it will load it from Primitive UB, binding unique uniform buffer and breaking auto-instancing. Pixel shader has a full access to a GPUScene
There are 3 ways how FSceneDataIntermediates gets populated
 1. PrimitiveId + GPUScene (Desktop)
 2. Per-Instance data + Primitive UB (Mobile)
 3. Primitive UB (auto-instancing disabled)
Details for GPUScene specific vertex inputs and access to FSceneDataIntermediates are hidden behind a macro:
VF_GPUSCENE_DECLARE_INPUT_BLOCK
VF_GPUSCENE_GET_INTERMEDIATES
FSceneDataIntermediates is now stored in FVertexFactoryIntermediates, FMaterialVertexParameters. Added a few GetPrimitiveData() overloads that allows you to access PrimitiveData depending on current context. Removed most of the cases where GetPrimitiveData() gets used with PrimitiveId.
#rb Ola.Ollson

#ROBOMERGE-SOURCE: CL 17093848 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v853-17066230)

[CL 17093856 by dmitriy dyomin in ue5-release-engine-test branch]
2021-08-07 07:20:52 -04:00
christopher waters
204ad930d4 Changing WaitForTasksAndClearSnapshots Task to add the required tasks as prerequisites instead of actually waiting on them.
#rb zach.bethel

#ROBOMERGE-OWNER: christopher.waters
#ROBOMERGE-AUTHOR: christopher.waters
#ROBOMERGE-SOURCE: CL 17060898 via CL 17061464 via CL 17061469 via CL 17062912
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v850-17047176)
#ROBOMERGE-CONFLICT from-shelf
#ROBOMERGE[STARSHIP]: UE5-Main

[CL 17063891 by christopher waters in ue5-release-engine-test branch]
2021-08-04 23:10:26 -04:00
dmitriy dyomin
8b92621f88 Use a regular draw calls (no indirect) for primitives with a single instance when possible
Move SubmitDrawCommands functionality into FInstanceCullingContext so we may use per-draw auxiliary information collected at Setup step
"UnCulled" bucket will use an optimized permutation that assumes that all submitted items are 'single instance'.
#rb ola.olsson
[FYI] krzysztof.narkowicz

#ROBOMERGE-SOURCE: CL 17029558 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v846-17029325)

[CL 17029645 by dmitriy dyomin in ue5-release-engine-test branch]
2021-08-03 09:31:28 -04:00
zach bethel
2b3e6e1148 Removing dead code path in mesh draw command task that would break RDG parallelism if enabled.
#rb trivial

#ROBOMERGE-SOURCE: CL 17000221 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v838-16927207)

[CL 17000227 by zach bethel in ue5-release-engine-test branch]
2021-07-29 15:48:43 -04:00