#include <RecastNavigationMeshComponentController.h>
Inherits RecastNavigationMeshRequestBus::Handler.
|
static void | Reflect (AZ::ReflectContext *context) |
|
static void | GetProvidedServices (AZ::ComponentDescriptor::DependencyArrayType &provided) |
|
static void | GetRequiredServices (AZ::ComponentDescriptor::DependencyArrayType &required) |
|
static void | GetIncompatibleServices (AZ::ComponentDescriptor::DependencyArrayType &incompatible) |
|
|
void | OnSendNotificationTick () |
|
bool | IsDebugDrawEnabled () const |
|
void | OnDebugDrawTick () |
| If debug draw was specified, then this call will be invoked every frame.
|
|
void | OnReceivedAllNewTiles () |
|
void | OnTileProcessedEvent (AZStd::shared_ptr< TileGeometry > tile) |
|
|
AZ::EntityComponentIdPair | m_entityComponentIdPair |
|
RecastNavigationMeshConfig | m_configuration |
| In-game navigation mesh configuration.
|
|
AZ::ScheduledEvent | m_sendNotificationEvent { [this]() { OnSendNotificationTick(); }, AZ::Name("RecastNavigationMeshUpdated") } |
|
AZ::ScheduledEvent | m_tickEvent { [this]() { OnDebugDrawTick(); }, AZ::Name("RecastNavigationDebugViewTick") } |
| Tick event for the optional debug draw.
|
|
AZ::ScheduledEvent | m_receivedAllNewTilesEvent { [this]() { OnReceivedAllNewTiles(); }, AZ::Name("RecastNavigationReceivedTiles") } |
|
RecastNavigationDebugDraw | m_customDebugDraw |
| Debug draw object for Recast navigation mesh.
|
|
AZStd::unique_ptr< rcContext > | m_context |
| Recast logging functionality and other optional tools.
|
|
AZStd::shared_ptr< NavMeshQuery > | m_navObject |
| Recast navigation objects.
|
|
AZStd::vector< AZStd::shared_ptr< TileGeometry > > | m_tilesToBeProcessed |
|
AZStd::recursive_mutex | m_tileProcessingMutex |
|
AZStd::atomic< bool > | m_shouldProcessTiles { true } |
| A way to check if we should stop tile processing (because we might be deactivating, for example).
|
|
AZ::TaskGraph | m_taskGraph { "RecastNavigation Tile Processing" } |
| Task graph objects to process tile geometry into Recast tiles.
|
|
AZ::TaskExecutor | m_taskExecutor |
|
AZStd::unique_ptr< AZ::TaskGraphEvent > | m_taskGraphEvent |
|
AZ::TaskDescriptor | m_taskDescriptor { "Processing Tiles", "Recast Navigation" } |
|
AZStd::atomic< bool > | m_updateInProgress { false } |
| If true, an update operation is in progress.
|
|
|
class | EditorRecastNavigationMeshComponent |
|
Common navigation mesh logic for Recast navigation components. Recommended use is as a base class. The method provided are not thread-safe. Use the mutex from @m_navObject to synchronize as necessary at the higher level.
◆ AttachNavigationTileToMesh()
bool RecastNavigation::RecastNavigationMeshComponentController::AttachNavigationTileToMesh |
( |
NavigationTileData & |
navigationTileData | ) |
|
Given a Recast data add a tile to the navigation mesh @m_navMesh.
- Parameters
-
navigationTileData | the raw data of a Recast tile |
- Returns
- true if successful.
◆ CreateNavigationMesh()
bool RecastNavigation::RecastNavigationMeshComponentController::CreateNavigationMesh |
( |
AZ::EntityId |
meshEntityId | ) |
|
Allocates and initializes Recast navigation mesh into @m_navMesh.
- Parameters
-
meshEntityId | the entity's positions will be used as the center of the navigation mesh. |
- Returns
- true if the navigation mesh object was successfully created.
◆ CreateNavigationTile()
Given a set of geometry and configuration create a Recast tile that can be attached using @AttachNavigationTileToMesh.
- Parameters
-
geom | A set of geometry, triangle data. |
meshConfig | Recast navigation mesh configuration. |
context | Recast context object, @rcContext. |
- Returns
- the tile data that can be attached to the navigation mesh using @AttachNavigationTileToMesh
◆ ReceivedAllNewTilesImpl()
void RecastNavigation::RecastNavigationMeshComponentController::ReceivedAllNewTilesImpl |
( |
const RecastNavigationMeshConfig & |
config, |
|
|
AZ::ScheduledEvent & |
sendNotificationEvent |
|
) |
| |
Creates a task graph with tasks to process received tile data.
- Parameters
-
config | navigation mesh configuration to apply to the tile data |
sendNotificationEvent | once all the tiles are processed and added to the navigation update notify on the main thread |
◆ UpdateNavigationMeshBlockUntilCompleted()
bool RecastNavigation::RecastNavigationMeshComponentController::UpdateNavigationMeshBlockUntilCompleted |
( |
| ) |
|
|
override |
RecastNavigationRequestBus overrides ...
◆ m_receivedAllNewTilesEvent
AZ::ScheduledEvent RecastNavigation::RecastNavigationMeshComponentController::m_receivedAllNewTilesEvent { [this]() { OnReceivedAllNewTiles(); }, AZ::Name("RecastNavigationReceivedTiles") } |
|
protected |
Tick event to notify on navigation mesh updates from the main thread. This is often needed for script environment, such as Script Canvas.
◆ m_sendNotificationEvent
AZ::ScheduledEvent RecastNavigation::RecastNavigationMeshComponentController::m_sendNotificationEvent { [this]() { OnSendNotificationTick(); }, AZ::Name("RecastNavigationMeshUpdated") } |
|
protected |
Tick event to notify on navigation mesh updates from the main thread. This is often needed for script environment, such as Script Canvas.
The documentation for this class was generated from the following file:
- Gems/RecastNavigation/Code/Source/Misc/RecastNavigationMeshComponentController.h