50 Commits

Author SHA1 Message Date
Brice Criswell
73e2f7d494 Fix no-Recast builds [Github Pull Request: 9579]
#jira UE-164492
#rb Maxime.Mercier, Aris.Theophanidis

[CL 26785685 by Brice Criswell in 5.3 branch]
2023-08-02 16:01:19 -04:00
aris theophanidis
bd0e95100b Build fix for 'Resolution': unknown override specifier
#rb trivial
#rnx
#preflight skip

[CL 25018888 by aris theophanidis in ue5-main branch]
2023-04-12 19:26:46 -04:00
aris theophanidis
566bd24ce3 Addition of AgentMaxStepHeight into FNavMeshResolutionParam
#rb Yoan.StAmant
#preflight 6436d6740c19befb6c93d674

[CL 25018392 by aris theophanidis in ue5-main branch]
2023-04-12 19:07:51 -04:00
Aris Theophanidis
45994379a5 [Navmesh] Addition of CellHeight in FNavMeshResolutionParam
#jira none
#rb Mieszko.Zielinski
#preflight 63c8054102024f93d8c56415

[CL 23755472 by Aris Theophanidis in ue5-main branch]
2023-01-18 09:53:42 -05:00
Aris Theophanidis
1e51958bfd Addition of a display option to display navmesh tile resolution
Offset navigation 2D debug text display on screen
#jira none
#rb Maxime.Mercier
#preflight 63c5ba4d2a6acaf1625cd326

[CL 23732536 by Aris Theophanidis in ue5-main branch]
2023-01-16 16:05:38 -05:00
christopher waters
8fd10b0e13 Dependency cleanup around some Rendering headers.
#preflight 63b893e547321b9d895924b0

[CL 23605570 by christopher waters in ue5-main branch]
2023-01-06 18:57:09 -05:00
christopher waters
f8abec7a8e Material header dependency cleanup
- Removing MaterialAttributeDefinitionMap and MaterialRenderProxy from MaterialShared.h
- Removing MaterialShared from Material.h

#preflight 639cbb35776b61ba3b82f03e

[CL 23541603 by christopher waters in ue5-main branch]
2022-12-16 16:24:02 -05:00
Aris Theophanidis
03a838da84 First pass at allowing a mix of low, default and high resolution tiles on the navmesh.
CellSize is now deprecated and CellSizes for the various resolutions are stored in the NavMeshResolutionParams array of ARecastNavMesh.
Added NavMeshResolution property to ANavModifierVolume.
Remove duplicated data in dtNavMesh (m_walkableHeight, etc. already in dtNavMeshParams).
Addition of a resolution index to dtMeshHeader.
Increase navmesh version for addition of tile resolutions.
#jira none
#rb Mieszko.Zielinski
#preflight 639106341776b8c21c370f73

[CL 23434938 by Aris Theophanidis in ue5-main branch]
2022-12-07 16:42:43 -05:00
Stephen Holmes
2f18773caa Addressing the remaining AI numeric conversion issues.
#jira UE-166285
#review
#preflight 638a031b35192facc1c0fd77

[CL 23372606 by Stephen Holmes in ue5-main branch]
2022-12-02 10:07:29 -05:00
Stephen Holmes
be96784816 More conversion warnings fixes
#jira UE-166285
#preflight 636d16603852f8738a1d4775
#review-23055159

[CL 23079248 by Stephen Holmes in ue5-main branch]
2022-11-10 10:40:09 -05:00
Aris Theophanidis
0669943a67 Fix crash when playing in viewport while navmesh is visible
(with other minor fixes)
#jira UE-169559
#rb trivial
#rnx
#preflight 636aef84376a9cd6a873ab2d

[CL 23044803 by Aris Theophanidis in ue5-main branch]
2022-11-08 19:22:46 -05:00
Aris Theophanidis
3b720bc803 Navigation display improvements
Addition of tile building statistics
Addition of partitioning type, navdata count and triangle count
Addition of profile tags in the tile generation
#jira none
#rb Mieszko.Zielinski
#preflight 636a92b7dc30a4ce96a8b738

[CL 23032335 by Aris Theophanidis in ue5-main branch]
2022-11-08 13:00:51 -05:00
Aris Theophanidis
7ca89a4180 Add navmesh and navsystem informations on screen when navigation display is enabled
Add bDrawTileBuildTimes property to display last tile build time
Add bDrawTileBuildTimesHeatMap property to display the navmesh as a colored heat map of tile build time
Fix UNavMeshRenderingComponent not clearing labels when they where turned off
Allow DebugLabels to be displayed in 2D on screen
Add draw distance clipping for navmesh label rendering
Addition of profile tags in NavMeshRenderingComponent
#jira none
#rb Mieszko.Zielinski
#preflight 63640460d308b70e6607fc77
#preflight 6364089cf233f06a1266b061

[CL 22960500 by Aris Theophanidis in ue5-main branch]
2022-11-03 14:49:40 -04:00
marc audy
311f7464bf Updated ../Engine/Source/Runtime/... to inline gen.cpp files
Before:
3648 unity files
Total CPU Time: 47886.140625 s
Total time in Parallel executor: 498.81 seconds

After:
3548 unity files
Total CPU Time: 46643.828125 s
Total time in Parallel executor: 486.06 seconds

#jira
#preflight

[CL 22173263 by marc audy in ue5-main branch]
2022-09-24 13:57:58 -04:00
Jeremy Moore
ff967b1163 Remove PRIMITIVE_SCENE_DATA_FLAG_DRAWS_VELOCITY and only use PRIMITIVE_SCENE_DATA_FLAG_OUTPUT_VELOCITY.
Tidy up use of FPrimitiveSceneProxy velocity getters.
Now DrawsVelocity() is only for velocity relevance.
And HasDynamicTransform() is for determining if we need to store previous transform state.
VSM caching was using PRIMITIVE_SCENE_DATA_FLAG_DRAWS_VELOCITY so replaced that with PRIMITIVE_SCENE_DATA_FLAG_SHOULD_CACHE_SHADOW which should use the old behavior and can be tweaked in future using ShouldCacheShadow().

A common pattern for determining whether to output velocity now is to check if a previous transform exists, and to OR in AlwaysHasVelocity().
I found some proxy types that don't check for previous transform.
Also I found that the debug physics aggregate types *never* check for previous transform.
These are pre-existing potential bugs for fixing in another pass.

Also I found some proxies that don't currently fill out velocity relevance.
These are pre-existing potential bugs for fixing in another pass.

#preflight 62863f789016c6dd897f1cd2
#fyi andrew.lauritzen

[CL 20279797 by Jeremy Moore in ue5-main branch]
2022-05-19 10:08:15 -04:00
Aris Theophanidis
7ee1676796 Fix gameplay debugger navmesh rendering issue
When using bRestrictBuildingToActiveTiles, GetDebugGeometry() would gather the data for all the active tiles for each tile in the TileSet instead of only once, leading to unsuable framerate.
#rb Mieszko.Zielinski
#jira none
#preflight 627434d8fd59d6606e05341a

[CL 20064369 by Aris Theophanidis in ue5-main branch]
2022-05-05 16:48:48 -04:00
fred kimberley
7fbfaf57c8 Require explicit constructors/casts when converting between FVector, FVector3d, and FVector3f.
#jira UE-122078
#rb Andrew.Davidson, Colin.McGinley
#preflight standard build

#ROBOMERGE-AUTHOR: fred.kimberley
#ROBOMERGE-SOURCE: CL 18817999 in //UE5/Release-5.0/... via CL 18818012 via CL 18822871
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v910-18824042)

[CL 18824721 by fred kimberley in ue5-main branch]
2022-02-02 07:59:31 -05:00
andrew davidson
8e95b10069 Fix FVector2D variant casts - Runtime
Submitted on behalf of fred.kimberley
#rb andy.davidson
#preflight 61f8729a5a026d2d19bb9ca6
#preflight 61f87a025a026d2d19be76ed

#ROBOMERGE-OWNER: andrew.davidson
#ROBOMERGE-AUTHOR: andrew.davidson
#ROBOMERGE-SOURCE: CL 18802361 in //UE5/Release-5.0/... via CL 18802891 via CL 18821557
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v908-18788545)

[CL 18821641 by andrew davidson in ue5-main branch]
2022-02-02 01:47:07 -05:00
jon nabozny
f89b654be6 Changes to SceneVisibility
1.  Nanite meshes are not longer marked as always visible, and will go through the standard rendering culling / pipeline.
2.  Add coarse frustum culling using the already existing scene octree.
3.  Remove Distance visibility bit array, and converted only usage to using the visibiliity map.  (Spoke with Kenzo about this, the original was put in due to differences between distance a vis flags, but this has been fixed)
4.  Optimized Frustum culling methods across the board.

[at]Graham.Wihlidal [at]krzysztof.narkowicz [at]andrew.firth
#preflight 6137e0d1d9c85a00015375cb

#ROBOMERGE-OWNER: jon.nabozny
#ROBOMERGE-AUTHOR: brandon.dawson
#ROBOMERGE-SOURCE: CL 17459502 via CL 17911378 via CL 18360795 via CL 18361127
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v895-18170469)

[CL 18361363 by jon nabozny in ue5-release-engine-test branch]
2021-12-02 18:21:56 -05:00
aurel cordonnier
a6e741e007 Merge from Release-Engine-Staging @ 17915896 to Release-Engine-Test
This represents UE4/Main @17911760, Release-5.0 @17915875 and Dev-PerfTest @17914035

[CL 17918595 by aurel cordonnier in ue5-release-engine-test branch]
2021-10-25 20:05:28 -04:00
aris theophanidis
84df4756f6 Fix navmesh rendering colors originating from recast
#rb Mikko.Mononen
#jira none
#preflight 6176a8aa7f75c700019400e8

#ROBOMERGE-AUTHOR: aris.theophanidis
#ROBOMERGE-SOURCE: CL 17905898 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v883-17842818)
#ROBOMERGE[STARSHIP]: UE5-Release-Engine-Staging Release-5.0

[CL 17905940 by aris theophanidis in ue5-release-engine-test branch]
2021-10-25 09:59:04 -04:00
aris theophanidis
5b2e9e44ce Fix navmesh rendering not displaying some triangles
#rb Mieszko.Zielinski
#jira none

#ROBOMERGE-AUTHOR: aris.theophanidis
#ROBOMERGE-SOURCE: CL 17888051 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v883-17842818)
#ROBOMERGE[STARSHIP]: UE5-Release-Engine-Staging Release-5.0

[CL 17888130 by aris theophanidis in ue5-release-engine-test branch]
2021-10-21 14:52:47 -04:00
yoan stamant
42299b520f [DebugDrawDelegateHelper] rollback of delegate unregistration issue previous fix and implemented a different approach for cases where proxy is not created:
In some code paths for loaded actors the call order might be different since primitive registration gets deferred (i.e. FRegisterComponentContext != nullptr).

Case 1 (normal flow): FRegisterComponentContext == nullptr
 > UPrimitiveComponent::CreateRenderState_Concurrent : calls CreateSceneProxy
 > RegisterDebugDrawDelegate
 > UnregisterDebugDrawDelegate  ==> works fine

Case 2 (deferred AddPrimitive): FRegisterComponentContext != nullptr
 > UPrimitiveComponent::CreateRenderState_Concurrent : defers CreateSceneProxy
 > RegisterDebugDrawDelegate (skip register since not init)
 > CreateSceneProxy
 > UnregisterDebugDrawDelegate  ==>  ensures in UnregisterDebugDrawDelegate

With this new version `CreateRenderState_Concurrent` calls `RequestRegisterDebugDrawDelegate` that will take care of registering the delegate immediately or mark it for deferred execution. An explicit call to `ProcessDeferredRegister` is then required from `CreateSceneProxy` to implement proper flow:

Case 2 (fixed) (deferred AddPrimitive + deferred Register): FRegisterComponentContext != nullptr
 > UPrimitiveComponent::CreateRenderState_Concurrent: defers CreateSceneProxy
 > RequestRegisterDebugDrawDelegate: defers RegisterDebugDrawDelegate
 > CreateSceneProxy: calls ProcessDeferredRegister & RegisterDebugDrawDelegate
 > UnregisterDebugDrawDelegate  ==> works fine

Bonus:
- New DebugDrawComponent abstract class that is now used to share common functionalities between existing debug related components. Takes care of DelegateHelper registration flow to render text on screen from different sources.
- FDebugDrawDelegateHelper::InitDelegateHelper is no longer virtual and derived classes requiring extra data from their associated scene proxy should set it up from their overriden CreateSceneProxy
- FDebugDrawDelegateHelper derived classes should not override RegisterDebugDrawDelegate/UnregisterDebugDrawDelegate to use their `DrawDebugLabels` method since this is already a virtual method that would get called from the base class.
- Fixed a few ViewFlag members in the SceneProxy so the DelegateHelper base class can behave as expected

#jira FORT-419154
#rb mieszko.zielinski
#preflight 61703f8766ed7f0001c0faf1

#ROBOMERGE-AUTHOR: yoan.stamant
#ROBOMERGE-COMMAND: FnMain
#ROBOMERGE-SOURCE: CL 17875336 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v883-17842818)
#ROBOMERGE[STARSHIP]: UE5-Release-Engine-Staging Release-5.0
#ROBOMERGE[bot1]: Main

[CL 17875370 by yoan stamant in ue5-release-engine-test branch]
2021-10-20 13:23:33 -04:00
arciel rekman
afea811357 Fix crashes during the shader compilation when showing NavMesh (UE-117842).
#rb Ben.Ingram
[CODEREVIEW] [at]Ben.Ingram
#jira UE-117842

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

[CL 17577310 by arciel rekman in ue5-release-engine-test branch]
2021-09-20 19:13:48 -04:00
yoan stamant
2fa9d8e00f [DebugDrawDelegate]
Update registration flow since CreateRenderState_Concurrent can't be used to register our delegate since it needs to be initialized first (CreateSceneProxy) and in some code paths for loaded actors the call order might be different since primitive registration gets deferred (i.e. FRegisterComponentContext != nullptr).
In that case initialization won't called and an ensure will fire in UnregisterDebugDrawDelegate since registration failed (was not initialized).
Case 1: FRegisterComponentContext == nullptr  ==> Super::CreateRenderState_Concurrent + sync CreateSceneProxy (init) + RegisterDebugDrawDelegate ==> works fine
Case 2: FRegisterComponentContext != nullptr  ==> Super::CreateRenderState_Concurrent + deferred CreateSceneProxy + RegisterDebugDrawDelegate (skipped since not init) + CreateSceneProxy ==> ensures in UnregisterDebugDrawDelegate

Bonus:
- some code analysis fixes
- removed some 'CoreMinimal.h' includes
- exported log category 'LogVisual'
- fixed some uninitialized properties (FNavTestDebugDrawDelegateHelper, UNavMeshRenderingComponent, FNavMeshSceneProxyData)
- fixed some methods hiding non-virtual from base class (GetAllocatedSize)
- fixed FGameplayDebuggerCompositeSceneProxy::GetMemoryFootprint that was not considering base class allocations

#rnx
#jira UE-125097
#preflight 614362684778fa00016a8cad
#rb mieszko.zielinski

#ROBOMERGE-AUTHOR: yoan.stamant
#ROBOMERGE-SOURCE: CL 17544171 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v870-17433530)

[CL 17544199 by yoan stamant in ue5-release-engine-test branch]
2021-09-16 16:50:03 -04:00