Commit Graph

111 Commits

Author SHA1 Message Date
sebastien lussier
d9833695e0 FortSplineStreaming - Properly replicate Collision Profile Name from source splines to streamed splines
* Deprecated CollisionProfileName from ULandscapeSplineSegment & ULandscapeSplineControlPoint
#rb patrick.enfedaque, jeanfrancois.dube
#preflight 62832a2ef9510a3ac6f2a0b1

#ROBOMERGE-AUTHOR: sebastien.lussier
#ROBOMERGE-SOURCE: CL 20241083 via CL 20241087 via CL 20241091 via CL 20241095
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v943-19904690)

[CL 20242394 by sebastien lussier in ue5-main branch]
2022-05-17 10:22:02 -04:00
christina tempelaarl
d2e0e0b949 Roll back 19428408 fix for UE-145385 to see if this fixes crash opening map related to landscape splines.
#rb none
#pf none

#ROBOMERGE-AUTHOR: christina.tempelaarl
#ROBOMERGE-SOURCE: CL 19440014 via CL 19444868 via CL 19445683 via CL 19445738
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v930-19419903)

[CL 19445894 by christina tempelaarl in ue5-main branch]
2022-03-19 18:34:28 -04:00
christina tempelaarl
b83c64ad05 Fix landscape splines to maintain spline mesh vertex color upon minor updates.
#jira UE-145385
#rb jonathan.bard
#preflight 6233a502791d231e020a5663

#ROBOMERGE-AUTHOR: christina.tempelaarl
#ROBOMERGE-SOURCE: CL 19428408 via CL 19432329 via CL 19436724 via CL 19436824
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v930-19419903)

[CL 19442404 by christina tempelaarl in ue5-main branch]
2022-03-18 18:50:14 -04:00
jonathan bard
2b57f2ff53 Local merge of landscape edit layers : complete refactor of the merge algorithm that doesn't require allocating several render targets the size of the entire loaded landscape components. Instead, each landscape component is merged individually and heightmaps/weightmaps are then resolved in several small batches. This allows working on large and/or partially loaded landscapes without overtaxing GPU memory.
* The new merge algorithm also speeds up the merging process by performing the merge operation in a single shader pass, which avoids intermediate clear/copies, even more so when dealing with several edit layers (O(n) -> O(1))
* Implemented via FRDGBuilder to benefit from transient memory allocation and optimal resource transitions.
* This is activated by a CVar (landscape.EditLayersLocalMerge.Enable, disabled by default) and disabled for landscapes containing BP brushes, since customers (similar to what the WaterBrushManager did) might have made the assumption that the merge is global and we don't want to break the existing landscapes.

For heightmaps:
* The algorithm is divided into several "component resolve batches" that render a list of neighboring components and merge all their edit layers into a single slice of a scratch texture array (first, copy all the edit layers texture subregions to a texture array then merge them in a single shader pass). Then those rendered components' borders are stitched (in order to mimic the behavior of global merge) so that there are no seams in between components even if they were not properly authored (i.e. one component authored while its neighbor was not loaded). Then normals are generated in another pass.
* In order to limit the amount of temporary copies of heightmaps, batches only render a max number of landscape components (including neighbor components), controlled by CVar landscape.EditLayersLocalMerge.MaxComponentsPerHeightmapResolveBatch. This means that a given component can effectively be rendered (i.e. merged) multiple times if it's needed for the computation of different batches but batches are built in a way to minimize this situation.
* Finally, mips are generated and the resulting heightmaps are copied to staging textures the same way they used to.

For weightmaps:
* The algorithm is divided into several "weightmap resolve batches" that render a list of components that participate to the output of a list of given weightmaps, processing each individual channel into a single slice of a scratch texture array (first, copy all the edit layers texture channels to a texture array then merge them in a single shader pass). Then, the weightmaps to resolve within the batch are finalized (i.e. individual, single-channel, weightmaps are packed into the final multi-channel weightmap), their mips are generated and the resulting weightmaps are copied to staging textures the same way they used to.
* In order to limit the amount of temporary copies of weightmaps, batches only render a max number of individual weightmaps, controlled by CVar landscape.EditLayersLocalMerge.MaxComponentsPerWeightmapResolveBatch. This means that a given weightmap can effectively be rendered (i.e. merged) multiple times if it's needed for the computation of different batches but batches are built in a way to minimize this situation.

Misc:
* Fixed RHI validation for GlobalMerge of weightmaps
* Moved landscape render resources to their own file to de-clutter LandscapeEditLayers.cpp a bit
* landscape.RenderCaptureLayersNextHeightmapDraws and landscape.RenderCaptureLayersNextWeightmapDraws now support capturing several draw calls
* Moved all intermediate containers (LandscapeComponentHeightmapsToRender/ToResolve, MapHelper, etc.) to a context object in order to centralize the local/global merge common structures. Note : the context is mutable and can be partially refreshed since weightmaps can be potentially added by the merge algorithms and therefore those structures were not up to date and we could miss reading back from newly-added weightmap textures
* Removed unused WeightmapLayersBlendSubstractive in global merge algorithm
* CVar commands landscape.Dirty and landscape.FixSplines now process all loaded game worlds

The next step is to re-work our internal brushes and provide a new API for them and user-implemented ones to work in the same fashion. Then the old BP brush API will be progressively phased out.

#rb sebastien.lussier, patrick.enfedaque
#tests full QA pass (UEENGQA-60460)
#preflight 61d8bc681f62d3ad4d728095

#ROBOMERGE-AUTHOR: jonathan.bard
#ROBOMERGE-SOURCE: CL 18751747 via CL 18751748 via CL 18751754 via CL 18751906 via CL 18751983
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)

[CL 18751988 by jonathan bard in ue5-main branch]
2022-01-27 06:12:09 -05:00
Marc Audy
0c3be2b6ad Merge Release-Engine-Staging to Test @ CL# 18240298
[CL 18241953 by Marc Audy in ue5-release-engine-test branch]
2021-11-18 14:37:34 -05:00
aurel cordonnier
a12d56ff31 Merge from Release-Engine-Staging @ 17791557 to Release-Engine-Test
This represents UE4/Main @17774255, Release-5.0 @17791557 and Dev-PerfTest @17789485

[CL 17794212 by aurel cordonnier in ue5-release-engine-test branch]
2021-10-12 21:21:22 -04:00
aurel cordonnier
7f517562d5 Merge from Release-Engine-Staging @ 17438845 to Release-Engine-Test
This represents UE4/Main @17430120 and Dev-PerfTest @17437669

[CL 17439044 by aurel cordonnier in ue5-release-engine-test branch]
2021-09-06 12:23:53 -04:00
patrick enfedaque
0568530c72 Landscape Splines: Fix checkSlow failing PostDuplicate (missing update of transient maps)
#rb francis.hurteau
#preflight 60a249e813a166000178565a

#ROBOMERGE-SOURCE: CL 16347312 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v804-16311228)

[CL 16347314 by patrick enfedaque in ue5-release-engine-test branch]
2021-05-17 07:46:14 -04:00
francis hurteau
f6168731af Fix assert occcuring when copying/duplicating map that contains landscape splines and register the component on an unitialized world.
#rb Patrick.Enfedaque
#jira UE-115715
#preflight 609ed20af6c6e300013d9f09

#ROBOMERGE-SOURCE: CL 16335967 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v804-16311228)

[CL 16335977 by francis hurteau in ue5-release-engine-test branch]
2021-05-14 16:56:24 -04:00
danny couture
25c6066c53 Prepare for the deprecation of direct access to the Resource member of UTexture in favor of the GetResource() accessor.
#rb Francis.Hurteau
#preflight 609e5182ef86d30001ad0a18
#rnx

#ROBOMERGE-SOURCE: CL 16328103 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v804-16311228)

[CL 16328107 by danny couture in ue5-release-engine-test branch]
2021-05-14 07:17:49 -04:00
mark lintott
bd61859350 #jira 112822
#rb johan.torp
Removal of UE4 references in Archive.h

[CL 16002350 by mark lintott in ue5-main branch]
2021-04-14 05:14:13 -04:00
jonathan bard
93900d8982 Fixed landscape splines not properly emptying the MeshComponents array after moving (trying to move, actually) its content to a local array : when TObjectPtr was introduced, the move was silently replaced by a copy as the destination array was of a different non-moveable type (ptr vs. TObjectPtr), leaving the source array *not* empty after the call, while the algorithm implied it was (after a move, no assumption should be made as to the source container's state, apart that it's undefined).
#rb patrick.enfedaque
#jira UE-112101, UE-112105
#lockdown simon.tourangeau

#ROBOMERGE-SOURCE: CL 15943201 in //UE5/Release-5.0-EarlyAccess/...
#ROBOMERGE-BOT: STARSHIP (Release-5.0-EarlyAccess -> Main) (v787-15839533)

[CL 15948544 by jonathan bard in ue5-main branch]
2021-04-07 20:33:45 -04:00
mark lintott
11a12136ce #jira UE-111647
#rb johan.torp
GetLinkerUE4Version renamed to GetLinkerUEVersion

#ROBOMERGE-SOURCE: CL 15859222 in //UE5/Release-5.0-EarlyAccess/...
#ROBOMERGE-BOT: STARSHIP (Release-5.0-EarlyAccess -> Main) (v786-15839533)

[CL 15859586 by mark lintott in ue5-main branch]
2021-03-30 06:44:49 -04:00
Zousar Shaker
fc2ad21a5e Prototype Wrapped Object Pointers (ObjectHandle/ObjectPtr)
Call-site changes for non-scalar wrapped object pointer upgrades in Engine + Shootergame

#rb devin.doucette

[CL 14996467 by Zousar Shaker in ue5-main branch]
2021-01-05 19:16:25 -04:00
Patrick Enfedaque
d12e7d5874 WorldPartition Conversion: Fix MoveSpline with 'y' splines (instead of finding starting points walk the connection graph which already early outs when dest outers match)
#rb jeanfrancois.dube, sebastien.lussier

[CL 14813746 by Patrick Enfedaque in ue5-main branch]
2020-11-25 15:49:37 -04:00
Patrick Enfedaque
14b4b2a11a Landscape WorldPartition support: New ALandscapeSplineActor which is indepedent of ALandscapeProxy and implements new ILandscapeSplineInterface to support existing data prior to WP worlds.
- Non WP worlds still use the ALandscapeProxy as a ULandscapeSplinesComponent container
- WP worlds create one ALandscapeSplineActor per Spline that have their own bounds (so they can be loaded properly based on that)

#rb richard.malo, sebastien.lussier

[CL 14806261 by Patrick Enfedaque in ue5-main branch]
2020-11-23 08:28:12 -04:00
Patrick Enfedaque
503ee9d2bb Landscape: Conversion fix Landscape Spline failed check when moving spline to new proxy
#rb sebastien.lussier

[CL 14500875 by Patrick Enfedaque in ue5-main branch]
2020-10-15 09:08:27 -04:00
Patrick Enfedaque
c814528b26 Landscape: New helper class allows changing Landscape Configuration (Component Size, Num Subsection, WorldPartition GridSize)
#rb richard.malo

[CL 14490266 by Patrick Enfedaque in ue5-main branch]
2020-10-14 08:06:05 -04:00
Marc Audy
50a3d7d368 Merge Release-Engine-Staging to Main @ CL# 14467590
This represents UE4/Main @ 14432125 + some cherrypick fixes

[CL 14468207 by Marc Audy in ue5-main branch]
2020-10-09 22:42:26 -04:00
Patrick Enfedaque
5c46684d31 Backout CL 14397037+14398210 LandscapeInfo map refactor until we can fix the Cooking (where Inactive World don't have Subsystems)
#rb none

[CL 14398311 by Patrick Enfedaque in ue5-main branch]
2020-09-25 14:17:42 -04:00
Patrick Enfedaque
970900bbef Move LandscapeInfo management into LandscapeSubsystem. (Remove usage of World->PerModuleDataObjects)
#rb richard.malo

[CL 14397037 by Patrick Enfedaque in ue5-main branch]
2020-09-25 12:14:34 -04:00
rajesh chilagani
a4cda818d2 Scaling Landscape Spline Widget to viewport based on distance from camera
#jira UE-94960
#rb patrick.enfedaque

[CL 14246079 by rajesh chilagani in ue5-main branch]
2020-09-02 14:01:46 -04:00
Marc Audy
a7c9001a94 Merging //UE5/Release-Engine-Staging to Main (//UE5/Main) @ 14075166
#rb
#rnx

[CL 14075271 by Marc Audy in ue5-main branch]
2020-08-11 01:36:57 -04:00
Marc Audy
11f5b21210 Merging //UE5/Release-Engine-Staging @ 13752110 to Main (//UE5/Main)
#rnx

[CL 13753156 by Marc Audy in ue5-main branch]
2020-06-23 18:40:00 -04:00
Patrick Enfedaque
a7b97e92c6 Fix ForeignWorld not being updated properly on SplineControlPoints (UDN)
#jira none
#rb richard.malo

[CL 12387007 by Patrick Enfedaque in Main branch]
2020-03-24 06:30:07 -04:00