dtPathCorridor::optimizePathTopology

Attempts to optimize the path using a local area search.

Windows
MacOS
Linux

References

Module

Navmesh

Header

/Engine/Source/Runtime/Navmesh/Public/DetourCrowd/DetourPathCorridor.h

Include

#include "DetourCrowd/DetourPathCorridor.h"

Source

/Engine/Source/Runtime/Navmesh/Private/DetourCrowd/DetourPathCorridor.cpp

Syntax

bool optimizePathTopology
(
    dtNavMeshQuery * navquery,
    const dtQueryFilter * filter
)

Remarks

Attempts to optimize the path using a local area search. (Partial replanning.)

Inaccurate locomotion or dynamic obstacle avoidance can force the agent position significantly outside the original corridor. Over time this can result in the formation of a non-optimal corridor. This function will use a local area path search to try to re-optimize the corridor.

The more inaccurate the agent movement, the more beneficial this function becomes. Simply adjust the frequency of the call to match the needs to the agent.

Parameters

Parameter

Description

navquery

The query object used to build the corridor.

filter

The filter to apply to the operation.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss