Commit Graph

51 Commits

Author SHA1 Message Date
yoan stamant
1bbc5d14dd NavigationSystemV1: GetNavDataForActor now returns any INavigationDataInterface found, not only classes in ARecastNavMesh class hierachy. It is up to the caller to cast and test for a specific sublass. (e.g. ANavigationData)
#jira UE-85467
[at]mieszko.zielinski [at]ken.kuwano [at]aris.theophanidis
#rb mieszko.zielinski


#ROBOMERGE-SOURCE: CL 10638011 via CL 10638033
#ROBOMERGE-BOT: (v609-10634694)

[CL 10638036 by yoan stamant in Main branch]
2019-12-10 13:42:41 -05:00
stephen holmes
17b247d433 Added a few perfromance stats to the navigation mesh regen code.
#ROBOMERGE-SOURCE: CL 10308613 via CL 10308622
#ROBOMERGE-BOT: (v593-10286020)

[CL 10308626 by stephen holmes in Main branch]
2019-11-19 11:38:03 -05:00
stephen holmes
6fe766c421 Work to Timeslice the Nav Tile Regen.
I've left the Sync code path as seperate to the Sync Time Sliced one, as its atleast 10% faster (but much spikier). Its also good way of easily verifying if the Time Sliced Code is correct.

I've let medium level functions have access to the timeslicer as they are often expensive enough to warrent it and many times we are time slicing within loops of these functions.

Some fucntions don't need timeslicing within them selves and can be timesliced from the outside and used on both code paths. Currently no functions are called from the non time slicing code that return a FTimeSliceWorkResultData type.

I've increaced the time slice regen times a bit to account for the fact we'll be going over the time slice limit less often now.

[at]Maxime.Mercier, [at]Mikko.Mononen, [at]Yoan.StAmant, [at]Aris.Theophanidis


#ROBOMERGE-SOURCE: CL 10303494 via CL 10303495
#ROBOMERGE-BOT: (v593-10286020)

[CL 10303496 by stephen holmes in Main branch]
2019-11-19 04:40:52 -05:00
yoan stamant
57dbc0d2d9 NavigationSystem: prevent registration of CustomNavLink from a different world in PIE
With Editor multiple NavigationSystems may exist at the same time (i.e. Editor, Client Game, Server Game worlds) so we want to make sure that any given NavigationSystem instance performs a single flush of the global pending queue to register the links associated to their outer World.

[at]guillaume.guay [at]mieszko.zielinski [at]aris.theophanidis


#ROBOMERGE-SOURCE: CL 10057481 via CL 10057734
#ROBOMERGE-BOT: (v566-10053404)

[CL 10057800 by yoan stamant in Main branch]
2019-11-06 13:02:33 -05:00
Matt Kuhlenschmidt
c0511b26d4 Moved BSP and all the related editor modes to a plugin so it can be disabled in some situations
#ROBOMERGE-OWNER: matt.kuhlenschmidt
#ROBOMERGE-AUTHOR: matt.kuhlenschmidt
#ROBOMERGE-SOURCE: CL 9870262 via CL 9870265
#ROBOMERGE-BOT: (v548-9842178)

#rb chris.gagnon

[CL 9872761 by Matt Kuhlenschmidt in Main branch]
2019-10-28 16:05:49 -04:00
mieszko zielinski
52ac5e391a Fixed a crash in AI CrowdManager resulting from the navigation data the manager is relying on going away, being streamed out or just being unregistered from the NavSystem.
Changed UNavigationSystemV1::OnBeginTearingDown to call UNavigationSystemV1::CleanUp so that CrowdManager doesn't do unnecessary work when we unregister nav data on EndPlay.

#jira UE-81818
[at]Yoan.StAmant, [at]Mikko.Mononen, [at]Aris.Theophanidis
#rb Yoan.StAmant

#ROBOMERGE-SOURCE: CL 9676135 in //UE4/Release-4.24/...
#ROBOMERGE-BOT: RELEASE (Release-4.24 -> Main) (v536-9675740)

[CL 9676136 by mieszko zielinski in Main branch]
2019-10-18 03:06:56 -04:00
Mieszko Zielinski
6cc98f7d80 Fixed a crash in navigation system when renaming NavigationData instance while there's already another on of that name. We've already had a safety feature for that but it turns out there might be multiple objects of the same name if Undo/Redo comes to play.
#jira UE-81596
#rb Yoan.StAmant
#review-9528515 @Yoan.StAmant, @Stephen.Holmes

[CL 9545633 by Mieszko Zielinski in Main branch]
2019-10-11 03:46:12 -04:00
Chris Gagnon
8ab0638182 Copying //UE4/Dev-Editor to Dev-Main (//UE4/Dev-Main) for 4.24
#rb none

[CL 9325047 by Chris Gagnon in Main branch]
2019-10-01 20:41:42 -04:00
steve robb
14cab21e0c Deprecating ARRAY_COUNT and changing it to UE_ARRAY_COUNT.
Replicated from CL# 7924370.

#rb none


#ROBOMERGE-OWNER: steve.robb
#ROBOMERGE-AUTHOR: steve.robb
#ROBOMERGE-SOURCE: CL 9279060 via CL 9279063
#ROBOMERGE-BOT: (v443-9013191)

[CL 9279836 by steve robb in Main branch]
2019-09-28 08:19:35 -04:00
stephen holmes
aea04bb205 Made some CSV stats off by default as they were firing too frequently.
[FYI] Ben.Woodhouse


#ROBOMERGE-SOURCE: CL 9045167 via CL 9046686 via CL 9046799
#ROBOMERGE-BOT: (v443-9013191)

[CL 9049646 by stephen holmes in Main branch]
2019-09-24 14:49:55 -04:00
mieszko zielinski
575c5cc953 Added a function to UNavigationSystemV1 that unregisteres all NavigationData instnces no longer supported by the nav system (as contolled by SupportedAgentsMask)
#rb none
[at]Yoan.StAmant, [at]Stephen.Holmes, [at]Mikko.Mononen


#ROBOMERGE-SOURCE: CL 9038081 via CL 9043888 via CL 9044090
#ROBOMERGE-BOT: (v443-9013191)

[CL 9047383 by mieszko zielinski in Main branch]
2019-09-24 14:17:23 -04:00
mieszko zielinski
38e321e0a0 Added a way to query NavigationSystemV1 for NavigationData corresponding to a given agent name
While modifying NavigationSystemV1 I've extended IsNavigationBuildingLocked with a parameter allowing more precise queries.

#rb Yoan.StAmant, Mikko.Mononen
[at]Yoan.StAmant, [at]Stephen.Holmes, [at]Mikko.Mononen


#ROBOMERGE-SOURCE: CL 8886708 via CL 8886728 via CL 8889423
#ROBOMERGE-BOT: (v427-8887818)

[CL 8889507 by mieszko zielinski in Main branch]
2019-09-19 12:00:05 -04:00
james brinkerhoff
48a66b17ea Hotfix from CL 8696491 for UE-79923: Show Navigation does not work
[FYI] Paul.Johnston


#ROBOMERGE-SOURCE: CL 8786492 via CL 8786506 via CL 8792525
#ROBOMERGE-BOT: (v422-8689730)

[CL 8792537 by james brinkerhoff in Main branch]
2019-09-17 20:57:06 -04:00
stephen holmes
9ef8a34b02 Adding CSV perf stats
[at]Mieszko.Zielinski


#ROBOMERGE-SOURCE: CL 8428126 via CL 8439014
#ROBOMERGE-BOT: (v404-8404397)

[CL 8439268 by stephen holmes in Main branch]
2019-09-03 18:15:50 -04:00
mieszko zielinski
7964042869 CIS fix
#rb none


#ROBOMERGE-SOURCE: CL 8191556 via CL 8194115 via CL 8207744
#ROBOMERGE-BOT: (v401-8057353)

[CL 8207917 by mieszko zielinski in Main branch]
2019-08-22 00:00:51 -04:00
mieszko zielinski
c9c9e0790d Reorganized how we configure SupportedAgents. From now on every NavigationSystem instance has data on the full set of SupportedAgents (as configured via ProjectSettings) but also has a SupportedAgentsMask, that marks agents supported by the instance. It has been done this way to keep filtered per-agent NavMeshBoundVolumes work regardless of which supported agents a nav sys instance wants to support.
This approach allowed for easy NavigationSystem's config update with NavSystemConfigOverride's properties. NavSystemConfigOverride can now specify if it wants to fully override the pre-existing nav sys instance or if it just wants to append new information (like supported agents) to the existing navigation system instance. There's also an option to do nothing if there's already a navigation system present.

This CL rolls-back a bunch of temp fixes done in past couple of days.

#rb Yoan.StAmant
Yoan.StAmant


#ROBOMERGE-OWNER: mieszko.zielinski
#ROBOMERGE-AUTHOR: mieszko.zielinski
#ROBOMERGE-SOURCE: CL 8187661 via CL 8193395 via CL 8207613
#ROBOMERGE-BOT: (v401-8057353)

[CL 8207758 by mieszko zielinski in Main branch]
2019-08-21 23:59:12 -04:00
yoan stamant
c1a425a2d4 NavSystem: Prevent AbstractNavData from being rejected during NavigationData registration. Problem was exposed by recent change to the order in which NavDataRegistrationQueue is processed. Since AbstractNavData uses the default config, it was rejected since another navigation data was already registered for the same agent config (which was not the case when AbstractNavData was processed first). With this change, we should no longer be dependant on the registration order.
#jira UE-78811
[at]guillaume.guay [at]mieszko.zielinski


#ROBOMERGE-SOURCE: CL 8119051 via CL 8122721
#ROBOMERGE-BOT: (v401-8057353)

[CL 8124722 by yoan stamant in Main branch]
2019-08-20 09:59:05 -04:00
Marc Audy
1c3be81dca Merging //UE4/Dev-Main to Dev-Framework (//UE4/Dev-Framework) @ 7950634
#rb
#rnx

[CL 7950994 by Marc Audy in Dev-Framework branch]
2019-08-12 12:52:39 -04:00
Marc Audy
3d0b873e3f Merging //UE4/Dev-Main to Dev-Framework (//UE4/Dev-Framework) @ 7712956
#rb
#rnx

[CL 7713270 by Marc Audy in Dev-Framework branch]
2019-08-04 15:53:40 -04:00
guillaume guay
a8821f80b4 - Added navigation system config 'bUseNavDataInAdditionalLevelWhenDuplicatedAgent". When set to TRUE, adding or streaming an additional level containing an already registered navigation data, it will unregister current one and register the new one;
- Added navigation system config 'bGenerateNavDataWhenNoCompatibleNavBound". When set to TRUE (default) it will still generate navigation data if any NavBoundVolume is compatible with its NavDataConfig, if false it gets rid of that navigation data;
- Make sure that when "bSpawnNavDataInNavBoundsLevel" is TRUE, it builds the navigation data in the first level containing a NavBoundVolume that actually supports this navigation data config (not any first one);
- Added virtual method on NavigateSystem "OnNavSystemOverriden" to give a chance to inspect previous NavigationSystem when getting overriden by a nav config override;
- Added some missing NavigationSystem clean up logic.

#tests client/server standalone Creative AI, Phoebe and regular + editor
#cr maxime.mercier
[FYI] mieszko.zielinski, stephen.holmes, yoan.stamant


#ROBOMERGE-OWNER: guillaume.guay
#ROBOMERGE-AUTHOR: guillaume.guay
#ROBOMERGE-SOURCE: CL 7679442 via CL 7679443 via CL 7688466
#ROBOMERGE-BOT: (v383-7686620)

[CL 7688470 by guillaume guay in Main branch]
2019-08-01 12:53:04 -04:00
Marc Audy
f3f7604cd4 Merge UE4/Main to Dev-Framework @ 7329145
#rb
#rnx

[CL 7415594 by Marc Audy in Dev-Framework branch]
2019-07-17 12:57:46 -04:00
yoan stamant
d29f1887a0 Added number of dirty areas to GameplayDebugger category navmesh
#rnx
[at]maxime.mercier
#rb guillaume.guay


#ROBOMERGE-SOURCE: CL 7289773 via CL 7306493
#ROBOMERGE-BOT: (v370-7290619)

[CL 7306546 by yoan stamant in Main branch]
2019-07-15 06:42:54 -04:00
Marc Audy
278eda75dd Merging //UE4/Dev-Main to Dev-Framework (//UE4/Dev-Framework) @ 7234503
#rb
#rnx

[CL 7263339 by Marc Audy in Dev-Framework branch]
2019-07-10 13:47:03 -04:00
mieszko zielinski
f7f3268d52 Extracted NavigationSystemV1's logic concerning NavOctree and navigation DirtyAreas into a separate structures for reusability
Notable changes:
- Added FNavigationOctreeController that wraps up what used to be NavigationSystemV1's navoctree-related logic
- Added FNavigationDirtyAreasController that wraps up what used to be NavigationSystemV1's DirtyAreas-related logic
- Added FNavigationDataHandler that is a helper struct that wraps up what used to be NavigationSystemV1's logic related to operation involving both navoctree and dirty areas
- Deprecated both FNavDataConfig.NavigationDataClass and FNavDataConfig.NavigationDataClassName and replaced them with a single NavDataClass property
- FNavigationOctree is not responsible for hashing element objects and storing their ElementId
- NavOctree elements how know about the octree they belong to (via a member property).

[at]Yoan.StAmant, [at]Maxime.Mercier, [at]Guillaume.Guay
#rb Yoan.StAmant


#ROBOMERGE-OWNER: mieszko.zielinski
#ROBOMERGE-AUTHOR: mieszko.zielinski
#ROBOMERGE-SOURCE: CL 7249089 via CL 7262555
#ROBOMERGE-BOT: (v369-7254125)

[CL 7262559 by mieszko zielinski in Main branch]
2019-07-10 13:31:21 -04:00
Yoan StAmant
534afb4738 Dynamic Obstacle support for Instanced Static Mesh or Hierarchical Instanced Static Mesh Component
FRecastTileGenerator & FRecastNavMeshGenerator
* Better support for transformation of per instance Convex shapes in MarkDynamicArea (replacing PartialTransformConvexHull)
* Added Per Instance modifier support in GrabDebugSnapshot for VisualLogger (both Geomerty export & AreaNavModifier)
* Added Per Instance modifier support in ExportNavigationData (both Geomerty export & AreaNavModifier)

FCompositeNavModifier
* Deprecated PerInstanceTransformDelegate code since it is unused and duplicated functionality handled by FNavigationRelevantData
* Added flag to mark as a PerInstance modifier

Fixed NavigationDataDump when default FBox is used (since GetVolume will be computed from uninitialized values)

#jira UE-71481
#review-6893930 @mieszko.zielinski
#rb mieszko.zielinski

[CL 6912667 by Yoan StAmant in Dev-Framework branch]
2019-06-10 12:57:10 -04:00