Planeshift
dtNavMeshCreateParams Struct Reference

Represents the source data used to build an navigation mesh tile. More...

#include <DetourNavMeshBuilder.h>

Public Attributes

Polygon Mesh Attributes

Used to create the base navigation graph. See rcPolyMesh for details related to these attributes.

const unsigned short * verts
 The polygon mesh vertices. [(x, y, z) * vertCount] [Unit: vx]. More...
 
int vertCount
 The number vertices in the polygon mesh. [Limit: >= 3]. More...
 
const unsigned short * polys
 The polygon data. [Size: polyCount * 2 * nvp]. More...
 
const unsigned short * polyFlags
 The user defined flags assigned to each polygon. [Size: polyCount]. More...
 
const unsigned char * polyAreas
 The user defined area ids assigned to each polygon. [Size: polyCount]. More...
 
int polyCount
 Number of polygons in the mesh. [Limit: >= 1]. More...
 
int nvp
 Number maximum number of vertices per polygon. [Limit: >= 3]. More...
 
Height Detail Attributes (Optional)

See rcPolyMeshDetail for details related to these attributes.

const unsigned intdetailMeshes
 The height detail sub-mesh data. [Size: 4 * polyCount]. More...
 
const floatdetailVerts
 The detail mesh vertices. [Size: 3 * detailVertsCount] [Unit: wu]. More...
 
int detailVertsCount
 The number of vertices in the detail mesh. More...
 
const unsigned char * detailTris
 The detail mesh triangles. [Size: 4 * detailTriCount]. More...
 
int detailTriCount
 The number of triangles in the detail mesh. More...
 
Off-Mesh Connections Attributes (Optional)

Used to define a custom point-to-point edge within the navigation graph, an off-mesh connection is a user defined traversable connection made up to two vertices, at least one of which resides within a navigation mesh polygon.

const floatoffMeshConVerts
 Off-mesh connection vertices. [(ax, ay, az, bx, by, bz) * offMeshConCount] [Unit: wu]. More...
 
const floatoffMeshConRad
 Off-mesh connection radii. [Size: offMeshConCount] [Unit: wu]. More...
 
const unsigned short * offMeshConFlags
 User defined flags assigned to the off-mesh connections. [Size: offMeshConCount]. More...
 
const unsigned char * offMeshConAreas
 User defined area ids assigned to the off-mesh connections. [Size: offMeshConCount]. More...
 
const unsigned char * offMeshConDir
 The permitted travel direction of the off-mesh connections. [Size: offMeshConCount]. More...
 
const unsigned intoffMeshConUserID
 The user defined ids of the off-mesh connection. [Size: offMeshConCount]. More...
 
int offMeshConCount
 The number of off-mesh connections. [Limit: >= 0]. More...
 
Tile Attributes
Note
The tile grid/layer data can be left at zero if the destination is a single tile mesh.
unsigned int userId
 The user defined id of the tile. More...
 
int tileX
 The tile's x-grid location within the multi-tile destination mesh. (Along the x-axis.) More...
 
int tileY
 The tile's y-grid location within the multi-tile desitation mesh. (Along the z-axis.) More...
 
int tileLayer
 The tile's layer within the layered destination mesh. Limit: >= 0 More...
 
float bmin [3]
 The minimum bounds of the tile. [(x, y, z)] [Unit: wu]. More...
 
float bmax [3]
 The maximum bounds of the tile. [(x, y, z)] [Unit: wu]. More...
 
General Configuration Attributes
float walkableHeight
 The agent height. [Unit: wu]. More...
 
float walkableRadius
 The agent radius. [Unit: wu]. More...
 
float walkableClimb
 The agent maximum traversable ledge. (Up/Down) [Unit: wu]. More...
 
float cs
 The xz-plane cell size of the polygon mesh. [Limit: > 0] [Unit: wu]. More...
 
float ch
 The y-axis cell height of the polygon mesh. [Limit: > 0] [Unit: wu]. More...
 
bool buildBvTree
 True if a bounding volume tree should be built for the tile. More...
 

Detailed Description

Represents the source data used to build an navigation mesh tile.

This structure is used to marshal data between the Recast mesh generation pipeline and Detour navigation components.

See the rcPolyMesh and rcPolyMeshDetail documentation for detailed information related to mesh structure.

Units are usually in voxels (vx) or world units (wu). The units for voxels, grid size, and cell size are all based on the values of cs and ch.

The standard navigation mesh build process is to create tile data using dtCreateNavMeshData, then add the tile to a navigation mesh using either the dtNavMesh single tile init() function or the dtNavMesh::addTile() function.

See also
dtCreateNavMeshData

Definition at line 26 of file DetourNavMeshBuilder.h.

Member Data Documentation

float dtNavMeshCreateParams::bmax[3]

The maximum bounds of the tile. [(x, y, z)] [Unit: wu].

Definition at line 88 of file DetourNavMeshBuilder.h.

float dtNavMeshCreateParams::bmin[3]

The minimum bounds of the tile. [(x, y, z)] [Unit: wu].

Definition at line 87 of file DetourNavMeshBuilder.h.

bool dtNavMeshCreateParams::buildBvTree

True if a bounding volume tree should be built for the tile.

Note
The BVTree is not normally needed for layered navigation meshes.

Definition at line 102 of file DetourNavMeshBuilder.h.

float dtNavMeshCreateParams::ch

The y-axis cell height of the polygon mesh. [Limit: > 0] [Unit: wu].

Definition at line 98 of file DetourNavMeshBuilder.h.

float dtNavMeshCreateParams::cs

The xz-plane cell size of the polygon mesh. [Limit: > 0] [Unit: wu].

Definition at line 97 of file DetourNavMeshBuilder.h.

const unsigned int* dtNavMeshCreateParams::detailMeshes

The height detail sub-mesh data. [Size: 4 * polyCount].

Definition at line 47 of file DetourNavMeshBuilder.h.

int dtNavMeshCreateParams::detailTriCount

The number of triangles in the detail mesh.

Definition at line 51 of file DetourNavMeshBuilder.h.

const unsigned char* dtNavMeshCreateParams::detailTris

The detail mesh triangles. [Size: 4 * detailTriCount].

Definition at line 50 of file DetourNavMeshBuilder.h.

const float* dtNavMeshCreateParams::detailVerts

The detail mesh vertices. [Size: 3 * detailVertsCount] [Unit: wu].

Definition at line 48 of file DetourNavMeshBuilder.h.

int dtNavMeshCreateParams::detailVertsCount

The number of vertices in the detail mesh.

Definition at line 49 of file DetourNavMeshBuilder.h.

int dtNavMeshCreateParams::nvp

Number maximum number of vertices per polygon. [Limit: >= 3].

Definition at line 40 of file DetourNavMeshBuilder.h.

const unsigned char* dtNavMeshCreateParams::offMeshConAreas

User defined area ids assigned to the off-mesh connections. [Size: offMeshConCount].

Definition at line 67 of file DetourNavMeshBuilder.h.

int dtNavMeshCreateParams::offMeshConCount

The number of off-mesh connections. [Limit: >= 0].

Definition at line 76 of file DetourNavMeshBuilder.h.

const unsigned char* dtNavMeshCreateParams::offMeshConDir

The permitted travel direction of the off-mesh connections. [Size: offMeshConCount].

0 = Travel only from endpoint A to endpoint B.
DT_OFFMESH_CON_BIDIR = Bidirectional travel.

Definition at line 72 of file DetourNavMeshBuilder.h.

const unsigned short* dtNavMeshCreateParams::offMeshConFlags

User defined flags assigned to the off-mesh connections. [Size: offMeshConCount].

Definition at line 65 of file DetourNavMeshBuilder.h.

const float* dtNavMeshCreateParams::offMeshConRad

Off-mesh connection radii. [Size: offMeshConCount] [Unit: wu].

Definition at line 63 of file DetourNavMeshBuilder.h.

const unsigned int* dtNavMeshCreateParams::offMeshConUserID

The user defined ids of the off-mesh connection. [Size: offMeshConCount].

Definition at line 74 of file DetourNavMeshBuilder.h.

const float* dtNavMeshCreateParams::offMeshConVerts

Off-mesh connection vertices. [(ax, ay, az, bx, by, bz) * offMeshConCount] [Unit: wu].

Definition at line 61 of file DetourNavMeshBuilder.h.

const unsigned char* dtNavMeshCreateParams::polyAreas

The user defined area ids assigned to each polygon. [Size: polyCount].

Definition at line 38 of file DetourNavMeshBuilder.h.

int dtNavMeshCreateParams::polyCount

Number of polygons in the mesh. [Limit: >= 1].

Definition at line 39 of file DetourNavMeshBuilder.h.

const unsigned short* dtNavMeshCreateParams::polyFlags

The user defined flags assigned to each polygon. [Size: polyCount].

Definition at line 37 of file DetourNavMeshBuilder.h.

const unsigned short* dtNavMeshCreateParams::polys

The polygon data. [Size: polyCount * 2 * nvp].

Definition at line 36 of file DetourNavMeshBuilder.h.

int dtNavMeshCreateParams::tileLayer

The tile's layer within the layered destination mesh. Limit: >= 0

Definition at line 86 of file DetourNavMeshBuilder.h.

int dtNavMeshCreateParams::tileX

The tile's x-grid location within the multi-tile destination mesh. (Along the x-axis.)

Definition at line 84 of file DetourNavMeshBuilder.h.

int dtNavMeshCreateParams::tileY

The tile's y-grid location within the multi-tile desitation mesh. (Along the z-axis.)

Definition at line 85 of file DetourNavMeshBuilder.h.

unsigned int dtNavMeshCreateParams::userId

The user defined id of the tile.

Definition at line 83 of file DetourNavMeshBuilder.h.

int dtNavMeshCreateParams::vertCount

The number vertices in the polygon mesh. [Limit: >= 3].

Definition at line 35 of file DetourNavMeshBuilder.h.

const unsigned short* dtNavMeshCreateParams::verts

The polygon mesh vertices. [(x, y, z) * vertCount] [Unit: vx].

Definition at line 34 of file DetourNavMeshBuilder.h.

float dtNavMeshCreateParams::walkableClimb

The agent maximum traversable ledge. (Up/Down) [Unit: wu].

Definition at line 96 of file DetourNavMeshBuilder.h.

float dtNavMeshCreateParams::walkableHeight

The agent height. [Unit: wu].

Definition at line 94 of file DetourNavMeshBuilder.h.

float dtNavMeshCreateParams::walkableRadius

The agent radius. [Unit: wu].

Definition at line 95 of file DetourNavMeshBuilder.h.


The documentation for this struct was generated from the following file: