Planeshift
DetourNavMesh.h File Reference
#include "DetourAlloc.h"
#include "DetourStatus.h"

Go to the source code of this file.

Classes

struct  dtBVNode
 Bounding volume node. More...
 
struct  dtLink
 Defines a link between polygons. More...
 
struct  dtMeshHeader
 Provides high level information related to a dtMeshTile object. More...
 
struct  dtMeshTile
 Defines a navigation mesh tile. More...
 
class  dtNavMesh
 A navigation mesh based on tiles of convex polygons. More...
 
struct  dtNavMeshParams
 Configuration parameters used to define multi-tile navigation meshes. The values are used to allocate space during the initialization of a navigation mesh. More...
 
struct  dtOffMeshConnection
 Defines an navigation mesh off-mesh connection within a dtMeshTile object. An off-mesh connection is a user defined traversable connection made up to two vertices. More...
 
struct  dtPoly
 Defines a polyogn within a dtMeshTile object. More...
 
struct  dtPolyDetail
 Defines the location of detail sub-mesh data within a dtMeshTile. More...
 

Typedefs

typedef unsigned int dtPolyRef
 A handle to a polygon within a navigation mesh tile. More...
 
typedef unsigned int dtTileRef
 A handle to a tile within a navigation mesh. More...
 

Enumerations

enum  dtPolyTypes { DT_POLYTYPE_GROUND = 0, DT_POLYTYPE_OFFMESH_CONNECTION = 1 }
 Flags representing the type of a navigation mesh polygon. More...
 
enum  dtStraightPathFlags { DT_STRAIGHTPATH_START = 0x01, DT_STRAIGHTPATH_END = 0x02, DT_STRAIGHTPATH_OFFMESH_CONNECTION = 0x04 }
 Vertex flags returned by dtNavMeshQuery::findStraightPath. More...
 
enum  dtTileFlags { DT_TILE_FREE_DATA = 0x01 }
 Tile flags used for various functions and fields. For an example, see dtNavMesh::addTile(). More...
 

Functions

dtNavMeshdtAllocNavMesh ()
 Allocates a navigation mesh object using the Detour allocator. More...
 
void dtFreeNavMesh (dtNavMesh *navmesh)
 Frees the specified navigation mesh object using the Detour allocator. More...
 

Variables

static const unsigned short DT_EXT_LINK = 0x8000
 A flag that indicates that an entity links to an external entity. (E.g. A polygon edge is a portal that links to another polygon.) More...
 
static const int DT_MAX_AREAS = 64
 The maximum number of user defined area ids. More...
 
static const unsigned int DT_NULL_LINK = 0xffffffff
 A value that indicates the entity does not link to anything. More...
 
static const unsigned int DT_OFFMESH_CON_BIDIR = 1
 A flag that indicates that an off-mesh connection can be traversed in both directions. (Is bidirectional.) More...
 
static const int DT_VERTS_PER_POLYGON = 6
 The maximum number of vertices per navigation polygon. More...
 
Tile Serialization Constants

These constants are used to detect whether a navigation tile's data and state format is compatible with the current build.

static const int DT_NAVMESH_MAGIC = 'D'<<24 | 'N'<<16 | 'A'<<8 | 'V'
 A magic number used to detect compatibility of navigation tile data. More...
 
static const int DT_NAVMESH_VERSION = 7
 A version number used to detect compatibility of navigation tile data. More...
 
static const int DT_NAVMESH_STATE_MAGIC = 'D'<<24 | 'N'<<16 | 'M'<<8 | 'S'
 A magic number used to detect the compatibility of navigation tile states. More...
 
static const int DT_NAVMESH_STATE_VERSION = 1
 A version number used to detect compatibility of navigation tile states. More...
 

Enumeration Type Documentation

Flags representing the type of a navigation mesh polygon.

Enumerator
DT_POLYTYPE_GROUND 

The polygon is a standard convex polygon that is part of the surface of the mesh.

DT_POLYTYPE_OFFMESH_CONNECTION 

The polygon is an off-mesh connection consisting of two vertices.

Definition at line 91 of file DetourNavMesh.h.

Vertex flags returned by dtNavMeshQuery::findStraightPath.

Enumerator
DT_STRAIGHTPATH_START 

The vertex is the start position in the path.

DT_STRAIGHTPATH_END 

The vertex is the end position in the path.

DT_STRAIGHTPATH_OFFMESH_CONNECTION 

The vertex is the start of an off-mesh connection.

Definition at line 83 of file DetourNavMesh.h.

Tile flags used for various functions and fields. For an example, see dtNavMesh::addTile().

Enumerator
DT_TILE_FREE_DATA 

The navigation mesh owns the tile memory and is responsible for freeing it.

Definition at line 76 of file DetourNavMesh.h.

Variable Documentation

const unsigned short DT_EXT_LINK = 0x8000
static

A flag that indicates that an entity links to an external entity. (E.g. A polygon edge is a portal that links to another polygon.)

Definition at line 62 of file DetourNavMesh.h.

const int DT_NAVMESH_MAGIC = 'D'<<24 | 'N'<<16 | 'A'<<8 | 'V'
static

A magic number used to detect compatibility of navigation tile data.

Definition at line 47 of file DetourNavMesh.h.

const int DT_NAVMESH_STATE_MAGIC = 'D'<<24 | 'N'<<16 | 'M'<<8 | 'S'
static

A magic number used to detect the compatibility of navigation tile states.

Definition at line 53 of file DetourNavMesh.h.

const int DT_NAVMESH_STATE_VERSION = 1
static

A version number used to detect compatibility of navigation tile states.

Definition at line 56 of file DetourNavMesh.h.

const int DT_NAVMESH_VERSION = 7
static

A version number used to detect compatibility of navigation tile data.

Definition at line 50 of file DetourNavMesh.h.

const unsigned int DT_NULL_LINK = 0xffffffff
static

A value that indicates the entity does not link to anything.

Definition at line 65 of file DetourNavMesh.h.

const unsigned int DT_OFFMESH_CON_BIDIR = 1
static

A flag that indicates that an off-mesh connection can be traversed in both directions. (Is bidirectional.)

Definition at line 68 of file DetourNavMesh.h.