TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
dtNavMeshCreateParams Struct Reference

#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 int * detailMeshes
 The height detail sub-mesh data. [Size: 4 * polyCount]. More...
 
const float * detailVerts
 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 float * offMeshConVerts
 Off-mesh connection vertices. [(ax, ay, az, bx, by, bz) * offMeshConCount] [Unit: wu]. More...
 
const float * offMeshConRad
 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
 
const unsigned int * offMeshConUserID
 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
 

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

Member Data Documentation

float dtNavMeshCreateParams::bmax[3]

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

float dtNavMeshCreateParams::bmin[3]

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

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.
float dtNavMeshCreateParams::ch

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

float dtNavMeshCreateParams::cs

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

const unsigned int* dtNavMeshCreateParams::detailMeshes

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

int dtNavMeshCreateParams::detailTriCount

The number of triangles in the detail mesh.

const unsigned char* dtNavMeshCreateParams::detailTris

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

const float* dtNavMeshCreateParams::detailVerts

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

int dtNavMeshCreateParams::detailVertsCount

The number of vertices in the detail mesh.

int dtNavMeshCreateParams::nvp

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

const unsigned char* dtNavMeshCreateParams::offMeshConAreas

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

int dtNavMeshCreateParams::offMeshConCount

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

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.

const unsigned short* dtNavMeshCreateParams::offMeshConFlags

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

const float* dtNavMeshCreateParams::offMeshConRad

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

const unsigned int* dtNavMeshCreateParams::offMeshConUserID

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

const float* dtNavMeshCreateParams::offMeshConVerts

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

const unsigned char* dtNavMeshCreateParams::polyAreas

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

int dtNavMeshCreateParams::polyCount

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

const unsigned short* dtNavMeshCreateParams::polyFlags

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

const unsigned short* dtNavMeshCreateParams::polys

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

int dtNavMeshCreateParams::tileLayer

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

int dtNavMeshCreateParams::tileX

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

int dtNavMeshCreateParams::tileY

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

unsigned int dtNavMeshCreateParams::userId

The user defined id of the tile.

int dtNavMeshCreateParams::vertCount

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

const unsigned short* dtNavMeshCreateParams::verts

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

float dtNavMeshCreateParams::walkableClimb

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

float dtNavMeshCreateParams::walkableHeight

The agent height. [Unit: wu].

float dtNavMeshCreateParams::walkableRadius

The agent radius. [Unit: wu].


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