Navigation
Unreal Engine C++ API Reference > Runtime > Navmesh > Detour
References
Module | Navmesh |
Header | /Engine/Source/Runtime/Navmesh/Public/Detour/DetourNavMeshQuery.h |
Include | #include "Detour/DetourNavMeshQuery.h" |
Syntax
class dtNavMeshQuery
Remarks
Provides the ability to perform pathfinding related queries against a navigation mesh.
For methods that support undersized buffers, if the buffer is too small to hold the entire result set the return status of the method will include the #DT_BUFFER_TOO_SMALL flag.
Constant member functions can be used by multiple clients without side effects. (E.g. No change to the closed list. No impact on an in-progress sliced path query. Etc.)
Walls and portals: A wall is a polygon segment that is considered impassable. A portal is a passable segment between polygons. A portal may be treated as a wall based on the dtQueryFilter used for a query.
Constructors
Type | Name | Description | |
---|---|---|---|
![]() |
Destructors
Type | Name | Description | |
---|---|---|---|
![]() |
Functions
Type | Name | Description | |
---|---|---|---|
![]() ![]() |
dtStatus | appendPortals
(
const int startIdx, |
Appends intermediate portal points to a straight path. |
![]() ![]() |
dtStatus | appendVertex
(
const dtReal* pos, |
Appends vertex to a straight path. |
![]() ![]() |
dtStatus | closestPointOnPoly
(
dtPolyRef ref, |
Finds the closest point on the specified polygon. |
![]() ![]() |
dtStatus | closestPointOnPolyBoundary
(
dtPolyRef ref, |
Returns a point on the boundary closest to the source point if the source point is outside the polygon's xz-bounds. |
![]() |
dtStatus | finalizeSlicedFindPath
(
dtPolyRef* path, |
Finalizes and returns the results of a sliced path query. |
![]() |
dtStatus | finalizeSlicedFindPathPartial
(
const dtPolyRef* existing, |
Finalizes and returns the results of an incomplete sliced path query, returning the path to the furthest polygon on the existing path that was visited during the search. |
![]() ![]() |
dtStatus | findDistanceToWall
(
dtPolyRef startRef, |
Finds the distance from the specified position to the nearest polygon wall. |
![]() ![]() |
dtStatus | findLocalNeighbourhood
(
dtPolyRef startRef, |
Finds the non-overlapping navigation polygons in the local neighbourhood around the center position. |
![]() ![]() |
dtStatus | findNearestContainingPoly
(
const dtReal* center, |
Finds the nearest polygon in height containing the specified center point. |
![]() ![]() |
dtStatus | findNearestPoly
(
const dtReal* center, |
Finds the polygon nearest to the specified center point. |
![]() ![]() |
dtStatus | findNearestPoly2D
(
const dtReal* center, |
Finds the polygon 2D-nearest to the specified center point. |
![]() ![]() |
dtStatus | findPath
(
dtPolyRef startRef, |
Finds a path from the start polygon to the end polygon. |
![]() ![]() |
dtStatus | findPolysAroundCircle
(
dtPolyRef startRef, |
Finds the polygons along the navigation graph that touch the specified circle. |
![]() ![]() |
dtStatus | findPolysAroundShape
(
dtPolyRef startRef, |
Finds the polygons along the naviation graph that touch the specified convex polygon. |
![]() ![]() |
dtStatus | findPolysInPathDistance
(
dtPolyRef startRef, |
Finds the polygons along the navigation graph that are no more than given path length away from centerPos. |
![]() ![]() |
dtStatus | findRandomPoint
(
const dtQueryFilter* filter, |
Returns random location on navmesh. |
![]() ![]() |
dtStatus | findRandomPointAroundCircle
(
dtPolyRef startRef, |
Returns random location on navmesh within the reach of specified location. |
![]() ![]() |
dtStatus | findRandomPointInPoly
(
dtPolyRef ref, |
Returns random location inside the specified polygon. |
![]() ![]() |
dtStatus | findStraightPath
(
const dtReal* startPos, |
Finds the straight path from the start to the end position within the polygon corridor. |
![]() ![]() |
dtStatus | findWallsAroundPath
(
const dtPolyRef* path, |
[UE] Finds the wall segments that overlap the polygon shape. |
![]() ![]() |
dtStatus | findWallsInNeighbourhood
(
dtPolyRef startRef, |
[UE] Finds the wall segments in local neighbourhood |
![]() ![]() |
dtStatus | findWallsOverlappingShape
(
dtPolyRef startRef, |
[UE] Finds the wall segments that overlap the polygon shape. |
![]() ![]() |
const dtNavMesh * | Gets the navigation mesh the query object is using. | |
![]() ![]() |
void | getCurrentBestResult
(
dtNode*& bestNode, |
Gets best node ref and cost from sliced pathfinding data. |
![]() ![]() |
dtStatus | getEdgeMidPoint
(
dtPolyRef from, |
|
![]() ![]() |
dtStatus | getEdgeMidPoint
(
dtPolyRef from, |
Returns edge mid point between two polygons. |
![]() ![]() |
dtNodePool * | getNodePool () |
Gets the node pool. |
![]() ![]() |
dtStatus | getPolyHeight
(
dtPolyRef ref, |
Gets the height of the polygon at the provided position using the height detail. |
![]() ![]() |
dtStatus | getPolyWallSegments
(
dtPolyRef ref, |
Returns the segments for the specified polygon, optionally including portals. |
![]() ![]() |
dtStatus | getPortalPoints
(
dtPolyRef from, |
Exposing function to be able to generate navigation corridors as sequence of point pairs |
![]() ![]() |
dtStatus | getPortalPoints
(
dtPolyRef from, |
|
![]() ![]() |
int | ||
![]() |
dtStatus | init
(
const dtNavMesh* nav, |
Initializes the query object. |
![]() |
dtStatus | initSlicedFindPath
(
dtPolyRef startRef, |
Initializes a sliced path query. |
![]() ![]() |
bool | isInClosedList
(
dtPolyRef ref |
Returns true if the polygon reference is in the closed list. |
![]() ![]() |
dtStatus | isPointInsidePoly
(
dtPolyRef ref, |
Checks if specified pos is inside given polygon specified by ref |
![]() ![]() |
bool | ||
![]() ![]() |
bool | isValidPolyRef
(
dtPolyRef ref, |
Returns true if the polygon reference is valid and passes the filter restrictions. |
![]() ![]() |
dtStatus | moveAlongSurface
(
dtPolyRef startRef, |
Moves from the start to the end position constrained to the navigation mesh. |
![]() ![]() |
bool | passLinkFilter
(
const dtMeshTile* tile, |
|
![]() ![]() |
bool | passLinkFilterByRef
(
const dtMeshTile* tile, |
|
![]() ![]() |
dtStatus | projectedPointOnPoly
(
dtPolyRef ref, |
Finds the point's projection on the specified polygon. |
![]() ![]() |
dtStatus | queryPolygons
(
const dtReal* center, |
Finds polygons that overlap the search box. |
![]() ![]() |
dtStatus | raycast
(
dtPolyRef startRef, |
Casts a 'walkability' ray along the surface of the navigation mesh from the start position toward the end position. |
![]() |
void | setRequireNavigableEndLocation
(
const bool value |
|
![]() |
void | updateLinkFilter
(
dtQuerySpecialLinkFilter* linkFilter |
UE: updates special link filter for this query. |
![]() |
dtStatus | updateSlicedFindPath
(
const int maxIter, |
Updates an in-progress sliced path query. |
![]() ![]() |
bool | wasClusterLinkSearched
(
dtPolyRef cFrom, |
Returns true if the cluster link was used in previous search. |
See Also
dtAllocNavMeshQuery()
dtAllocNavMeshQuery()