diff --git a/CONTRIBUTING_8md.html b/CONTRIBUTING_8md.html new file mode 100644 index 00000000..ca7b83cd --- /dev/null +++ b/CONTRIBUTING_8md.html @@ -0,0 +1,104 @@ + + +
+ + + + +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Classes | |
| struct | BoundsItem |
+Functions | |
| static int | compareItemX (const void *va, const void *vb) |
| static int | compareItemY (const void *va, const void *vb) |
| static void | calcExtends (const BoundsItem *items, const int, const int imin, const int imax, float *bmin, float *bmax) |
| int | longestAxis (float x, float y) |
| static void | subdivide (BoundsItem *items, int nitems, int imin, int imax, int trisPerChunk, int &curNode, rcChunkyTriMeshNode *nodes, const int maxNodes, int &curTri, int *outTris, const int *inTris) |
| bool | rcCreateChunkyTriMesh (const float *verts, const int *tris, int ntris, int trisPerChunk, rcChunkyTriMesh *cm) |
| Creates partitioned triangle mesh (AABB tree), where each node contains at max trisPerChunk triangles. More... | |
| bool | checkOverlapRect (const float amin[2], const float amax[2], const float bmin[2], const float bmax[2]) |
| int | rcGetChunksOverlappingRect (const rcChunkyTriMesh *cm, float bmin[2], float bmax[2], int *ids, const int maxIds) |
| Returns the chunk indices which overlap the input rectable. More... | |
| static bool | checkOverlapSegment (const float p[2], const float q[2], const float bmin[2], const float bmax[2]) |
| int | rcGetChunksOverlappingSegment (const rcChunkyTriMesh *cm, float p[2], float q[2], int *ids, const int maxIds) |
| Returns the chunk indices which overlap the input segment. More... | |
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
| bool rcCreateChunkyTriMesh | +( | +const float * | +verts, | +
| + | + | const int * | +tris, | +
| + | + | int | +ntris, | +
| + | + | int | +trisPerChunk, | +
| + | + | rcChunkyTriMesh * | +cm | +
| + | ) | ++ |
Creates partitioned triangle mesh (AABB tree), where each node contains at max trisPerChunk triangles.
+ +| int rcGetChunksOverlappingRect | +( | +const rcChunkyTriMesh * | +cm, | +
| + | + | float | +bmin[2], | +
| + | + | float | +bmax[2], | +
| + | + | int * | +ids, | +
| + | + | const int | +maxIds | +
| + | ) | ++ |
Returns the chunk indices which overlap the input rectable.
+ +| int rcGetChunksOverlappingSegment | +( | +const rcChunkyTriMesh * | +cm, | +
| + | + | float | +p[2], | +
| + | + | float | +q[2], | +
| + | + | int * | +ids, | +
| + | + | const int | +maxIds | +
| + | ) | ++ |
Returns the chunk indices which overlap the input segment.
+ +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| struct | rcChunkyTriMeshNode |
| struct | rcChunkyTriMesh |
+Functions | |
| bool | rcCreateChunkyTriMesh (const float *verts, const int *tris, int ntris, int trisPerChunk, rcChunkyTriMesh *cm) |
| Creates partitioned triangle mesh (AABB tree), where each node contains at max trisPerChunk triangles. More... | |
| int | rcGetChunksOverlappingRect (const rcChunkyTriMesh *cm, float bmin[2], float bmax[2], int *ids, const int maxIds) |
| Returns the chunk indices which overlap the input rectable. More... | |
| int | rcGetChunksOverlappingSegment (const rcChunkyTriMesh *cm, float p[2], float q[2], int *ids, const int maxIds) |
| Returns the chunk indices which overlap the input segment. More... | |
| bool rcCreateChunkyTriMesh | +( | +const float * | +verts, | +
| + | + | const int * | +tris, | +
| + | + | int | +ntris, | +
| + | + | int | +trisPerChunk, | +
| + | + | rcChunkyTriMesh * | +cm | +
| + | ) | ++ |
Creates partitioned triangle mesh (AABB tree), where each node contains at max trisPerChunk triangles.
+ +| int rcGetChunksOverlappingRect | +( | +const rcChunkyTriMesh * | +cm, | +
| + | + | float | +bmin[2], | +
| + | + | float | +bmax[2], | +
| + | + | int * | +ids, | +
| + | + | const int | +maxIds | +
| + | ) | ++ |
Returns the chunk indices which overlap the input rectable.
+ +| int rcGetChunksOverlappingSegment | +( | +const rcChunkyTriMesh * | +cm, | +
| + | + | float | +p[2], | +
| + | + | float | +q[2], | +
| + | + | int * | +ids, | +
| + | + | const int | +maxIds | +
| + | ) | ++ |
Returns the chunk indices which overlap the input segment.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <string.h>#include <float.h>#include "SDL.h"#include "SDL_opengl.h"#include "imgui.h"#include "ConvexVolumeTool.h"#include "InputGeom.h"#include "Sample.h"#include "Recast.h"#include "RecastDebugDraw.h"#include "DetourDebugDraw.h"+Functions | |
| bool | left (const float *a, const float *b, const float *c) |
| bool | cmppt (const float *a, const float *b) |
| static int | convexhull (const float *pts, int npts, int *out) |
| static int | pointInPoly (int nvert, const float *verts, const float *p) |
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "Sample.h"Go to the source code of this file.
++Classes | |
| class | ConvexVolumeTool |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <string.h>#include <float.h>#include "SDL.h"#include "SDL_opengl.h"#include <GL/glu.h>#include "imgui.h"#include "CrowdTool.h"#include "InputGeom.h"#include "Sample.h"#include "DetourCrowd.h"#include "DetourDebugDraw.h"#include "DetourObstacleAvoidance.h"#include "DetourCommon.h"#include "DetourNode.h"#include "SampleInterfaces.h"+Functions | |
| static bool | isectSegAABB (const float *sp, const float *sq, const float *amin, const float *amax, float &tmin, float &tmax) |
| static void | getAgentBounds (const dtCrowdAgent *ag, float *bmin, float *bmax) |
| static void | calcVel (float *vel, const float *pos, const float *tgt, const float speed) |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "Sample.h"#include "DetourNavMesh.h"#include "DetourObstacleAvoidance.h"#include "ValueHistory.h"#include "DetourCrowd.h"Go to the source code of this file.
++Classes | |
| struct | CrowdToolParams |
| class | CrowdToolState |
| class | CrowdTool |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Functions | |
| int | bit (int a, int b) |
| unsigned int | duIntToCol (int i, int a) |
| void | duIntToCol (int i, float *col) |
| void | duCalcBoxColors (unsigned int *colors, unsigned int colTop, unsigned int colSide) |
| void | duDebugDrawCylinderWire (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col, const float lineWidth) |
| void | duDebugDrawBoxWire (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col, const float lineWidth) |
| void | duDebugDrawArc (struct duDebugDraw *dd, const float x0, const float y0, const float z0, const float x1, const float y1, const float z1, const float h, const float as0, const float as1, unsigned int col, const float lineWidth) |
| void | duDebugDrawArrow (struct duDebugDraw *dd, const float x0, const float y0, const float z0, const float x1, const float y1, const float z1, const float as0, const float as1, unsigned int col, const float lineWidth) |
| void | duDebugDrawCircle (struct duDebugDraw *dd, const float x, const float y, const float z, const float r, unsigned int col, const float lineWidth) |
| void | duDebugDrawCross (struct duDebugDraw *dd, const float x, const float y, const float z, const float size, unsigned int col, const float lineWidth) |
| void | duDebugDrawBox (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, const unsigned int *fcol) |
| void | duDebugDrawCylinder (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col) |
| void | duDebugDrawGridXZ (struct duDebugDraw *dd, const float ox, const float oy, const float oz, const int w, const int h, const float size, const unsigned int col, const float lineWidth) |
| void | duAppendCylinderWire (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col) |
| void | duAppendBoxWire (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col) |
| void | duAppendBoxPoints (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col) |
| void | duAppendBox (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, const unsigned int *fcol) |
| void | duAppendCylinder (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col) |
| void | evalArc (const float x0, const float y0, const float z0, const float dx, const float dy, const float dz, const float h, const float u, float *res) |
| void | vcross (float *dest, const float *v1, const float *v2) |
| void | vnormalize (float *v) |
| void | vsub (float *dest, const float *v1, const float *v2) |
| float | vdistSqr (const float *v1, const float *v2) |
| void | appendArrowHead (struct duDebugDraw *dd, const float *p, const float *q, const float s, unsigned int col) |
| void | duAppendArc (struct duDebugDraw *dd, const float x0, const float y0, const float z0, const float x1, const float y1, const float z1, const float h, const float as0, const float as1, unsigned int col) |
| void | duAppendArrow (struct duDebugDraw *dd, const float x0, const float y0, const float z0, const float x1, const float y1, const float z1, const float as0, const float as1, unsigned int col) |
| void | duAppendCircle (struct duDebugDraw *dd, const float x, const float y, const float z, const float r, unsigned int col) |
| void | duAppendCross (struct duDebugDraw *dd, const float x, const float y, const float z, const float s, unsigned int col) |
| void appendArrowHead | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float * | +p, | +
| + | + | const float * | +q, | +
| + | + | const float | +s, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
+
|
+ +inline | +
| void duAppendArc | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x0, | +
| + | + | const float | +y0, | +
| + | + | const float | +z0, | +
| + | + | const float | +x1, | +
| + | + | const float | +y1, | +
| + | + | const float | +z1, | +
| + | + | const float | +h, | +
| + | + | const float | +as0, | +
| + | + | const float | +as1, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendArrow | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x0, | +
| + | + | const float | +y0, | +
| + | + | const float | +z0, | +
| + | + | const float | +x1, | +
| + | + | const float | +y1, | +
| + | + | const float | +z1, | +
| + | + | const float | +as0, | +
| + | + | const float | +as1, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendBox | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | const unsigned int * | +fcol | +
| + | ) | ++ |
| void duAppendBoxPoints | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendBoxWire | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendCircle | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x, | +
| + | + | const float | +y, | +
| + | + | const float | +z, | +
| + | + | const float | +r, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendCross | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x, | +
| + | + | const float | +y, | +
| + | + | const float | +z, | +
| + | + | const float | +s, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendCylinder | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendCylinderWire | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duCalcBoxColors | +( | +unsigned int * | +colors, | +
| + | + | unsigned int | +colTop, | +
| + | + | unsigned int | +colSide | +
| + | ) | ++ |
| void duDebugDrawArc | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x0, | +
| + | + | const float | +y0, | +
| + | + | const float | +z0, | +
| + | + | const float | +x1, | +
| + | + | const float | +y1, | +
| + | + | const float | +z1, | +
| + | + | const float | +h, | +
| + | + | const float | +as0, | +
| + | + | const float | +as1, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawArrow | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x0, | +
| + | + | const float | +y0, | +
| + | + | const float | +z0, | +
| + | + | const float | +x1, | +
| + | + | const float | +y1, | +
| + | + | const float | +z1, | +
| + | + | const float | +as0, | +
| + | + | const float | +as1, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawBox | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | const unsigned int * | +fcol | +
| + | ) | ++ |
| void duDebugDrawBoxWire | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawCircle | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x, | +
| + | + | const float | +y, | +
| + | + | const float | +z, | +
| + | + | const float | +r, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawCross | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x, | +
| + | + | const float | +y, | +
| + | + | const float | +z, | +
| + | + | const float | +size, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawCylinder | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duDebugDrawCylinderWire | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawGridXZ | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +ox, | +
| + | + | const float | +oy, | +
| + | + | const float | +oz, | +
| + | + | const int | +w, | +
| + | + | const int | +h, | +
| + | + | const float | +size, | +
| + | + | const unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duIntToCol | +( | +int | +i, | +
| + | + | float * | +col | +
| + | ) | ++ |
| unsigned int duIntToCol | +( | +int | +i, | +
| + | + | int | +a | +
| + | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| struct | duDebugDraw |
| Abstract debug draw interface. More... | |
| class | duDisplayList |
+Enumerations | |
| enum | duDebugDrawPrimitives { DU_DRAW_POINTS +, DU_DRAW_LINES +, DU_DRAW_TRIS +, DU_DRAW_QUADS + } |
+Functions | |
| unsigned int | duRGBA (int r, int g, int b, int a) |
| unsigned int | duRGBAf (float fr, float fg, float fb, float fa) |
| unsigned int | duIntToCol (int i, int a) |
| void | duIntToCol (int i, float *col) |
| unsigned int | duMultCol (const unsigned int col, const unsigned int d) |
| unsigned int | duDarkenCol (unsigned int col) |
| unsigned int | duLerpCol (unsigned int ca, unsigned int cb, unsigned int u) |
| unsigned int | duTransCol (unsigned int c, unsigned int a) |
| void | duCalcBoxColors (unsigned int *colors, unsigned int colTop, unsigned int colSide) |
| void | duDebugDrawCylinderWire (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col, const float lineWidth) |
| void | duDebugDrawBoxWire (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col, const float lineWidth) |
| void | duDebugDrawArc (struct duDebugDraw *dd, const float x0, const float y0, const float z0, const float x1, const float y1, const float z1, const float h, const float as0, const float as1, unsigned int col, const float lineWidth) |
| void | duDebugDrawArrow (struct duDebugDraw *dd, const float x0, const float y0, const float z0, const float x1, const float y1, const float z1, const float as0, const float as1, unsigned int col, const float lineWidth) |
| void | duDebugDrawCircle (struct duDebugDraw *dd, const float x, const float y, const float z, const float r, unsigned int col, const float lineWidth) |
| void | duDebugDrawCross (struct duDebugDraw *dd, const float x, const float y, const float z, const float size, unsigned int col, const float lineWidth) |
| void | duDebugDrawBox (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, const unsigned int *fcol) |
| void | duDebugDrawCylinder (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col) |
| void | duDebugDrawGridXZ (struct duDebugDraw *dd, const float ox, const float oy, const float oz, const int w, const int h, const float size, const unsigned int col, const float lineWidth) |
| void | duAppendCylinderWire (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col) |
| void | duAppendBoxWire (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col) |
| void | duAppendBoxPoints (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col) |
| void | duAppendArc (struct duDebugDraw *dd, const float x0, const float y0, const float z0, const float x1, const float y1, const float z1, const float h, const float as0, const float as1, unsigned int col) |
| void | duAppendArrow (struct duDebugDraw *dd, const float x0, const float y0, const float z0, const float x1, const float y1, const float z1, const float as0, const float as1, unsigned int col) |
| void | duAppendCircle (struct duDebugDraw *dd, const float x, const float y, const float z, const float r, unsigned int col) |
| void | duAppendCross (struct duDebugDraw *dd, const float x, const float y, const float z, const float size, unsigned int col) |
| void | duAppendBox (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, const unsigned int *fcol) |
| void | duAppendCylinder (struct duDebugDraw *dd, float minx, float miny, float minz, float maxx, float maxy, float maxz, unsigned int col) |
+Variables | |
| static const float | DU_PI = 3.14159265f |
| enum duDebugDrawPrimitives | +
| void duAppendArc | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x0, | +
| + | + | const float | +y0, | +
| + | + | const float | +z0, | +
| + | + | const float | +x1, | +
| + | + | const float | +y1, | +
| + | + | const float | +z1, | +
| + | + | const float | +h, | +
| + | + | const float | +as0, | +
| + | + | const float | +as1, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendArrow | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x0, | +
| + | + | const float | +y0, | +
| + | + | const float | +z0, | +
| + | + | const float | +x1, | +
| + | + | const float | +y1, | +
| + | + | const float | +z1, | +
| + | + | const float | +as0, | +
| + | + | const float | +as1, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendBox | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | const unsigned int * | +fcol | +
| + | ) | ++ |
| void duAppendBoxPoints | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendBoxWire | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendCircle | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x, | +
| + | + | const float | +y, | +
| + | + | const float | +z, | +
| + | + | const float | +r, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendCross | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x, | +
| + | + | const float | +y, | +
| + | + | const float | +z, | +
| + | + | const float | +size, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendCylinder | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duAppendCylinderWire | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duCalcBoxColors | +( | +unsigned int * | +colors, | +
| + | + | unsigned int | +colTop, | +
| + | + | unsigned int | +colSide | +
| + | ) | ++ |
+
|
+ +inline | +
| void duDebugDrawArc | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x0, | +
| + | + | const float | +y0, | +
| + | + | const float | +z0, | +
| + | + | const float | +x1, | +
| + | + | const float | +y1, | +
| + | + | const float | +z1, | +
| + | + | const float | +h, | +
| + | + | const float | +as0, | +
| + | + | const float | +as1, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawArrow | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x0, | +
| + | + | const float | +y0, | +
| + | + | const float | +z0, | +
| + | + | const float | +x1, | +
| + | + | const float | +y1, | +
| + | + | const float | +z1, | +
| + | + | const float | +as0, | +
| + | + | const float | +as1, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawBox | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | const unsigned int * | +fcol | +
| + | ) | ++ |
| void duDebugDrawBoxWire | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawCircle | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x, | +
| + | + | const float | +y, | +
| + | + | const float | +z, | +
| + | + | const float | +r, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawCross | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +x, | +
| + | + | const float | +y, | +
| + | + | const float | +z, | +
| + | + | const float | +size, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawCylinder | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col | +
| + | ) | ++ |
| void duDebugDrawCylinderWire | +( | +struct duDebugDraw * | +dd, | +
| + | + | float | +minx, | +
| + | + | float | +miny, | +
| + | + | float | +minz, | +
| + | + | float | +maxx, | +
| + | + | float | +maxy, | +
| + | + | float | +maxz, | +
| + | + | unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duDebugDrawGridXZ | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float | +ox, | +
| + | + | const float | +oy, | +
| + | + | const float | +oz, | +
| + | + | const int | +w, | +
| + | + | const int | +h, | +
| + | + | const float | +size, | +
| + | + | const unsigned int | +col, | +
| + | + | const float | +lineWidth | +
| + | ) | ++ |
| void duIntToCol | +( | +int | +i, | +
| + | + | float * | +col | +
| + | ) | ++ |
| unsigned int duIntToCol | +( | +int | +i, | +
| + | + | int | +a | +
| + | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Functions | |
| static void * | dtAllocDefault (size_t size, dtAllocHint) |
| static void | dtFreeDefault (void *ptr) |
| void | dtAllocSetCustom (dtAllocFunc *allocFunc, dtFreeFunc *freeFunc) |
| Sets the base custom allocation functions to be used by Detour. More... | |
| void * | dtAlloc (size_t size, dtAllocHint hint) |
| Allocates a memory block. More... | |
| void | dtFree (void *ptr) |
| Deallocates a memory block. More... | |
+Variables | |
| static dtAllocFunc * | sAllocFunc = dtAllocDefault |
| static dtFreeFunc * | sFreeFunc = dtFreeDefault |
| void* dtAlloc | +( | +size_t | +size, | +
| + | + | dtAllocHint | +hint | +
| + | ) | ++ |
Allocates a memory block.
+| [in] | size | The size, in bytes of memory, to allocate. |
| [in] | hint | A hint to the allocator on how long the memory is expected to be in use. |
+
|
+ +static | +
| void dtAllocSetCustom | +( | +dtAllocFunc * | +allocFunc, | +
| + | + | dtFreeFunc * | +freeFunc | +
| + | ) | ++ |
| void dtFree | +( | +void * | +ptr | ) | ++ |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <stddef.h>Go to the source code of this file.
++Typedefs | |
| typedef void *() | dtAllocFunc(size_t size, dtAllocHint hint) |
| A memory allocation function. More... | |
| typedef void() | dtFreeFunc(void *ptr) |
| A memory deallocation function. More... | |
+Enumerations | |
| enum | dtAllocHint { DT_ALLOC_PERM +, DT_ALLOC_TEMP + } |
| Provides hint values to the memory allocator on how long the memory is expected to be used. More... | |
+Functions | |
| void | dtAllocSetCustom (dtAllocFunc *allocFunc, dtFreeFunc *freeFunc) |
| Sets the base custom allocation functions to be used by Detour. More... | |
| void * | dtAlloc (size_t size, dtAllocHint hint) |
| Allocates a memory block. More... | |
| void | dtFree (void *ptr) |
| Deallocates a memory block. More... | |
| typedef void*() dtAllocFunc(size_t size, dtAllocHint hint) | +
A memory allocation function.
+| typedef void() dtFreeFunc(void *ptr) | +
A memory deallocation function.
+| [in] | ptr | A pointer to a memory block previously allocated using dtAllocFunc. |
| enum dtAllocHint | +
| void* dtAlloc | +( | +size_t | +size, | +
| + | + | dtAllocHint | +hint | +
| + | ) | ++ |
Allocates a memory block.
+| [in] | size | The size, in bytes of memory, to allocate. |
| [in] | hint | A hint to the allocator on how long the memory is expected to be in use. |
| void dtAllocSetCustom | +( | +dtAllocFunc * | +allocFunc, | +
| + | + | dtFreeFunc * | +freeFunc | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourAssert.h"+Functions | |
| void | dtAssertFailSetCustom (dtAssertFailFunc *assertFailFunc) |
| Sets the base custom assertion failure function to be used by Detour. More... | |
| dtAssertFailFunc * | dtAssertFailGetCustom () |
| Gets the base custom assertion failure function to be used by Detour. More... | |
+Variables | |
| static dtAssertFailFunc * | sAssertFailFunc = 0 |
| dtAssertFailFunc* dtAssertFailGetCustom | +( | +) | ++ |
Gets the base custom assertion failure function to be used by Detour.
+ +| void dtAssertFailSetCustom | +( | +dtAssertFailFunc * | +assertFailFunc | ) | ++ |
Sets the base custom assertion failure function to be used by Detour.
+| [in] | assertFailFunc | The function to be invoked in case of failure of dtAssert |
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <assert.h>Go to the source code of this file.
++Macros | |
| #define | dtAssert(expression) |
+Typedefs | |
| typedef void() | dtAssertFailFunc(const char *expression, const char *file, int line) |
| An assertion failure function. More... | |
+Functions | |
| void | dtAssertFailSetCustom (dtAssertFailFunc *assertFailFunc) |
| Sets the base custom assertion failure function to be used by Detour. More... | |
| dtAssertFailFunc * | dtAssertFailGetCustom () |
| Gets the base custom assertion failure function to be used by Detour. More... | |
| #define dtAssert | +( | ++ | expression | ) | ++ |
| typedef void() dtAssertFailFunc(const char *expression, const char *file, int line) | +
An assertion failure function.
+| dtAssertFailFunc* dtAssertFailGetCustom | +( | +) | ++ |
Gets the base custom assertion failure function to be used by Detour.
+ +| void dtAssertFailSetCustom | +( | +dtAssertFailFunc * | +assertFailFunc | ) | ++ |
Sets the base custom assertion failure function to be used by Detour.
+| [in] | assertFailFunc | The function to be invoked in case of failure of dtAssert |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Functions | |
| void | dtClosestPtPointTriangle (float *closest, const float *p, const float *a, const float *b, const float *c) |
| Derives the closest point on a triangle from the specified reference point. More... | |
| bool | dtIntersectSegmentPoly2D (const float *p0, const float *p1, const float *verts, int nverts, float &tmin, float &tmax, int &segMin, int &segMax) |
| float | dtDistancePtSegSqr2D (const float *pt, const float *p, const float *q, float &t) |
| void | dtCalcPolyCenter (float *tc, const unsigned short *idx, int nidx, const float *verts) |
| Derives the centroid of a convex polygon. More... | |
| bool | dtClosestHeightPointTriangle (const float *p, const float *a, const float *b, const float *c, float &h) |
| Derives the y-axis height of the closest point on the triangle from the specified reference point. More... | |
| bool | dtPointInPolygon (const float *pt, const float *verts, const int nverts) |
| Determines if the specified point is inside the convex polygon on the xz-plane. More... | |
| bool | dtDistancePtPolyEdgesSqr (const float *pt, const float *verts, const int nverts, float *ed, float *et) |
| static void | projectPoly (const float *axis, const float *poly, const int npoly, float &rmin, float &rmax) |
| bool | overlapRange (const float amin, const float amax, const float bmin, const float bmax, const float eps) |
| bool | dtOverlapPolyPoly2D (const float *polya, const int npolya, const float *polyb, const int npolyb) |
| Determines if the two convex polygons overlap on the xz-plane. More... | |
| void | dtRandomPointInConvexPoly (const float *pts, const int npts, float *areas, const float s, const float t, float *out) |
| float | vperpXZ (const float *a, const float *b) |
| bool | dtIntersectSegSeg2D (const float *ap, const float *aq, const float *bp, const float *bq, float &s, float &t) |
| void dtCalcPolyCenter | +( | +float * | +tc, | +
| + | + | const unsigned short * | +idx, | +
| + | + | int | +nidx, | +
| + | + | const float * | +verts | +
| + | ) | ++ |
Derives the centroid of a convex polygon.
+| [out] | tc | The centroid of the polgyon. [(x, y, z)] |
| [in] | idx | The polygon indices. [(vertIndex) * nidx] |
| [in] | nidx | The number of indices in the polygon. [Limit: >= 3] |
| [in] | verts | The polygon vertices. [(x, y, z) * vertCount] |
| bool dtClosestHeightPointTriangle | +( | +const float * | +p, | +
| + | + | const float * | +a, | +
| + | + | const float * | +b, | +
| + | + | const float * | +c, | +
| + | + | float & | +h | +
| + | ) | ++ |
Derives the y-axis height of the closest point on the triangle from the specified reference point.
+| [in] | p | The reference point from which to test. [(x, y, z)] |
| [in] | a | Vertex A of triangle ABC. [(x, y, z)] |
| [in] | b | Vertex B of triangle ABC. [(x, y, z)] |
| [in] | c | Vertex C of triangle ABC. [(x, y, z)] |
| [out] | h | The resulting height. |
| void dtClosestPtPointTriangle | +( | +float * | +closest, | +
| + | + | const float * | +p, | +
| + | + | const float * | +a, | +
| + | + | const float * | +b, | +
| + | + | const float * | +c | +
| + | ) | ++ |
Derives the closest point on a triangle from the specified reference point.
+| [out] | closest | The closest point on the triangle. + |
| [in] | p | The reference point from which to test. [(x, y, z)] |
| [in] | a | Vertex A of triangle ABC. [(x, y, z)] |
| [in] | b | Vertex B of triangle ABC. [(x, y, z)] |
| [in] | c | Vertex C of triangle ABC. [(x, y, z)] |
| bool dtDistancePtPolyEdgesSqr | +( | +const float * | +pt, | +
| + | + | const float * | +verts, | +
| + | + | const int | +nverts, | +
| + | + | float * | +ed, | +
| + | + | float * | +et | +
| + | ) | ++ |
| float dtDistancePtSegSqr2D | +( | +const float * | +pt, | +
| + | + | const float * | +p, | +
| + | + | const float * | +q, | +
| + | + | float & | +t | +
| + | ) | ++ |
| bool dtIntersectSegmentPoly2D | +( | +const float * | +p0, | +
| + | + | const float * | +p1, | +
| + | + | const float * | +verts, | +
| + | + | int | +nverts, | +
| + | + | float & | +tmin, | +
| + | + | float & | +tmax, | +
| + | + | int & | +segMin, | +
| + | + | int & | +segMax | +
| + | ) | ++ |
| bool dtIntersectSegSeg2D | +( | +const float * | +ap, | +
| + | + | const float * | +aq, | +
| + | + | const float * | +bp, | +
| + | + | const float * | +bq, | +
| + | + | float & | +s, | +
| + | + | float & | +t | +
| + | ) | ++ |
| bool dtOverlapPolyPoly2D | +( | +const float * | +polya, | +
| + | + | const int | +npolya, | +
| + | + | const float * | +polyb, | +
| + | + | const int | +npolyb | +
| + | ) | ++ |
Determines if the two convex polygons overlap on the xz-plane.
+All vertices are projected onto the xz-plane, so the y-values are ignored.
+ +| bool dtPointInPolygon | +( | +const float * | +pt, | +
| + | + | const float * | +verts, | +
| + | + | const int | +nverts | +
| + | ) | ++ |
Determines if the specified point is inside the convex polygon on the xz-plane.
+All points are projected onto the xz-plane, so the y-values are ignored.
+ +| void dtRandomPointInConvexPoly | +( | +const float * | +pts, | +
| + | + | const int | +npts, | +
| + | + | float * | +areas, | +
| + | + | const float | +s, | +
| + | + | const float | +t, | +
| + | + | float * | +out | +
| + | ) | ++ |
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Functions | |
General helper functions | |
| template<class T > | |
| void | dtIgnoreUnused (const T &) |
| Used to ignore a function parameter. More... | |
| template<class T > | |
| void | dtSwap (T &a, T &b) |
| Swaps the values of the two parameters. More... | |
| template<class T > | |
| T | dtMin (T a, T b) |
| Returns the minimum of two values. More... | |
| template<class T > | |
| T | dtMax (T a, T b) |
| Returns the maximum of two values. More... | |
| template<class T > | |
| T | dtAbs (T a) |
| Returns the absolute value. More... | |
| template<class T > | |
| T | dtSqr (T a) |
| Returns the square of the value. More... | |
| template<class T > | |
| T | dtClamp (T v, T mn, T mx) |
| Clamps the value to the specified range. More... | |
Vector helper functions. | |
| void | dtVcross (float *dest, const float *v1, const float *v2) |
| Derives the cross product of two vectors. More... | |
| float | dtVdot (const float *v1, const float *v2) |
| Derives the dot product of two vectors. More... | |
| void | dtVmad (float *dest, const float *v1, const float *v2, const float s) |
| Performs a scaled vector addition. More... | |
| void | dtVlerp (float *dest, const float *v1, const float *v2, const float t) |
| Performs a linear interpolation between two vectors. More... | |
| void | dtVadd (float *dest, const float *v1, const float *v2) |
| Performs a vector addition. More... | |
| void | dtVsub (float *dest, const float *v1, const float *v2) |
| Performs a vector subtraction. More... | |
| void | dtVscale (float *dest, const float *v, const float t) |
| Scales the vector by the specified value. More... | |
| void | dtVmin (float *mn, const float *v) |
| Selects the minimum value of each element from the specified vectors. More... | |
| void | dtVmax (float *mx, const float *v) |
| Selects the maximum value of each element from the specified vectors. More... | |
| void | dtVset (float *dest, const float x, const float y, const float z) |
| Sets the vector elements to the specified values. More... | |
| void | dtVcopy (float *dest, const float *a) |
| Performs a vector copy. More... | |
| float | dtVlen (const float *v) |
| Derives the scalar length of the vector. More... | |
| float | dtVlenSqr (const float *v) |
| Derives the square of the scalar length of the vector. More... | |
| float | dtVdist (const float *v1, const float *v2) |
| Returns the distance between two points. More... | |
| float | dtVdistSqr (const float *v1, const float *v2) |
| Returns the square of the distance between two points. More... | |
| float | dtVdist2D (const float *v1, const float *v2) |
| Derives the distance between the specified points on the xz-plane. More... | |
| float | dtVdist2DSqr (const float *v1, const float *v2) |
| Derives the square of the distance between the specified points on the xz-plane. More... | |
| void | dtVnormalize (float *v) |
| Normalizes the vector. More... | |
| bool | dtVequal (const float *p0, const float *p1) |
| Performs a 'sloppy' colocation check of the specified points. More... | |
| bool | dtVisfinite (const float *v) |
| Checks that the specified vector's components are all finite. More... | |
| bool | dtVisfinite2D (const float *v) |
| Checks that the specified vector's 2D components are finite. More... | |
| float | dtVdot2D (const float *u, const float *v) |
| Derives the dot product of two vectors on the xz-plane. More... | |
| float | dtVperp2D (const float *u, const float *v) |
| Derives the xz-plane 2D perp product of the two vectors. More... | |
Computational geometry helper functions. | |
| float | dtTriArea2D (const float *a, const float *b, const float *c) |
| Derives the signed xz-plane area of the triangle ABC, or the relationship of line AB to point C. More... | |
| bool | dtOverlapQuantBounds (const unsigned short amin[3], const unsigned short amax[3], const unsigned short bmin[3], const unsigned short bmax[3]) |
| Determines if two axis-aligned bounding boxes overlap. More... | |
| bool | dtOverlapBounds (const float *amin, const float *amax, const float *bmin, const float *bmax) |
| Determines if two axis-aligned bounding boxes overlap. More... | |
| void | dtClosestPtPointTriangle (float *closest, const float *p, const float *a, const float *b, const float *c) |
| Derives the closest point on a triangle from the specified reference point. More... | |
| bool | dtClosestHeightPointTriangle (const float *p, const float *a, const float *b, const float *c, float &h) |
| Derives the y-axis height of the closest point on the triangle from the specified reference point. More... | |
| bool | dtIntersectSegmentPoly2D (const float *p0, const float *p1, const float *verts, int nverts, float &tmin, float &tmax, int &segMin, int &segMax) |
| bool | dtIntersectSegSeg2D (const float *ap, const float *aq, const float *bp, const float *bq, float &s, float &t) |
| bool | dtPointInPolygon (const float *pt, const float *verts, const int nverts) |
| Determines if the specified point is inside the convex polygon on the xz-plane. More... | |
| bool | dtDistancePtPolyEdgesSqr (const float *pt, const float *verts, const int nverts, float *ed, float *et) |
| float | dtDistancePtSegSqr2D (const float *pt, const float *p, const float *q, float &t) |
| void | dtCalcPolyCenter (float *tc, const unsigned short *idx, int nidx, const float *verts) |
| Derives the centroid of a convex polygon. More... | |
| bool | dtOverlapPolyPoly2D (const float *polya, const int npolya, const float *polyb, const int npolyb) |
| Determines if the two convex polygons overlap on the xz-plane. More... | |
Miscellanious functions. | |
| unsigned int | dtNextPow2 (unsigned int v) |
| unsigned int | dtIlog2 (unsigned int v) |
| int | dtAlign4 (int x) |
| int | dtOppositeTile (int side) |
| void | dtSwapByte (unsigned char *a, unsigned char *b) |
| void | dtSwapEndian (unsigned short *v) |
| void | dtSwapEndian (short *v) |
| void | dtSwapEndian (unsigned int *v) |
| void | dtSwapEndian (int *v) |
| void | dtSwapEndian (float *v) |
| void | dtRandomPointInConvexPoly (const float *pts, const int npts, float *areas, const float s, const float t, float *out) |
| template<typename TypeToRetrieveAs > | |
| TypeToRetrieveAs * | dtGetThenAdvanceBufferPointer (const unsigned char *&buffer, const size_t distanceToAdvance) |
| template<typename TypeToRetrieveAs > | |
| TypeToRetrieveAs * | dtGetThenAdvanceBufferPointer (unsigned char *&buffer, const size_t distanceToAdvance) |
+
|
+ +inline | +
Returns the absolute value.
+| [in] | a | The value. |
+
|
+ +inline | +
| void dtCalcPolyCenter | +( | +float * | +tc, | +
| + | + | const unsigned short * | +idx, | +
| + | + | int | +nidx, | +
| + | + | const float * | +verts | +
| + | ) | ++ |
Derives the centroid of a convex polygon.
+| [out] | tc | The centroid of the polgyon. [(x, y, z)] |
| [in] | idx | The polygon indices. [(vertIndex) * nidx] |
| [in] | nidx | The number of indices in the polygon. [Limit: >= 3] |
| [in] | verts | The polygon vertices. [(x, y, z) * vertCount] |
+
|
+ +inline | +
Clamps the value to the specified range.
+| [in] | v | The value to clamp. |
| [in] | mn | The minimum permitted return value. |
| [in] | mx | The maximum permitted return value. |
| bool dtClosestHeightPointTriangle | +( | +const float * | +p, | +
| + | + | const float * | +a, | +
| + | + | const float * | +b, | +
| + | + | const float * | +c, | +
| + | + | float & | +h | +
| + | ) | ++ |
Derives the y-axis height of the closest point on the triangle from the specified reference point.
+| [in] | p | The reference point from which to test. [(x, y, z)] |
| [in] | a | Vertex A of triangle ABC. [(x, y, z)] |
| [in] | b | Vertex B of triangle ABC. [(x, y, z)] |
| [in] | c | Vertex C of triangle ABC. [(x, y, z)] |
| [out] | h | The resulting height. |
| void dtClosestPtPointTriangle | +( | +float * | +closest, | +
| + | + | const float * | +p, | +
| + | + | const float * | +a, | +
| + | + | const float * | +b, | +
| + | + | const float * | +c | +
| + | ) | ++ |
Derives the closest point on a triangle from the specified reference point.
+| [out] | closest | The closest point on the triangle. + |
| [in] | p | The reference point from which to test. [(x, y, z)] |
| [in] | a | Vertex A of triangle ABC. [(x, y, z)] |
| [in] | b | Vertex B of triangle ABC. [(x, y, z)] |
| [in] | c | Vertex C of triangle ABC. [(x, y, z)] |
| bool dtDistancePtPolyEdgesSqr | +( | +const float * | +pt, | +
| + | + | const float * | +verts, | +
| + | + | const int | +nverts, | +
| + | + | float * | +ed, | +
| + | + | float * | +et | +
| + | ) | ++ |
| float dtDistancePtSegSqr2D | +( | +const float * | +pt, | +
| + | + | const float * | +p, | +
| + | + | const float * | +q, | +
| + | + | float & | +t | +
| + | ) | ++ |
| TypeToRetrieveAs* dtGetThenAdvanceBufferPointer | +( | +const unsigned char *& | +buffer, | +
| + | + | const size_t | +distanceToAdvance | +
| + | ) | ++ |
| TypeToRetrieveAs* dtGetThenAdvanceBufferPointer | +( | +unsigned char *& | +buffer, | +
| + | + | const size_t | +distanceToAdvance | +
| + | ) | ++ |
| void dtIgnoreUnused | +( | +const T & | +) | ++ |
Used to ignore a function parameter.
+VS complains about unused parameters and this silences the warning.
+ +
+
|
+ +inline | +
| bool dtIntersectSegmentPoly2D | +( | +const float * | +p0, | +
| + | + | const float * | +p1, | +
| + | + | const float * | +verts, | +
| + | + | int | +nverts, | +
| + | + | float & | +tmin, | +
| + | + | float & | +tmax, | +
| + | + | int & | +segMin, | +
| + | + | int & | +segMax | +
| + | ) | ++ |
| bool dtIntersectSegSeg2D | +( | +const float * | +ap, | +
| + | + | const float * | +aq, | +
| + | + | const float * | +bp, | +
| + | + | const float * | +bq, | +
| + | + | float & | +s, | +
| + | + | float & | +t | +
| + | ) | ++ |
+
|
+ +inline | +
Returns the maximum of two values.
+| [in] | a | Value A |
| [in] | b | Value B |
+
|
+ +inline | +
Returns the minimum of two values.
+| [in] | a | Value A |
| [in] | b | Value B |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
Determines if two axis-aligned bounding boxes overlap.
+| [in] | amin | Minimum bounds of box A. [(x, y, z)] |
| [in] | amax | Maximum bounds of box A. [(x, y, z)] |
| [in] | bmin | Minimum bounds of box B. [(x, y, z)] |
| [in] | bmax | Maximum bounds of box B. [(x, y, z)] |
| bool dtOverlapPolyPoly2D | +( | +const float * | +polya, | +
| + | + | const int | +npolya, | +
| + | + | const float * | +polyb, | +
| + | + | const int | +npolyb | +
| + | ) | ++ |
Determines if the two convex polygons overlap on the xz-plane.
+| [in] | polya | Polygon A vertices. [(x, y, z) * npolya] |
| [in] | npolya | The number of vertices in polygon A. |
| [in] | polyb | Polygon B vertices. [(x, y, z) * npolyb] |
| [in] | npolyb | The number of vertices in polygon B. |
All vertices are projected onto the xz-plane, so the y-values are ignored.
+ +
+
|
+ +inline | +
Determines if two axis-aligned bounding boxes overlap.
+| [in] | amin | Minimum bounds of box A. [(x, y, z)] |
| [in] | amax | Maximum bounds of box A. [(x, y, z)] |
| [in] | bmin | Minimum bounds of box B. [(x, y, z)] |
| [in] | bmax | Maximum bounds of box B. [(x, y, z)] |
| bool dtPointInPolygon | +( | +const float * | +pt, | +
| + | + | const float * | +verts, | +
| + | + | const int | +nverts | +
| + | ) | ++ |
Determines if the specified point is inside the convex polygon on the xz-plane.
+| [in] | pt | The point to check. [(x, y, z)] |
| [in] | verts | The polygon vertices. [(x, y, z) * nverts] |
| [in] | nverts | The number of vertices. [Limit: >= 3] |
All points are projected onto the xz-plane, so the y-values are ignored.
+ +| void dtRandomPointInConvexPoly | +( | +const float * | +pts, | +
| + | + | const int | +npts, | +
| + | + | float * | +areas, | +
| + | + | const float | +s, | +
| + | + | const float | +t, | +
| + | + | float * | +out | +
| + | ) | ++ |
+
|
+ +inline | +
Returns the square of the value.
+| [in] | a | The value. |
+
|
+ +inline | +
Swaps the values of the two parameters.
+| [in,out] | a | Value A |
| [in,out] | b | Value B |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
Derives the signed xz-plane area of the triangle ABC, or the relationship of line AB to point C.
+| [in] | a | Vertex A. [(x, y, z)] |
| [in] | b | Vertex B. [(x, y, z)] |
| [in] | c | Vertex C. [(x, y, z)] |
The vertices are projected onto the xz-plane, so the y-values are ignored.
+This is a low cost function than can be used for various purposes. Its main purpose is for point/line relationship testing.
+In all cases: A value of zero indicates that all vertices are collinear or represent the same point. (On the xz-plane.)
+When used for point/line relationship tests, AB usually represents a line against which the C point is to be tested. In this case:
+A positive value indicates that point C is to the left of line AB, looking from A toward B.
+ A negative value indicates that point C is to the right of lineAB, looking from A toward B.
When used for evaluating a triangle:
+The absolute value of the return value is two times the area of the triangle when it is projected onto the xz-plane.
+A positive return value indicates:
+A negative return value indicates:
+
+
|
+ +inline | +
Performs a vector addition.
+(v1 + v2)
| [out] | dest | The result vector. [(x, y, z)] |
| [in] | v1 | The base vector. [(x, y, z)] |
| [in] | v2 | The vector to add to v1. [(x, y, z)] |
+
|
+ +inline | +
Performs a vector copy.
+| [out] | dest | The result. [(x, y, z)] |
| [in] | a | The vector to copy. [(x, y, z)] |
+
|
+ +inline | +
Derives the cross product of two vectors.
+(v1 x v2)
| [out] | dest | The cross product. [(x, y, z)] |
| [in] | v1 | A Vector [(x, y, z)] |
| [in] | v2 | A vector [(x, y, z)] |
+
|
+ +inline | +
Returns the distance between two points.
+| [in] | v1 | A point. [(x, y, z)] |
| [in] | v2 | A point. [(x, y, z)] |
+
|
+ +inline | +
Derives the distance between the specified points on the xz-plane.
+| [in] | v1 | A point. [(x, y, z)] |
| [in] | v2 | A point. [(x, y, z)] |
The vectors are projected onto the xz-plane, so the y-values are ignored.
+ +
+
|
+ +inline | +
Derives the square of the distance between the specified points on the xz-plane.
+| [in] | v1 | A point. [(x, y, z)] |
| [in] | v2 | A point. [(x, y, z)] |
+
|
+ +inline | +
Returns the square of the distance between two points.
+| [in] | v1 | A point. [(x, y, z)] |
| [in] | v2 | A point. [(x, y, z)] |
+
|
+ +inline | +
Derives the dot product of two vectors.
+(v1 . v2)
| [in] | v1 | A Vector [(x, y, z)] |
| [in] | v2 | A vector [(x, y, z)] |
+
|
+ +inline | +
Derives the dot product of two vectors on the xz-plane.
+(u . v)
| [in] | u | A vector [(x, y, z)] |
| [in] | v | A vector [(x, y, z)] |
The vectors are projected onto the xz-plane, so the y-values are ignored.
+ +
+
|
+ +inline | +
Performs a 'sloppy' colocation check of the specified points.
+| [in] | p0 | A point. [(x, y, z)] |
| [in] | p1 | A point. [(x, y, z)] |
Basically, this function will return true if the specified points are close enough to eachother to be considered colocated.
+ +
+
|
+ +inline | +
Checks that the specified vector's components are all finite.
+| [in] | v | A point. [(x, y, z)] |
+
|
+ +inline | +
Checks that the specified vector's 2D components are finite.
+| [in] | v | A point. [(x, y, z)] |
+
|
+ +inline | +
Derives the scalar length of the vector.
+| [in] | v | The vector. [(x, y, z)] |
+
|
+ +inline | +
Derives the square of the scalar length of the vector.
+(len * len)
| [in] | v | The vector. [(x, y, z)] |
+
|
+ +inline | +
Performs a linear interpolation between two vectors.
+(v1 toward v2)
| [out] | dest | The result vector. [(x, y, x)] |
| [in] | v1 | The starting vector. |
| [in] | v2 | The destination vector. |
| [in] | t | The interpolation factor. [Limits: 0 <= value <= 1.0] |
+
|
+ +inline | +
Performs a scaled vector addition.
+(v1 + (v2 * s))
| [out] | dest | The result vector. [(x, y, z)] |
| [in] | v1 | The base vector. [(x, y, z)] |
| [in] | v2 | The vector to scale and add to v1. [(x, y, z)] |
| [in] | s | The amount to scale v2 by before adding to v1. |
+
|
+ +inline | +
Selects the maximum value of each element from the specified vectors.
+| [in,out] | mx | A vector. (Will be updated with the result.) [(x, y, z)] |
| [in] | v | A vector. [(x, y, z)] |
+
|
+ +inline | +
Selects the minimum value of each element from the specified vectors.
+| [in,out] | mn | A vector. (Will be updated with the result.) [(x, y, z)] |
| [in] | v | A vector. [(x, y, z)] |
+
|
+ +inline | +
Normalizes the vector.
+| [in,out] | v | The vector to normalize. [(x, y, z)] |
+
|
+ +inline | +
Derives the xz-plane 2D perp product of the two vectors.
+(uz*vx - ux*vz)
| [in] | u | The LHV vector [(x, y, z)] |
| [in] | v | The RHV vector [(x, y, z)] |
The vectors are projected onto the xz-plane, so the y-values are ignored.
+ +
+
|
+ +inline | +
Scales the vector by the specified value.
+(v * t)
| [out] | dest | The result vector. [(x, y, z)] |
| [in] | v | The vector to scale. [(x, y, z)] |
| [in] | t | The scaling factor. |
+
|
+ +inline | +
Sets the vector elements to the specified values.
+| [out] | dest | The result vector. [(x, y, z)] |
| [in] | x | The x-value of the vector. |
| [in] | y | The y-value of the vector. |
| [in] | z | The z-value of the vector. |
+
|
+ +inline | +
Performs a vector subtraction.
+(v1 - v2)
| [out] | dest | The result vector. [(x, y, z)] |
| [in] | v1 | The base vector. [(x, y, z)] |
| [in] | v2 | The vector to subtract from v1. [(x, y, z)] |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <string.h>#include <float.h>#include <stdlib.h>#include <new>#include "DetourCrowd.h"#include "DetourNavMesh.h"#include "DetourNavMeshQuery.h"#include "DetourObstacleAvoidance.h"#include "DetourCommon.h"#include "DetourMath.h"#include "DetourAssert.h"#include "DetourAlloc.h"+Functions | |
| dtCrowd * | dtAllocCrowd () |
| Allocates a crowd object using the Detour allocator. More... | |
| void | dtFreeCrowd (dtCrowd *ptr) |
| Frees the specified crowd object using the Detour allocator. More... | |
| float | tween (const float t, const float t0, const float t1) |
| static void | integrate (dtCrowdAgent *ag, const float dt) |
| static bool | overOffmeshConnection (const dtCrowdAgent *ag, const float radius) |
| static float | getDistanceToGoal (const dtCrowdAgent *ag, const float range) |
| static void | calcSmoothSteerDirection (const dtCrowdAgent *ag, float *dir) |
| static void | calcStraightSteerDirection (const dtCrowdAgent *ag, float *dir) |
| static int | addNeighbour (const int idx, const float dist, dtCrowdNeighbour *neis, const int nneis, const int maxNeis) |
| static int | getNeighbours (const float *pos, const float height, const float range, const dtCrowdAgent *skip, dtCrowdNeighbour *result, const int maxResult, dtCrowdAgent **agents, const int, dtProximityGrid *grid) |
| static int | addToOptQueue (dtCrowdAgent *newag, dtCrowdAgent **agents, const int nagents, const int maxAgents) |
| static int | addToPathQueue (dtCrowdAgent *newag, dtCrowdAgent **agents, const int nagents, const int maxAgents) |
+Variables | |
| static const int | MAX_ITERS_PER_UPDATE = 100 |
| static const int | MAX_PATHQUEUE_NODES = 4096 |
| static const int | MAX_COMMON_NODES = 512 |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourNavMeshQuery.h"#include "DetourObstacleAvoidance.h"#include "DetourLocalBoundary.h"#include "DetourPathCorridor.h"#include "DetourProximityGrid.h"#include "DetourPathQueue.h"Go to the source code of this file.
++Classes | |
| struct | dtCrowdNeighbour |
| Provides neighbor data for agents managed by the crowd. More... | |
| struct | dtCrowdAgentParams |
| Configuration parameters for a crowd agent. More... | |
| struct | dtCrowdAgent |
| Represents an agent managed by a dtCrowd object. More... | |
| struct | dtCrowdAgentAnimation |
| struct | dtCrowdAgentDebugInfo |
| class | dtCrowd |
| Provides local steering behaviors for a group of agents. More... | |
+Enumerations | |
| enum | CrowdAgentState { DT_CROWDAGENT_STATE_INVALID +, DT_CROWDAGENT_STATE_WALKING +, DT_CROWDAGENT_STATE_OFFMESH + } |
| The type of navigation mesh polygon the agent is currently traversing. More... | |
| enum | MoveRequestState { + DT_CROWDAGENT_TARGET_NONE = 0 +, DT_CROWDAGENT_TARGET_FAILED +, DT_CROWDAGENT_TARGET_VALID +, DT_CROWDAGENT_TARGET_REQUESTING +, + DT_CROWDAGENT_TARGET_WAITING_FOR_QUEUE +, DT_CROWDAGENT_TARGET_WAITING_FOR_PATH +, DT_CROWDAGENT_TARGET_VELOCITY + + } |
| enum | UpdateFlags { + DT_CROWD_ANTICIPATE_TURNS = 1 +, DT_CROWD_OBSTACLE_AVOIDANCE = 2 +, DT_CROWD_SEPARATION = 4 +, DT_CROWD_OPTIMIZE_VIS = 8 +, + DT_CROWD_OPTIMIZE_TOPO = 16 + + } |
| Crowd agent update flags. More... | |
+Functions | |
| dtCrowd * | dtAllocCrowd () |
| Allocates a crowd object using the Detour allocator. More... | |
| void | dtFreeCrowd (dtCrowd *ptr) |
| Frees the specified crowd object using the Detour allocator. More... | |
+Variables | |
| static const int | DT_CROWDAGENT_MAX_NEIGHBOURS = 6 |
| The maximum number of neighbors that a crowd agent can take into account for steering decisions. More... | |
| static const int | DT_CROWDAGENT_MAX_CORNERS = 4 |
| The maximum number of corners a crowd agent will look ahead in the path. More... | |
| static const int | DT_CROWD_MAX_OBSTAVOIDANCE_PARAMS = 8 |
| The maximum number of crowd avoidance configurations supported by the crowd manager. More... | |
| static const int | DT_CROWD_MAX_QUERY_FILTER_TYPE = 16 |
| The maximum number of query filter types supported by the crowd manager. More... | |
| enum MoveRequestState | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DebugDraw.h"#include "DetourDebugDraw.h"#include "DetourNavMesh.h"#include "DetourCommon.h"#include "DetourNode.h"+Functions | |
| static float | distancePtLine2d (const float *pt, const float *p, const float *q) |
| static void | drawPolyBoundaries (duDebugDraw *dd, const dtMeshTile *tile, const unsigned int col, const float linew, bool inner) |
| static void | drawMeshTile (duDebugDraw *dd, const dtNavMesh &mesh, const dtNavMeshQuery *query, const dtMeshTile *tile, unsigned char flags) |
| void | duDebugDrawNavMesh (duDebugDraw *dd, const dtNavMesh &mesh, unsigned char flags) |
| void | duDebugDrawNavMeshWithClosedList (struct duDebugDraw *dd, const dtNavMesh &mesh, const dtNavMeshQuery &query, unsigned char flags) |
| void | duDebugDrawNavMeshNodes (struct duDebugDraw *dd, const dtNavMeshQuery &query) |
| static void | drawMeshTileBVTree (duDebugDraw *dd, const dtMeshTile *tile) |
| void | duDebugDrawNavMeshBVTree (duDebugDraw *dd, const dtNavMesh &mesh) |
| static void | drawMeshTilePortal (duDebugDraw *dd, const dtMeshTile *tile) |
| void | duDebugDrawNavMeshPortals (duDebugDraw *dd, const dtNavMesh &mesh) |
| void | duDebugDrawNavMeshPolysWithFlags (struct duDebugDraw *dd, const dtNavMesh &mesh, const unsigned short polyFlags, const unsigned int col) |
| void | duDebugDrawNavMeshPoly (duDebugDraw *dd, const dtNavMesh &mesh, dtPolyRef ref, const unsigned int col) |
| static void | debugDrawTileCachePortals (struct duDebugDraw *dd, const dtTileCacheLayer &layer, const float cs, const float ch) |
| void | duDebugDrawTileCacheLayerAreas (struct duDebugDraw *dd, const dtTileCacheLayer &layer, const float cs, const float ch) |
| void | duDebugDrawTileCacheLayerRegions (struct duDebugDraw *dd, const dtTileCacheLayer &layer, const float cs, const float ch) |
| void | duDebugDrawTileCacheContours (duDebugDraw *dd, const struct dtTileCacheContourSet &lcset, const float *orig, const float cs, const float ch) |
| void | duDebugDrawTileCachePolyMesh (duDebugDraw *dd, const struct dtTileCachePolyMesh &lmesh, const float *orig, const float cs, const float ch) |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
| void duDebugDrawNavMesh | +( | +duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh, | +
| + | + | unsigned char | +flags | +
| + | ) | ++ |
| void duDebugDrawNavMeshBVTree | +( | +duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh | +
| + | ) | ++ |
| void duDebugDrawNavMeshNodes | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtNavMeshQuery & | +query | +
| + | ) | ++ |
| void duDebugDrawNavMeshPoly | +( | +duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh, | +
| + | + | dtPolyRef | +ref, | +
| + | + | const unsigned int | +col | +
| + | ) | ++ |
| void duDebugDrawNavMeshPolysWithFlags | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh, | +
| + | + | const unsigned short | +polyFlags, | +
| + | + | const unsigned int | +col | +
| + | ) | ++ |
| void duDebugDrawNavMeshPortals | +( | +duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh | +
| + | ) | ++ |
| void duDebugDrawNavMeshWithClosedList | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh, | +
| + | + | const dtNavMeshQuery & | +query, | +
| + | + | unsigned char | +flags | +
| + | ) | ++ |
| void duDebugDrawTileCacheContours | +( | +duDebugDraw * | +dd, | +
| + | + | const struct dtTileCacheContourSet & | +lcset, | +
| + | + | const float * | +orig, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch | +
| + | ) | ++ |
| void duDebugDrawTileCacheLayerAreas | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtTileCacheLayer & | +layer, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch | +
| + | ) | ++ |
| void duDebugDrawTileCacheLayerRegions | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtTileCacheLayer & | +layer, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch | +
| + | ) | ++ |
| void duDebugDrawTileCachePolyMesh | +( | +duDebugDraw * | +dd, | +
| + | + | const struct dtTileCachePolyMesh & | +lmesh, | +
| + | + | const float * | +orig, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Enumerations | |
| enum | DrawNavMeshFlags { DU_DRAWNAVMESH_OFFMESHCONS = 0x01 +, DU_DRAWNAVMESH_CLOSEDLIST = 0x02 +, DU_DRAWNAVMESH_COLOR_TILES = 0x04 + } |
+Functions | |
| void | duDebugDrawNavMesh (struct duDebugDraw *dd, const dtNavMesh &mesh, unsigned char flags) |
| void | duDebugDrawNavMeshWithClosedList (struct duDebugDraw *dd, const dtNavMesh &mesh, const dtNavMeshQuery &query, unsigned char flags) |
| void | duDebugDrawNavMeshNodes (struct duDebugDraw *dd, const dtNavMeshQuery &query) |
| void | duDebugDrawNavMeshBVTree (struct duDebugDraw *dd, const dtNavMesh &mesh) |
| void | duDebugDrawNavMeshPortals (struct duDebugDraw *dd, const dtNavMesh &mesh) |
| void | duDebugDrawNavMeshPolysWithFlags (struct duDebugDraw *dd, const dtNavMesh &mesh, const unsigned short polyFlags, const unsigned int col) |
| void | duDebugDrawNavMeshPoly (struct duDebugDraw *dd, const dtNavMesh &mesh, dtPolyRef ref, const unsigned int col) |
| void | duDebugDrawTileCacheLayerAreas (struct duDebugDraw *dd, const dtTileCacheLayer &layer, const float cs, const float ch) |
| void | duDebugDrawTileCacheLayerRegions (struct duDebugDraw *dd, const dtTileCacheLayer &layer, const float cs, const float ch) |
| void | duDebugDrawTileCacheContours (duDebugDraw *dd, const struct dtTileCacheContourSet &lcset, const float *orig, const float cs, const float ch) |
| void | duDebugDrawTileCachePolyMesh (duDebugDraw *dd, const struct dtTileCachePolyMesh &lmesh, const float *orig, const float cs, const float ch) |
| enum DrawNavMeshFlags | +
| void duDebugDrawNavMesh | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh, | +
| + | + | unsigned char | +flags | +
| + | ) | ++ |
| void duDebugDrawNavMeshBVTree | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh | +
| + | ) | ++ |
| void duDebugDrawNavMeshNodes | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtNavMeshQuery & | +query | +
| + | ) | ++ |
| void duDebugDrawNavMeshPoly | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh, | +
| + | + | dtPolyRef | +ref, | +
| + | + | const unsigned int | +col | +
| + | ) | ++ |
| void duDebugDrawNavMeshPolysWithFlags | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh, | +
| + | + | const unsigned short | +polyFlags, | +
| + | + | const unsigned int | +col | +
| + | ) | ++ |
| void duDebugDrawNavMeshPortals | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh | +
| + | ) | ++ |
| void duDebugDrawNavMeshWithClosedList | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtNavMesh & | +mesh, | +
| + | + | const dtNavMeshQuery & | +query, | +
| + | + | unsigned char | +flags | +
| + | ) | ++ |
| void duDebugDrawTileCacheContours | +( | +duDebugDraw * | +dd, | +
| + | + | const struct dtTileCacheContourSet & | +lcset, | +
| + | + | const float * | +orig, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch | +
| + | ) | ++ |
| void duDebugDrawTileCacheLayerAreas | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtTileCacheLayer & | +layer, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch | +
| + | ) | ++ |
| void duDebugDrawTileCacheLayerRegions | +( | +struct duDebugDraw * | +dd, | +
| + | + | const dtTileCacheLayer & | +layer, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch | +
| + | ) | ++ |
| void duDebugDrawTileCachePolyMesh | +( | +duDebugDraw * | +dd, | +
| + | + | const struct dtTileCachePolyMesh & | +lmesh, | +
| + | + | const float * | +orig, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <float.h>#include <string.h>#include "DetourLocalBoundary.h"#include "DetourNavMeshQuery.h"#include "DetourCommon.h"#include "DetourAssert.h"|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourNavMeshQuery.h"Go to the source code of this file.
++Classes | |
| class | dtLocalBoundary |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <cmath>Go to the source code of this file.
++Functions | |
| float | dtMathFabsf (float x) |
| float | dtMathSqrtf (float x) |
| float | dtMathFloorf (float x) |
| float | dtMathCeilf (float x) |
| float | dtMathCosf (float x) |
| float | dtMathSinf (float x) |
| float | dtMathAtan2f (float y, float x) |
| bool | dtMathIsfinite (float x) |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <stdio.h>#include <stdlib.h>#include <string.h>#include <float.h>#include "DetourNavMesh.h"#include "DetourCommon.h"#include "DetourMath.h"#include "DetourNavMeshBuilder.h"#include "DetourAlloc.h"#include "DetourAssert.h"+Classes | |
| struct | BVItem |
+Functions | |
| static int | compareItemX (const void *va, const void *vb) |
| static int | compareItemY (const void *va, const void *vb) |
| static int | compareItemZ (const void *va, const void *vb) |
| static void | calcExtends (BVItem *items, const int, const int imin, const int imax, unsigned short *bmin, unsigned short *bmax) |
| int | longestAxis (unsigned short x, unsigned short y, unsigned short z) |
| static void | subdivide (BVItem *items, int nitems, int imin, int imax, int &curNode, dtBVNode *nodes) |
| static int | createBVTree (dtNavMeshCreateParams *params, dtBVNode *nodes, int) |
| static unsigned char | classifyOffMeshPoint (const float *pt, const float *bmin, const float *bmax) |
| bool | dtCreateNavMeshData (dtNavMeshCreateParams *params, unsigned char **outData, int *outDataSize) |
| Builds navigation mesh tile data from the provided tile creation data. More... | |
| bool | dtNavMeshHeaderSwapEndian (unsigned char *data, const int) |
| Swaps the endianess of the tile data's header (dtMeshHeader). More... | |
| bool | dtNavMeshDataSwapEndian (unsigned char *data, const int) |
| Swaps endianess of the tile data. More... | |
+Variables | |
| static unsigned short | MESH_NULL_IDX = 0xffff |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
| bool dtNavMeshDataSwapEndian | +( | +unsigned char * | +data, | +
| + | + | const int | +dataSize | +
| + | ) | ++ |
Swaps endianess of the tile data.
+| bool dtNavMeshHeaderSwapEndian | +( | +unsigned char * | +data, | +
| + | + | const int | +dataSize | +
| + | ) | ++ |
Swaps the endianess of the tile data's header (dtMeshHeader).
+| [in,out] | data | The tile data array. |
| [in] | dataSize | The size of the data array. |
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourAlloc.h"Go to the source code of this file.
++Classes | |
| struct | dtNavMeshCreateParams |
| Represents the source data used to build an navigation mesh tile. More... | |
+Functions | |
| bool | dtCreateNavMeshData (dtNavMeshCreateParams *params, unsigned char **outData, int *outDataSize) |
| Builds navigation mesh tile data from the provided tile creation data. More... | |
| bool | dtNavMeshHeaderSwapEndian (unsigned char *data, const int dataSize) |
| Swaps the endianess of the tile data's header (dtMeshHeader). More... | |
| bool | dtNavMeshDataSwapEndian (unsigned char *data, const int dataSize) |
| Swaps endianess of the tile data. More... | |
| bool dtNavMeshDataSwapEndian | +( | +unsigned char * | +data, | +
| + | + | const int | +dataSize | +
| + | ) | ++ |
Swaps endianess of the tile data.
+| [in,out] | data | The tile data array. |
| [in] | dataSize | The size of the data array. |
| bool dtNavMeshHeaderSwapEndian | +( | +unsigned char * | +data, | +
| + | + | const int | +dataSize | +
| + | ) | ++ |
Swaps the endianess of the tile data's header (dtMeshHeader).
+| [in,out] | data | The tile data array. |
| [in] | dataSize | The size of the data array. |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <float.h>#include <string.h>#include "DetourNavMeshQuery.h"#include "DetourNavMesh.h"#include "DetourNode.h"#include "DetourCommon.h"#include "DetourMath.h"#include "DetourAlloc.h"#include "DetourAssert.h"#include <new>+Classes | |
| class | dtFindNearestPolyQuery |
| class | dtCollectPolysQuery |
| struct | dtSegInterval |
+Functions | |
| dtNavMeshQuery * | dtAllocNavMeshQuery () |
| Allocates a query object using the Detour allocator. More... | |
| void | dtFreeNavMeshQuery (dtNavMeshQuery *navmesh) |
| Frees the specified query object using the Detour allocator. More... | |
| static void | insertInterval (dtSegInterval *ints, int &nints, const int maxInts, const short tmin, const short tmax, const dtPolyRef ref) |
+Variables | |
| static const float | H_SCALE = 0.999f |
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | dtQueryFilter |
| Defines polygon filtering and traversal costs for navigation mesh query operations. More... | |
| struct | dtRaycastHit |
| Provides information about raycast hit filled by dtNavMeshQuery::raycast. More... | |
| class | dtPolyQuery |
| Provides custom polygon query behavior. More... | |
| class | dtNavMeshQuery |
| Provides the ability to perform pathfinding related queries against a navigation mesh. More... | |
+Functions | |
| dtNavMeshQuery * | dtAllocNavMeshQuery () |
| Allocates a query object using the Detour allocator. More... | |
| void | dtFreeNavMeshQuery (dtNavMeshQuery *query) |
| Frees the specified query object using the Detour allocator. More... | |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <float.h>#include <string.h>#include <stdio.h>#include "DetourNavMesh.h"#include "DetourNode.h"#include "DetourCommon.h"#include "DetourMath.h"#include "DetourAlloc.h"#include "DetourAssert.h"#include <new>+Classes | |
| struct | dtTileState |
| struct | dtPolyState |
+Functions | |
| bool | overlapSlabs (const float *amin, const float *amax, const float *bmin, const float *bmax, const float px, const float py) |
| static float | getSlabCoord (const float *va, const int side) |
| static void | calcSlabEndPoints (const float *va, const float *vb, float *bmin, float *bmax, const int side) |
| int | computeTileHash (int x, int y, const int mask) |
| unsigned int | allocLink (dtMeshTile *tile) |
| void | freeLink (dtMeshTile *tile, unsigned int link) |
| dtNavMesh * | dtAllocNavMesh () |
| 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... | |
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| struct | dtPoly |
| Defines a polygon within a dtMeshTile object. More... | |
| struct | dtPolyDetail |
| Defines the location of detail sub-mesh data within a dtMeshTile. More... | |
| struct | dtLink |
| Defines a link between polygons. More... | |
| struct | dtBVNode |
| Bounding volume node. More... | |
| struct | dtOffMeshConnection |
| Defines an navigation mesh off-mesh connection within a dtMeshTile object. More... | |
| struct | dtMeshHeader |
| Provides high level information related to a dtMeshTile object. More... | |
| struct | dtMeshTile |
| Defines a navigation mesh tile. More... | |
| struct | dtNavMeshParams |
| Configuration parameters used to define multi-tile navigation meshes. More... | |
| class | dtNavMesh |
| A navigation mesh based on tiles of convex polygons. 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 | dtTileFlags { DT_TILE_FREE_DATA = 0x01 + } |
| Tile flags used for various functions and fields. More... | |
| enum | dtStraightPathFlags { DT_STRAIGHTPATH_START = 0x01 +, DT_STRAIGHTPATH_END = 0x02 +, DT_STRAIGHTPATH_OFFMESH_CONNECTION = 0x04 + } |
| Vertex flags returned by dtNavMeshQuery::findStraightPath. More... | |
| enum | dtStraightPathOptions { DT_STRAIGHTPATH_AREA_CROSSINGS = 0x01 +, DT_STRAIGHTPATH_ALL_CROSSINGS = 0x02 + } |
| Options for dtNavMeshQuery::findStraightPath. More... | |
| enum | dtFindPathOptions { DT_FINDPATH_ANY_ANGLE = 0x02 + } |
| Options for dtNavMeshQuery::initSlicedFindPath and updateSlicedFindPath. More... | |
| enum | dtRaycastOptions { DT_RAYCAST_USE_COSTS = 0x01 + } |
| Options for dtNavMeshQuery::raycast. More... | |
| enum | dtDetailTriEdgeFlags { DT_DETAIL_EDGE_BOUNDARY = 0x01 + } |
| enum | dtPolyTypes { DT_POLYTYPE_GROUND = 0 +, DT_POLYTYPE_OFFMESH_CONNECTION = 1 + } |
| Flags representing the type of a navigation mesh polygon. More... | |
+Functions | |
| int | dtGetDetailTriEdgeFlags (unsigned char triFlags, int edgeIndex) |
| Get flags for edge in detail triangle. More... | |
| dtNavMesh * | dtAllocNavMesh () |
| 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 int | DT_VERTS_PER_POLYGON = 6 |
| The maximum number of vertices per navigation polygon. More... | |
| static const unsigned short | DT_EXT_LINK = 0x8000 |
| A flag that indicates that an entity links to an external entity. 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_MAX_AREAS = 64 |
| The maximum number of user defined area ids. More... | |
| static const float | DT_RAY_CAST_LIMIT_PROPORTIONS = 50.0f |
| Limit raycasting during any angle pahfinding The limit is given as a multiple of the character radius. 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... | |
| enum dtDetailTriEdgeFlags | +
| enum dtFindPathOptions | +
Options for dtNavMeshQuery::initSlicedFindPath and updateSlicedFindPath.
+| Enumerator | |
|---|---|
| DT_FINDPATH_ANY_ANGLE | use raycasts during pathfind to "shortcut" (raycast still consider costs) + |
| enum dtPolyTypes | +
| enum dtRaycastOptions | +
Options for dtNavMeshQuery::raycast.
+| Enumerator | |
|---|---|
| DT_RAYCAST_USE_COSTS | Raycast should calculate movement cost along the ray and fill RaycastHit::cost. + |
| enum dtStraightPathFlags | +
Vertex flags returned by dtNavMeshQuery::findStraightPath.
+| enum dtStraightPathOptions | +
Options for dtNavMeshQuery::findStraightPath.
+| Enumerator | |
|---|---|
| DT_STRAIGHTPATH_AREA_CROSSINGS | Add a vertex at every polygon edge crossing where area changes. + |
| DT_STRAIGHTPATH_ALL_CROSSINGS | Add a vertex at every polygon edge crossing. + |
| enum dtTileFlags | +
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. + |
+
|
+ +inline | +
Get flags for edge in detail triangle.
+| [in] | triFlags | The flags for the triangle (last component of detail vertices above). |
| [in] | edgeIndex | The index of the first vertex of the edge. For instance, if 0, returns flags for edge AB. |
+
|
+ +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.)
+ +
+
|
+ +static | +
A magic number used to detect compatibility of navigation tile data.
+ +
+
|
+ +static | +
A magic number used to detect the compatibility of navigation tile states.
+ +
+
|
+ +static | +
A version number used to detect compatibility of navigation tile states.
+ +
+
|
+ +static | +
A version number used to detect compatibility of navigation tile data.
+ +
+
|
+ +static | +
A value that indicates the entity does not link to anything.
+ +
+
|
+ +static | +
A flag that indicates that an off-mesh connection can be traversed in both directions. (Is bidirectional.)
+ +
+
|
+ +static | +
Limit raycasting during any angle pahfinding The limit is given as a multiple of the character radius.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourNode.h"#include "DetourAlloc.h"#include "DetourAssert.h"#include "DetourCommon.h"#include <string.h>+Functions | |
| unsigned int | dtHashRef (dtPolyRef a) |
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourNavMesh.h"Go to the source code of this file.
++Classes | |
| struct | dtNode |
| class | dtNodePool |
| class | dtNodeQueue |
+Typedefs | |
| typedef unsigned short | dtNodeIndex |
+Enumerations | |
| enum | dtNodeFlags { DT_NODE_OPEN = 0x01 +, DT_NODE_CLOSED = 0x02 +, DT_NODE_PARENT_DETACHED = 0x04 + } |
+Variables | |
| static const dtNodeIndex | DT_NULL_IDX = (dtNodeIndex)~0 |
| static const int | DT_NODE_PARENT_BITS = 24 |
| static const int | DT_NODE_STATE_BITS = 2 |
| static const int | DT_MAX_STATES_PER_NODE = 1 << DT_NODE_STATE_BITS |
| typedef unsigned short dtNodeIndex | +
| enum dtNodeFlags | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourObstacleAvoidance.h"#include "DetourCommon.h"#include "DetourMath.h"#include "DetourAlloc.h"#include "DetourAssert.h"#include <string.h>#include <float.h>#include <new>+Functions | |
| static int | sweepCircleCircle (const float *c0, const float r0, const float *v, const float *c1, const float r1, float &tmin, float &tmax) |
| static int | isectRaySeg (const float *ap, const float *u, const float *bp, const float *bq, float &t) |
| dtObstacleAvoidanceDebugData * | dtAllocObstacleAvoidanceDebugData () |
| void | dtFreeObstacleAvoidanceDebugData (dtObstacleAvoidanceDebugData *ptr) |
| static void | normalizeArray (float *arr, const int n) |
| dtObstacleAvoidanceQuery * | dtAllocObstacleAvoidanceQuery () |
| void | dtFreeObstacleAvoidanceQuery (dtObstacleAvoidanceQuery *ptr) |
| void | dtNormalize2D (float *v) |
| void | dtRorate2D (float *dest, const float *v, float ang) |
+Variables | |
| static const float | DT_PI = 3.14159265f |
| dtObstacleAvoidanceDebugData* dtAllocObstacleAvoidanceDebugData | +( | +) | ++ |
| dtObstacleAvoidanceQuery* dtAllocObstacleAvoidanceQuery | +( | +) | ++ |
| void dtFreeObstacleAvoidanceDebugData | +( | +dtObstacleAvoidanceDebugData * | +ptr | ) | ++ |
| void dtFreeObstacleAvoidanceQuery | +( | +dtObstacleAvoidanceQuery * | +ptr | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| struct | dtObstacleCircle |
| struct | dtObstacleSegment |
| class | dtObstacleAvoidanceDebugData |
| struct | dtObstacleAvoidanceParams |
| class | dtObstacleAvoidanceQuery |
+Functions | |
| dtObstacleAvoidanceDebugData * | dtAllocObstacleAvoidanceDebugData () |
| void | dtFreeObstacleAvoidanceDebugData (dtObstacleAvoidanceDebugData *ptr) |
| dtObstacleAvoidanceQuery * | dtAllocObstacleAvoidanceQuery () |
| void | dtFreeObstacleAvoidanceQuery (dtObstacleAvoidanceQuery *ptr) |
+Variables | |
| static const int | DT_MAX_PATTERN_DIVS = 32 |
| Max numver of adaptive divs. More... | |
| static const int | DT_MAX_PATTERN_RINGS = 4 |
| Max number of adaptive rings. More... | |
| dtObstacleAvoidanceDebugData* dtAllocObstacleAvoidanceDebugData | +( | +) | ++ |
| dtObstacleAvoidanceQuery* dtAllocObstacleAvoidanceQuery | +( | +) | ++ |
| void dtFreeObstacleAvoidanceDebugData | +( | +dtObstacleAvoidanceDebugData * | +ptr | ) | ++ |
| void dtFreeObstacleAvoidanceQuery | +( | +dtObstacleAvoidanceQuery * | +ptr | ) | ++ |
+
|
+ +static | +
Max numver of adaptive divs.
+ +
+
|
+ +static | +
Max number of adaptive rings.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <string.h>#include "DetourPathCorridor.h"#include "DetourNavMeshQuery.h"#include "DetourCommon.h"#include "DetourAssert.h"#include "DetourAlloc.h"+Functions | |
| int | dtMergeCorridorStartMoved (dtPolyRef *path, const int npath, const int maxPath, const dtPolyRef *visited, const int nvisited) |
| int | dtMergeCorridorEndMoved (dtPolyRef *path, const int npath, const int maxPath, const dtPolyRef *visited, const int nvisited) |
| int | dtMergeCorridorStartShortcut (dtPolyRef *path, const int npath, const int maxPath, const dtPolyRef *visited, const int nvisited) |
| int dtMergeCorridorEndMoved | +( | +dtPolyRef * | +path, | +
| + | + | const int | +npath, | +
| + | + | const int | +maxPath, | +
| + | + | const dtPolyRef * | +visited, | +
| + | + | const int | +nvisited | +
| + | ) | ++ |
| int dtMergeCorridorStartMoved | +( | +dtPolyRef * | +path, | +
| + | + | const int | +npath, | +
| + | + | const int | +maxPath, | +
| + | + | const dtPolyRef * | +visited, | +
| + | + | const int | +nvisited | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourNavMeshQuery.h"Go to the source code of this file.
++Classes | |
| class | dtPathCorridor |
| Represents a dynamic polygon corridor used to plan agent movement. More... | |
+Functions | |
| int | dtMergeCorridorStartMoved (dtPolyRef *path, const int npath, const int maxPath, const dtPolyRef *visited, const int nvisited) |
| int | dtMergeCorridorEndMoved (dtPolyRef *path, const int npath, const int maxPath, const dtPolyRef *visited, const int nvisited) |
| int | dtMergeCorridorStartShortcut (dtPolyRef *path, const int npath, const int maxPath, const dtPolyRef *visited, const int nvisited) |
| int dtMergeCorridorEndMoved | +( | +dtPolyRef * | +path, | +
| + | + | const int | +npath, | +
| + | + | const int | +maxPath, | +
| + | + | const dtPolyRef * | +visited, | +
| + | + | const int | +nvisited | +
| + | ) | ++ |
| int dtMergeCorridorStartMoved | +( | +dtPolyRef * | +path, | +
| + | + | const int | +npath, | +
| + | + | const int | +maxPath, | +
| + | + | const dtPolyRef * | +visited, | +
| + | + | const int | +nvisited | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <string.h>#include "DetourPathQueue.h"#include "DetourNavMesh.h"#include "DetourNavMeshQuery.h"#include "DetourAlloc.h"#include "DetourCommon.h"|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | dtPathQueue |
+Typedefs | |
| typedef unsigned int | dtPathQueueRef |
+Variables | |
| static const unsigned int | DT_PATHQ_INVALID = 0 |
| typedef unsigned int dtPathQueueRef | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <string.h>#include <new>#include "DetourProximityGrid.h"#include "DetourCommon.h"#include "DetourMath.h"#include "DetourAlloc.h"#include "DetourAssert.h"+Functions | |
| dtProximityGrid * | dtAllocProximityGrid () |
| void | dtFreeProximityGrid (dtProximityGrid *ptr) |
| int | hashPos2 (int x, int y, int n) |
| dtProximityGrid* dtAllocProximityGrid | +( | +) | ++ |
| void dtFreeProximityGrid | +( | +dtProximityGrid * | +ptr | ) | ++ |
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | dtProximityGrid |
+Functions | |
| dtProximityGrid * | dtAllocProximityGrid () |
| void | dtFreeProximityGrid (dtProximityGrid *ptr) |
| dtProximityGrid* dtAllocProximityGrid | +( | +) | ++ |
| void dtFreeProximityGrid | +( | +dtProximityGrid * | +ptr | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Typedefs | |
| typedef unsigned int | dtStatus |
+Functions | |
| bool | dtStatusSucceed (dtStatus status) |
| bool | dtStatusFailed (dtStatus status) |
| bool | dtStatusInProgress (dtStatus status) |
| bool | dtStatusDetail (dtStatus status, unsigned int detail) |
+Variables | |
| static const unsigned int | DT_FAILURE = 1u << 31 |
| static const unsigned int | DT_SUCCESS = 1u << 30 |
| static const unsigned int | DT_IN_PROGRESS = 1u << 29 |
| static const unsigned int | DT_STATUS_DETAIL_MASK = 0x0ffffff |
| static const unsigned int | DT_WRONG_MAGIC = 1 << 0 |
| static const unsigned int | DT_WRONG_VERSION = 1 << 1 |
| static const unsigned int | DT_OUT_OF_MEMORY = 1 << 2 |
| static const unsigned int | DT_INVALID_PARAM = 1 << 3 |
| static const unsigned int | DT_BUFFER_TOO_SMALL = 1 << 4 |
| static const unsigned int | DT_OUT_OF_NODES = 1 << 5 |
| static const unsigned int | DT_PARTIAL_RESULT = 1 << 6 |
| static const unsigned int | DT_ALREADY_OCCUPIED = 1 << 7 |
| typedef unsigned int dtStatus | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourCommon.h"#include "DetourMath.h"#include "DetourStatus.h"#include "DetourAssert.h"#include "DetourTileCacheBuilder.h"#include <string.h>+Classes | |
| class | dtFixedArray< T > |
| struct | dtLayerSweepSpan |
| struct | dtLayerMonotoneRegion |
| struct | dtTempContour |
| struct | rcEdge |
+Functions | |
| int | getDirOffsetX (int dir) |
| int | getDirOffsetY (int dir) |
| dtTileCacheContourSet * | dtAllocTileCacheContourSet (dtTileCacheAlloc *alloc) |
| void | dtFreeTileCacheContourSet (dtTileCacheAlloc *alloc, dtTileCacheContourSet *cset) |
| dtTileCachePolyMesh * | dtAllocTileCachePolyMesh (dtTileCacheAlloc *alloc) |
| void | dtFreeTileCachePolyMesh (dtTileCacheAlloc *alloc, dtTileCachePolyMesh *lmesh) |
| bool | overlapRangeExl (const unsigned short amin, const unsigned short amax, const unsigned short bmin, const unsigned short bmax) |
| static void | addUniqueLast (unsigned char *a, unsigned char &an, unsigned char v) |
| bool | isConnected (const dtTileCacheLayer &layer, const int ia, const int ib, const int walkableClimb) |
| static bool | canMerge (unsigned char oldRegId, unsigned char newRegId, const dtLayerMonotoneRegion *regs, const int nregs) |
| dtStatus | dtBuildTileCacheRegions (dtTileCacheAlloc *alloc, dtTileCacheLayer &layer, const int walkableClimb) |
| static bool | appendVertex (dtTempContour &cont, const int x, const int y, const int z, const int r) |
| static unsigned char | getNeighbourReg (dtTileCacheLayer &layer, const int ax, const int ay, const int dir) |
| static bool | walkContour (dtTileCacheLayer &layer, int x, int y, dtTempContour &cont) |
| static float | distancePtSeg (const int x, const int z, const int px, const int pz, const int qx, const int qz) |
| static void | simplifyContour (dtTempContour &cont, const float maxError) |
| static unsigned char | getCornerHeight (dtTileCacheLayer &layer, const int x, const int y, const int z, const int walkableClimb, bool &shouldRemove) |
| dtStatus | dtBuildTileCacheContours (dtTileCacheAlloc *alloc, dtTileCacheLayer &layer, const int walkableClimb, const float maxError, dtTileCacheContourSet &lcset) |
| int | computeVertexHash2 (int x, int y, int z) |
| static unsigned short | addVertex (unsigned short x, unsigned short y, unsigned short z, unsigned short *verts, unsigned short *firstVert, unsigned short *nextVert, int &nv) |
| static bool | buildMeshAdjacency (dtTileCacheAlloc *alloc, unsigned short *polys, const int npolys, const unsigned short *verts, const int nverts, const dtTileCacheContourSet &lcset) |
| int | prev (int i, int n) |
| int | next (int i, int n) |
| int | area2 (const unsigned char *a, const unsigned char *b, const unsigned char *c) |
| bool | xorb (bool x, bool y) |
| bool | left (const unsigned char *a, const unsigned char *b, const unsigned char *c) |
| bool | leftOn (const unsigned char *a, const unsigned char *b, const unsigned char *c) |
| bool | collinear (const unsigned char *a, const unsigned char *b, const unsigned char *c) |
| static bool | intersectProp (const unsigned char *a, const unsigned char *b, const unsigned char *c, const unsigned char *d) |
| static bool | between (const unsigned char *a, const unsigned char *b, const unsigned char *c) |
| static bool | intersect (const unsigned char *a, const unsigned char *b, const unsigned char *c, const unsigned char *d) |
| static bool | vequal (const unsigned char *a, const unsigned char *b) |
| static bool | diagonalie (int i, int j, int n, const unsigned char *verts, const unsigned short *indices) |
| static bool | inCone (int i, int j, int n, const unsigned char *verts, const unsigned short *indices) |
| static bool | diagonal (int i, int j, int n, const unsigned char *verts, const unsigned short *indices) |
| static int | triangulate (int n, const unsigned char *verts, unsigned short *indices, unsigned short *tris) |
| static int | countPolyVerts (const unsigned short *p) |
| bool | uleft (const unsigned short *a, const unsigned short *b, const unsigned short *c) |
| static int | getPolyMergeValue (unsigned short *pa, unsigned short *pb, const unsigned short *verts, int &ea, int &eb) |
| static void | mergePolys (unsigned short *pa, unsigned short *pb, int ea, int eb) |
| static void | pushFront (unsigned short v, unsigned short *arr, int &an) |
| static void | pushBack (unsigned short v, unsigned short *arr, int &an) |
| static bool | canRemoveVertex (dtTileCachePolyMesh &mesh, const unsigned short rem) |
| static dtStatus | removeVertex (dtTileCachePolyMesh &mesh, const unsigned short rem, const int maxTris) |
| dtStatus | dtBuildTileCachePolyMesh (dtTileCacheAlloc *alloc, dtTileCacheContourSet &lcset, dtTileCachePolyMesh &mesh) |
| dtStatus | dtMarkCylinderArea (dtTileCacheLayer &layer, const float *orig, const float cs, const float ch, const float *pos, const float radius, const float height, const unsigned char areaId) |
| dtStatus | dtMarkBoxArea (dtTileCacheLayer &layer, const float *orig, const float cs, const float ch, const float *bmin, const float *bmax, const unsigned char areaId) |
| dtStatus | dtMarkBoxArea (dtTileCacheLayer &layer, const float *orig, const float cs, const float ch, const float *center, const float *halfExtents, const float *rotAux, const unsigned char areaId) |
| dtStatus | dtBuildTileCacheLayer (dtTileCacheCompressor *comp, dtTileCacheLayerHeader *header, const unsigned char *heights, const unsigned char *areas, const unsigned char *cons, unsigned char **outData, int *outDataSize) |
| void | dtFreeTileCacheLayer (dtTileCacheAlloc *alloc, dtTileCacheLayer *layer) |
| dtStatus | dtDecompressTileCacheLayer (dtTileCacheAlloc *alloc, dtTileCacheCompressor *comp, unsigned char *compressed, const int compressedSize, dtTileCacheLayer **layerOut) |
| bool | dtTileCacheHeaderSwapEndian (unsigned char *data, const int dataSize) |
| Swaps the endianess of the compressed tile data's header (dtTileCacheLayerHeader). More... | |
+Variables | |
| static const int | MAX_VERTS_PER_POLY = 6 |
| static const int | MAX_REM_EDGES = 48 |
| static const int | DT_LAYER_MAX_NEIS = 16 |
| static const int | VERTEX_BUCKET_COUNT2 = (1<<8) |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
| dtTileCacheContourSet* dtAllocTileCacheContourSet | +( | +dtTileCacheAlloc * | +alloc | ) | ++ |
| dtTileCachePolyMesh* dtAllocTileCachePolyMesh | +( | +dtTileCacheAlloc * | +alloc | ) | ++ |
| dtStatus dtBuildTileCacheContours | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheLayer & | +layer, | +
| + | + | const int | +walkableClimb, | +
| + | + | const float | +maxError, | +
| + | + | dtTileCacheContourSet & | +lcset | +
| + | ) | ++ |
| dtStatus dtBuildTileCacheLayer | +( | +dtTileCacheCompressor * | +comp, | +
| + | + | dtTileCacheLayerHeader * | +header, | +
| + | + | const unsigned char * | +heights, | +
| + | + | const unsigned char * | +areas, | +
| + | + | const unsigned char * | +cons, | +
| + | + | unsigned char ** | +outData, | +
| + | + | int * | +outDataSize | +
| + | ) | ++ |
| dtStatus dtBuildTileCachePolyMesh | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheContourSet & | +lcset, | +
| + | + | dtTileCachePolyMesh & | +mesh | +
| + | ) | ++ |
| dtStatus dtBuildTileCacheRegions | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheLayer & | +layer, | +
| + | + | const int | +walkableClimb | +
| + | ) | ++ |
| dtStatus dtDecompressTileCacheLayer | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheCompressor * | +comp, | +
| + | + | unsigned char * | +compressed, | +
| + | + | const int | +compressedSize, | +
| + | + | dtTileCacheLayer ** | +layerOut | +
| + | ) | ++ |
| void dtFreeTileCacheContourSet | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheContourSet * | +cset | +
| + | ) | ++ |
| void dtFreeTileCacheLayer | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheLayer * | +layer | +
| + | ) | ++ |
| void dtFreeTileCachePolyMesh | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCachePolyMesh * | +lmesh | +
| + | ) | ++ |
| dtStatus dtMarkBoxArea | +( | +dtTileCacheLayer & | +layer, | +
| + | + | const float * | +orig, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch, | +
| + | + | const float * | +bmin, | +
| + | + | const float * | +bmax, | +
| + | + | const unsigned char | +areaId | +
| + | ) | ++ |
| dtStatus dtMarkBoxArea | +( | +dtTileCacheLayer & | +layer, | +
| + | + | const float * | +orig, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch, | +
| + | + | const float * | +center, | +
| + | + | const float * | +halfExtents, | +
| + | + | const float * | +rotAux, | +
| + | + | const unsigned char | +areaId | +
| + | ) | ++ |
| dtStatus dtMarkCylinderArea | +( | +dtTileCacheLayer & | +layer, | +
| + | + | const float * | +orig, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch, | +
| + | + | const float * | +pos, | +
| + | + | const float | +radius, | +
| + | + | const float | +height, | +
| + | + | const unsigned char | +areaId | +
| + | ) | ++ |
| bool dtTileCacheHeaderSwapEndian | +( | +unsigned char * | +data, | +
| + | + | const int | +dataSize | +
| + | ) | ++ |
Swaps the endianess of the compressed tile data's header (dtTileCacheLayerHeader).
+Tile layer data does not need endian swapping as it consits only of bytes.
| [in,out] | data | The tile data array. |
| [in] | dataSize | The size of the data array. |
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| struct | dtTileCacheLayerHeader |
| struct | dtTileCacheLayer |
| struct | dtTileCacheContour |
| struct | dtTileCacheContourSet |
| struct | dtTileCachePolyMesh |
| struct | dtTileCacheAlloc |
| struct | dtTileCacheCompressor |
+Functions | |
| dtStatus | dtBuildTileCacheLayer (dtTileCacheCompressor *comp, dtTileCacheLayerHeader *header, const unsigned char *heights, const unsigned char *areas, const unsigned char *cons, unsigned char **outData, int *outDataSize) |
| void | dtFreeTileCacheLayer (dtTileCacheAlloc *alloc, dtTileCacheLayer *layer) |
| dtStatus | dtDecompressTileCacheLayer (dtTileCacheAlloc *alloc, dtTileCacheCompressor *comp, unsigned char *compressed, const int compressedSize, dtTileCacheLayer **layerOut) |
| dtTileCacheContourSet * | dtAllocTileCacheContourSet (dtTileCacheAlloc *alloc) |
| void | dtFreeTileCacheContourSet (dtTileCacheAlloc *alloc, dtTileCacheContourSet *cset) |
| dtTileCachePolyMesh * | dtAllocTileCachePolyMesh (dtTileCacheAlloc *alloc) |
| void | dtFreeTileCachePolyMesh (dtTileCacheAlloc *alloc, dtTileCachePolyMesh *lmesh) |
| dtStatus | dtMarkCylinderArea (dtTileCacheLayer &layer, const float *orig, const float cs, const float ch, const float *pos, const float radius, const float height, const unsigned char areaId) |
| dtStatus | dtMarkBoxArea (dtTileCacheLayer &layer, const float *orig, const float cs, const float ch, const float *bmin, const float *bmax, const unsigned char areaId) |
| dtStatus | dtMarkBoxArea (dtTileCacheLayer &layer, const float *orig, const float cs, const float ch, const float *center, const float *halfExtents, const float *rotAux, const unsigned char areaId) |
| dtStatus | dtBuildTileCacheRegions (dtTileCacheAlloc *alloc, dtTileCacheLayer &layer, const int walkableClimb) |
| dtStatus | dtBuildTileCacheContours (dtTileCacheAlloc *alloc, dtTileCacheLayer &layer, const int walkableClimb, const float maxError, dtTileCacheContourSet &lcset) |
| dtStatus | dtBuildTileCachePolyMesh (dtTileCacheAlloc *alloc, dtTileCacheContourSet &lcset, dtTileCachePolyMesh &mesh) |
| bool | dtTileCacheHeaderSwapEndian (unsigned char *data, const int dataSize) |
| Swaps the endianess of the compressed tile data's header (dtTileCacheLayerHeader). More... | |
+Variables | |
| static const int | DT_TILECACHE_MAGIC = 'D'<<24 | 'T'<<16 | 'L'<<8 | 'R' |
| 'DTLR'; More... | |
| static const int | DT_TILECACHE_VERSION = 1 |
| static const unsigned char | DT_TILECACHE_NULL_AREA = 0 |
| static const unsigned char | DT_TILECACHE_WALKABLE_AREA = 63 |
| static const unsigned short | DT_TILECACHE_NULL_IDX = 0xffff |
| dtTileCacheContourSet* dtAllocTileCacheContourSet | +( | +dtTileCacheAlloc * | +alloc | ) | ++ |
| dtTileCachePolyMesh* dtAllocTileCachePolyMesh | +( | +dtTileCacheAlloc * | +alloc | ) | ++ |
| dtStatus dtBuildTileCacheContours | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheLayer & | +layer, | +
| + | + | const int | +walkableClimb, | +
| + | + | const float | +maxError, | +
| + | + | dtTileCacheContourSet & | +lcset | +
| + | ) | ++ |
| dtStatus dtBuildTileCacheLayer | +( | +dtTileCacheCompressor * | +comp, | +
| + | + | dtTileCacheLayerHeader * | +header, | +
| + | + | const unsigned char * | +heights, | +
| + | + | const unsigned char * | +areas, | +
| + | + | const unsigned char * | +cons, | +
| + | + | unsigned char ** | +outData, | +
| + | + | int * | +outDataSize | +
| + | ) | ++ |
| dtStatus dtBuildTileCachePolyMesh | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheContourSet & | +lcset, | +
| + | + | dtTileCachePolyMesh & | +mesh | +
| + | ) | ++ |
| dtStatus dtBuildTileCacheRegions | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheLayer & | +layer, | +
| + | + | const int | +walkableClimb | +
| + | ) | ++ |
| dtStatus dtDecompressTileCacheLayer | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheCompressor * | +comp, | +
| + | + | unsigned char * | +compressed, | +
| + | + | const int | +compressedSize, | +
| + | + | dtTileCacheLayer ** | +layerOut | +
| + | ) | ++ |
| void dtFreeTileCacheContourSet | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheContourSet * | +cset | +
| + | ) | ++ |
| void dtFreeTileCacheLayer | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCacheLayer * | +layer | +
| + | ) | ++ |
| void dtFreeTileCachePolyMesh | +( | +dtTileCacheAlloc * | +alloc, | +
| + | + | dtTileCachePolyMesh * | +lmesh | +
| + | ) | ++ |
| dtStatus dtMarkBoxArea | +( | +dtTileCacheLayer & | +layer, | +
| + | + | const float * | +orig, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch, | +
| + | + | const float * | +bmin, | +
| + | + | const float * | +bmax, | +
| + | + | const unsigned char | +areaId | +
| + | ) | ++ |
| dtStatus dtMarkBoxArea | +( | +dtTileCacheLayer & | +layer, | +
| + | + | const float * | +orig, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch, | +
| + | + | const float * | +center, | +
| + | + | const float * | +halfExtents, | +
| + | + | const float * | +rotAux, | +
| + | + | const unsigned char | +areaId | +
| + | ) | ++ |
| dtStatus dtMarkCylinderArea | +( | +dtTileCacheLayer & | +layer, | +
| + | + | const float * | +orig, | +
| + | + | const float | +cs, | +
| + | + | const float | +ch, | +
| + | + | const float * | +pos, | +
| + | + | const float | +radius, | +
| + | + | const float | +height, | +
| + | + | const unsigned char | +areaId | +
| + | ) | ++ |
| bool dtTileCacheHeaderSwapEndian | +( | +unsigned char * | +data, | +
| + | + | const int | +dataSize | +
| + | ) | ++ |
Swaps the endianess of the compressed tile data's header (dtTileCacheLayerHeader).
+Tile layer data does not need endian swapping as it consits only of bytes.
| [in,out] | data | The tile data array. |
| [in] | dataSize | The size of the data array. |
+
|
+ +static | +
'DTLR';
+ +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourTileCache.h"#include "DetourTileCacheBuilder.h"#include "DetourNavMeshBuilder.h"#include "DetourNavMesh.h"#include "DetourCommon.h"#include "DetourMath.h"#include "DetourAlloc.h"#include "DetourAssert.h"#include <string.h>#include <new>+Classes | |
| struct | NavMeshTileBuildContext |
+Functions | |
| dtTileCache * | dtAllocTileCache () |
| void | dtFreeTileCache (dtTileCache *tc) |
| static bool | contains (const dtCompressedTileRef *a, const int n, const dtCompressedTileRef v) |
| int | computeTileHash (int x, int y, const int mask) |
+
|
+ +inline | +
+
|
+ +static | +
| dtTileCache* dtAllocTileCache | +( | +) | ++ |
| void dtFreeTileCache | +( | +dtTileCache * | +tc | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "DetourStatus.h"Go to the source code of this file.
++Classes | |
| struct | dtCompressedTile |
| struct | dtObstacleCylinder |
| struct | dtObstacleBox |
| struct | dtObstacleOrientedBox |
| struct | dtTileCacheObstacle |
| struct | dtTileCacheParams |
| struct | dtTileCacheMeshProcess |
| class | dtTileCache |
+Typedefs | |
| typedef unsigned int | dtObstacleRef |
| typedef unsigned int | dtCompressedTileRef |
+Enumerations | |
| enum | dtCompressedTileFlags { DT_COMPRESSEDTILE_FREE_DATA = 0x01 + } |
| Flags for addTile. More... | |
| enum | ObstacleState { DT_OBSTACLE_EMPTY +, DT_OBSTACLE_PROCESSING +, DT_OBSTACLE_PROCESSED +, DT_OBSTACLE_REMOVING + } |
| enum | ObstacleType { DT_OBSTACLE_CYLINDER +, DT_OBSTACLE_BOX +, DT_OBSTACLE_ORIENTED_BOX + } |
+Functions | |
| dtTileCache * | dtAllocTileCache () |
| void | dtFreeTileCache (dtTileCache *tc) |
+Variables | |
| static const int | DT_MAX_TOUCHED_TILES = 8 |
| typedef unsigned int dtCompressedTileRef | +
| typedef unsigned int dtObstacleRef | +
| enum dtCompressedTileFlags | +
| enum ObstacleState | +
| enum ObstacleType | +
| dtTileCache* dtAllocTileCache | +( | +) | ++ |
| void dtFreeTileCache | +( | +dtTileCache * | +tc | ) | ++ |
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Functions | |
| void | scanDirectoryAppend (const string &path, const string &ext, vector< string > &filelist) |
| void | scanDirectory (const string &path, const string &ext, vector< string > &filelist) |
| void scanDirectory | +( | +const string & | +path, | +
| + | + | const string & | +ext, | +
| + | + | vector< string > & | +filelist | +
| + | ) | ++ |
| void scanDirectoryAppend | +( | +const string & | +path, | +
| + | + | const string & | +ext, | +
| + | + | vector< string > & | +filelist | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <vector>#include <string>Go to the source code of this file.
++Functions | |
| void | scanDirectoryAppend (const std::string &path, const std::string &ext, std::vector< std::string > &fileList) |
| void | scanDirectory (const std::string &path, const std::string &ext, std::vector< std::string > &fileList) |
| void scanDirectory | +( | +const std::string & | +path, | +
| + | + | const std::string & | +ext, | +
| + | + | std::vector< std::string > & | +fileList | +
| + | ) | ++ |
| void scanDirectoryAppend | +( | +const std::string & | +path, | +
| + | + | const std::string & | +ext, | +
| + | + | std::vector< std::string > & | +fileList | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <ctype.h>#include <string.h>#include <algorithm>#include "Recast.h"#include "InputGeom.h"#include "ChunkyTriMesh.h"#include "MeshLoaderObj.h"#include "DebugDraw.h"#include "RecastDebugDraw.h"#include "DetourNavMesh.h"#include "Sample.h"+Functions | |
| static bool | intersectSegmentTriangle (const float *sp, const float *sq, const float *a, const float *b, const float *c, float &t) |
| static char * | parseRow (char *buf, char *bufEnd, char *row, int len) |
| static bool | isectSegAABB (const float *sp, const float *sq, const float *amin, const float *amax, float &tmin, float &tmax) |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| struct | ConvexVolume |
| struct | BuildSettings |
| class | InputGeom |
+Variables | |
| static const int | MAX_CONVEXVOL_PTS = 12 |
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "MeshLoaderObj.h"#include <stdio.h>#include <stdlib.h>#include <cstring>#include <math.h>+Functions | |
| static char * | parseRow (char *buf, char *bufEnd, char *row, int len) |
| static int | parseFace (char *row, int *data, int n, int vcnt) |
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <string.h>#include <float.h>#include <vector>#include "SDL.h"#include "SDL_opengl.h"#include "imgui.h"#include "NavMeshPruneTool.h"#include "InputGeom.h"#include "Sample.h"#include "DetourNavMesh.h"#include "DetourCommon.h"#include "DetourAssert.h"#include "DetourDebugDraw.h"+Classes | |
| class | NavmeshFlags |
+Functions | |
| static void | floodNavmesh (dtNavMesh *nav, NavmeshFlags *flags, dtPolyRef start, unsigned char flag) |
| static void | disableUnvisitedPolys (dtNavMesh *nav, NavmeshFlags *flags) |
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "Sample.h"Go to the source code of this file.
++Classes | |
| class | NavMeshPruneTool |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <stdlib.h>#include <string.h>#include "SDL.h"#include "SDL_opengl.h"#include <GL/glu.h>#include "imgui.h"#include "NavMeshTesterTool.h"#include "Sample.h"#include "Recast.h"#include "RecastDebugDraw.h"#include "DetourNavMesh.h"#include "DetourNavMeshBuilder.h"#include "DetourDebugDraw.h"#include "DetourCommon.h"+Macros | |
| #define | DUMP_REQS |
+Functions | |
| static float | frand () |
| bool | inRange (const float *v1, const float *v2, const float r, const float h) |
| static int | fixupCorridor (dtPolyRef *path, const int npath, const int maxPath, const dtPolyRef *visited, const int nvisited) |
| static int | fixupShortcuts (dtPolyRef *path, int npath, dtNavMeshQuery *navQuery) |
| static bool | getSteerTarget (dtNavMeshQuery *navQuery, const float *startPos, const float *endPos, const float minTargetDist, const dtPolyRef *path, const int pathSize, float *steerPos, unsigned char &steerPosFlag, dtPolyRef &steerPosRef, float *outPoints=0, int *outPointCount=0) |
| static void | getPolyCenter (dtNavMesh *navMesh, dtPolyRef ref, float *center) |
| #define DUMP_REQS | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | NavMeshTesterTool |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <string.h>#include <float.h>#include "SDL.h"#include "SDL_opengl.h"#include <GL/glu.h>#include "imgui.h"#include "OffMeshConnectionTool.h"#include "InputGeom.h"#include "Sample.h"#include "Recast.h"#include "RecastDebugDraw.h"#include "DetourDebugDraw.h"|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "Sample.h"Go to the source code of this file.
++Classes | |
| class | OffMeshConnectionTool |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Functions | |
| TimeVal | getPerfTime () |
| int | getPerfTimeUsec (const TimeVal duration) |
| TimeVal getPerfTime | +( | +) | ++ |
| int getPerfTimeUsec | +( | +const TimeVal | +duration | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Typedefs | |
| typedef __int64 | TimeVal |
+Functions | |
| TimeVal | getPerfTime () |
| int | getPerfTimeUsec (const TimeVal duration) |
| typedef __int64 TimeVal | +
| TimeVal getPerfTime | +( | +) | ++ |
| int getPerfTimeUsec | +( | +const TimeVal | +duration | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "RecastAlloc.h"+Functions | |
| static void * | rcAllocDefault (size_t size, rcAllocHint) |
| static void | rcFreeDefault (void *ptr) |
| void | rcAllocSetCustom (rcAllocFunc *allocFunc, rcFreeFunc *freeFunc) |
| Sets the base custom allocation functions to be used by Recast. More... | |
| void * | rcAlloc (size_t size, rcAllocHint hint) |
| Allocates a memory block. More... | |
| void | rcFree (void *ptr) |
| Deallocates a memory block. More... | |
+Variables | |
| static rcAllocFunc * | sRecastAllocFunc = rcAllocDefault |
| static rcFreeFunc * | sRecastFreeFunc = rcFreeDefault |
| void* rcAlloc | +( | +size_t | +size, | +
| + | + | rcAllocHint | +hint | +
| + | ) | ++ |
Allocates a memory block.
+| [in] | size | The size, in bytes of memory, to allocate. |
| [in] | hint | A hint to the allocator on how long the memory is expected to be in use. |
+
|
+ +static | +
| void rcAllocSetCustom | +( | +rcAllocFunc * | +allocFunc, | +
| + | + | rcFreeFunc * | +freeFunc | +
| + | ) | ++ |
| void rcFree | +( | +void * | +ptr | ) | ++ |
Deallocates a memory block.
+If ptr is NULL, this does nothing.
ptr unchanged. So it still points to the same (now invalid) location, and not to null.| [in] | ptr | A pointer to a memory block previously allocated using rcAlloc. |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| struct | rcNewTag |
| An implementation of operator new usable for placement new. More... | |
| class | rcVectorBase< T, H > |
| Variable-sized storage type. More... | |
| class | rcTempVector< T > |
| class | rcPermVector< T > |
| class | rcIntArray |
| Legacy class. Prefer rcVector<int>. More... | |
| class | rcScopedDelete< T > |
| A simple helper class used to delete an array when it goes out of scope. More... | |
+Macros | |
| #define | RC_SIZE_MAX INTPTR_MAX |
| #define | rcLikely(x) (x) |
| Macros to hint to the compiler about the likeliest branch. More... | |
| #define | rcUnlikely(x) (x) |
+Typedefs | |
| typedef void *() | rcAllocFunc(size_t size, rcAllocHint hint) |
| A memory allocation function. More... | |
| typedef void() | rcFreeFunc(void *ptr) |
| A memory deallocation function. More... | |
| typedef intptr_t | rcSizeType |
| Signed to avoid warnnings when comparing to int loop indexes, and common error with comparing to zero. More... | |
+Enumerations | |
| enum | rcAllocHint { RC_ALLOC_PERM +, RC_ALLOC_TEMP + } |
| Provides hint values to the memory allocator on how long the memory is expected to be used. More... | |
+Functions | |
| void | rcAllocSetCustom (rcAllocFunc *allocFunc, rcFreeFunc *freeFunc) |
| Sets the base custom allocation functions to be used by Recast. More... | |
| void * | rcAlloc (size_t size, rcAllocHint hint) |
| Allocates a memory block. More... | |
| void | rcFree (void *ptr) |
| Deallocates a memory block. More... | |
| void * | operator new (size_t, const rcNewTag &, void *p) |
| void | operator delete (void *, const rcNewTag &, void *) |
| #define RC_SIZE_MAX INTPTR_MAX | +
| #define rcLikely | +( | ++ | x | ) | +(x) | +
Macros to hint to the compiler about the likeliest branch.
+Please add a benchmark that demonstrates a performance improvement before introducing use cases.
+ +| #define rcUnlikely | +( | ++ | x | ) | +(x) | +
| typedef void*() rcAllocFunc(size_t size, rcAllocHint hint) | +
A memory allocation function.
+| typedef void() rcFreeFunc(void *ptr) | +
A memory deallocation function.
+| [in] | ptr | A pointer to a memory block previously allocated using rcAllocFunc. |
| typedef intptr_t rcSizeType | +
Signed to avoid warnnings when comparing to int loop indexes, and common error with comparing to zero.
+MSVC2010 has a bug where ssize_t is unsigned (!!!).
+ +| enum rcAllocHint | +
+
|
+ +inline | +
+
|
+ +inline | +
| void* rcAlloc | +( | +size_t | +size, | +
| + | + | rcAllocHint | +hint | +
| + | ) | ++ |
Allocates a memory block.
+| [in] | size | The size, in bytes of memory, to allocate. |
| [in] | hint | A hint to the allocator on how long the memory is expected to be in use. |
| void rcAllocSetCustom | +( | +rcAllocFunc * | +allocFunc, | +
| + | + | rcFreeFunc * | +freeFunc | +
| + | ) | ++ |
| void rcFree | +( | +void * | +ptr | ) | ++ |
Deallocates a memory block.
+If ptr is NULL, this does nothing.
ptr unchanged. So it still points to the same (now invalid) location, and not to null.| [in] | ptr | A pointer to a memory block previously allocated using rcAlloc. |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <float.h>#include <math.h>#include <string.h>#include <stdlib.h>#include <stdio.h>#include "Recast.h"#include "RecastAlloc.h"#include "RecastAssert.h"+Functions | |
| bool | rcErodeWalkableArea (rcContext *ctx, int radius, rcCompactHeightfield &chf) |
| Erodes the walkable area within the heightfield by the specified radius. More... | |
| static void | insertSort (unsigned char *a, const int n) |
| bool | rcMedianFilterWalkableArea (rcContext *ctx, rcCompactHeightfield &chf) |
| Applies a median filter to walkable area types (based on area id), removing noise. More... | |
| void | rcMarkBoxArea (rcContext *ctx, const float *bmin, const float *bmax, unsigned char areaId, rcCompactHeightfield &chf) |
| Applies an area id to all spans within the specified bounding box. More... | |
| static int | pointInPoly (int nvert, const float *verts, const float *p) |
| void | rcMarkConvexPolyArea (rcContext *ctx, const float *verts, const int nverts, const float hmin, const float hmax, unsigned char areaId, rcCompactHeightfield &chf) |
| Applies the area id to the all spans within the specified convex polygon. More... | |
| int | rcOffsetPoly (const float *verts, const int nverts, const float offset, float *outVerts, const int maxOutVerts) |
| Helper function to offset voncex polygons for rcMarkConvexPolyArea. More... | |
| void | rcMarkCylinderArea (rcContext *ctx, const float *pos, const float r, const float h, unsigned char areaId, rcCompactHeightfield &chf) |
| Applies the area id to all spans within the specified cylinder. More... | |
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "RecastAssert.h"+Functions | |
| void | rcAssertFailSetCustom (rcAssertFailFunc *assertFailFunc) |
| Sets the base custom assertion failure function to be used by Recast. More... | |
| rcAssertFailFunc * | rcAssertFailGetCustom () |
| Gets the base custom assertion failure function to be used by Recast. More... | |
+Variables | |
| static rcAssertFailFunc * | sRecastAssertFailFunc = 0 |
| rcAssertFailFunc* rcAssertFailGetCustom | +( | +) | ++ |
Gets the base custom assertion failure function to be used by Recast.
+ +| void rcAssertFailSetCustom | +( | +rcAssertFailFunc * | +assertFailFunc | ) | ++ |
Sets the base custom assertion failure function to be used by Recast.
+| [in] | assertFailFunc | The function to be used in case of failure of dtAssert |
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <assert.h>Go to the source code of this file.
++Macros | |
| #define | rcAssert(expression) |
+Typedefs | |
| typedef void() | rcAssertFailFunc(const char *expression, const char *file, int line) |
| An assertion failure function. More... | |
+Functions | |
| void | rcAssertFailSetCustom (rcAssertFailFunc *assertFailFunc) |
| Sets the base custom assertion failure function to be used by Recast. More... | |
| rcAssertFailFunc * | rcAssertFailGetCustom () |
| Gets the base custom assertion failure function to be used by Recast. More... | |
| #define rcAssert | +( | ++ | expression | ) | ++ |
| typedef void() rcAssertFailFunc(const char *expression, const char *file, int line) | +
An assertion failure function.
+| rcAssertFailFunc* rcAssertFailGetCustom | +( | +) | ++ |
Gets the base custom assertion failure function to be used by Recast.
+ +| void rcAssertFailSetCustom | +( | +rcAssertFailFunc * | +assertFailFunc | ) | ++ |
Sets the base custom assertion failure function to be used by Recast.
+| [in] | assertFailFunc | The function to be used in case of failure of dtAssert |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <string.h>#include <stdio.h>#include <stdlib.h>#include "Recast.h"#include "RecastAlloc.h"#include "RecastAssert.h"+Classes | |
| struct | rcContourHole |
| struct | rcContourRegion |
| struct | rcPotentialDiagonal |
+Functions | |
| static int | getCornerHeight (int x, int y, int i, int dir, const rcCompactHeightfield &chf, bool &isBorderVertex) |
| static void | walkContour (int x, int y, int i, rcCompactHeightfield &chf, unsigned char *flags, rcIntArray &points) |
| static float | distancePtSeg (const int x, const int z, const int px, const int pz, const int qx, const int qz) |
| static void | simplifyContour (rcIntArray &points, rcIntArray &simplified, const float maxError, const int maxEdgeLen, const int buildFlags) |
| static int | calcAreaOfPolygon2D (const int *verts, const int nverts) |
| int | prev (int i, int n) |
| int | next (int i, int n) |
| int | area2 (const int *a, const int *b, const int *c) |
| bool | xorb (bool x, bool y) |
| bool | left (const int *a, const int *b, const int *c) |
| bool | leftOn (const int *a, const int *b, const int *c) |
| bool | collinear (const int *a, const int *b, const int *c) |
| static bool | intersectProp (const int *a, const int *b, const int *c, const int *d) |
| static bool | between (const int *a, const int *b, const int *c) |
| static bool | intersect (const int *a, const int *b, const int *c, const int *d) |
| static bool | vequal (const int *a, const int *b) |
| static bool | intersectSegCountour (const int *d0, const int *d1, int i, int n, const int *verts) |
| static bool | inCone (int i, int n, const int *verts, const int *pj) |
| static void | removeDegenerateSegments (rcIntArray &simplified) |
| static bool | mergeContours (rcContour &ca, rcContour &cb, int ia, int ib) |
| static void | findLeftMostVertex (rcContour *contour, int *minx, int *minz, int *leftmost) |
| static int | compareHoles (const void *va, const void *vb) |
| static int | compareDiagDist (const void *va, const void *vb) |
| static void | mergeRegionHoles (rcContext *ctx, rcContourRegion ®ion) |
| bool | rcBuildContours (rcContext *ctx, rcCompactHeightfield &chf, const float maxError, const int maxEdgeLen, rcContourSet &cset, const int buildFlags) |
| Builds a contour set from the region outlines in the provided compact heightfield. More... | |
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Functions | |
| void | duDebugDrawTriMesh (duDebugDraw *dd, const float *verts, int, const int *tris, const float *normals, int ntris, const unsigned char *flags, const float texScale) |
| void | duDebugDrawTriMeshSlope (duDebugDraw *dd, const float *verts, int, const int *tris, const float *normals, int ntris, const float walkableSlopeAngle, const float texScale) |
| void | duDebugDrawHeightfieldSolid (duDebugDraw *dd, const rcHeightfield &hf) |
| void | duDebugDrawHeightfieldWalkable (duDebugDraw *dd, const rcHeightfield &hf) |
| void | duDebugDrawCompactHeightfieldSolid (duDebugDraw *dd, const rcCompactHeightfield &chf) |
| void | duDebugDrawCompactHeightfieldRegions (duDebugDraw *dd, const rcCompactHeightfield &chf) |
| void | duDebugDrawCompactHeightfieldDistance (duDebugDraw *dd, const rcCompactHeightfield &chf) |
| static void | drawLayerPortals (duDebugDraw *dd, const rcHeightfieldLayer *layer) |
| void | duDebugDrawHeightfieldLayer (duDebugDraw *dd, const struct rcHeightfieldLayer &layer, const int idx) |
| void | duDebugDrawHeightfieldLayers (duDebugDraw *dd, const struct rcHeightfieldLayerSet &lset) |
| static void | getContourCenter (const rcContour *cont, const float *orig, float cs, float ch, float *center) |
| static const rcContour * | findContourFromSet (const rcContourSet &cset, unsigned short reg) |
| void | duDebugDrawRegionConnections (duDebugDraw *dd, const rcContourSet &cset, const float alpha) |
| void | duDebugDrawRawContours (duDebugDraw *dd, const rcContourSet &cset, const float alpha) |
| void | duDebugDrawContours (duDebugDraw *dd, const rcContourSet &cset, const float alpha) |
| void | duDebugDrawPolyMesh (duDebugDraw *dd, const struct rcPolyMesh &mesh) |
| void | duDebugDrawPolyMeshDetail (duDebugDraw *dd, const struct rcPolyMeshDetail &dmesh) |
+
|
+ +static | +
| void duDebugDrawCompactHeightfieldDistance | +( | +duDebugDraw * | +dd, | +
| + | + | const rcCompactHeightfield & | +chf | +
| + | ) | ++ |
| void duDebugDrawCompactHeightfieldRegions | +( | +duDebugDraw * | +dd, | +
| + | + | const rcCompactHeightfield & | +chf | +
| + | ) | ++ |
| void duDebugDrawCompactHeightfieldSolid | +( | +duDebugDraw * | +dd, | +
| + | + | const rcCompactHeightfield & | +chf | +
| + | ) | ++ |
| void duDebugDrawContours | +( | +duDebugDraw * | +dd, | +
| + | + | const rcContourSet & | +cset, | +
| + | + | const float | +alpha | +
| + | ) | ++ |
| void duDebugDrawHeightfieldLayer | +( | +duDebugDraw * | +dd, | +
| + | + | const struct rcHeightfieldLayer & | +layer, | +
| + | + | const int | +idx | +
| + | ) | ++ |
| void duDebugDrawHeightfieldLayers | +( | +duDebugDraw * | +dd, | +
| + | + | const struct rcHeightfieldLayerSet & | +lset | +
| + | ) | ++ |
| void duDebugDrawHeightfieldSolid | +( | +duDebugDraw * | +dd, | +
| + | + | const rcHeightfield & | +hf | +
| + | ) | ++ |
| void duDebugDrawHeightfieldWalkable | +( | +duDebugDraw * | +dd, | +
| + | + | const rcHeightfield & | +hf | +
| + | ) | ++ |
| void duDebugDrawPolyMesh | +( | +duDebugDraw * | +dd, | +
| + | + | const struct rcPolyMesh & | +mesh | +
| + | ) | ++ |
| void duDebugDrawPolyMeshDetail | +( | +duDebugDraw * | +dd, | +
| + | + | const struct rcPolyMeshDetail & | +dmesh | +
| + | ) | ++ |
| void duDebugDrawRawContours | +( | +duDebugDraw * | +dd, | +
| + | + | const rcContourSet & | +cset, | +
| + | + | const float | +alpha | +
| + | ) | ++ |
| void duDebugDrawRegionConnections | +( | +duDebugDraw * | +dd, | +
| + | + | const rcContourSet & | +cset, | +
| + | + | const float | +alpha | +
| + | ) | ++ |
| void duDebugDrawTriMesh | +( | +duDebugDraw * | +dd, | +
| + | + | const float * | +verts, | +
| + | + | int | +nverts, | +
| + | + | const int * | +tris, | +
| + | + | const float * | +normals, | +
| + | + | int | +ntris, | +
| + | + | const unsigned char * | +flags, | +
| + | + | const float | +texScale | +
| + | ) | ++ |
| void duDebugDrawTriMeshSlope | +( | +duDebugDraw * | +dd, | +
| + | + | const float * | +verts, | +
| + | + | int | +nverts, | +
| + | + | const int * | +tris, | +
| + | + | const float * | +normals, | +
| + | + | int | +ntris, | +
| + | + | const float | +walkableSlopeAngle, | +
| + | + | const float | +texScale | +
| + | ) | ++ |
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Functions | |
| void | duDebugDrawTriMesh (struct duDebugDraw *dd, const float *verts, int nverts, const int *tris, const float *normals, int ntris, const unsigned char *flags, const float texScale) |
| void | duDebugDrawTriMeshSlope (struct duDebugDraw *dd, const float *verts, int nverts, const int *tris, const float *normals, int ntris, const float walkableSlopeAngle, const float texScale) |
| void | duDebugDrawHeightfieldSolid (struct duDebugDraw *dd, const struct rcHeightfield &hf) |
| void | duDebugDrawHeightfieldWalkable (struct duDebugDraw *dd, const struct rcHeightfield &hf) |
| void | duDebugDrawCompactHeightfieldSolid (struct duDebugDraw *dd, const struct rcCompactHeightfield &chf) |
| void | duDebugDrawCompactHeightfieldRegions (struct duDebugDraw *dd, const struct rcCompactHeightfield &chf) |
| void | duDebugDrawCompactHeightfieldDistance (struct duDebugDraw *dd, const struct rcCompactHeightfield &chf) |
| void | duDebugDrawHeightfieldLayer (duDebugDraw *dd, const struct rcHeightfieldLayer &layer, const int idx) |
| void | duDebugDrawHeightfieldLayers (duDebugDraw *dd, const struct rcHeightfieldLayerSet &lset) |
| void | duDebugDrawHeightfieldLayersRegions (duDebugDraw *dd, const struct rcHeightfieldLayerSet &lset) |
| void | duDebugDrawRegionConnections (struct duDebugDraw *dd, const struct rcContourSet &cset, const float alpha=1.0f) |
| void | duDebugDrawRawContours (struct duDebugDraw *dd, const struct rcContourSet &cset, const float alpha=1.0f) |
| void | duDebugDrawContours (struct duDebugDraw *dd, const struct rcContourSet &cset, const float alpha=1.0f) |
| void | duDebugDrawPolyMesh (struct duDebugDraw *dd, const struct rcPolyMesh &mesh) |
| void | duDebugDrawPolyMeshDetail (struct duDebugDraw *dd, const struct rcPolyMeshDetail &dmesh) |
| void duDebugDrawCompactHeightfieldDistance | +( | +struct duDebugDraw * | +dd, | +
| + | + | const struct rcCompactHeightfield & | +chf | +
| + | ) | ++ |
| void duDebugDrawCompactHeightfieldRegions | +( | +struct duDebugDraw * | +dd, | +
| + | + | const struct rcCompactHeightfield & | +chf | +
| + | ) | ++ |
| void duDebugDrawCompactHeightfieldSolid | +( | +struct duDebugDraw * | +dd, | +
| + | + | const struct rcCompactHeightfield & | +chf | +
| + | ) | ++ |
| void duDebugDrawContours | +( | +struct duDebugDraw * | +dd, | +
| + | + | const struct rcContourSet & | +cset, | +
| + | + | const float | +alpha = 1.0f |
+
| + | ) | ++ |
| void duDebugDrawHeightfieldLayer | +( | +duDebugDraw * | +dd, | +
| + | + | const struct rcHeightfieldLayer & | +layer, | +
| + | + | const int | +idx | +
| + | ) | ++ |
| void duDebugDrawHeightfieldLayers | +( | +duDebugDraw * | +dd, | +
| + | + | const struct rcHeightfieldLayerSet & | +lset | +
| + | ) | ++ |
| void duDebugDrawHeightfieldLayersRegions | +( | +duDebugDraw * | +dd, | +
| + | + | const struct rcHeightfieldLayerSet & | +lset | +
| + | ) | ++ |
| void duDebugDrawHeightfieldSolid | +( | +struct duDebugDraw * | +dd, | +
| + | + | const struct rcHeightfield & | +hf | +
| + | ) | ++ |
| void duDebugDrawHeightfieldWalkable | +( | +struct duDebugDraw * | +dd, | +
| + | + | const struct rcHeightfield & | +hf | +
| + | ) | ++ |
| void duDebugDrawPolyMesh | +( | +struct duDebugDraw * | +dd, | +
| + | + | const struct rcPolyMesh & | +mesh | +
| + | ) | ++ |
| void duDebugDrawPolyMeshDetail | +( | +struct duDebugDraw * | +dd, | +
| + | + | const struct rcPolyMeshDetail & | +dmesh | +
| + | ) | ++ |
| void duDebugDrawRawContours | +( | +struct duDebugDraw * | +dd, | +
| + | + | const struct rcContourSet & | +cset, | +
| + | + | const float | +alpha = 1.0f |
+
| + | ) | ++ |
| void duDebugDrawRegionConnections | +( | +struct duDebugDraw * | +dd, | +
| + | + | const struct rcContourSet & | +cset, | +
| + | + | const float | +alpha = 1.0f |
+
| + | ) | ++ |
| void duDebugDrawTriMesh | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float * | +verts, | +
| + | + | int | +nverts, | +
| + | + | const int * | +tris, | +
| + | + | const float * | +normals, | +
| + | + | int | +ntris, | +
| + | + | const unsigned char * | +flags, | +
| + | + | const float | +texScale | +
| + | ) | ++ |
| void duDebugDrawTriMeshSlope | +( | +struct duDebugDraw * | +dd, | +
| + | + | const float * | +verts, | +
| + | + | int | +nverts, | +
| + | + | const int * | +tris, | +
| + | + | const float * | +normals, | +
| + | + | int | +ntris, | +
| + | + | const float | +walkableSlopeAngle, | +
| + | + | const float | +texScale | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <stdarg.h>#include <string.h>#include "Recast.h"#include "RecastAlloc.h"#include "RecastDump.h"+Functions | |
| static void | ioprintf (duFileIO *io, const char *format,...) |
| bool | duDumpPolyMeshToObj (rcPolyMesh &pmesh, duFileIO *io) |
| bool | duDumpPolyMeshDetailToObj (rcPolyMeshDetail &dmesh, duFileIO *io) |
| bool | duDumpContourSet (struct rcContourSet &cset, duFileIO *io) |
| bool | duReadContourSet (struct rcContourSet &cset, duFileIO *io) |
| bool | duDumpCompactHeightfield (struct rcCompactHeightfield &chf, duFileIO *io) |
| bool | duReadCompactHeightfield (struct rcCompactHeightfield &chf, duFileIO *io) |
| static void | logLine (rcContext &ctx, rcTimerLabel label, const char *name, const float pc) |
| void | duLogBuildTimes (rcContext &ctx, const int totalTimeUsec) |
+Variables | |
| static const int | CSET_MAGIC = ('c' << 24) | ('s' << 16) | ('e' << 8) | 't' |
| static const int | CSET_VERSION = 2 |
| static const int | CHF_MAGIC = ('r' << 24) | ('c' << 16) | ('h' << 8) | 'f' |
| static const int | CHF_VERSION = 3 |
| bool duDumpCompactHeightfield | +( | +struct rcCompactHeightfield & | +chf, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
| bool duDumpContourSet | +( | +struct rcContourSet & | +cset, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
| bool duDumpPolyMeshDetailToObj | +( | +rcPolyMeshDetail & | +dmesh, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
| bool duDumpPolyMeshToObj | +( | +rcPolyMesh & | +pmesh, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
| void duLogBuildTimes | +( | +rcContext & | +ctx, | +
| + | + | const int | +totalTimeUsec | +
| + | ) | ++ |
| bool duReadCompactHeightfield | +( | +struct rcCompactHeightfield & | +chf, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
| bool duReadContourSet | +( | +struct rcContourSet & | +cset, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| struct | duFileIO |
+Functions | |
| bool | duDumpPolyMeshToObj (struct rcPolyMesh &pmesh, duFileIO *io) |
| bool | duDumpPolyMeshDetailToObj (struct rcPolyMeshDetail &dmesh, duFileIO *io) |
| bool | duDumpContourSet (struct rcContourSet &cset, duFileIO *io) |
| bool | duReadContourSet (struct rcContourSet &cset, duFileIO *io) |
| bool | duDumpCompactHeightfield (struct rcCompactHeightfield &chf, duFileIO *io) |
| bool | duReadCompactHeightfield (struct rcCompactHeightfield &chf, duFileIO *io) |
| void | duLogBuildTimes (rcContext &ctx, const int totalTileUsec) |
| bool duDumpCompactHeightfield | +( | +struct rcCompactHeightfield & | +chf, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
| bool duDumpContourSet | +( | +struct rcContourSet & | +cset, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
| bool duDumpPolyMeshDetailToObj | +( | +struct rcPolyMeshDetail & | +dmesh, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
| bool duDumpPolyMeshToObj | +( | +struct rcPolyMesh & | +pmesh, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
| void duLogBuildTimes | +( | +rcContext & | +ctx, | +
| + | + | const int | +totalTileUsec | +
| + | ) | ++ |
| bool duReadCompactHeightfield | +( | +struct rcCompactHeightfield & | +chf, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
| bool duReadContourSet | +( | +struct rcContourSet & | +cset, | +
| + | + | duFileIO * | +io | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Functions | |
| void | rcFilterLowHangingWalkableObstacles (rcContext *context, const int walkableClimb, rcHeightfield &heightfield) |
Marks non-walkable spans as walkable if their maximum is within walkableClimb of a walkable neighbor. More... | |
| void | rcFilterLedgeSpans (rcContext *context, const int walkableHeight, const int walkableClimb, rcHeightfield &heightfield) |
| Marks spans that are ledges as not-walkable. More... | |
| void | rcFilterWalkableLowHeightSpans (rcContext *context, const int walkableHeight, rcHeightfield &heightfield) |
| Marks walkable spans as not walkable if the clearance above the span is less than the specified height. More... | |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <float.h>#include <math.h>#include <string.h>#include <stdlib.h>#include <stdio.h>#include "Recast.h"#include "RecastAlloc.h"#include "RecastAssert.h"+Classes | |
| struct | rcLayerRegion |
| struct | rcLayerSweepSpan |
+Functions | |
| static bool | contains (const unsigned char *a, const unsigned char an, const unsigned char v) |
| static bool | addUnique (unsigned char *a, unsigned char &an, int anMax, unsigned char v) |
| bool | overlapRange (const unsigned short amin, const unsigned short amax, const unsigned short bmin, const unsigned short bmax) |
| bool | rcBuildHeightfieldLayers (rcContext *ctx, rcCompactHeightfield &chf, const int borderSize, const int walkableHeight, rcHeightfieldLayerSet &lset) |
| Builds a layer set from the specified compact heightfield. More... | |
+Variables | |
| static const int | RC_MAX_LAYERS = 63 |
| static const int | RC_MAX_NEIS = 16 |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <float.h>#include <math.h>#include <string.h>#include <stdlib.h>#include <stdio.h>#include "Recast.h"#include "RecastAlloc.h"#include "RecastAssert.h"+Classes | |
| struct | rcHeightPatch |
+Enumerations | |
| enum | EdgeValues { EV_UNDEF = -1 +, EV_HULL = -2 + } |
+Functions | |
| float | vdot2 (const float *a, const float *b) |
| float | vdistSq2 (const float *p, const float *q) |
| float | vdist2 (const float *p, const float *q) |
| float | vcross2 (const float *p1, const float *p2, const float *p3) |
| static bool | circumCircle (const float *p1, const float *p2, const float *p3, float *c, float &r) |
| static float | distPtTri (const float *p, const float *a, const float *b, const float *c) |
| static float | distancePtSeg (const float *pt, const float *p, const float *q) |
| static float | distancePtSeg2d (const float *pt, const float *p, const float *q) |
| static float | distToTriMesh (const float *p, const float *verts, const int, const int *tris, const int ntris) |
| static float | distToPoly (int nvert, const float *verts, const float *p) |
| static unsigned short | getHeight (const float fx, const float fy, const float fz, const float, const float ics, const float ch, const int radius, const rcHeightPatch &hp) |
| static int | findEdge (const int *edges, int nedges, int s, int t) |
| static int | addEdge (rcContext *ctx, int *edges, int &nedges, const int maxEdges, int s, int t, int l, int r) |
| static void | updateLeftFace (int *e, int s, int t, int f) |
| static int | overlapSegSeg2d (const float *a, const float *b, const float *c, const float *d) |
| static bool | overlapEdges (const float *pts, const int *edges, int nedges, int s1, int t1) |
| static void | completeFacet (rcContext *ctx, const float *pts, int npts, int *edges, int &nedges, const int maxEdges, int &nfaces, int e) |
| static void | delaunayHull (rcContext *ctx, const int npts, const float *pts, const int nhull, const int *hull, rcIntArray &tris, rcIntArray &edges) |
| static float | polyMinExtent (const float *verts, const int nverts) |
| int | prev (int i, int n) |
| int | next (int i, int n) |
| static void | triangulateHull (const int, const float *verts, const int nhull, const int *hull, const int nin, rcIntArray &tris) |
| float | getJitterX (const int i) |
| float | getJitterY (const int i) |
| static bool | buildPolyDetail (rcContext *ctx, const float *in, const int nin, const float sampleDist, const float sampleMaxError, const int heightSearchRadius, const rcCompactHeightfield &chf, const rcHeightPatch &hp, float *verts, int &nverts, rcIntArray &tris, rcIntArray &edges, rcIntArray &samples) |
| static void | seedArrayWithPolyCenter (rcContext *ctx, const rcCompactHeightfield &chf, const unsigned short *poly, const int npoly, const unsigned short *verts, const int bs, rcHeightPatch &hp, rcIntArray &array) |
| static void | push3 (rcIntArray &queue, int v1, int v2, int v3) |
| static void | getHeightData (rcContext *ctx, const rcCompactHeightfield &chf, const unsigned short *poly, const int npoly, const unsigned short *verts, const int bs, rcHeightPatch &hp, rcIntArray &queue, int region) |
| static unsigned char | getEdgeFlags (const float *va, const float *vb, const float *vpoly, const int npoly) |
| static unsigned char | getTriFlags (const float *va, const float *vb, const float *vc, const float *vpoly, const int npoly) |
| bool | rcBuildPolyMeshDetail (rcContext *ctx, const rcPolyMesh &mesh, const rcCompactHeightfield &chf, const float sampleDist, const float sampleMaxError, rcPolyMeshDetail &dmesh) |
| Builds a detail mesh from the provided polygon mesh. More... | |
| bool | rcMergePolyMeshDetails (rcContext *ctx, rcPolyMeshDetail **meshes, const int nmeshes, rcPolyMeshDetail &mesh) |
| Merges multiple detail meshes into a single detail mesh. More... | |
+Variables | |
| static const unsigned | RC_UNSET_HEIGHT = 0xffff |
| enum EdgeValues | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <string.h>#include <stdio.h>#include "Recast.h"#include "RecastAlloc.h"#include "RecastAssert.h"+Classes | |
| struct | rcEdge |
+Functions | |
| static bool | buildMeshAdjacency (unsigned short *polys, const int npolys, const int nverts, const int vertsPerPoly) |
| int | computeVertexHash (int x, int y, int z) |
| static unsigned short | addVertex (unsigned short x, unsigned short y, unsigned short z, unsigned short *verts, int *firstVert, int *nextVert, int &nv) |
| int | prev (int i, int n) |
| int | next (int i, int n) |
| int | area2 (const int *a, const int *b, const int *c) |
| bool | xorb (bool x, bool y) |
| bool | left (const int *a, const int *b, const int *c) |
| bool | leftOn (const int *a, const int *b, const int *c) |
| bool | collinear (const int *a, const int *b, const int *c) |
| static bool | intersectProp (const int *a, const int *b, const int *c, const int *d) |
| static bool | between (const int *a, const int *b, const int *c) |
| static bool | intersect (const int *a, const int *b, const int *c, const int *d) |
| static bool | vequal (const int *a, const int *b) |
| static bool | diagonalie (int i, int j, int n, const int *verts, int *indices) |
| static bool | inCone (int i, int j, int n, const int *verts, int *indices) |
| static bool | diagonal (int i, int j, int n, const int *verts, int *indices) |
| static bool | diagonalieLoose (int i, int j, int n, const int *verts, int *indices) |
| static bool | inConeLoose (int i, int j, int n, const int *verts, int *indices) |
| static bool | diagonalLoose (int i, int j, int n, const int *verts, int *indices) |
| static int | triangulate (int n, const int *verts, int *indices, int *tris) |
| static int | countPolyVerts (const unsigned short *p, const int nvp) |
| bool | uleft (const unsigned short *a, const unsigned short *b, const unsigned short *c) |
| static int | getPolyMergeValue (unsigned short *pa, unsigned short *pb, const unsigned short *verts, int &ea, int &eb, const int nvp) |
| static void | mergePolyVerts (unsigned short *pa, unsigned short *pb, int ea, int eb, unsigned short *tmp, const int nvp) |
| static void | pushFront (int v, int *arr, int &an) |
| static void | pushBack (int v, int *arr, int &an) |
| static bool | canRemoveVertex (rcContext *ctx, rcPolyMesh &mesh, const unsigned short rem) |
| static bool | removeVertex (rcContext *ctx, rcPolyMesh &mesh, const unsigned short rem, const int maxTris) |
| bool | rcBuildPolyMesh (rcContext *ctx, rcContourSet &cset, const int nvp, rcPolyMesh &mesh) |
| Builds a polygon mesh from the provided contours. More... | |
| bool | rcMergePolyMeshes (rcContext *ctx, rcPolyMesh **meshes, const int nmeshes, rcPolyMesh &mesh) |
| Merges multiple polygon meshes into a single mesh. More... | |
| bool | rcCopyPolyMesh (rcContext *ctx, const rcPolyMesh &src, rcPolyMesh &dst) |
| Copies the poly mesh data from src to dst. More... | |
+Variables | |
| static const int | VERTEX_BUCKET_COUNT = (1<<12) |
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include "Recast.h"#include "RecastAlloc.h"#include "RecastAssert.h"+Enumerations | |
| enum | rcAxis { RC_AXIS_X = 0 +, RC_AXIS_Y = 1 +, RC_AXIS_Z = 2 + } |
+Functions | |
| static bool | overlapBounds (const float *aMin, const float *aMax, const float *bMin, const float *bMax) |
| Check whether two bounding boxes overlap. More... | |
| static rcSpan * | allocSpan (rcHeightfield &hf) |
| Allocates a new span in the heightfield. More... | |
| static void | freeSpan (rcHeightfield &hf, rcSpan *span) |
| Releases the memory used by the span back to the heightfield, so it can be re-used for new spans. More... | |
| static bool | addSpan (rcHeightfield &hf, const int x, const int z, const unsigned short min, const unsigned short max, const unsigned char areaID, const int flagMergeThreshold) |
| Adds a span to the heightfield. More... | |
| bool | rcAddSpan (rcContext *context, rcHeightfield &heightfield, const int x, const int z, const unsigned short spanMin, const unsigned short spanMax, const unsigned char areaID, const int flagMergeThreshold) |
| Adds a span to the specified heightfield. More... | |
| static void | dividePoly (const float *inVerts, int inVertsCount, float *outVerts1, int *outVerts1Count, float *outVerts2, int *outVerts2Count, float axisOffset, rcAxis axis) |
| Divides a convex polygon of max 12 vertices into two convex polygons across a separating axis. More... | |
| static bool | rasterizeTri (const float *v0, const float *v1, const float *v2, const unsigned char areaID, rcHeightfield &hf, const float *hfBBMin, const float *hfBBMax, const float cellSize, const float inverseCellSize, const float inverseCellHeight, const int flagMergeThreshold) |
| Rasterize a single triangle to the heightfield. More... | |
| bool | rcRasterizeTriangle (rcContext *context, const float *v0, const float *v1, const float *v2, const unsigned char areaID, rcHeightfield &heightfield, const int flagMergeThreshold) |
| Rasterizes a single triangle into the specified heightfield. More... | |
| bool | rcRasterizeTriangles (rcContext *context, const float *verts, const int, const int *tris, const unsigned char *triAreaIDs, const int numTris, rcHeightfield &heightfield, const int flagMergeThreshold) |
| Rasterizes an indexed triangle mesh into the specified heightfield. More... | |
| bool | rcRasterizeTriangles (rcContext *context, const float *verts, const int, const unsigned short *tris, const unsigned char *triAreaIDs, const int numTris, rcHeightfield &heightfield, const int flagMergeThreshold) |
| Rasterizes an indexed triangle mesh into the specified heightfield. More... | |
| bool | rcRasterizeTriangles (rcContext *context, const float *verts, const unsigned char *triAreaIDs, const int numTris, rcHeightfield &heightfield, const int flagMergeThreshold) |
| Rasterizes a triangle list into the specified heightfield. More... | |
| enum rcAxis | +
+
|
+ +static | +
Adds a span to the heightfield.
+If the new span overlaps existing spans, it will merge the new span with the existing ones.
+| [in] | hf | Heightfield to add spans to |
| [in] | x | The new span's column cell x index |
| [in] | z | The new span's column cell z index |
| [in] | min | The new span's minimum cell index |
| [in] | max | The new span's maximum cell index |
| [in] | areaID | The new span's area type ID |
| [in] | flagMergeThreshold | How close two spans maximum extents need to be to merge area type IDs |
+
|
+ +static | +
Allocates a new span in the heightfield.
+Use a memory pool and free list to minimize actual allocations.
+| [in] | hf | The heightfield |
+
|
+ +static | +
Divides a convex polygon of max 12 vertices into two convex polygons across a separating axis.
+| [in] | inVerts | The input polygon vertices |
| [in] | inVertsCount | The number of input polygon vertices |
| [out] | outVerts1 | Resulting polygon 1's vertices |
| [out] | outVerts1Count | The number of resulting polygon 1 vertices |
| [out] | outVerts2 | Resulting polygon 2's vertices |
| [out] | outVerts2Count | The number of resulting polygon 2 vertices |
| [in] | axisOffset | THe offset along the specified axis |
| [in] | axis | The separating axis |
+
|
+ +static | +
Releases the memory used by the span back to the heightfield, so it can be re-used for new spans.
+| [in] | hf | The heightfield. |
| [in] | span | A pointer to the span to free |
+
|
+ +static | +
Check whether two bounding boxes overlap.
+| [in] | aMin | Min axis extents of bounding box A |
| [in] | aMax | Max axis extents of bounding box A |
| [in] | bMin | Min axis extents of bounding box B |
| [in] | bMax | Max axis extents of bounding box B |
+
|
+ +static | +
Rasterize a single triangle to the heightfield.
+This code is extremely hot, so much care should be given to maintaining maximum perf here.
+| [in] | v0 | Triangle vertex 0 |
| [in] | v1 | Triangle vertex 1 |
| [in] | v2 | Triangle vertex 2 |
| [in] | areaID | The area ID to assign to the rasterized spans |
| [in] | hf | Heightfield to rasterize into |
| [in] | hfBBMin | The min extents of the heightfield bounding box |
| [in] | hfBBMax | The max extents of the heightfield bounding box |
| [in] | cellSize | The x and z axis size of a voxel in the heightfield |
| [in] | inverseCellSize | 1 / cellSize |
| [in] | inverseCellHeight | 1 / cellHeight |
| [in] | flagMergeThreshold | The threshold in which area flags will be merged |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <float.h>#include <math.h>#include <string.h>#include <stdlib.h>#include <stdio.h>#include "Recast.h"#include "RecastAlloc.h"#include "RecastAssert.h"+Classes | |
| struct | DirtyEntry |
| struct | rcRegion |
| struct | rcSweepSpan |
+Functions | |
| static void | calculateDistanceField (rcCompactHeightfield &chf, unsigned short *src, unsigned short &maxDist) |
| static unsigned short * | boxBlur (rcCompactHeightfield &chf, int thr, unsigned short *src, unsigned short *dst) |
| static bool | floodRegion (int x, int y, int i, unsigned short level, unsigned short r, rcCompactHeightfield &chf, unsigned short *srcReg, unsigned short *srcDist, rcTempVector< LevelStackEntry > &stack) |
| static void | expandRegions (int maxIter, unsigned short level, rcCompactHeightfield &chf, unsigned short *srcReg, unsigned short *srcDist, rcTempVector< LevelStackEntry > &stack, bool fillStack) |
| static void | sortCellsByLevel (unsigned short startLevel, rcCompactHeightfield &chf, const unsigned short *srcReg, unsigned int nbStacks, rcTempVector< LevelStackEntry > *stacks, unsigned short loglevelsPerStack) |
| static void | appendStacks (const rcTempVector< LevelStackEntry > &srcStack, rcTempVector< LevelStackEntry > &dstStack, const unsigned short *srcReg) |
| static void | removeAdjacentNeighbours (rcRegion ®) |
| static void | replaceNeighbour (rcRegion ®, unsigned short oldId, unsigned short newId) |
| static bool | canMergeWithRegion (const rcRegion ®a, const rcRegion ®b) |
| static void | addUniqueFloorRegion (rcRegion ®, int n) |
| static bool | mergeRegions (rcRegion ®a, rcRegion ®b) |
| static bool | isRegionConnectedToBorder (const rcRegion ®) |
| static bool | isSolidEdge (rcCompactHeightfield &chf, const unsigned short *srcReg, int x, int y, int i, int dir) |
| static void | walkContour (int x, int y, int i, int dir, rcCompactHeightfield &chf, const unsigned short *srcReg, rcIntArray &cont) |
| static bool | mergeAndFilterRegions (rcContext *ctx, int minRegionArea, int mergeRegionSize, unsigned short &maxRegionId, rcCompactHeightfield &chf, unsigned short *srcReg, rcIntArray &overlaps) |
| static void | addUniqueConnection (rcRegion ®, int n) |
| static bool | mergeAndFilterLayerRegions (rcContext *ctx, int minRegionArea, unsigned short &maxRegionId, rcCompactHeightfield &chf, unsigned short *srcReg) |
| bool | rcBuildDistanceField (rcContext *ctx, rcCompactHeightfield &chf) |
| Builds the distance field for the specified compact heightfield. More... | |
| static void | paintRectRegion (int minx, int maxx, int miny, int maxy, unsigned short regId, rcCompactHeightfield &chf, unsigned short *srcReg) |
| bool | rcBuildRegionsMonotone (rcContext *ctx, rcCompactHeightfield &chf, const int borderSize, const int minRegionArea, const int mergeRegionArea) |
| Builds region data for the heightfield using simple monotone partitioning. More... | |
| bool | rcBuildRegions (rcContext *ctx, rcCompactHeightfield &chf, const int borderSize, const int minRegionArea, const int mergeRegionArea) |
| Builds region data for the heightfield using watershed partitioning. More... | |
| bool | rcBuildLayerRegions (rcContext *ctx, rcCompactHeightfield &chf, const int borderSize, const int minRegionArea) |
| Builds region data for the heightfield by partitioning the heightfield in non-overlapping layers. More... | |
+Variables | |
| static const unsigned short | RC_NULL_NEI = 0xffff |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include "Recast.h"#include "RecastAlloc.h"#include "RecastAssert.h"#include <math.h>#include <string.h>#include <stdio.h>#include <stdarg.h>+Functions | |
| float | rcSqrt (float x) |
| Returns the square root of the value. More... | |
| rcHeightfield * | rcAllocHeightfield () |
| Allocates a heightfield object using the Recast allocator. More... | |
| void | rcFreeHeightField (rcHeightfield *heightfield) |
| Frees the specified heightfield object using the Recast allocator. More... | |
| rcCompactHeightfield * | rcAllocCompactHeightfield () |
| Allocates a compact heightfield object using the Recast allocator. More... | |
| void | rcFreeCompactHeightfield (rcCompactHeightfield *compactHeightfield) |
| Frees the specified compact heightfield object using the Recast allocator. More... | |
| rcHeightfieldLayerSet * | rcAllocHeightfieldLayerSet () |
| Allocates a heightfield layer set using the Recast allocator. More... | |
| void | rcFreeHeightfieldLayerSet (rcHeightfieldLayerSet *layerSet) |
| Frees the specified heightfield layer set using the Recast allocator. More... | |
| rcContourSet * | rcAllocContourSet () |
| Allocates a contour set object using the Recast allocator. More... | |
| void | rcFreeContourSet (rcContourSet *contourSet) |
| Frees the specified contour set using the Recast allocator. More... | |
| rcPolyMesh * | rcAllocPolyMesh () |
| Allocates a polygon mesh object using the Recast allocator. More... | |
| void | rcFreePolyMesh (rcPolyMesh *polyMesh) |
| Frees the specified polygon mesh using the Recast allocator. More... | |
| rcPolyMeshDetail * | rcAllocPolyMeshDetail () |
| Allocates a detail mesh object using the Recast allocator. More... | |
| void | rcFreePolyMeshDetail (rcPolyMeshDetail *detailMesh) |
| Frees the specified detail mesh using the Recast allocator. More... | |
| void | rcCalcBounds (const float *verts, int numVerts, float *minBounds, float *maxBounds) |
| Calculates the bounding box of an array of vertices. More... | |
| void | rcCalcGridSize (const float *minBounds, const float *maxBounds, const float cellSize, int *sizeX, int *sizeZ) |
| Calculates the grid size based on the bounding box and grid cell size. More... | |
| bool | rcCreateHeightfield (rcContext *context, rcHeightfield &heightfield, int sizeX, int sizeZ, const float *minBounds, const float *maxBounds, float cellSize, float cellHeight) |
| Initializes a new heightfield. More... | |
| static void | calcTriNormal (const float *v0, const float *v1, const float *v2, float *faceNormal) |
| void | rcMarkWalkableTriangles (rcContext *context, const float walkableSlopeAngle, const float *verts, const int numVerts, const int *tris, const int numTris, unsigned char *triAreaIDs) |
| Sets the area id of all triangles with a slope below the specified value to RC_WALKABLE_AREA. More... | |
| void | rcClearUnwalkableTriangles (rcContext *context, const float walkableSlopeAngle, const float *verts, int numVerts, const int *tris, int numTris, unsigned char *triAreaIDs) |
| Sets the area id of all triangles with a slope greater than or equal to the specified value to RC_NULL_AREA. More... | |
| int | rcGetHeightFieldSpanCount (rcContext *context, const rcHeightfield &heightfield) |
| Returns the number of spans contained in the specified heightfield. More... | |
| bool | rcBuildCompactHeightfield (rcContext *context, const int walkableHeight, const int walkableClimb, rcHeightfield &heightfield, rcCompactHeightfield &compactHeightfield) |
| Builds a compact heightfield representing open space, from a heightfield representing solid space. More... | |
+
|
+ +static | +
| float rcSqrt | +( | +float | +x | ) | ++ |
Returns the square root of the value.
+| [in] | x | The value. |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | rcContext |
| Provides an interface for optional logging and performance tracking of the Recast build process. More... | |
| class | rcScopedTimer |
| A helper to first start a timer and then stop it when this helper goes out of scope. More... | |
| struct | rcConfig |
| Specifies a configuration to use when performing Recast builds. More... | |
| struct | rcSpan |
| Represents a span in a heightfield. More... | |
| struct | rcSpanPool |
| A memory pool used for quick allocation of spans within a heightfield. More... | |
| struct | rcHeightfield |
| A dynamic heightfield representing obstructed space. More... | |
| struct | rcCompactCell |
| Provides information on the content of a cell column in a compact heightfield. More... | |
| struct | rcCompactSpan |
| Represents a span of unobstructed space within a compact heightfield. More... | |
| struct | rcCompactHeightfield |
| A compact, static heightfield representing unobstructed space. More... | |
| struct | rcHeightfieldLayer |
| Represents a heightfield layer within a layer set. More... | |
| struct | rcHeightfieldLayerSet |
| Represents a set of heightfield layers. More... | |
| struct | rcContour |
| Represents a simple, non-overlapping contour in field space. More... | |
| struct | rcContourSet |
| Represents a group of related contours. More... | |
| struct | rcPolyMesh |
| Represents a polygon mesh suitable for use in building a navigation mesh. More... | |
| struct | rcPolyMeshDetail |
| Contains triangle meshes that represent detailed height data associated with the polygons in its associated polygon mesh object. More... | |
+Functions | |
| template<class T > | |
| void | rcIgnoreUnused (const T &) |
| Used to ignore unused function parameters and silence any compiler warnings. More... | |
Allocation Functions | |
Functions used to allocate and de-allocate Recast objects. +
| |
| rcHeightfield * | rcAllocHeightfield () |
| Allocates a heightfield object using the Recast allocator. More... | |
| void | rcFreeHeightField (rcHeightfield *heightfield) |
| Frees the specified heightfield object using the Recast allocator. More... | |
| rcCompactHeightfield * | rcAllocCompactHeightfield () |
| Allocates a compact heightfield object using the Recast allocator. More... | |
| void | rcFreeCompactHeightfield (rcCompactHeightfield *compactHeightfield) |
| Frees the specified compact heightfield object using the Recast allocator. More... | |
| rcHeightfieldLayerSet * | rcAllocHeightfieldLayerSet () |
| Allocates a heightfield layer set using the Recast allocator. More... | |
| void | rcFreeHeightfieldLayerSet (rcHeightfieldLayerSet *layerSet) |
| Frees the specified heightfield layer set using the Recast allocator. More... | |
| rcContourSet * | rcAllocContourSet () |
| Allocates a contour set object using the Recast allocator. More... | |
| void | rcFreeContourSet (rcContourSet *contourSet) |
| Frees the specified contour set using the Recast allocator. More... | |
| rcPolyMesh * | rcAllocPolyMesh () |
| Allocates a polygon mesh object using the Recast allocator. More... | |
| void | rcFreePolyMesh (rcPolyMesh *polyMesh) |
| Frees the specified polygon mesh using the Recast allocator. More... | |
| rcPolyMeshDetail * | rcAllocPolyMeshDetail () |
| Allocates a detail mesh object using the Recast allocator. More... | |
| void | rcFreePolyMeshDetail (rcPolyMeshDetail *detailMesh) |
| Frees the specified detail mesh using the Recast allocator. More... | |
General helper functions | |
| template<class T > | |
| void | rcSwap (T &a, T &b) |
| Swaps the values of the two parameters. More... | |
| template<class T > | |
| T | rcMin (T a, T b) |
| Returns the minimum of two values. More... | |
| template<class T > | |
| T | rcMax (T a, T b) |
| Returns the maximum of two values. More... | |
| template<class T > | |
| T | rcAbs (T a) |
| Returns the absolute value. More... | |
| template<class T > | |
| T | rcSqr (T a) |
| Returns the square of the value. More... | |
| template<class T > | |
| T | rcClamp (T value, T minInclusive, T maxInclusive) |
| Clamps the value to the specified range. More... | |
| float | rcSqrt (float x) |
| Returns the square root of the value. More... | |
Vector helper functions. | |
| void | rcVcross (float *dest, const float *v1, const float *v2) |
| Derives the cross product of two vectors. More... | |
| float | rcVdot (const float *v1, const float *v2) |
| Derives the dot product of two vectors. More... | |
| void | rcVmad (float *dest, const float *v1, const float *v2, const float s) |
| Performs a scaled vector addition. More... | |
| void | rcVadd (float *dest, const float *v1, const float *v2) |
| Performs a vector addition. More... | |
| void | rcVsub (float *dest, const float *v1, const float *v2) |
| Performs a vector subtraction. More... | |
| void | rcVmin (float *mn, const float *v) |
| Selects the minimum value of each element from the specified vectors. More... | |
| void | rcVmax (float *mx, const float *v) |
| Selects the maximum value of each element from the specified vectors. More... | |
| void | rcVcopy (float *dest, const float *v) |
| Performs a vector copy. More... | |
| float | rcVdist (const float *v1, const float *v2) |
| Returns the distance between two points. More... | |
| float | rcVdistSqr (const float *v1, const float *v2) |
| Returns the square of the distance between two points. More... | |
| void | rcVnormalize (float *v) |
| Normalizes the vector. More... | |
Heightfield Functions | |
| |
| void | rcCalcBounds (const float *verts, int numVerts, float *minBounds, float *maxBounds) |
| Calculates the bounding box of an array of vertices. More... | |
| void | rcCalcGridSize (const float *minBounds, const float *maxBounds, float cellSize, int *sizeX, int *sizeZ) |
| Calculates the grid size based on the bounding box and grid cell size. More... | |
| bool | rcCreateHeightfield (rcContext *context, rcHeightfield &heightfield, int sizeX, int sizeZ, const float *minBounds, const float *maxBounds, float cellSize, float cellHeight) |
| Initializes a new heightfield. More... | |
| void | rcMarkWalkableTriangles (rcContext *context, float walkableSlopeAngle, const float *verts, int numVerts, const int *tris, int numTris, unsigned char *triAreaIDs) |
| Sets the area id of all triangles with a slope below the specified value to RC_WALKABLE_AREA. More... | |
| void | rcClearUnwalkableTriangles (rcContext *context, float walkableSlopeAngle, const float *verts, int numVerts, const int *tris, int numTris, unsigned char *triAreaIDs) |
| Sets the area id of all triangles with a slope greater than or equal to the specified value to RC_NULL_AREA. More... | |
| bool | rcAddSpan (rcContext *context, rcHeightfield &heightfield, int x, int z, unsigned short spanMin, unsigned short spanMax, unsigned char areaID, int flagMergeThreshold) |
| Adds a span to the specified heightfield. More... | |
| bool | rcRasterizeTriangle (rcContext *context, const float *v0, const float *v1, const float *v2, unsigned char areaID, rcHeightfield &heightfield, int flagMergeThreshold=1) |
| Rasterizes a single triangle into the specified heightfield. More... | |
| bool | rcRasterizeTriangles (rcContext *context, const float *verts, int numVerts, const int *tris, const unsigned char *triAreaIDs, int numTris, rcHeightfield &heightfield, int flagMergeThreshold=1) |
| Rasterizes an indexed triangle mesh into the specified heightfield. More... | |
| bool | rcRasterizeTriangles (rcContext *context, const float *verts, int numVerts, const unsigned short *tris, const unsigned char *triAreaIDs, int numTris, rcHeightfield &heightfield, int flagMergeThreshold=1) |
| Rasterizes an indexed triangle mesh into the specified heightfield. More... | |
| bool | rcRasterizeTriangles (rcContext *context, const float *verts, const unsigned char *triAreaIDs, int numTris, rcHeightfield &heightfield, int flagMergeThreshold=1) |
| Rasterizes a triangle list into the specified heightfield. More... | |
| void | rcFilterLowHangingWalkableObstacles (rcContext *context, int walkableClimb, rcHeightfield &heightfield) |
Marks non-walkable spans as walkable if their maximum is within walkableClimb of a walkable neighbor. More... | |
| void | rcFilterLedgeSpans (rcContext *context, int walkableHeight, int walkableClimb, rcHeightfield &heightfield) |
| Marks spans that are ledges as not-walkable. More... | |
| void | rcFilterWalkableLowHeightSpans (rcContext *context, int walkableHeight, rcHeightfield &heightfield) |
| Marks walkable spans as not walkable if the clearance above the span is less than the specified height. More... | |
| int | rcGetHeightFieldSpanCount (rcContext *context, const rcHeightfield &heightfield) |
| Returns the number of spans contained in the specified heightfield. More... | |
Compact Heightfield Functions | |
| |
| bool | rcBuildCompactHeightfield (rcContext *context, int walkableHeight, int walkableClimb, rcHeightfield &heightfield, rcCompactHeightfield &compactHeightfield) |
| Builds a compact heightfield representing open space, from a heightfield representing solid space. More... | |
| bool | rcErodeWalkableArea (rcContext *ctx, int radius, rcCompactHeightfield &chf) |
| Erodes the walkable area within the heightfield by the specified radius. More... | |
| bool | rcMedianFilterWalkableArea (rcContext *ctx, rcCompactHeightfield &chf) |
| Applies a median filter to walkable area types (based on area id), removing noise. More... | |
| void | rcMarkBoxArea (rcContext *ctx, const float *bmin, const float *bmax, unsigned char areaId, rcCompactHeightfield &chf) |
| Applies an area id to all spans within the specified bounding box. More... | |
| void | rcMarkConvexPolyArea (rcContext *ctx, const float *verts, const int nverts, const float hmin, const float hmax, unsigned char areaId, rcCompactHeightfield &chf) |
| Applies the area id to the all spans within the specified convex polygon. More... | |
| int | rcOffsetPoly (const float *verts, const int nverts, const float offset, float *outVerts, const int maxOutVerts) |
| Helper function to offset voncex polygons for rcMarkConvexPolyArea. More... | |
| void | rcMarkCylinderArea (rcContext *ctx, const float *pos, const float r, const float h, unsigned char areaId, rcCompactHeightfield &chf) |
| Applies the area id to all spans within the specified cylinder. More... | |
| bool | rcBuildDistanceField (rcContext *ctx, rcCompactHeightfield &chf) |
| Builds the distance field for the specified compact heightfield. More... | |
| bool | rcBuildRegions (rcContext *ctx, rcCompactHeightfield &chf, int borderSize, int minRegionArea, int mergeRegionArea) |
| Builds region data for the heightfield using watershed partitioning. More... | |
| bool | rcBuildLayerRegions (rcContext *ctx, rcCompactHeightfield &chf, int borderSize, int minRegionArea) |
| Builds region data for the heightfield by partitioning the heightfield in non-overlapping layers. More... | |
| bool | rcBuildRegionsMonotone (rcContext *ctx, rcCompactHeightfield &chf, int borderSize, int minRegionArea, int mergeRegionArea) |
| Builds region data for the heightfield using simple monotone partitioning. More... | |
| void | rcSetCon (rcCompactSpan &span, int direction, int neighborIndex) |
| Sets the neighbor connection data for the specified direction. More... | |
| int | rcGetCon (const rcCompactSpan &span, int direction) |
| Gets neighbor connection data for the specified direction. More... | |
| int | rcGetDirOffsetX (int direction) |
| Gets the standard width (x-axis) offset for the specified direction. More... | |
| int | rcGetDirOffsetY (int direction) |
| Gets the standard height (z-axis) offset for the specified direction. More... | |
| int | rcGetDirForOffset (int offsetX, int offsetZ) |
| Gets the direction for the specified offset. More... | |
Layer, Contour, Polymesh, and Detail Mesh Functions | |
| |
| bool | rcBuildHeightfieldLayers (rcContext *ctx, rcCompactHeightfield &chf, int borderSize, int walkableHeight, rcHeightfieldLayerSet &lset) |
| Builds a layer set from the specified compact heightfield. More... | |
| bool | rcBuildContours (rcContext *ctx, rcCompactHeightfield &chf, float maxError, int maxEdgeLen, rcContourSet &cset, int buildFlags=RC_CONTOUR_TESS_WALL_EDGES) |
| Builds a contour set from the region outlines in the provided compact heightfield. More... | |
| bool | rcBuildPolyMesh (rcContext *ctx, rcContourSet &cset, const int nvp, rcPolyMesh &mesh) |
| Builds a polygon mesh from the provided contours. More... | |
| bool | rcMergePolyMeshes (rcContext *ctx, rcPolyMesh **meshes, const int nmeshes, rcPolyMesh &mesh) |
| Merges multiple polygon meshes into a single mesh. More... | |
| bool | rcBuildPolyMeshDetail (rcContext *ctx, const rcPolyMesh &mesh, const rcCompactHeightfield &chf, float sampleDist, float sampleMaxError, rcPolyMeshDetail &dmesh) |
| Builds a detail mesh from the provided polygon mesh. More... | |
| bool | rcCopyPolyMesh (rcContext *ctx, const rcPolyMesh &src, rcPolyMesh &dst) |
| Copies the poly mesh data from src to dst. More... | |
| bool | rcMergePolyMeshDetails (rcContext *ctx, rcPolyMeshDetail **meshes, const int nmeshes, rcPolyMeshDetail &mesh) |
| Merges multiple detail meshes into a single detail mesh. More... | |
+Variables | |
| static const float | RC_PI = 3.14159265f |
| The value of PI used by Recast. More... | |
| static const int | RC_SPAN_HEIGHT_BITS = 13 |
| Defines the number of bits allocated to rcSpan::smin and rcSpan::smax. More... | |
| static const int | RC_SPAN_MAX_HEIGHT = (1 << RC_SPAN_HEIGHT_BITS) - 1 |
| Defines the maximum value for rcSpan::smin and rcSpan::smax. More... | |
| static const int | RC_SPANS_PER_POOL = 2048 |
| The number of spans allocated per span spool. More... | |
| static const unsigned short | RC_BORDER_REG = 0x8000 |
| Heightfield border flag. More... | |
| static const unsigned short | RC_MULTIPLE_REGS = 0 |
| Polygon touches multiple regions. More... | |
| static const int | RC_BORDER_VERTEX = 0x10000 |
| Border vertex flag. More... | |
| static const int | RC_AREA_BORDER = 0x20000 |
| Area border flag. More... | |
| static const int | RC_CONTOUR_REG_MASK = 0xffff |
| Applied to the region id field of contour vertices in order to extract the region id. More... | |
| static const unsigned short | RC_MESH_NULL_IDX = 0xffff |
| An value which indicates an invalid index within a mesh. More... | |
| static const unsigned char | RC_NULL_AREA = 0 |
| Represents the null area. More... | |
| static const unsigned char | RC_WALKABLE_AREA = 63 |
| The default area id used to indicate a walkable polygon. More... | |
| static const int | RC_NOT_CONNECTED = 0x3f |
| The value returned by rcGetCon if the specified direction is not connected to another span. More... | |
| enum rcBuildContoursFlags | +
Contour build flags.
+| enum rcLogCategory | +
Recast log categories.
+| Enumerator | |
|---|---|
| RC_LOG_PROGRESS | A progress log entry. + |
| RC_LOG_WARNING | A warning log entry. + |
| RC_LOG_ERROR | An error log entry. + |
| enum rcTimerLabel | +
Recast performance timer categories.
+| Enumerator | |
|---|---|
| RC_TIMER_TOTAL | The user defined total time of the build. + |
| RC_TIMER_TEMP | A user defined build time. + |
| RC_TIMER_RASTERIZE_TRIANGLES | The time to rasterize the triangles. (See: rcRasterizeTriangle) + |
| RC_TIMER_BUILD_COMPACTHEIGHTFIELD | The time to build the compact heightfield. (See: rcBuildCompactHeightfield) + |
| RC_TIMER_BUILD_CONTOURS | The total time to build the contours. (See: rcBuildContours) + |
| RC_TIMER_BUILD_CONTOURS_TRACE | The time to trace the boundaries of the contours. (See: rcBuildContours) + |
| RC_TIMER_BUILD_CONTOURS_SIMPLIFY | The time to simplify the contours. (See: rcBuildContours) + |
| RC_TIMER_FILTER_BORDER | The time to filter ledge spans. (See: rcFilterLedgeSpans) + |
| RC_TIMER_FILTER_WALKABLE | The time to filter low height spans. (See: rcFilterWalkableLowHeightSpans) + |
| RC_TIMER_MEDIAN_AREA | The time to apply the median filter. (See: rcMedianFilterWalkableArea) + |
| RC_TIMER_FILTER_LOW_OBSTACLES | The time to filter low obstacles. (See: rcFilterLowHangingWalkableObstacles) + |
| RC_TIMER_BUILD_POLYMESH | The time to build the polygon mesh. (See: rcBuildPolyMesh) + |
| RC_TIMER_MERGE_POLYMESH | The time to merge polygon meshes. (See: rcMergePolyMeshes) + |
| RC_TIMER_ERODE_AREA | The time to erode the walkable area. (See: rcErodeWalkableArea) + |
| RC_TIMER_MARK_BOX_AREA | The time to mark a box area. (See: rcMarkBoxArea) + |
| RC_TIMER_MARK_CYLINDER_AREA | The time to mark a cylinder area. (See: rcMarkCylinderArea) + |
| RC_TIMER_MARK_CONVEXPOLY_AREA | The time to mark a convex polygon area. (See: rcMarkConvexPolyArea) + |
| RC_TIMER_BUILD_DISTANCEFIELD | The total time to build the distance field. (See: rcBuildDistanceField) + |
| RC_TIMER_BUILD_DISTANCEFIELD_DIST | The time to build the distances of the distance field. (See: rcBuildDistanceField) + |
| RC_TIMER_BUILD_DISTANCEFIELD_BLUR | The time to blur the distance field. (See: rcBuildDistanceField) + |
| RC_TIMER_BUILD_REGIONS | The total time to build the regions. (See: rcBuildRegions, rcBuildRegionsMonotone) + |
| RC_TIMER_BUILD_REGIONS_WATERSHED | The total time to apply the watershed algorithm. (See: rcBuildRegions) + |
| RC_TIMER_BUILD_REGIONS_EXPAND | The time to expand regions while applying the watershed algorithm. (See: rcBuildRegions) + |
| RC_TIMER_BUILD_REGIONS_FLOOD | The time to flood regions while applying the watershed algorithm. (See: rcBuildRegions) + |
| RC_TIMER_BUILD_REGIONS_FILTER | The time to filter out small regions. (See: rcBuildRegions, rcBuildRegionsMonotone) + |
| RC_TIMER_BUILD_LAYERS | The time to build heightfield layers. (See: rcBuildHeightfieldLayers) + |
| RC_TIMER_BUILD_POLYMESHDETAIL | The time to build the polygon mesh detail. (See: rcBuildPolyMeshDetail) + |
| RC_TIMER_MERGE_POLYMESHDETAIL | The time to merge polygon mesh details. (See: rcMergePolyMeshDetails) + |
| RC_MAX_TIMERS | The maximum number of timers. (Used for iterating timers.) + |
+
|
+ +inline | +
Returns the absolute value.
+| [in] | a | The value. |
+
|
+ +inline | +
Clamps the value to the specified range.
+| [in] | value | The value to clamp. |
| [in] | minInclusive | The minimum permitted return value. |
| [in] | maxInclusive | The maximum permitted return value. |
| void rcIgnoreUnused | +( | +const T & | +) | ++ |
Used to ignore unused function parameters and silence any compiler warnings.
+ +
+
|
+ +inline | +
Returns the maximum of two values.
+| [in] | a | Value A |
| [in] | b | Value B |
+
|
+ +inline | +
Returns the minimum of two values.
+| [in] | a | Value A |
| [in] | b | Value B |
+
|
+ +inline | +
Returns the square of the value.
+| [in] | a | The value. |
| float rcSqrt | +( | +float | +x | ) | ++ |
Returns the square root of the value.
+| [in] | x | The value. |
+
|
+ +inline | +
Swaps the values of the two parameters.
+| [in,out] | a | Value A |
| [in,out] | b | Value B |
+
|
+ +inline | +
Performs a vector addition.
+(v1 + v2)
| [out] | dest | The result vector. [(x, y, z)] |
| [in] | v1 | The base vector. [(x, y, z)] |
| [in] | v2 | The vector to add to v1. [(x, y, z)] |
+
|
+ +inline | +
Performs a vector copy.
+| [out] | dest | The result. [(x, y, z)] |
| [in] | v | The vector to copy. [(x, y, z)] |
+
|
+ +inline | +
Derives the cross product of two vectors.
+(v1 x v2)
| [out] | dest | The cross product. [(x, y, z)] |
| [in] | v1 | A Vector [(x, y, z)] |
| [in] | v2 | A vector [(x, y, z)] |
+
|
+ +inline | +
Returns the distance between two points.
+| [in] | v1 | A point. [(x, y, z)] |
| [in] | v2 | A point. [(x, y, z)] |
+
|
+ +inline | +
Returns the square of the distance between two points.
+| [in] | v1 | A point. [(x, y, z)] |
| [in] | v2 | A point. [(x, y, z)] |
+
|
+ +inline | +
Derives the dot product of two vectors.
+(v1 . v2)
| [in] | v1 | A Vector [(x, y, z)] |
| [in] | v2 | A vector [(x, y, z)] |
+
|
+ +inline | +
Performs a scaled vector addition.
+(v1 + (v2 * s))
| [out] | dest | The result vector. [(x, y, z)] |
| [in] | v1 | The base vector. [(x, y, z)] |
| [in] | v2 | The vector to scale and add to v1. [(x, y, z)] |
| [in] | s | The amount to scale v2 by before adding to v1. |
+
|
+ +inline | +
Selects the maximum value of each element from the specified vectors.
+| [in,out] | mx | A vector. (Will be updated with the result.) [(x, y, z)] |
| [in] | v | A vector. [(x, y, z)] |
+
|
+ +inline | +
Selects the minimum value of each element from the specified vectors.
+| [in,out] | mn | A vector. (Will be updated with the result.) [(x, y, z)] |
| [in] | v | A vector. [(x, y, z)] |
+
|
+ +inline | +
Normalizes the vector.
+| [in,out] | v | The vector to normalize. [(x, y, z)] |
+
|
+ +inline | +
Performs a vector subtraction.
+(v1 - v2)
| [out] | dest | The result vector. [(x, y, z)] |
| [in] | v1 | The base vector. [(x, y, z)] |
| [in] | v2 | The vector to subtract from v1. [(x, y, z)] |
+
|
+ +static | +
Area border flag.
+If a region ID has this bit set, then the associated element lies on the border of an area. (Used during the region and contour build process.)
+ +
+
|
+ +static | +
Heightfield border flag.
+If a heightfield region ID has this bit set, then the region is a border region and its spans are considered un-walkable. (Used during the region and contour build process.)
+
|
+ +static | +
Border vertex flag.
+If a region ID has this bit set, then the associated element lies on a tile border. If a contour vertex's region ID has this bit set, the vertex will later be removed in order to match the segments and vertices at tile boundaries. (Used during the build process.)
+ +
+
|
+ +static | +
Applied to the region id field of contour vertices in order to extract the region id.
+The region id field of a vertex may have several flags applied to it. So the fields value can't be used directly.
+
|
+ +static | +
An value which indicates an invalid index within a mesh.
+
+
|
+ +static | +
Polygon touches multiple regions.
+If a polygon has this region ID it was merged with or created from polygons of different regions during the polymesh build step that removes redundant border vertices. (Used during the polymesh and detail polymesh build processes)
+
|
+ +static | +
The value returned by rcGetCon if the specified direction is not connected to another span.
+(Has no neighbor.)
+ +
+
|
+ +static | +
Represents the null area.
+When a data element is given this value it is considered to no longer be assigned to a usable area. (E.g. It is un-walkable.)
+ +
+
|
+ +static | +
The value of PI used by Recast.
+ +
+
|
+ +static | +
Defines the number of bits allocated to rcSpan::smin and rcSpan::smax.
+ +
+
|
+ +static | +
Defines the maximum value for rcSpan::smin and rcSpan::smax.
+ +
+
|
+ +static | +
The number of spans allocated per span spool.
+
+
|
+ +static | +
The default area id used to indicate a walkable polygon.
+This is also the maximum allowed area id, and the only non-null area id recognized by some steps in the build process.
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <stdarg.h>#include "SampleInterfaces.h"#include "Recast.h"#include "RecastDebugDraw.h"#include "DetourDebugDraw.h"#include "PerfTimer.h"#include "SDL.h"#include "SDL_opengl.h"+Classes | |
| class | GLCheckerTexture |
+Variables | |
| static GLCheckerTexture | g_tex |
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | BuildContext |
| Recast build context. More... | |
| class | DebugDrawGL |
| OpenGL debug draw implementation. More... | |
| class | FileIO |
| stdio file implementation. More... | |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include "Sample.h"#include "InputGeom.h"#include "Recast.h"#include "RecastDebugDraw.h"#include "DetourDebugDraw.h"#include "DetourNavMesh.h"#include "DetourNavMeshQuery.h"#include "DetourCrowd.h"#include "imgui.h"#include "SDL.h"#include "SDL_opengl.h"+Classes | |
| struct | NavMeshSetHeader |
| struct | NavMeshTileHeader |
+Variables | |
| static const int | NAVMESHSET_MAGIC = 'M'<<24 | 'S'<<16 | 'E'<<8 | 'T' |
| static const int | NAVMESHSET_VERSION = 1 |
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | SampleDebugDraw |
| struct | SampleTool |
| struct | SampleToolState |
| class | Sample |
+Enumerations | |
| enum | SampleToolType { + TOOL_NONE = 0 +, TOOL_TILE_EDIT +, TOOL_TILE_HIGHLIGHT +, TOOL_TEMP_OBSTACLE +, + TOOL_NAVMESH_TESTER +, TOOL_NAVMESH_PRUNE +, TOOL_OFFMESH_CONNECTION +, TOOL_CONVEX_VOLUME +, + TOOL_CROWD +, MAX_TOOLS + + } |
| Tool types. More... | |
| enum | SamplePolyAreas { + SAMPLE_POLYAREA_GROUND +, SAMPLE_POLYAREA_WATER +, SAMPLE_POLYAREA_ROAD +, SAMPLE_POLYAREA_DOOR +, + SAMPLE_POLYAREA_GRASS +, SAMPLE_POLYAREA_JUMP + + } |
| These are just sample areas to use consistent values across the samples. More... | |
| enum | SamplePolyFlags { + SAMPLE_POLYFLAGS_WALK = 0x01 +, SAMPLE_POLYFLAGS_SWIM = 0x02 +, SAMPLE_POLYFLAGS_DOOR = 0x04 +, SAMPLE_POLYFLAGS_JUMP = 0x08 +, + SAMPLE_POLYFLAGS_DISABLED = 0x10 +, SAMPLE_POLYFLAGS_ALL = 0xffff + + } |
| enum | SamplePartitionType { SAMPLE_PARTITION_WATERSHED +, SAMPLE_PARTITION_MONOTONE +, SAMPLE_PARTITION_LAYERS + } |
| enum SamplePartitionType | +
| enum SamplePolyAreas | +
| enum SamplePolyFlags | +
| enum SampleToolType | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include "Sample_Debug.h"#include "InputGeom.h"#include "Recast.h"#include "DetourNavMesh.h"#include "RecastDebugDraw.h"#include "DetourDebugDraw.h"#include "RecastDump.h"#include "imgui.h"#include "SDL.h"#include "SDL_opengl.h"|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | Sample_Debug |
| Sample used for random debugging. More... | |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <string.h>#include "SDL.h"#include "SDL_opengl.h"#include "imgui.h"#include "InputGeom.h"#include "Sample.h"#include "Sample_SoloMesh.h"#include "Recast.h"#include "RecastDebugDraw.h"#include "RecastDump.h"#include "DetourNavMesh.h"#include "DetourNavMeshBuilder.h"#include "DetourDebugDraw.h"#include "NavMeshTesterTool.h"#include "NavMeshPruneTool.h"#include "OffMeshConnectionTool.h"#include "ConvexVolumeTool.h"#include "CrowdTool.h"|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | Sample_SoloMesh |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <string.h>#include <float.h>#include <new>#include "SDL.h"#include "SDL_opengl.h"#include <GL/glu.h>#include "imgui.h"#include "InputGeom.h"#include "Sample.h"#include "Sample_TempObstacles.h"#include "Recast.h"#include "RecastDebugDraw.h"#include "DetourAssert.h"#include "DetourNavMesh.h"#include "DetourNavMeshBuilder.h"#include "DetourDebugDraw.h"#include "DetourCommon.h"#include "DetourTileCache.h"#include "NavMeshTesterTool.h"#include "OffMeshConnectionTool.h"#include "ConvexVolumeTool.h"#include "CrowdTool.h"#include "RecastAlloc.h"#include "RecastAssert.h"#include "fastlz.h"+Classes | |
| struct | FastLZCompressor |
| struct | LinearAllocator |
| struct | MeshProcess |
| struct | TileCacheData |
| struct | RasterizationContext |
| class | TempObstacleHilightTool |
| class | TempObstacleCreateTool |
| struct | TileCacheSetHeader |
| struct | TileCacheTileHeader |
+Enumerations | |
| enum | DrawDetailType { DRAWDETAIL_AREAS +, DRAWDETAIL_REGIONS +, DRAWDETAIL_CONTOURS +, DRAWDETAIL_MESH + } |
+Functions | |
| static bool | isectSegAABB (const float *sp, const float *sq, const float *amin, const float *amax, float &tmin, float &tmax) |
| static int | calcLayerBufferSize (const int gridWidth, const int gridHeight) |
| void | drawTiles (duDebugDraw *dd, dtTileCache *tc) |
| void | drawDetail (duDebugDraw *dd, dtTileCache *tc, const int tx, const int ty, int type) |
| void | drawDetailOverlay (const dtTileCache *tc, const int tx, const int ty, double *proj, double *model, int *view) |
| dtObstacleRef | hitTestObstacle (const dtTileCache *tc, const float *sp, const float *sq) |
| void | drawObstacles (duDebugDraw *dd, const dtTileCache *tc) |
+Variables | |
| static const int | EXPECTED_LAYERS_PER_TILE = 4 |
| static const int | MAX_LAYERS = 32 |
| static const int | TILECACHESET_MAGIC = 'T'<<24 | 'S'<<16 | 'E'<<8 | 'T' |
| static const int | TILECACHESET_VERSION = 1 |
| enum DrawDetailType | +
+
|
+ +static | +
| void drawDetail | +( | +duDebugDraw * | +dd, | +
| + | + | dtTileCache * | +tc, | +
| + | + | const int | +tx, | +
| + | + | const int | +ty, | +
| + | + | int | +type | +
| + | ) | ++ |
| void drawDetailOverlay | +( | +const dtTileCache * | +tc, | +
| + | + | const int | +tx, | +
| + | + | const int | +ty, | +
| + | + | double * | +proj, | +
| + | + | double * | +model, | +
| + | + | int * | +view | +
| + | ) | ++ |
| void drawObstacles | +( | +duDebugDraw * | +dd, | +
| + | + | const dtTileCache * | +tc | +
| + | ) | ++ |
| void drawTiles | +( | +duDebugDraw * | +dd, | +
| + | + | dtTileCache * | +tc | +
| + | ) | ++ |
| dtObstacleRef hitTestObstacle | +( | +const dtTileCache * | +tc, | +
| + | + | const float * | +sp, | +
| + | + | const float * | +sq | +
| + | ) | ++ |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | Sample_TempObstacles |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <math.h>#include <stdio.h>#include <string.h>#include "SDL.h"#include "SDL_opengl.h"#include <GL/glu.h>#include "imgui.h"#include "InputGeom.h"#include "Sample.h"#include "Sample_TileMesh.h"#include "Recast.h"#include "RecastDebugDraw.h"#include "DetourNavMesh.h"#include "DetourNavMeshBuilder.h"#include "DetourDebugDraw.h"#include "NavMeshTesterTool.h"#include "NavMeshPruneTool.h"#include "OffMeshConnectionTool.h"#include "ConvexVolumeTool.h"#include "CrowdTool.h"+Classes | |
| class | NavMeshTileTool |
+Functions | |
| unsigned int | nextPow2 (unsigned int v) |
| unsigned int | ilog2 (unsigned int v) |
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | Sample_TileMesh |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <stdio.h>#include <ctype.h>#include <string.h>#include <math.h>#include "TestCase.h"#include "DetourNavMesh.h"#include "DetourNavMeshQuery.h"#include "DetourCommon.h"#include "SDL.h"#include "SDL_opengl.h"#include <GL/glu.h>#include "imgui.h"#include "PerfTimer.h"+Functions | |
| static char * | parseRow (char *buf, char *bufEnd, char *row, int len) |
| static void | copyName (std::string &dst, const char *src) |
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | TestCase |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Functions | |
| void | drawGraphBackground (const GraphParams *p) |
| void | drawGraph (const GraphParams *p, const ValueHistory *graph, int idx, const char *label, const unsigned int col) |
| void drawGraph | +( | +const GraphParams * | +p, | +
| + | + | const ValueHistory * | +graph, | +
| + | + | int | +idx, | +
| + | + | const char * | +label, | +
| + | + | const unsigned int | +col | +
| + | ) | ++ |
| void drawGraphBackground | +( | +const GraphParams * | +p | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| class | ValueHistory |
| struct | GraphParams |
+Functions | |
| void | drawGraphBackground (const GraphParams *p) |
| void | drawGraph (const GraphParams *p, const ValueHistory *graph, int idx, const char *label, const unsigned int col) |
| void drawGraph | +( | +const GraphParams * | +p, | +
| + | + | const ValueHistory * | +graph, | +
| + | + | int | +idx, | +
| + | + | const char * | +label, | +
| + | + | const unsigned int | +col | +
| + | ) | ++ |
| void drawGraphBackground | +( | +const GraphParams * | +p | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
| CBoundsItem | |
| CBuildContext | Recast build context |
| CBuildSettings | |
| CBVItem | |
| CConvexVolume | |
| CConvexVolumeTool | |
| CCrowdTool | |
| CCrowdToolParams | |
| CCrowdToolState | |
| CDebugDrawGL | OpenGL debug draw implementation |
| CDirtyEntry | |
| CdtBVNode | Bounding volume node |
| CdtCollectPolysQuery | |
| CdtCompressedTile | |
| CdtCrowd | Provides local steering behaviors for a group of agents |
| CdtCrowdAgent | Represents an agent managed by a dtCrowd object |
| CdtCrowdAgentAnimation | |
| CdtCrowdAgentDebugInfo | |
| CdtCrowdAgentParams | Configuration parameters for a crowd agent |
| CdtCrowdNeighbour | Provides neighbor data for agents managed by the crowd |
| CdtFindNearestPolyQuery | |
| CdtFixedArray | |
| CdtLayerMonotoneRegion | |
| CdtLayerSweepSpan | |
| CdtLink | Defines a link between polygons |
| CdtLocalBoundary | |
| CdtMeshHeader | Provides high level information related to a dtMeshTile object |
| CdtMeshTile | Defines a navigation mesh tile |
| CdtNavMesh | A navigation mesh based on tiles of convex polygons |
| CdtNavMeshCreateParams | Represents the source data used to build an navigation mesh tile |
| CdtNavMeshParams | Configuration parameters used to define multi-tile navigation meshes |
| CdtNavMeshQuery | Provides the ability to perform pathfinding related queries against a navigation mesh |
| CdtNode | |
| CdtNodePool | |
| CdtNodeQueue | |
| CdtObstacleAvoidanceDebugData | |
| CdtObstacleAvoidanceParams | |
| CdtObstacleAvoidanceQuery | |
| CdtObstacleBox | |
| CdtObstacleCircle | |
| CdtObstacleCylinder | |
| CdtObstacleOrientedBox | |
| CdtObstacleSegment | |
| CdtOffMeshConnection | Defines an navigation mesh off-mesh connection within a dtMeshTile object |
| CdtPathCorridor | Represents a dynamic polygon corridor used to plan agent movement |
| CdtPathQueue | |
| CdtPoly | Defines a polygon within a dtMeshTile object |
| CdtPolyDetail | Defines the location of detail sub-mesh data within a dtMeshTile |
| CdtPolyQuery | Provides custom polygon query behavior |
| CdtPolyState | |
| CdtProximityGrid | |
| CdtQueryFilter | Defines polygon filtering and traversal costs for navigation mesh query operations |
| CdtRaycastHit | Provides information about raycast hit filled by dtNavMeshQuery::raycast |
| CdtSegInterval | |
| CdtTempContour | |
| CdtTileCache | |
| CdtTileCacheAlloc | |
| CdtTileCacheCompressor | |
| CdtTileCacheContour | |
| CdtTileCacheContourSet | |
| CdtTileCacheLayer | |
| CdtTileCacheLayerHeader | |
| CdtTileCacheMeshProcess | |
| CdtTileCacheObstacle | |
| CdtTileCacheParams | |
| CdtTileCachePolyMesh | |
| CdtTileState | |
| CduDebugDraw | Abstract debug draw interface |
| CduDisplayList | |
| CduFileIO | |
| CFastLZCompressor | |
| CFileIO | Stdio file implementation |
| CGLCheckerTexture | |
| CGraphParams | |
| CGuiState | |
| CimguiGfxCmd | |
| CimguiGfxLine | |
| CimguiGfxRect | |
| CimguiGfxText | |
| CInputGeom | |
| CLinearAllocator | |
| CMeshProcess | |
| CNavmeshFlags | |
| CNavMeshPruneTool | |
| CNavMeshSetHeader | |
| CNavMeshTesterTool | |
| CNavMeshTileBuildContext | |
| CNavMeshTileHeader | |
| CNavMeshTileTool | |
| COffMeshConnectionTool | |
| CRasterizationContext | |
| CrcChunkyTriMesh | |
| CrcChunkyTriMeshNode | |
| CrcCompactCell | Provides information on the content of a cell column in a compact heightfield |
| CrcCompactHeightfield | A compact, static heightfield representing unobstructed space |
| CrcCompactSpan | Represents a span of unobstructed space within a compact heightfield |
| CrcConfig | Specifies a configuration to use when performing Recast builds |
| CrcContext | Provides an interface for optional logging and performance tracking of the Recast build process |
| CrcContour | Represents a simple, non-overlapping contour in field space |
| CrcContourHole | |
| CrcContourRegion | |
| CrcContourSet | Represents a group of related contours |
| CrcEdge | |
| CrcHeightfield | A dynamic heightfield representing obstructed space |
| CrcHeightfieldLayer | Represents a heightfield layer within a layer set |
| CrcHeightfieldLayerSet | Represents a set of heightfield layers |
| CrcHeightPatch | |
| CrcIntArray | Legacy class. Prefer rcVector<int> |
| CrcLayerRegion | |
| CrcLayerSweepSpan | |
| CrcMeshLoaderObj | |
| CrcNewTag | An implementation of operator new usable for placement new |
| CrcPermVector | |
| CrcPolyMesh | Represents a polygon mesh suitable for use in building a navigation mesh |
| CrcPolyMeshDetail | Contains triangle meshes that represent detailed height data associated with the polygons in its associated polygon mesh object |
| CrcPotentialDiagonal | |
| CrcRegion | |
| CrcScopedDelete | A simple helper class used to delete an array when it goes out of scope |
| CrcScopedTimer | A helper to first start a timer and then stop it when this helper goes out of scope |
| CrcSpan | Represents a span in a heightfield |
| CrcSpanPool | A memory pool used for quick allocation of spans within a heightfield |
| CrcSweepSpan | |
| CrcTempVector | |
| CrcVectorBase | Variable-sized storage type |
| CSample | |
| CSample_Debug | Sample used for random debugging |
| CSample_SoloMesh | |
| CSample_TempObstacles | |
| CSample_TileMesh | |
| CSampleDebugDraw | |
| CSampleItem | |
| CSampleTool | |
| CSampleToolState | |
| CTempObstacleCreateTool | |
| CTempObstacleHilightTool | |
| CTestCase | |
| CTileCacheData | |
| CTileCacheSetHeader | |
| CTileCacheTileHeader | |
| CValueHistory |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for BuildContext, including all inherited members.
+| BuildContext() | BuildContext | |
| doGetAccumulatedTime(const rcTimerLabel label) const | BuildContext | protectedvirtual |
| doLog(const rcLogCategory category, const char *msg, const int len) | BuildContext | protectedvirtual |
| doResetLog() | BuildContext | protectedvirtual |
| doResetTimers() | BuildContext | protectedvirtual |
| doStartTimer(const rcTimerLabel label) | BuildContext | protectedvirtual |
| doStopTimer(const rcTimerLabel label) | BuildContext | protectedvirtual |
| dumpLog(const char *format,...) | BuildContext | |
| enableLog(bool state) | rcContext | inline |
| enableTimer(bool state) | rcContext | inline |
| getAccumulatedTime(const rcTimerLabel label) const | rcContext | inline |
| getLogCount() const | BuildContext | |
| getLogText(const int i) const | BuildContext | |
| log(const rcLogCategory category, const char *format,...) | rcContext | |
| m_logEnabled | rcContext | protected |
| m_timerEnabled | rcContext | protected |
| rcContext(bool state=true) | rcContext | inline |
| resetLog() | rcContext | inline |
| resetTimers() | rcContext | inline |
| startTimer(const rcTimerLabel label) | rcContext | inline |
| stopTimer(const rcTimerLabel label) | rcContext | inline |
| ~rcContext() | rcContext | inlinevirtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Recast build context. + More...
+ +#include <SampleInterfaces.h>
+
++Public Member Functions | |
| BuildContext () | |
| void | dumpLog (const char *format,...) |
| Dumps the log to stdout. More... | |
| int | getLogCount () const |
| Returns number of log messages. More... | |
| const char * | getLogText (const int i) const |
| Returns log message text. More... | |
Public Member Functions inherited from rcContext | |
| rcContext (bool state=true) | |
| Constructor. More... | |
| virtual | ~rcContext () |
| void | enableLog (bool state) |
| Enables or disables logging. More... | |
| void | resetLog () |
| Clears all log entries. More... | |
| void | log (const rcLogCategory category, const char *format,...) |
| Logs a message. More... | |
| void | enableTimer (bool state) |
| Enables or disables the performance timers. More... | |
| void | resetTimers () |
| Clears all performance timers. (Resets all to unused.) More... | |
| void | startTimer (const rcTimerLabel label) |
| Starts the specified performance timer. More... | |
| void | stopTimer (const rcTimerLabel label) |
| Stops the specified performance timer. More... | |
| int | getAccumulatedTime (const rcTimerLabel label) const |
| Returns the total accumulated time of the specified performance timer. More... | |
+Protected Member Functions | |
| virtual void | doResetLog () |
| Virtual functions for custom implementations. More... | |
| virtual void | doLog (const rcLogCategory category, const char *msg, const int len) |
| Logs a message. More... | |
| virtual void | doResetTimers () |
| Clears all timers. (Resets all to unused.) More... | |
| virtual void | doStartTimer (const rcTimerLabel label) |
| Starts the specified performance timer. More... | |
| virtual void | doStopTimer (const rcTimerLabel label) |
| Stops the specified performance timer. More... | |
| virtual int | doGetAccumulatedTime (const rcTimerLabel label) const |
| Returns the total accumulated time of the specified performance timer. More... | |
+Additional Inherited Members | |
Protected Attributes inherited from rcContext | |
| bool | m_logEnabled |
| True if logging is enabled. More... | |
| bool | m_timerEnabled |
| True if the performance timers are enabled. More... | |
Recast build context.
+| BuildContext::BuildContext | +( | +) | ++ |
+
|
+ +protectedvirtual | +
Returns the total accumulated time of the specified performance timer.
+| [in] | label | The category of the timer. |
Reimplemented from rcContext.
+ +
+
|
+ +protectedvirtual | +
Logs a message.
+| [in] | category | The category of the message. |
| [in] | msg | The formatted message. |
| [in] | len | The length of the formatted message. |
Reimplemented from rcContext.
+ +
+
|
+ +protectedvirtual | +
Virtual functions for custom implementations.
+ +Reimplemented from rcContext.
+ +
+
|
+ +protectedvirtual | +
Clears all timers. (Resets all to unused.)
+ +Reimplemented from rcContext.
+ +
+
|
+ +protectedvirtual | +
Starts the specified performance timer.
+| [in] | label | The category of timer. |
Reimplemented from rcContext.
+ +
+
|
+ +protectedvirtual | +
Stops the specified performance timer.
+| [in] | label | The category of the timer. |
Reimplemented from rcContext.
+ +| void BuildContext::dumpLog | +( | +const char * | +format, | +
| + | + | + | ... | +
| + | ) | ++ |
Dumps the log to stdout.
+ +| int BuildContext::getLogCount | +( | +) | +const | +
Returns number of log messages.
+ +| const char * BuildContext::getLogText | +( | +const int | +i | ) | +const | +
Returns log message text.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for ConvexVolumeTool, including all inherited members.
+| ConvexVolumeTool() | ConvexVolumeTool | |
| handleClick(const float *s, const float *p, bool shift) | ConvexVolumeTool | virtual |
| handleMenu() | ConvexVolumeTool | virtual |
| handleRender() | ConvexVolumeTool | virtual |
| handleRenderOverlay(double *proj, double *model, int *view) | ConvexVolumeTool | virtual |
| handleStep() | ConvexVolumeTool | virtual |
| handleToggle() | ConvexVolumeTool | virtual |
| handleUpdate(const float dt) | ConvexVolumeTool | virtual |
| init(Sample *sample) | ConvexVolumeTool | virtual |
| reset() | ConvexVolumeTool | virtual |
| type() | ConvexVolumeTool | inlinevirtual |
| ~SampleTool() | SampleTool | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <ConvexVolumeTool.h>
+
++Public Member Functions | |
| ConvexVolumeTool () | |
| virtual int | type () |
| virtual void | init (Sample *sample) |
| virtual void | reset () |
| virtual void | handleMenu () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float dt) |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
Public Member Functions inherited from SampleTool | |
| virtual | ~SampleTool () |
| ConvexVolumeTool::ConvexVolumeTool | +( | +) | ++ |
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for CrowdTool, including all inherited members.
+| CrowdTool() | CrowdTool | |
| handleClick(const float *s, const float *p, bool shift) | CrowdTool | virtual |
| handleMenu() | CrowdTool | virtual |
| handleRender() | CrowdTool | virtual |
| handleRenderOverlay(double *proj, double *model, int *view) | CrowdTool | virtual |
| handleStep() | CrowdTool | virtual |
| handleToggle() | CrowdTool | virtual |
| handleUpdate(const float dt) | CrowdTool | virtual |
| init(Sample *sample) | CrowdTool | virtual |
| reset() | CrowdTool | virtual |
| type() | CrowdTool | inlinevirtual |
| ~SampleTool() | SampleTool | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <CrowdTool.h>
+
++Public Member Functions | |
| CrowdTool () | |
| virtual int | type () |
| virtual void | init (Sample *sample) |
| virtual void | reset () |
| virtual void | handleMenu () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float dt) |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
Public Member Functions inherited from SampleTool | |
| virtual | ~SampleTool () |
| CrowdTool::CrowdTool | +( | +) | ++ |
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for CrowdToolState, including all inherited members.
+| addAgent(const float *pos) | CrowdToolState | |
| CrowdToolState() | CrowdToolState | |
| getToolParams() | CrowdToolState | inline |
| handleRender() | CrowdToolState | virtual |
| handleRenderOverlay(double *proj, double *model, int *view) | CrowdToolState | virtual |
| handleUpdate(const float dt) | CrowdToolState | virtual |
| hilightAgent(const int idx) | CrowdToolState | |
| hitTestAgents(const float *s, const float *p) | CrowdToolState | |
| init(class Sample *sample) | CrowdToolState | virtual |
| isRunning() const | CrowdToolState | inline |
| removeAgent(const int idx) | CrowdToolState | |
| reset() | CrowdToolState | virtual |
| setMoveTarget(const float *p, bool adjust) | CrowdToolState | |
| setRunning(const bool s) | CrowdToolState | inline |
| updateAgentParams() | CrowdToolState | |
| updateTick(const float dt) | CrowdToolState | |
| ~CrowdToolState() | CrowdToolState | virtual |
| ~SampleToolState() | SampleToolState | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <CrowdTool.h>
+
++Public Member Functions | |
| CrowdToolState () | |
| virtual | ~CrowdToolState () |
| virtual void | init (class Sample *sample) |
| virtual void | reset () |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
| virtual void | handleUpdate (const float dt) |
| bool | isRunning () const |
| void | setRunning (const bool s) |
| void | addAgent (const float *pos) |
| void | removeAgent (const int idx) |
| void | hilightAgent (const int idx) |
| void | updateAgentParams () |
| int | hitTestAgents (const float *s, const float *p) |
| void | setMoveTarget (const float *p, bool adjust) |
| void | updateTick (const float dt) |
| CrowdToolParams * | getToolParams () |
Public Member Functions inherited from SampleToolState | |
| virtual | ~SampleToolState () |
| CrowdToolState::CrowdToolState | +( | +) | ++ |
+
|
+ +virtual | +
| void CrowdToolState::addAgent | +( | +const float * | +pos | ) | ++ |
+
|
+ +inline | +
+
|
+ +virtual | +
Implements SampleToolState.
+ +
+
|
+ +virtual | +
Implements SampleToolState.
+ +
+
|
+ +virtual | +
Implements SampleToolState.
+ +| void CrowdToolState::hilightAgent | +( | +const int | +idx | ) | ++ |
| int CrowdToolState::hitTestAgents | +( | +const float * | +s, | +
| + | + | const float * | +p | +
| + | ) | ++ |
+
|
+ +virtual | +
Implements SampleToolState.
+ +
+
|
+ +inline | +
| void CrowdToolState::removeAgent | +( | +const int | +idx | ) | ++ |
+
|
+ +virtual | +
Implements SampleToolState.
+ +| void CrowdToolState::setMoveTarget | +( | +const float * | +p, | +
| + | + | bool | +adjust | +
| + | ) | ++ |
+
|
+ +inline | +
| void CrowdToolState::updateAgentParams | +( | +) | ++ |
| void CrowdToolState::updateTick | +( | +const float | +dt | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for DebugDrawGL, including all inherited members.
+| areaToCol(unsigned int area) | duDebugDraw | virtual |
| begin(duDebugDrawPrimitives prim, float size=1.0f) | DebugDrawGL | virtual |
| depthMask(bool state) | DebugDrawGL | virtual |
| end() | DebugDrawGL | virtual |
| texture(bool state) | DebugDrawGL | virtual |
| vertex(const float *pos, unsigned int color) | DebugDrawGL | virtual |
| vertex(const float x, const float y, const float z, unsigned int color) | DebugDrawGL | virtual |
| vertex(const float *pos, unsigned int color, const float *uv) | DebugDrawGL | virtual |
| vertex(const float x, const float y, const float z, unsigned int color, const float u, const float v) | DebugDrawGL | virtual |
| ~duDebugDraw()=0 | duDebugDraw | pure virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
OpenGL debug draw implementation. + More...
+ +#include <SampleInterfaces.h>
+
++Public Member Functions | |
| virtual void | depthMask (bool state) |
| virtual void | texture (bool state) |
| virtual void | begin (duDebugDrawPrimitives prim, float size=1.0f) |
| Begin drawing primitives. More... | |
| virtual void | vertex (const float *pos, unsigned int color) |
| Submit a vertex. More... | |
| virtual void | vertex (const float x, const float y, const float z, unsigned int color) |
| Submit a vertex. More... | |
| virtual void | vertex (const float *pos, unsigned int color, const float *uv) |
| Submit a vertex. More... | |
| virtual void | vertex (const float x, const float y, const float z, unsigned int color, const float u, const float v) |
| Submit a vertex. More... | |
| virtual void | end () |
| End drawing primitives. More... | |
Public Member Functions inherited from duDebugDraw | |
| virtual | ~duDebugDraw ()=0 |
| virtual unsigned int | areaToCol (unsigned int area) |
| Compute a color for given area. More... | |
OpenGL debug draw implementation.
+
+
|
+ +virtual | +
Begin drawing primitives.
+| prim | [in] primitive type to draw, one of rcDebugDrawPrimitives. |
| size | [in] size of a primitive, applies to point size and line width only. |
Implements duDebugDraw.
+ +
+
|
+ +virtual | +
Implements duDebugDraw.
+ +
+
|
+ +virtual | +
End drawing primitives.
+ +Implements duDebugDraw.
+ +
+
|
+ +virtual | +
Implements duDebugDraw.
+ +
+
|
+ +virtual | +
Submit a vertex.
+| pos | [in] position of the verts. |
| color | [in] color of the verts. |
Implements duDebugDraw.
+ +
+
|
+ +virtual | +
Submit a vertex.
+| pos | [in] position of the verts. |
| color | [in] color of the verts. |
| uv | [in] the uv coordinates of the verts. |
Implements duDebugDraw.
+ +
+
|
+ +virtual | +
Submit a vertex.
+| x,y,z | [in] position of the verts. |
| color | [in] color of the verts. |
Implements duDebugDraw.
+ +
+
|
+ +virtual | +
Submit a vertex.
+| x,y,z | [in] position of the verts. |
| color | [in] color of the verts. |
| u,v | [in] the uv coordinates of the verts. |
Implements duDebugDraw.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for FileIO, including all inherited members.
+| FileIO() | FileIO | |
| isReading() const | FileIO | virtual |
| isWriting() const | FileIO | virtual |
| openForRead(const char *path) | FileIO | |
| openForWrite(const char *path) | FileIO | |
| read(void *ptr, const size_t size) | FileIO | virtual |
| write(const void *ptr, const size_t size) | FileIO | virtual |
| ~duFileIO() | duFileIO | virtual |
| ~FileIO() | FileIO | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
stdio file implementation. + More...
+ +#include <SampleInterfaces.h>
+
++Public Member Functions | |
| FileIO () | |
| virtual | ~FileIO () |
| bool | openForWrite (const char *path) |
| bool | openForRead (const char *path) |
| virtual bool | isWriting () const |
| virtual bool | isReading () const |
| virtual bool | write (const void *ptr, const size_t size) |
| virtual bool | read (void *ptr, const size_t size) |
Public Member Functions inherited from duFileIO | |
| virtual | ~duFileIO () |
stdio file implementation.
+| FileIO::FileIO | +( | +) | ++ |
+
|
+ +virtual | +
+
|
+ +virtual | +
Implements duFileIO.
+ +
+
|
+ +virtual | +
Implements duFileIO.
+ +| bool FileIO::openForRead | +( | +const char * | +path | ) | ++ |
| bool FileIO::openForWrite | +( | +const char * | +path | ) | ++ |
+
|
+ +virtual | +
Implements duFileIO.
+ +
+
|
+ +virtual | +
Implements duFileIO.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for GLCheckerTexture, including all inherited members.
+| bind() | GLCheckerTexture | inline |
| GLCheckerTexture() | GLCheckerTexture | inline |
| ~GLCheckerTexture() | GLCheckerTexture | inline |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Public Member Functions | |
| GLCheckerTexture () | |
| ~GLCheckerTexture () | |
| void | bind () |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for InputGeom, including all inherited members.
+| addConvexVolume(const float *verts, const int nverts, const float minh, const float maxh, unsigned char area) | InputGeom | |
| addOffMeshConnection(const float *spos, const float *epos, const float rad, unsigned char bidir, unsigned char area, unsigned short flags) | InputGeom | |
| deleteConvexVolume(int i) | InputGeom | |
| deleteOffMeshConnection(int i) | InputGeom | |
| drawConvexVolumes(struct duDebugDraw *dd, bool hilight=false) | InputGeom | |
| drawOffMeshConnections(struct duDebugDraw *dd, bool hilight=false) | InputGeom | |
| getBuildSettings() const | InputGeom | inline |
| getChunkyMesh() const | InputGeom | inline |
| getConvexVolumeCount() const | InputGeom | inline |
| getConvexVolumes() const | InputGeom | inline |
| getMesh() const | InputGeom | inline |
| getMeshBoundsMax() const | InputGeom | inline |
| getMeshBoundsMin() const | InputGeom | inline |
| getNavMeshBoundsMax() const | InputGeom | inline |
| getNavMeshBoundsMin() const | InputGeom | inline |
| getOffMeshConnectionAreas() const | InputGeom | inline |
| getOffMeshConnectionCount() const | InputGeom | inline |
| getOffMeshConnectionDirs() const | InputGeom | inline |
| getOffMeshConnectionFlags() const | InputGeom | inline |
| getOffMeshConnectionId() const | InputGeom | inline |
| getOffMeshConnectionRads() const | InputGeom | inline |
| getOffMeshConnectionVerts() const | InputGeom | inline |
| InputGeom() | InputGeom | |
| load(class rcContext *ctx, const std::string &filepath) | InputGeom | |
| raycastMesh(float *src, float *dst, float &tmin) | InputGeom | |
| saveGeomSet(const BuildSettings *settings) | InputGeom | |
| ~InputGeom() | InputGeom |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <InputGeom.h>
+Public Member Functions | |
| InputGeom () | |
| ~InputGeom () | |
| bool | load (class rcContext *ctx, const std::string &filepath) |
| bool | saveGeomSet (const BuildSettings *settings) |
| const rcMeshLoaderObj * | getMesh () const |
| Method to return static mesh data. More... | |
| const float * | getMeshBoundsMin () const |
| const float * | getMeshBoundsMax () const |
| const float * | getNavMeshBoundsMin () const |
| const float * | getNavMeshBoundsMax () const |
| const rcChunkyTriMesh * | getChunkyMesh () const |
| const BuildSettings * | getBuildSettings () const |
| bool | raycastMesh (float *src, float *dst, float &tmin) |
Box Volumes. | |
| int | getConvexVolumeCount () const |
| const ConvexVolume * | getConvexVolumes () const |
| void | addConvexVolume (const float *verts, const int nverts, const float minh, const float maxh, unsigned char area) |
| void | deleteConvexVolume (int i) |
| void | drawConvexVolumes (struct duDebugDraw *dd, bool hilight=false) |
Off-Mesh connections. | |
| int | getOffMeshConnectionCount () const |
| const float * | getOffMeshConnectionVerts () const |
| const float * | getOffMeshConnectionRads () const |
| const unsigned char * | getOffMeshConnectionDirs () const |
| const unsigned char * | getOffMeshConnectionAreas () const |
| const unsigned short * | getOffMeshConnectionFlags () const |
| const unsigned int * | getOffMeshConnectionId () const |
| void | addOffMeshConnection (const float *spos, const float *epos, const float rad, unsigned char bidir, unsigned char area, unsigned short flags) |
| void | deleteOffMeshConnection (int i) |
| void | drawOffMeshConnections (struct duDebugDraw *dd, bool hilight=false) |
| InputGeom::InputGeom | +( | +) | ++ |
| InputGeom::~InputGeom | +( | +) | ++ |
| void InputGeom::addConvexVolume | +( | +const float * | +verts, | +
| + | + | const int | +nverts, | +
| + | + | const float | +minh, | +
| + | + | const float | +maxh, | +
| + | + | unsigned char | +area | +
| + | ) | ++ |
| void InputGeom::addOffMeshConnection | +( | +const float * | +spos, | +
| + | + | const float * | +epos, | +
| + | + | const float | +rad, | +
| + | + | unsigned char | +bidir, | +
| + | + | unsigned char | +area, | +
| + | + | unsigned short | +flags | +
| + | ) | ++ |
| void InputGeom::deleteConvexVolume | +( | +int | +i | ) | ++ |
| void InputGeom::deleteOffMeshConnection | +( | +int | +i | ) | ++ |
| void InputGeom::drawConvexVolumes | +( | +struct duDebugDraw * | +dd, | +
| + | + | bool | +hilight = false |
+
| + | ) | ++ |
| void InputGeom::drawOffMeshConnections | +( | +struct duDebugDraw * | +dd, | +
| + | + | bool | +hilight = false |
+
| + | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
Method to return static mesh data.
+ +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| bool InputGeom::load | +( | +class rcContext * | +ctx, | +
| + | + | const std::string & | +filepath | +
| + | ) | ++ |
| bool InputGeom::raycastMesh | +( | +float * | +src, | +
| + | + | float * | +dst, | +
| + | + | float & | +tmin | +
| + | ) | ++ |
| bool InputGeom::saveGeomSet | +( | +const BuildSettings * | +settings | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for NavMeshPruneTool, including all inherited members.
+| handleClick(const float *s, const float *p, bool shift) | NavMeshPruneTool | virtual |
| handleMenu() | NavMeshPruneTool | virtual |
| handleRender() | NavMeshPruneTool | virtual |
| handleRenderOverlay(double *proj, double *model, int *view) | NavMeshPruneTool | virtual |
| handleStep() | NavMeshPruneTool | virtual |
| handleToggle() | NavMeshPruneTool | virtual |
| handleUpdate(const float dt) | NavMeshPruneTool | virtual |
| init(Sample *sample) | NavMeshPruneTool | virtual |
| NavMeshPruneTool() | NavMeshPruneTool | |
| reset() | NavMeshPruneTool | virtual |
| type() | NavMeshPruneTool | inlinevirtual |
| ~NavMeshPruneTool() | NavMeshPruneTool | virtual |
| ~SampleTool() | SampleTool | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <NavMeshPruneTool.h>
+
++Public Member Functions | |
| NavMeshPruneTool () | |
| virtual | ~NavMeshPruneTool () |
| virtual int | type () |
| virtual void | init (Sample *sample) |
| virtual void | reset () |
| virtual void | handleMenu () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float dt) |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
Public Member Functions inherited from SampleTool | |
| virtual | ~SampleTool () |
| NavMeshPruneTool::NavMeshPruneTool | +( | +) | ++ |
+
|
+ +virtual | +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for NavMeshTesterTool, including all inherited members.
+| drawAgent(const float *pos, float r, float h, float c, const unsigned int col) | NavMeshTesterTool | |
| handleClick(const float *s, const float *p, bool shift) | NavMeshTesterTool | virtual |
| handleMenu() | NavMeshTesterTool | virtual |
| handleRender() | NavMeshTesterTool | virtual |
| handleRenderOverlay(double *proj, double *model, int *view) | NavMeshTesterTool | virtual |
| handleStep() | NavMeshTesterTool | virtual |
| handleToggle() | NavMeshTesterTool | virtual |
| handleUpdate(const float dt) | NavMeshTesterTool | virtual |
| init(Sample *sample) | NavMeshTesterTool | virtual |
| NavMeshTesterTool() | NavMeshTesterTool | |
| recalc() | NavMeshTesterTool | |
| reset() | NavMeshTesterTool | virtual |
| type() | NavMeshTesterTool | inlinevirtual |
| ~SampleTool() | SampleTool | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <NavMeshTesterTool.h>
+
++Public Member Functions | |
| NavMeshTesterTool () | |
| virtual int | type () |
| virtual void | init (Sample *sample) |
| virtual void | reset () |
| virtual void | handleMenu () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float dt) |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
| void | recalc () |
| void | drawAgent (const float *pos, float r, float h, float c, const unsigned int col) |
Public Member Functions inherited from SampleTool | |
| virtual | ~SampleTool () |
| NavMeshTesterTool::NavMeshTesterTool | +( | +) | ++ |
| void NavMeshTesterTool::drawAgent | +( | +const float * | +pos, | +
| + | + | float | +r, | +
| + | + | float | +h, | +
| + | + | float | +c, | +
| + | + | const unsigned int | +col | +
| + | ) | ++ |
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +| void NavMeshTesterTool::recalc | +( | +) | ++ |
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for NavMeshTileTool, including all inherited members.
+| handleClick(const float *, const float *p, bool shift) | NavMeshTileTool | inlinevirtual |
| handleMenu() | NavMeshTileTool | inlinevirtual |
| handleRender() | NavMeshTileTool | inlinevirtual |
| handleRenderOverlay(double *proj, double *model, int *view) | NavMeshTileTool | inlinevirtual |
| handleStep() | NavMeshTileTool | inlinevirtual |
| handleToggle() | NavMeshTileTool | inlinevirtual |
| handleUpdate(const float) | NavMeshTileTool | inlinevirtual |
| init(Sample *sample) | NavMeshTileTool | inlinevirtual |
| NavMeshTileTool() | NavMeshTileTool | inline |
| reset() | NavMeshTileTool | inlinevirtual |
| type() | NavMeshTileTool | inlinevirtual |
| ~NavMeshTileTool() | NavMeshTileTool | virtual |
| ~SampleTool() | SampleTool | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+
++Public Member Functions | |
| NavMeshTileTool () | |
| virtual | ~NavMeshTileTool () |
| virtual int | type () |
| virtual void | init (Sample *sample) |
| virtual void | reset () |
| virtual void | handleMenu () |
| virtual void | handleClick (const float *, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float) |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
Public Member Functions inherited from SampleTool | |
| virtual | ~SampleTool () |
+
|
+ +inline | +
+
|
+ +virtual | +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for NavmeshFlags, including all inherited members.
+| clearAllFlags() | NavmeshFlags | inline |
| getFlags(dtPolyRef ref) | NavmeshFlags | inline |
| init(const dtNavMesh *nav) | NavmeshFlags | inline |
| NavmeshFlags() | NavmeshFlags | inline |
| setFlags(dtPolyRef ref, unsigned char flags) | NavmeshFlags | inline |
| ~NavmeshFlags() | NavmeshFlags | inline |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Public Member Functions | |
| NavmeshFlags () | |
| ~NavmeshFlags () | |
| bool | init (const dtNavMesh *nav) |
| void | clearAllFlags () |
| unsigned char | getFlags (dtPolyRef ref) |
| void | setFlags (dtPolyRef ref, unsigned char flags) |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for OffMeshConnectionTool, including all inherited members.
+| handleClick(const float *s, const float *p, bool shift) | OffMeshConnectionTool | virtual |
| handleMenu() | OffMeshConnectionTool | virtual |
| handleRender() | OffMeshConnectionTool | virtual |
| handleRenderOverlay(double *proj, double *model, int *view) | OffMeshConnectionTool | virtual |
| handleStep() | OffMeshConnectionTool | virtual |
| handleToggle() | OffMeshConnectionTool | virtual |
| handleUpdate(const float dt) | OffMeshConnectionTool | virtual |
| init(Sample *sample) | OffMeshConnectionTool | virtual |
| OffMeshConnectionTool() | OffMeshConnectionTool | |
| reset() | OffMeshConnectionTool | virtual |
| type() | OffMeshConnectionTool | inlinevirtual |
| ~OffMeshConnectionTool() | OffMeshConnectionTool | |
| ~SampleTool() | SampleTool | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <OffMeshConnectionTool.h>
+
++Public Member Functions | |
| OffMeshConnectionTool () | |
| ~OffMeshConnectionTool () | |
| virtual int | type () |
| virtual void | init (Sample *sample) |
| virtual void | reset () |
| virtual void | handleMenu () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float dt) |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
Public Member Functions inherited from SampleTool | |
| virtual | ~SampleTool () |
| OffMeshConnectionTool::OffMeshConnectionTool | +( | +) | ++ |
| OffMeshConnectionTool::~OffMeshConnectionTool | +( | +) | ++ |
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +virtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for Sample, including all inherited members.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <Sample.h>
+
++Public Member Functions | |
| Sample () | |
| virtual | ~Sample () |
| void | setContext (BuildContext *ctx) |
| void | setTool (SampleTool *tool) |
| SampleToolState * | getToolState (int type) |
| void | setToolState (int type, SampleToolState *s) |
| SampleDebugDraw & | getDebugDraw () |
| virtual void | handleSettings () |
| virtual void | handleTools () |
| virtual void | handleDebugMode () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
| virtual void | handleMeshChanged (class InputGeom *geom) |
| virtual bool | handleBuild () |
| virtual void | handleUpdate (const float dt) |
| virtual void | collectSettings (struct BuildSettings &settings) |
| virtual class InputGeom * | getInputGeom () |
| virtual class dtNavMesh * | getNavMesh () |
| virtual class dtNavMeshQuery * | getNavMeshQuery () |
| virtual class dtCrowd * | getCrowd () |
| virtual float | getAgentRadius () |
| virtual float | getAgentHeight () |
| virtual float | getAgentClimb () |
| unsigned char | getNavMeshDrawFlags () const |
| void | setNavMeshDrawFlags (unsigned char flags) |
| void | updateToolStates (const float dt) |
| void | initToolStates (Sample *sample) |
| void | resetToolStates () |
| void | renderToolStates () |
| void | renderOverlayToolStates (double *proj, double *model, int *view) |
| void | resetCommonSettings () |
| void | handleCommonSettings () |
+Protected Member Functions | |
| dtNavMesh * | loadAll (const char *path) |
| void | saveAll (const char *path, const dtNavMesh *mesh) |
+Protected Attributes | |
| class InputGeom * | m_geom |
| class dtNavMesh * | m_navMesh |
| class dtNavMeshQuery * | m_navQuery |
| class dtCrowd * | m_crowd |
| unsigned char | m_navMeshDrawFlags |
| float | m_cellSize |
| float | m_cellHeight |
| float | m_agentHeight |
| float | m_agentRadius |
| float | m_agentMaxClimb |
| float | m_agentMaxSlope |
| float | m_regionMinSize |
| float | m_regionMergeSize |
| float | m_edgeMaxLen |
| float | m_edgeMaxError |
| float | m_vertsPerPoly |
| float | m_detailSampleDist |
| float | m_detailSampleMaxError |
| int | m_partitionType |
| bool | m_filterLowHangingObstacles |
| bool | m_filterLedgeSpans |
| bool | m_filterWalkableLowHeightSpans |
| SampleTool * | m_tool |
| SampleToolState * | m_toolStates [MAX_TOOLS] |
| BuildContext * | m_ctx |
| SampleDebugDraw | m_dd |
| Sample::Sample | +( | +) | ++ |
+
|
+ +virtual | +
+
|
+ +virtual | +
Reimplemented in Sample_TileMesh.
+ +
+
|
+ +inlinevirtual | +
+
|
+ +inlinevirtual | +
+
|
+ +inlinevirtual | +
+
|
+ +inlinevirtual | +
+
|
+ +inline | +
+
|
+ +inlinevirtual | +
+
|
+ +inlinevirtual | +
+
|
+ +inline | +
+
|
+ +inlinevirtual | +
+
|
+ +inline | +
+
|
+ +virtual | +
Reimplemented in Sample_TileMesh, Sample_TempObstacles, Sample_SoloMesh, and Sample_Debug.
+ +
+
|
+ +virtual | +
Reimplemented in Sample_Debug.
+ +| void Sample::handleCommonSettings | +( | +) | ++ |
+
|
+ +virtual | +
Reimplemented in Sample_TileMesh, Sample_TempObstacles, Sample_SoloMesh, and Sample_Debug.
+ +
+
|
+ +virtual | +
Reimplemented in Sample_TileMesh, Sample_TempObstacles, Sample_SoloMesh, and Sample_Debug.
+ +
+
|
+ +virtual | +
Reimplemented in Sample_TileMesh, Sample_TempObstacles, Sample_SoloMesh, and Sample_Debug.
+ +
+
|
+ +virtual | +
Reimplemented in Sample_TileMesh, Sample_TempObstacles, Sample_SoloMesh, and Sample_Debug.
+ +
+
|
+ +virtual | +
Reimplemented in Sample_TileMesh, Sample_TempObstacles, Sample_SoloMesh, and Sample_Debug.
+ +
+
|
+ +virtual | +
+
|
+ +virtual | +
Reimplemented in Sample_Debug.
+ +
+
|
+ +virtual | +
Reimplemented in Sample_TileMesh, Sample_TempObstacles, Sample_SoloMesh, and Sample_Debug.
+ +
+
|
+ +virtual | +
Reimplemented in Sample_TempObstacles.
+ +| void Sample::initToolStates | +( | +Sample * | +sample | ) | ++ |
+
|
+ +protected | +
| void Sample::renderOverlayToolStates | +( | +double * | +proj, | +
| + | + | double * | +model, | +
| + | + | int * | +view | +
| + | ) | ++ |
| void Sample::renderToolStates | +( | +) | ++ |
| void Sample::resetCommonSettings | +( | +) | ++ |
| void Sample::resetToolStates | +( | +) | ++ |
+
|
+ +protected | +
+
|
+ +inline | +
+
|
+ +inline | +
| void Sample::setTool | +( | +SampleTool * | +tool | ) | ++ |
+
|
+ +inline | +
| void Sample::updateToolStates | +( | +const float | +dt | ) | ++ |
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for SampleDebugDraw, including all inherited members.
+| areaToCol(unsigned int area) | SampleDebugDraw | virtual |
| begin(duDebugDrawPrimitives prim, float size=1.0f) | DebugDrawGL | virtual |
| depthMask(bool state) | DebugDrawGL | virtual |
| end() | DebugDrawGL | virtual |
| texture(bool state) | DebugDrawGL | virtual |
| vertex(const float *pos, unsigned int color) | DebugDrawGL | virtual |
| vertex(const float x, const float y, const float z, unsigned int color) | DebugDrawGL | virtual |
| vertex(const float *pos, unsigned int color, const float *uv) | DebugDrawGL | virtual |
| vertex(const float x, const float y, const float z, unsigned int color, const float u, const float v) | DebugDrawGL | virtual |
| ~duDebugDraw()=0 | duDebugDraw | pure virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <Sample.h>
+
++Public Member Functions | |
| virtual unsigned int | areaToCol (unsigned int area) |
| Compute a color for given area. More... | |
Public Member Functions inherited from DebugDrawGL | |
| virtual void | depthMask (bool state) |
| virtual void | texture (bool state) |
| virtual void | begin (duDebugDrawPrimitives prim, float size=1.0f) |
| Begin drawing primitives. More... | |
| virtual void | vertex (const float *pos, unsigned int color) |
| Submit a vertex. More... | |
| virtual void | vertex (const float x, const float y, const float z, unsigned int color) |
| Submit a vertex. More... | |
| virtual void | vertex (const float *pos, unsigned int color, const float *uv) |
| Submit a vertex. More... | |
| virtual void | vertex (const float x, const float y, const float z, unsigned int color, const float u, const float v) |
| Submit a vertex. More... | |
| virtual void | end () |
| End drawing primitives. More... | |
Public Member Functions inherited from duDebugDraw | |
| virtual | ~duDebugDraw ()=0 |
+
|
+ +virtual | +
Compute a color for given area.
+ +Reimplemented from duDebugDraw.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for Sample_Debug, including all inherited members.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Sample used for random debugging. + More...
+ +#include <Sample_Debug.h>
+
++Public Member Functions | |
| Sample_Debug () | |
| virtual | ~Sample_Debug () |
| virtual void | handleSettings () |
| virtual void | handleTools () |
| virtual void | handleDebugMode () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
| virtual void | handleMeshChanged (class InputGeom *geom) |
| virtual bool | handleBuild () |
| virtual const float * | getBoundsMin () |
| virtual const float * | getBoundsMax () |
Public Member Functions inherited from Sample | |
| Sample () | |
| virtual | ~Sample () |
| void | setContext (BuildContext *ctx) |
| void | setTool (SampleTool *tool) |
| SampleToolState * | getToolState (int type) |
| void | setToolState (int type, SampleToolState *s) |
| SampleDebugDraw & | getDebugDraw () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float dt) |
| virtual void | collectSettings (struct BuildSettings &settings) |
| virtual class InputGeom * | getInputGeom () |
| virtual class dtNavMesh * | getNavMesh () |
| virtual class dtNavMeshQuery * | getNavMeshQuery () |
| virtual class dtCrowd * | getCrowd () |
| virtual float | getAgentRadius () |
| virtual float | getAgentHeight () |
| virtual float | getAgentClimb () |
| unsigned char | getNavMeshDrawFlags () const |
| void | setNavMeshDrawFlags (unsigned char flags) |
| void | updateToolStates (const float dt) |
| void | initToolStates (Sample *sample) |
| void | resetToolStates () |
| void | renderToolStates () |
| void | renderOverlayToolStates (double *proj, double *model, int *view) |
| void | resetCommonSettings () |
| void | handleCommonSettings () |
+Protected Attributes | |
| rcCompactHeightfield * | m_chf |
| rcContourSet * | m_cset |
| rcPolyMesh * | m_pmesh |
| float | m_halfExtents [3] |
| float | m_center [3] |
| float | m_bmin [3] |
| float | m_bmax [3] |
| dtPolyRef | m_ref |
Protected Attributes inherited from Sample | |
| class InputGeom * | m_geom |
| class dtNavMesh * | m_navMesh |
| class dtNavMeshQuery * | m_navQuery |
| class dtCrowd * | m_crowd |
| unsigned char | m_navMeshDrawFlags |
| float | m_cellSize |
| float | m_cellHeight |
| float | m_agentHeight |
| float | m_agentRadius |
| float | m_agentMaxClimb |
| float | m_agentMaxSlope |
| float | m_regionMinSize |
| float | m_regionMergeSize |
| float | m_edgeMaxLen |
| float | m_edgeMaxError |
| float | m_vertsPerPoly |
| float | m_detailSampleDist |
| float | m_detailSampleMaxError |
| int | m_partitionType |
| bool | m_filterLowHangingObstacles |
| bool | m_filterLedgeSpans |
| bool | m_filterWalkableLowHeightSpans |
| SampleTool * | m_tool |
| SampleToolState * | m_toolStates [MAX_TOOLS] |
| BuildContext * | m_ctx |
| SampleDebugDraw | m_dd |
+Additional Inherited Members | |
Protected Member Functions inherited from Sample | |
| dtNavMesh * | loadAll (const char *path) |
| void | saveAll (const char *path, const dtNavMesh *mesh) |
Sample used for random debugging.
+| Sample_Debug::Sample_Debug | +( | +) | ++ |
+
|
+ +virtual | +
+
|
+ +virtual | +
+
|
+ +virtual | +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for Sample_SoloMesh, including all inherited members.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <Sample_SoloMesh.h>
+
++Public Member Functions | |
| Sample_SoloMesh () | |
| virtual | ~Sample_SoloMesh () |
| virtual void | handleSettings () |
| virtual void | handleTools () |
| virtual void | handleDebugMode () |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
| virtual void | handleMeshChanged (class InputGeom *geom) |
| virtual bool | handleBuild () |
Public Member Functions inherited from Sample | |
| Sample () | |
| virtual | ~Sample () |
| void | setContext (BuildContext *ctx) |
| void | setTool (SampleTool *tool) |
| SampleToolState * | getToolState (int type) |
| void | setToolState (int type, SampleToolState *s) |
| SampleDebugDraw & | getDebugDraw () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float dt) |
| virtual void | collectSettings (struct BuildSettings &settings) |
| virtual class InputGeom * | getInputGeom () |
| virtual class dtNavMesh * | getNavMesh () |
| virtual class dtNavMeshQuery * | getNavMeshQuery () |
| virtual class dtCrowd * | getCrowd () |
| virtual float | getAgentRadius () |
| virtual float | getAgentHeight () |
| virtual float | getAgentClimb () |
| unsigned char | getNavMeshDrawFlags () const |
| void | setNavMeshDrawFlags (unsigned char flags) |
| void | updateToolStates (const float dt) |
| void | initToolStates (Sample *sample) |
| void | resetToolStates () |
| void | renderToolStates () |
| void | renderOverlayToolStates (double *proj, double *model, int *view) |
| void | resetCommonSettings () |
| void | handleCommonSettings () |
+Protected Types | |
| enum | DrawMode { + DRAWMODE_NAVMESH +, DRAWMODE_NAVMESH_TRANS +, DRAWMODE_NAVMESH_BVTREE +, DRAWMODE_NAVMESH_NODES +, + DRAWMODE_NAVMESH_INVIS +, DRAWMODE_MESH +, DRAWMODE_VOXELS +, DRAWMODE_VOXELS_WALKABLE +, + DRAWMODE_COMPACT +, DRAWMODE_COMPACT_DISTANCE +, DRAWMODE_COMPACT_REGIONS +, DRAWMODE_REGION_CONNECTIONS +, + DRAWMODE_RAW_CONTOURS +, DRAWMODE_BOTH_CONTOURS +, DRAWMODE_CONTOURS +, DRAWMODE_POLYMESH +, + DRAWMODE_POLYMESH_DETAIL +, MAX_DRAWMODE + + } |
+Protected Member Functions | |
| void | cleanup () |
Protected Member Functions inherited from Sample | |
| dtNavMesh * | loadAll (const char *path) |
| void | saveAll (const char *path, const dtNavMesh *mesh) |
+
|
+ +protected | +
| Sample_SoloMesh::Sample_SoloMesh | +( | +) | ++ |
+
|
+ +virtual | +
+
|
+ +protected | +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for Sample_TempObstacles, including all inherited members.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <Sample_TempObstacles.h>
+
++Public Member Functions | |
| Sample_TempObstacles () | |
| virtual | ~Sample_TempObstacles () |
| virtual void | handleSettings () |
| virtual void | handleTools () |
| virtual void | handleDebugMode () |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
| virtual void | handleMeshChanged (class InputGeom *geom) |
| virtual bool | handleBuild () |
| virtual void | handleUpdate (const float dt) |
| void | getTilePos (const float *pos, int &tx, int &ty) |
| void | renderCachedTile (const int tx, const int ty, const int type) |
| void | renderCachedTileOverlay (const int tx, const int ty, double *proj, double *model, int *view) |
| void | addTempObstacle (const float *pos) |
| void | removeTempObstacle (const float *sp, const float *sq) |
| void | clearAllTempObstacles () |
| void | saveAll (const char *path) |
| void | loadAll (const char *path) |
Public Member Functions inherited from Sample | |
| Sample () | |
| virtual | ~Sample () |
| void | setContext (BuildContext *ctx) |
| void | setTool (SampleTool *tool) |
| SampleToolState * | getToolState (int type) |
| void | setToolState (int type, SampleToolState *s) |
| SampleDebugDraw & | getDebugDraw () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | collectSettings (struct BuildSettings &settings) |
| virtual class InputGeom * | getInputGeom () |
| virtual class dtNavMesh * | getNavMesh () |
| virtual class dtNavMeshQuery * | getNavMeshQuery () |
| virtual class dtCrowd * | getCrowd () |
| virtual float | getAgentRadius () |
| virtual float | getAgentHeight () |
| virtual float | getAgentClimb () |
| unsigned char | getNavMeshDrawFlags () const |
| void | setNavMeshDrawFlags (unsigned char flags) |
| void | updateToolStates (const float dt) |
| void | initToolStates (Sample *sample) |
| void | resetToolStates () |
| void | renderToolStates () |
| void | renderOverlayToolStates (double *proj, double *model, int *view) |
| void | resetCommonSettings () |
| void | handleCommonSettings () |
+Protected Types | |
| enum | DrawMode { + DRAWMODE_NAVMESH +, DRAWMODE_NAVMESH_TRANS +, DRAWMODE_NAVMESH_BVTREE +, DRAWMODE_NAVMESH_NODES +, + DRAWMODE_NAVMESH_PORTALS +, DRAWMODE_NAVMESH_INVIS +, DRAWMODE_MESH +, DRAWMODE_CACHE_BOUNDS +, + MAX_DRAWMODE + + } |
+Additional Inherited Members | |
Protected Member Functions inherited from Sample | |
| dtNavMesh * | loadAll (const char *path) |
| void | saveAll (const char *path, const dtNavMesh *mesh) |
+
|
+ +protected | +
| Sample_TempObstacles::Sample_TempObstacles | +( | +) | ++ |
+
|
+ +virtual | +
| void Sample_TempObstacles::addTempObstacle | +( | +const float * | +pos | ) | ++ |
| void Sample_TempObstacles::clearAllTempObstacles | +( | +) | ++ |
| void Sample_TempObstacles::getTilePos | +( | +const float * | +pos, | +
| + | + | int & | +tx, | +
| + | + | int & | +ty | +
| + | ) | ++ |
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +| void Sample_TempObstacles::loadAll | +( | +const char * | +path | ) | ++ |
| void Sample_TempObstacles::removeTempObstacle | +( | +const float * | +sp, | +
| + | + | const float * | +sq | +
| + | ) | ++ |
| void Sample_TempObstacles::renderCachedTile | +( | +const int | +tx, | +
| + | + | const int | +ty, | +
| + | + | const int | +type | +
| + | ) | ++ |
| void Sample_TempObstacles::renderCachedTileOverlay | +( | +const int | +tx, | +
| + | + | const int | +ty, | +
| + | + | double * | +proj, | +
| + | + | double * | +model, | +
| + | + | int * | +view | +
| + | ) | ++ |
| void Sample_TempObstacles::saveAll | +( | +const char * | +path | ) | ++ |
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for Sample_TileMesh, including all inherited members.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <Sample_TileMesh.h>
+
++Public Member Functions | |
| Sample_TileMesh () | |
| virtual | ~Sample_TileMesh () |
| virtual void | handleSettings () |
| virtual void | handleTools () |
| virtual void | handleDebugMode () |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
| virtual void | handleMeshChanged (class InputGeom *geom) |
| virtual bool | handleBuild () |
| virtual void | collectSettings (struct BuildSettings &settings) |
| void | getTilePos (const float *pos, int &tx, int &ty) |
| void | buildTile (const float *pos) |
| void | removeTile (const float *pos) |
| void | buildAllTiles () |
| void | removeAllTiles () |
Public Member Functions inherited from Sample | |
| Sample () | |
| virtual | ~Sample () |
| void | setContext (BuildContext *ctx) |
| void | setTool (SampleTool *tool) |
| SampleToolState * | getToolState (int type) |
| void | setToolState (int type, SampleToolState *s) |
| SampleDebugDraw & | getDebugDraw () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float dt) |
| virtual class InputGeom * | getInputGeom () |
| virtual class dtNavMesh * | getNavMesh () |
| virtual class dtNavMeshQuery * | getNavMeshQuery () |
| virtual class dtCrowd * | getCrowd () |
| virtual float | getAgentRadius () |
| virtual float | getAgentHeight () |
| virtual float | getAgentClimb () |
| unsigned char | getNavMeshDrawFlags () const |
| void | setNavMeshDrawFlags (unsigned char flags) |
| void | updateToolStates (const float dt) |
| void | initToolStates (Sample *sample) |
| void | resetToolStates () |
| void | renderToolStates () |
| void | renderOverlayToolStates (double *proj, double *model, int *view) |
| void | resetCommonSettings () |
| void | handleCommonSettings () |
+Protected Types | |
| enum | DrawMode { + DRAWMODE_NAVMESH +, DRAWMODE_NAVMESH_TRANS +, DRAWMODE_NAVMESH_BVTREE +, DRAWMODE_NAVMESH_NODES +, + DRAWMODE_NAVMESH_PORTALS +, DRAWMODE_NAVMESH_INVIS +, DRAWMODE_MESH +, DRAWMODE_VOXELS +, + DRAWMODE_VOXELS_WALKABLE +, DRAWMODE_COMPACT +, DRAWMODE_COMPACT_DISTANCE +, DRAWMODE_COMPACT_REGIONS +, + DRAWMODE_REGION_CONNECTIONS +, DRAWMODE_RAW_CONTOURS +, DRAWMODE_BOTH_CONTOURS +, DRAWMODE_CONTOURS +, + DRAWMODE_POLYMESH +, DRAWMODE_POLYMESH_DETAIL +, MAX_DRAWMODE + + } |
+Protected Member Functions | |
| unsigned char * | buildTileMesh (const int tx, const int ty, const float *bmin, const float *bmax, int &dataSize) |
| void | cleanup () |
| void | saveAll (const char *path, const dtNavMesh *mesh) |
| dtNavMesh * | loadAll (const char *path) |
Protected Member Functions inherited from Sample | |
| dtNavMesh * | loadAll (const char *path) |
| void | saveAll (const char *path, const dtNavMesh *mesh) |
+
|
+ +protected | +
| Sample_TileMesh::Sample_TileMesh | +( | +) | ++ |
+
|
+ +virtual | +
| void Sample_TileMesh::buildAllTiles | +( | +) | ++ |
| void Sample_TileMesh::buildTile | +( | +const float * | +pos | ) | ++ |
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +| void Sample_TileMesh::getTilePos | +( | +const float * | +pos, | +
| + | + | int & | +tx, | +
| + | + | int & | +ty | +
| + | ) | ++ |
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +virtual | +
Reimplemented from Sample.
+ +
+
|
+ +protected | +
| void Sample_TileMesh::removeAllTiles | +( | +) | ++ |
| void Sample_TileMesh::removeTile | +( | +const float * | +pos | ) | ++ |
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
+
|
+ +protected | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for TempObstacleCreateTool, including all inherited members.
+| handleClick(const float *s, const float *p, bool shift) | TempObstacleCreateTool | inlinevirtual |
| handleMenu() | TempObstacleCreateTool | inlinevirtual |
| handleRender() | TempObstacleCreateTool | inlinevirtual |
| handleRenderOverlay(double *, double *, int *) | TempObstacleCreateTool | inlinevirtual |
| handleStep() | TempObstacleCreateTool | inlinevirtual |
| handleToggle() | TempObstacleCreateTool | inlinevirtual |
| handleUpdate(const float) | TempObstacleCreateTool | inlinevirtual |
| init(Sample *sample) | TempObstacleCreateTool | inlinevirtual |
| reset() | TempObstacleCreateTool | inlinevirtual |
| TempObstacleCreateTool() | TempObstacleCreateTool | inline |
| type() | TempObstacleCreateTool | inlinevirtual |
| ~SampleTool() | SampleTool | virtual |
| ~TempObstacleCreateTool() | TempObstacleCreateTool | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+
++Public Member Functions | |
| TempObstacleCreateTool () | |
| virtual | ~TempObstacleCreateTool () |
| virtual int | type () |
| virtual void | init (Sample *sample) |
| virtual void | reset () |
| virtual void | handleMenu () |
| virtual void | handleClick (const float *s, const float *p, bool shift) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float) |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *, double *, int *) |
Public Member Functions inherited from SampleTool | |
| virtual | ~SampleTool () |
+
|
+ +inline | +
+
|
+ +virtual | +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for TempObstacleHilightTool, including all inherited members.
+| handleClick(const float *, const float *p, bool) | TempObstacleHilightTool | inlinevirtual |
| handleMenu() | TempObstacleHilightTool | inlinevirtual |
| handleRender() | TempObstacleHilightTool | inlinevirtual |
| handleRenderOverlay(double *proj, double *model, int *view) | TempObstacleHilightTool | inlinevirtual |
| handleStep() | TempObstacleHilightTool | inlinevirtual |
| handleToggle() | TempObstacleHilightTool | inlinevirtual |
| handleUpdate(const float) | TempObstacleHilightTool | inlinevirtual |
| init(Sample *sample) | TempObstacleHilightTool | inlinevirtual |
| reset() | TempObstacleHilightTool | inlinevirtual |
| TempObstacleHilightTool() | TempObstacleHilightTool | inline |
| type() | TempObstacleHilightTool | inlinevirtual |
| ~SampleTool() | SampleTool | virtual |
| ~TempObstacleHilightTool() | TempObstacleHilightTool | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+
++Public Member Functions | |
| TempObstacleHilightTool () | |
| virtual | ~TempObstacleHilightTool () |
| virtual int | type () |
| virtual void | init (Sample *sample) |
| virtual void | reset () |
| virtual void | handleMenu () |
| virtual void | handleClick (const float *, const float *p, bool) |
| virtual void | handleToggle () |
| virtual void | handleStep () |
| virtual void | handleUpdate (const float) |
| virtual void | handleRender () |
| virtual void | handleRenderOverlay (double *proj, double *model, int *view) |
Public Member Functions inherited from SampleTool | |
| virtual | ~SampleTool () |
+
|
+ +inline | +
+
|
+ +virtual | +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +
+
|
+ +inlinevirtual | +
Implements SampleTool.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for TestCase, including all inherited members.
+| doTests(class dtNavMesh *navmesh, class dtNavMeshQuery *navquery) | TestCase | |
| getGeomFileName() const | TestCase | inline |
| getSampleName() const | TestCase | inline |
| handleRender() | TestCase | |
| handleRenderOverlay(double *proj, double *model, int *view) | TestCase | |
| load(const std::string &filePath) | TestCase | |
| TestCase() | TestCase | |
| ~TestCase() | TestCase |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <TestCase.h>
+Public Member Functions | |
| TestCase () | |
| ~TestCase () | |
| bool | load (const std::string &filePath) |
| const std::string & | getSampleName () const |
| const std::string & | getGeomFileName () const |
| void | doTests (class dtNavMesh *navmesh, class dtNavMeshQuery *navquery) |
| void | handleRender () |
| bool | handleRenderOverlay (double *proj, double *model, int *view) |
| TestCase::TestCase | +( | +) | ++ |
| TestCase::~TestCase | +( | +) | ++ |
| void TestCase::doTests | +( | +class dtNavMesh * | +navmesh, | +
| + | + | class dtNavMeshQuery * | +navquery | +
| + | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
| void TestCase::handleRender | +( | +) | ++ |
| bool TestCase::handleRenderOverlay | +( | +double * | +proj, | +
| + | + | double * | +model, | +
| + | + | int * | +view | +
| + | ) | ++ |
| bool TestCase::load | +( | +const std::string & | +filePath | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for ValueHistory, including all inherited members.
+| addSample(const float val) | ValueHistory | inline |
| getAverage() const | ValueHistory | |
| getSample(const int i) const | ValueHistory | inline |
| getSampleCount() const | ValueHistory | inline |
| getSampleMax() const | ValueHistory | |
| getSampleMin() const | ValueHistory | |
| ValueHistory() | ValueHistory |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <ValueHistory.h>
+Public Member Functions | |
| ValueHistory () | |
| void | addSample (const float val) |
| int | getSampleCount () const |
| float | getSample (const int i) const |
| float | getSampleMin () const |
| float | getSampleMax () const |
| float | getAverage () const |
| ValueHistory::ValueHistory | +( | +) | ++ |
+
|
+ +inline | +
| float ValueHistory::getAverage | +( | +) | +const | +
+
|
+ +inline | +
+
|
+ +inline | +
| float ValueHistory::getSampleMax | +( | +) | +const | +
| float ValueHistory::getSampleMin | +( | +) | +const | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtCollectPolysQuery, including all inherited members.
+| dtCollectPolysQuery(dtPolyRef *polys, const int maxPolys) | dtCollectPolysQuery | inline |
| numCollected() const | dtCollectPolysQuery | inline |
| overflowed() const | dtCollectPolysQuery | inline |
| process(const dtMeshTile *tile, dtPoly **polys, dtPolyRef *refs, int count) | dtCollectPolysQuery | inlinevirtual |
| ~dtCollectPolysQuery() | dtCollectPolysQuery | virtual |
| ~dtPolyQuery() | dtPolyQuery | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+
++Public Member Functions | |
| dtCollectPolysQuery (dtPolyRef *polys, const int maxPolys) | |
| virtual | ~dtCollectPolysQuery () |
| int | numCollected () const |
| bool | overflowed () const |
| void | process (const dtMeshTile *tile, dtPoly **polys, dtPolyRef *refs, int count) |
| Called for each batch of unique polygons touched by the search area in dtNavMeshQuery::queryPolygons. More... | |
Public Member Functions inherited from dtPolyQuery | |
| virtual | ~dtPolyQuery () |
+
|
+ +inline | +
+
|
+ +virtual | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inlinevirtual | +
Called for each batch of unique polygons touched by the search area in dtNavMeshQuery::queryPolygons.
+This can be called multiple times for a single query.
+ +Implements dtPolyQuery.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtCrowd, including all inherited members.
+| addAgent(const float *pos, const dtCrowdAgentParams *params) | dtCrowd | |
| dtCrowd() | dtCrowd | |
| getActiveAgents(dtCrowdAgent **agents, const int maxAgents) | dtCrowd | |
| getAgent(const int idx) | dtCrowd | |
| getAgentCount() const | dtCrowd | |
| getEditableAgent(const int idx) | dtCrowd | |
| getEditableFilter(const int i) | dtCrowd | inline |
| getFilter(const int i) const | dtCrowd | inline |
| getGrid() const | dtCrowd | inline |
| getNavMeshQuery() const | dtCrowd | inline |
| getObstacleAvoidanceParams(const int idx) const | dtCrowd | |
| getPathQueue() const | dtCrowd | inline |
| getQueryExtents() const | dtCrowd | inline |
| getQueryHalfExtents() const | dtCrowd | inline |
| getVelocitySampleCount() const | dtCrowd | inline |
| init(const int maxAgents, const float maxAgentRadius, dtNavMesh *nav) | dtCrowd | |
| removeAgent(const int idx) | dtCrowd | |
| requestMoveTarget(const int idx, dtPolyRef ref, const float *pos) | dtCrowd | |
| requestMoveVelocity(const int idx, const float *vel) | dtCrowd | |
| resetMoveTarget(const int idx) | dtCrowd | |
| setObstacleAvoidanceParams(const int idx, const dtObstacleAvoidanceParams *params) | dtCrowd | |
| update(const float dt, dtCrowdAgentDebugInfo *debug) | dtCrowd | |
| updateAgentParameters(const int idx, const dtCrowdAgentParams *params) | dtCrowd | |
| ~dtCrowd() | dtCrowd |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Provides local steering behaviors for a group of agents. + More...
+ +#include <DetourCrowd.h>
+Public Member Functions | |
| dtCrowd () | |
| ~dtCrowd () | |
| bool | init (const int maxAgents, const float maxAgentRadius, dtNavMesh *nav) |
| Initializes the crowd. More... | |
| void | setObstacleAvoidanceParams (const int idx, const dtObstacleAvoidanceParams *params) |
| Sets the shared avoidance configuration for the specified index. More... | |
| const dtObstacleAvoidanceParams * | getObstacleAvoidanceParams (const int idx) const |
| Gets the shared avoidance configuration for the specified index. More... | |
| const dtCrowdAgent * | getAgent (const int idx) |
| Gets the specified agent from the pool. More... | |
| dtCrowdAgent * | getEditableAgent (const int idx) |
| Gets the specified agent from the pool. More... | |
| int | getAgentCount () const |
| The maximum number of agents that can be managed by the object. More... | |
| int | addAgent (const float *pos, const dtCrowdAgentParams *params) |
| Adds a new agent to the crowd. More... | |
| void | updateAgentParameters (const int idx, const dtCrowdAgentParams *params) |
| Updates the specified agent's configuration. More... | |
| void | removeAgent (const int idx) |
| Removes the agent from the crowd. More... | |
| bool | requestMoveTarget (const int idx, dtPolyRef ref, const float *pos) |
| Submits a new move request for the specified agent. More... | |
| bool | requestMoveVelocity (const int idx, const float *vel) |
| Submits a new move request for the specified agent. More... | |
| bool | resetMoveTarget (const int idx) |
| Resets any request for the specified agent. More... | |
| int | getActiveAgents (dtCrowdAgent **agents, const int maxAgents) |
| Gets the active agents int the agent pool. More... | |
| void | update (const float dt, dtCrowdAgentDebugInfo *debug) |
| Updates the steering and positions of all agents. More... | |
| const dtQueryFilter * | getFilter (const int i) const |
| Gets the filter used by the crowd. More... | |
| dtQueryFilter * | getEditableFilter (const int i) |
| Gets the filter used by the crowd. More... | |
| const float * | getQueryHalfExtents () const |
| Gets the search halfExtents [(x, y, z)] used by the crowd for query operations. More... | |
| const float * | getQueryExtents () const |
| Same as getQueryHalfExtents. More... | |
| int | getVelocitySampleCount () const |
| Gets the velocity sample count. More... | |
| const dtProximityGrid * | getGrid () const |
| Gets the crowd's proximity grid. More... | |
| const dtPathQueue * | getPathQueue () const |
| Gets the crowd's path request queue. More... | |
| const dtNavMeshQuery * | getNavMeshQuery () const |
| Gets the query object used by the crowd. More... | |
Provides local steering behaviors for a group of agents.
+This is the core class of the Crowd module. See the Crowd documentation for a summary of the crowd features.
+A common method for setting up the crowd is as follows:
+A common process for managing the crowd is as follows:
+Some agent configuration settings can be updated using updateAgentParameters(). But the crowd owns the agent position. So it is not possible to update an active agent's position. If agent position must be fed back into the crowd, the agent must be removed and re-added.
+Notes:
+| dtCrowd::dtCrowd | +( | +) | ++ |
| dtCrowd::~dtCrowd | +( | +) | ++ |
| int dtCrowd::addAgent | +( | +const float * | +pos, | +
| + | + | const dtCrowdAgentParams * | +params | +
| + | ) | ++ |
Adds a new agent to the crowd.
+| [in] | pos | The requested position of the agent. [(x, y, z)] |
| [in] | params | The configutation of the agent. |
The agent's position will be constrained to the surface of the navigation mesh.
+ +| int dtCrowd::getActiveAgents | +( | +dtCrowdAgent ** | +agents, | +
| + | + | const int | +maxAgents | +
| + | ) | ++ |
Gets the active agents int the agent pool.
+| [out] | agents | An array of agent pointers. [(dtCrowdAgent *) * maxAgents] |
| [in] | maxAgents | The size of the crowd agent array. |
agents. | const dtCrowdAgent * dtCrowd::getAgent | +( | +const int | +idx | ) | ++ |
Gets the specified agent from the pool.
+| [in] | idx | The agent index. [Limits: 0 <= value < getAgentCount()] |
Agents in the pool may not be in use. Check dtCrowdAgent.active before using the returned object.
+ +| int dtCrowd::getAgentCount | +( | +) | +const | +
The maximum number of agents that can be managed by the object.
+| dtCrowdAgent * dtCrowd::getEditableAgent | +( | +const int | +idx | ) | ++ |
Gets the specified agent from the pool.
+Agents in the pool may not be in use.
+| [in] | idx | The agent index. [Limits: 0 <= value < getAgentCount()] |
Check dtCrowdAgent.active before using the returned object.
+ +
+
|
+ +inline | +
Gets the filter used by the crowd.
+
+
|
+ +inline | +
Gets the filter used by the crowd.
+
+
|
+ +inline | +
Gets the crowd's proximity grid.
+
+
|
+ +inline | +
Gets the query object used by the crowd.
+ +| const dtObstacleAvoidanceParams * dtCrowd::getObstacleAvoidanceParams | +( | +const int | +idx | ) | +const | +
Gets the shared avoidance configuration for the specified index.
+| [in] | idx | The index of the configuration to retreive. [Limits: 0 <= value < DT_CROWD_MAX_OBSTAVOIDANCE_PARAMS] |
+
|
+ +inline | +
Gets the crowd's path request queue.
+
+
|
+ +inline | +
Same as getQueryHalfExtents.
+Left to maintain backwards compatibility.
+
|
+ +inline | +
Gets the search halfExtents [(x, y, z)] used by the crowd for query operations.
+
+
|
+ +inline | +
Gets the velocity sample count.
+| bool dtCrowd::init | +( | +const int | +maxAgents, | +
| + | + | const float | +maxAgentRadius, | +
| + | + | dtNavMesh * | +nav | +
| + | ) | ++ |
Initializes the crowd.
+
+
| [in] | maxAgents | The maximum number of agents the crowd can manage. [Limit: >= 1] |
| [in] | maxAgentRadius | The maximum radius of any agent that will be added to the crowd. [Limit: > 0] |
| [in] | nav | The navigation mesh to use for planning. |
May be called more than once to purge and re-initialize the crowd.
+ +| void dtCrowd::removeAgent | +( | +const int | +idx | ) | ++ |
Removes the agent from the crowd.
+| [in] | idx | The agent index. [Limits: 0 <= value < getAgentCount()] |
The agent is deactivated and will no longer be processed. Its dtCrowdAgent object is not removed from the pool. It is marked as inactive so that it is available for reuse.
+ +| bool dtCrowd::requestMoveTarget | +( | +const int | +idx, | +
| + | + | dtPolyRef | +ref, | +
| + | + | const float * | +pos | +
| + | ) | ++ |
Submits a new move request for the specified agent.
+| [in] | idx | The agent index. [Limits: 0 <= value < getAgentCount()] |
| [in] | ref | The position's polygon reference. |
| [in] | pos | The position within the polygon. [(x, y, z)] |
This method is used when a new target is set.
+The position will be constrained to the surface of the navigation mesh.
+The request will be processed during the next update().
+ +| bool dtCrowd::requestMoveVelocity | +( | +const int | +idx, | +
| + | + | const float * | +vel | +
| + | ) | ++ |
Submits a new move request for the specified agent.
+| [in] | idx | The agent index. [Limits: 0 <= value < getAgentCount()] |
| [in] | vel | The movement velocity. [(x, y, z)] |
| bool dtCrowd::resetMoveTarget | +( | +const int | +idx | ) | ++ |
Resets any request for the specified agent.
+| [in] | idx | The agent index. [Limits: 0 <= value < getAgentCount()] |
| void dtCrowd::setObstacleAvoidanceParams | +( | +const int | +idx, | +
| + | + | const dtObstacleAvoidanceParams * | +params | +
| + | ) | ++ |
Sets the shared avoidance configuration for the specified index.
+| [in] | idx | The index. [Limits: 0 <= value < DT_CROWD_MAX_OBSTAVOIDANCE_PARAMS] |
| [in] | params | The new configuration. |
| void dtCrowd::update | +( | +const float | +dt, | +
| + | + | dtCrowdAgentDebugInfo * | +debug | +
| + | ) | ++ |
Updates the steering and positions of all agents.
+| [in] | dt | The time, in seconds, to update the simulation. [Limit: > 0] |
| [out] | debug | A debug object to load with debug information. [Opt] |
| void dtCrowd::updateAgentParameters | +( | +const int | +idx, | +
| + | + | const dtCrowdAgentParams * | +params | +
| + | ) | ++ |
Updates the specified agent's configuration.
+| [in] | idx | The agent index. [Limits: 0 <= value < getAgentCount()] |
| [in] | params | The new agent configuration. |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtFindNearestPolyQuery, including all inherited members.
+| dtFindNearestPolyQuery(const dtNavMeshQuery *query, const float *center) | dtFindNearestPolyQuery | inline |
| isOverPoly() const | dtFindNearestPolyQuery | inline |
| nearestPoint() const | dtFindNearestPolyQuery | inline |
| nearestRef() const | dtFindNearestPolyQuery | inline |
| process(const dtMeshTile *tile, dtPoly **polys, dtPolyRef *refs, int count) | dtFindNearestPolyQuery | inlinevirtual |
| ~dtFindNearestPolyQuery() | dtFindNearestPolyQuery | virtual |
| ~dtPolyQuery() | dtPolyQuery | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+
++Public Member Functions | |
| dtFindNearestPolyQuery (const dtNavMeshQuery *query, const float *center) | |
| virtual | ~dtFindNearestPolyQuery () |
| dtPolyRef | nearestRef () const |
| const float * | nearestPoint () const |
| bool | isOverPoly () const |
| void | process (const dtMeshTile *tile, dtPoly **polys, dtPolyRef *refs, int count) |
| Called for each batch of unique polygons touched by the search area in dtNavMeshQuery::queryPolygons. More... | |
Public Member Functions inherited from dtPolyQuery | |
| virtual | ~dtPolyQuery () |
+
|
+ +inline | +
+
|
+ +virtual | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inlinevirtual | +
Called for each batch of unique polygons touched by the search area in dtNavMeshQuery::queryPolygons.
+This can be called multiple times for a single query.
+ +Implements dtPolyQuery.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtFixedArray< T >, including all inherited members.
+| dtFixedArray(dtTileCacheAlloc *a, const int s) | dtFixedArray< T > | inline |
| operator T*() | dtFixedArray< T > | inline |
| size() const | dtFixedArray< T > | inline |
| ~dtFixedArray() | dtFixedArray< T > | inline |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Public Member Functions | |
| dtFixedArray (dtTileCacheAlloc *a, const int s) | |
| ~dtFixedArray () | |
| operator T* () | |
| int | size () const |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtLocalBoundary, including all inherited members.
+| dtLocalBoundary() | dtLocalBoundary | |
| getCenter() const | dtLocalBoundary | inline |
| getSegment(int i) const | dtLocalBoundary | inline |
| getSegmentCount() const | dtLocalBoundary | inline |
| isValid(dtNavMeshQuery *navquery, const dtQueryFilter *filter) | dtLocalBoundary | |
| reset() | dtLocalBoundary | |
| update(dtPolyRef ref, const float *pos, const float collisionQueryRange, dtNavMeshQuery *navquery, const dtQueryFilter *filter) | dtLocalBoundary | |
| ~dtLocalBoundary() | dtLocalBoundary |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <DetourLocalBoundary.h>
+Public Member Functions | |
| dtLocalBoundary () | |
| ~dtLocalBoundary () | |
| void | reset () |
| void | update (dtPolyRef ref, const float *pos, const float collisionQueryRange, dtNavMeshQuery *navquery, const dtQueryFilter *filter) |
| bool | isValid (dtNavMeshQuery *navquery, const dtQueryFilter *filter) |
| const float * | getCenter () const |
| int | getSegmentCount () const |
| const float * | getSegment (int i) const |
| dtLocalBoundary::dtLocalBoundary | +( | +) | ++ |
| dtLocalBoundary::~dtLocalBoundary | +( | +) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| bool dtLocalBoundary::isValid | +( | +dtNavMeshQuery * | +navquery, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | ++ |
| void dtLocalBoundary::reset | +( | +) | ++ |
| void dtLocalBoundary::update | +( | +dtPolyRef | +ref, | +
| + | + | const float * | +pos, | +
| + | + | const float | +collisionQueryRange, | +
| + | + | dtNavMeshQuery * | +navquery, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtNavMesh, including all inherited members.
+| addTile(unsigned char *data, int dataSize, int flags, dtTileRef lastRef, dtTileRef *result) | dtNavMesh | |
| calcTileLoc(const float *pos, int *tx, int *ty) const | dtNavMesh | |
| decodePolyId(dtPolyRef ref, unsigned int &salt, unsigned int &it, unsigned int &ip) const | dtNavMesh | inline |
| decodePolyIdPoly(dtPolyRef ref) const | dtNavMesh | inline |
| decodePolyIdSalt(dtPolyRef ref) const | dtNavMesh | inline |
| decodePolyIdTile(dtPolyRef ref) const | dtNavMesh | inline |
| dtNavMesh() | dtNavMesh | |
| dtNavMeshQuery class | dtNavMesh | friend |
| encodePolyId(unsigned int salt, unsigned int it, unsigned int ip) const | dtNavMesh | inline |
| getMaxTiles() const | dtNavMesh | |
| getOffMeshConnectionByRef(dtPolyRef ref) const | dtNavMesh | |
| getOffMeshConnectionPolyEndPoints(dtPolyRef prevRef, dtPolyRef polyRef, float *startPos, float *endPos) const | dtNavMesh | |
| getParams() const | dtNavMesh | |
| getPolyArea(dtPolyRef ref, unsigned char *resultArea) const | dtNavMesh | |
| getPolyFlags(dtPolyRef ref, unsigned short *resultFlags) const | dtNavMesh | |
| getPolyRefBase(const dtMeshTile *tile) const | dtNavMesh | |
| getTile(int i) const | dtNavMesh | |
| getTileAndPolyByRef(const dtPolyRef ref, const dtMeshTile **tile, const dtPoly **poly) const | dtNavMesh | |
| getTileAndPolyByRefUnsafe(const dtPolyRef ref, const dtMeshTile **tile, const dtPoly **poly) const | dtNavMesh | |
| getTileAt(const int x, const int y, const int layer) const | dtNavMesh | |
| getTileByRef(dtTileRef ref) const | dtNavMesh | |
| getTileRef(const dtMeshTile *tile) const | dtNavMesh | |
| getTileRefAt(int x, int y, int layer) const | dtNavMesh | |
| getTilesAt(const int x, const int y, dtMeshTile const **tiles, const int maxTiles) const | dtNavMesh | |
| getTileStateSize(const dtMeshTile *tile) const | dtNavMesh | |
| init(const dtNavMeshParams *params) | dtNavMesh | |
| init(unsigned char *data, const int dataSize, const int flags) | dtNavMesh | |
| isValidPolyRef(dtPolyRef ref) const | dtNavMesh | |
| removeTile(dtTileRef ref, unsigned char **data, int *dataSize) | dtNavMesh | |
| restoreTileState(dtMeshTile *tile, const unsigned char *data, const int maxDataSize) | dtNavMesh | |
| setPolyArea(dtPolyRef ref, unsigned char area) | dtNavMesh | |
| setPolyFlags(dtPolyRef ref, unsigned short flags) | dtNavMesh | |
| storeTileState(const dtMeshTile *tile, unsigned char *data, const int maxDataSize) const | dtNavMesh | |
| ~dtNavMesh() | dtNavMesh |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
A navigation mesh based on tiles of convex polygons. + More...
+ +#include <DetourNavMesh.h>
+Public Member Functions | |
| dtNavMesh () | |
| ~dtNavMesh () | |
Initialization and Tile Management | |
| dtStatus | init (const dtNavMeshParams *params) |
| Initializes the navigation mesh for tiled use. More... | |
| dtStatus | init (unsigned char *data, const int dataSize, const int flags) |
| Initializes the navigation mesh for single tile use. More... | |
| const dtNavMeshParams * | getParams () const |
| The navigation mesh initialization params. More... | |
| dtStatus | addTile (unsigned char *data, int dataSize, int flags, dtTileRef lastRef, dtTileRef *result) |
| Adds a tile to the navigation mesh. More... | |
| dtStatus | removeTile (dtTileRef ref, unsigned char **data, int *dataSize) |
| Removes the specified tile from the navigation mesh. More... | |
Query Functions | |
| void | calcTileLoc (const float *pos, int *tx, int *ty) const |
| Calculates the tile grid location for the specified world position. More... | |
| const dtMeshTile * | getTileAt (const int x, const int y, const int layer) const |
| Gets the tile at the specified grid location. More... | |
| int | getTilesAt (const int x, const int y, dtMeshTile const **tiles, const int maxTiles) const |
| Gets all tiles at the specified grid location. More... | |
| dtTileRef | getTileRefAt (int x, int y, int layer) const |
| Gets the tile reference for the tile at specified grid location. More... | |
| dtTileRef | getTileRef (const dtMeshTile *tile) const |
| Gets the tile reference for the specified tile. More... | |
| const dtMeshTile * | getTileByRef (dtTileRef ref) const |
| Gets the tile for the specified tile reference. More... | |
| int | getMaxTiles () const |
| The maximum number of tiles supported by the navigation mesh. More... | |
| const dtMeshTile * | getTile (int i) const |
| Gets the tile at the specified index. More... | |
| dtStatus | getTileAndPolyByRef (const dtPolyRef ref, const dtMeshTile **tile, const dtPoly **poly) const |
| Gets the tile and polygon for the specified polygon reference. More... | |
| void | getTileAndPolyByRefUnsafe (const dtPolyRef ref, const dtMeshTile **tile, const dtPoly **poly) const |
| Returns the tile and polygon for the specified polygon reference. More... | |
| bool | isValidPolyRef (dtPolyRef ref) const |
| Checks the validity of a polygon reference. More... | |
| dtPolyRef | getPolyRefBase (const dtMeshTile *tile) const |
| Gets the polygon reference for the tile's base polygon. More... | |
| dtStatus | getOffMeshConnectionPolyEndPoints (dtPolyRef prevRef, dtPolyRef polyRef, float *startPos, float *endPos) const |
| Gets the endpoints for an off-mesh connection, ordered by "direction of travel". More... | |
| const dtOffMeshConnection * | getOffMeshConnectionByRef (dtPolyRef ref) const |
| Gets the specified off-mesh connection. More... | |
State Management | |
| dtStatus | setPolyFlags (dtPolyRef ref, unsigned short flags) |
| Sets the user defined flags for the specified polygon. More... | |
| dtStatus | getPolyFlags (dtPolyRef ref, unsigned short *resultFlags) const |
| Gets the user defined flags for the specified polygon. More... | |
| dtStatus | setPolyArea (dtPolyRef ref, unsigned char area) |
| Sets the user defined area for the specified polygon. More... | |
| dtStatus | getPolyArea (dtPolyRef ref, unsigned char *resultArea) const |
| Gets the user defined area for the specified polygon. More... | |
| int | getTileStateSize (const dtMeshTile *tile) const |
| Gets the size of the buffer required by storeTileState to store the specified tile's state. More... | |
| dtStatus | storeTileState (const dtMeshTile *tile, unsigned char *data, const int maxDataSize) const |
| Stores the non-structural state of the tile in the specified buffer. More... | |
| dtStatus | restoreTileState (dtMeshTile *tile, const unsigned char *data, const int maxDataSize) |
| Restores the state of the tile. More... | |
Encoding and Decoding | |
These functions are generally meant for internal use only. + | |
| dtPolyRef | encodePolyId (unsigned int salt, unsigned int it, unsigned int ip) const |
| Derives a standard polygon reference. More... | |
| void | decodePolyId (dtPolyRef ref, unsigned int &salt, unsigned int &it, unsigned int &ip) const |
| Decodes a standard polygon reference. More... | |
| unsigned int | decodePolyIdSalt (dtPolyRef ref) const |
| Extracts a tile's salt value from the specified polygon reference. More... | |
| unsigned int | decodePolyIdTile (dtPolyRef ref) const |
| Extracts the tile's index from the specified polygon reference. More... | |
| unsigned int | decodePolyIdPoly (dtPolyRef ref) const |
| Extracts the polygon's index (within its tile) from the specified polygon reference. More... | |
+Friends | |
| class | dtNavMeshQuery |
A navigation mesh based on tiles of convex polygons.
+The navigation mesh consists of one or more tiles defining three primary types of structural data:
+A polygon mesh which defines most of the navigation graph. (See rcPolyMesh for its structure.) A detail mesh used for determining surface height on the polygon mesh. (See rcPolyMeshDetail for its structure.) Off-mesh connections, which define custom point-to-point edges within the navigation graph.
+The general build process is as follows:
+Notes:
+| dtNavMesh::dtNavMesh | +( | +) | ++ |
| dtNavMesh::~dtNavMesh | +( | +) | ++ |
| dtStatus dtNavMesh::addTile | +( | +unsigned char * | +data, | +
| + | + | int | +dataSize, | +
| + | + | int | +flags, | +
| + | + | dtTileRef | +lastRef, | +
| + | + | dtTileRef * | +result | +
| + | ) | ++ |
Adds a tile to the navigation mesh.
+| [in] | data | Data for the new tile mesh. (See: dtCreateNavMeshData) |
| [in] | dataSize | Data size of the new tile mesh. |
| [in] | flags | Tile flags. (See: dtTileFlags) |
| [in] | lastRef | The desired reference for the tile. (When reloading a tile.) [opt] [Default: 0] |
| [out] | result | The tile reference. (If the tile was succesfully added.) [opt] |
The add operation will fail if the data is in the wrong format, the allocated tile space is full, or there is a tile already at the specified reference.
+The lastRef parameter is used to restore a tile with the same tile reference it had previously used. In this case the dtPolyRef's for the tile will be restored to the same values they were before the tile was removed.
+The nav mesh assumes exclusive access to the data passed and will make changes to the dynamic portion of the data. For that reason the data should not be reused in other nav meshes until the tile has been successfully removed from this nav mesh.
+| void dtNavMesh::calcTileLoc | +( | +const float * | +pos, | +
| + | + | int * | +tx, | +
| + | + | int * | +ty | +
| + | ) | +const | +
Calculates the tile grid location for the specified world position.
+| [in] | pos | The world position for the query. [(x, y, z)] |
| [out] | tx | The tile's x-location. (x, y) |
| [out] | ty | The tile's y-location. (x, y) |
+
|
+ +inline | +
Decodes a standard polygon reference.
+| [in] | ref | The polygon reference to decode. |
| [out] | salt | The tile's salt value. |
| [out] | it | The index of the tile. |
| [out] | ip | The index of the polygon within the tile. |
+
|
+ +inline | +
Extracts the polygon's index (within its tile) from the specified polygon reference.
+| [in] | ref | The polygon reference. |
+
|
+ +inline | +
Extracts a tile's salt value from the specified polygon reference.
+| [in] | ref | The polygon reference. |
+
|
+ +inline | +
Extracts the tile's index from the specified polygon reference.
+| [in] | ref | The polygon reference. |
+
|
+ +inline | +
Derives a standard polygon reference.
+| [in] | salt | The tile's salt value. |
| [in] | it | The index of the tile. |
| [in] | ip | The index of the polygon within the tile. |
| int dtNavMesh::getMaxTiles | +( | +) | +const | +
The maximum number of tiles supported by the navigation mesh.
+| const dtOffMeshConnection * dtNavMesh::getOffMeshConnectionByRef | +( | +dtPolyRef | +ref | ) | +const | +
Gets the specified off-mesh connection.
+| [in] | ref | The polygon reference of the off-mesh connection. |
| dtStatus dtNavMesh::getOffMeshConnectionPolyEndPoints | +( | +dtPolyRef | +prevRef, | +
| + | + | dtPolyRef | +polyRef, | +
| + | + | float * | +startPos, | +
| + | + | float * | +endPos | +
| + | ) | +const | +
Gets the endpoints for an off-mesh connection, ordered by "direction of travel".
+| [in] | prevRef | The reference of the polygon before the connection. |
| [in] | polyRef | The reference of the off-mesh connection polygon. |
| [out] | startPos | The start position of the off-mesh connection. [(x, y, z)] |
| [out] | endPos | The end position of the off-mesh connection. [(x, y, z)] |
Off-mesh connections are stored in the navigation mesh as special 2-vertex polygons with a single edge. At least one of the vertices is expected to be inside a normal polygon. So an off-mesh connection is "entered" from a normal polygon at one of its endpoints. This is the polygon identified by the prevRef parameter.
+ +| const dtNavMeshParams * dtNavMesh::getParams | +( | +) | +const | +
The navigation mesh initialization params.
+| dtStatus dtNavMesh::getPolyArea | +( | +dtPolyRef | +ref, | +
| + | + | unsigned char * | +resultArea | +
| + | ) | +const | +
Gets the user defined area for the specified polygon.
+| [in] | ref | The polygon reference. |
| [out] | resultArea | The area id for the polygon. |
| dtStatus dtNavMesh::getPolyFlags | +( | +dtPolyRef | +ref, | +
| + | + | unsigned short * | +resultFlags | +
| + | ) | +const | +
Gets the user defined flags for the specified polygon.
+| [in] | ref | The polygon reference. |
| [out] | resultFlags | The polygon flags. |
| dtPolyRef dtNavMesh::getPolyRefBase | +( | +const dtMeshTile * | +tile | ) | +const | +
Gets the polygon reference for the tile's base polygon.
+| [in] | tile | The tile. |
Example use case:
| const dtMeshTile * dtNavMesh::getTile | +( | +int | +i | ) | +const | +
Gets the tile at the specified index.
+| [in] | i | The tile index. [Limit: 0 >= index < getMaxTiles()] |
| dtStatus dtNavMesh::getTileAndPolyByRef | +( | +const dtPolyRef | +ref, | +
| + | + | const dtMeshTile ** | +tile, | +
| + | + | const dtPoly ** | +poly | +
| + | ) | +const | +
Gets the tile and polygon for the specified polygon reference.
+| [in] | ref | The reference for the a polygon. |
| [out] | tile | The tile containing the polygon. |
| [out] | poly | The polygon. |
| void dtNavMesh::getTileAndPolyByRefUnsafe | +( | +const dtPolyRef | +ref, | +
| + | + | const dtMeshTile ** | +tile, | +
| + | + | const dtPoly ** | +poly | +
| + | ) | +const | +
Returns the tile and polygon for the specified polygon reference.
+| [in] | ref | A known valid reference for a polygon. |
| [out] | tile | The tile containing the polygon. |
| [out] | poly | The polygon. |
| const dtMeshTile * dtNavMesh::getTileAt | +( | +const int | +x, | +
| + | + | const int | +y, | +
| + | + | const int | +layer | +
| + | ) | +const | +
Gets the tile at the specified grid location.
+| [in] | x | The tile's x-location. (x, y, layer) |
| [in] | y | The tile's y-location. (x, y, layer) |
| [in] | layer | The tile's layer. (x, y, layer) |
| const dtMeshTile * dtNavMesh::getTileByRef | +( | +dtTileRef | +ref | ) | +const | +
Gets the tile for the specified tile reference.
+| [in] | ref | The tile reference of the tile to retrieve. |
| dtTileRef dtNavMesh::getTileRef | +( | +const dtMeshTile * | +tile | ) | +const | +
Gets the tile reference for the specified tile.
+| [in] | tile | The tile. |
| dtTileRef dtNavMesh::getTileRefAt | +( | +int | +x, | +
| + | + | int | +y, | +
| + | + | int | +layer | +
| + | ) | +const | +
Gets the tile reference for the tile at specified grid location.
+| [in] | x | The tile's x-location. (x, y, layer) |
| [in] | y | The tile's y-location. (x, y, layer) |
| [in] | layer | The tile's layer. (x, y, layer) |
| int dtNavMesh::getTilesAt | +( | +const int | +x, | +
| + | + | const int | +y, | +
| + | + | dtMeshTile const ** | +tiles, | +
| + | + | const int | +maxTiles | +
| + | ) | +const | +
Gets all tiles at the specified grid location.
+(All layers.)
| [in] | x | The tile's x-location. (x, y) |
| [in] | y | The tile's y-location. (x, y) |
| [out] | tiles | A pointer to an array of tiles that will hold the result. |
| [in] | maxTiles | The maximum tiles the tiles parameter can hold. |
This function will not fail if the tiles array is too small to hold the entire result set. It will simply fill the array to capacity.
+ +| int dtNavMesh::getTileStateSize | +( | +const dtMeshTile * | +tile | ) | +const | +
Gets the size of the buffer required by storeTileState to store the specified tile's state.
+| [in] | tile | The tile. |
| dtStatus dtNavMesh::init | +( | +const dtNavMeshParams * | +params | ) | ++ |
Initializes the navigation mesh for tiled use.
+| [in] | params | Initialization parameters. |
| dtStatus dtNavMesh::init | +( | +unsigned char * | +data, | +
| + | + | const int | +dataSize, | +
| + | + | const int | +flags | +
| + | ) | ++ |
Initializes the navigation mesh for single tile use.
+| [in] | data | Data of the new tile. (See: dtCreateNavMeshData) |
| [in] | dataSize | The data size of the new tile. |
| [in] | flags | The tile flags. (See: dtTileFlags) |
| bool dtNavMesh::isValidPolyRef | +( | +dtPolyRef | +ref | ) | +const | +
Checks the validity of a polygon reference.
+| [in] | ref | The polygon reference to check. |
| dtStatus dtNavMesh::removeTile | +( | +dtTileRef | +ref, | +
| + | + | unsigned char ** | +data, | +
| + | + | int * | +dataSize | +
| + | ) | ++ |
Removes the specified tile from the navigation mesh.
+| [in] | ref | The reference of the tile to remove. |
| [out] | data | Data associated with deleted tile. |
| [out] | dataSize | Size of the data associated with deleted tile. |
This function returns the data for the tile so that, if desired, it can be added back to the navigation mesh at a later point.
+| dtStatus dtNavMesh::restoreTileState | +( | +dtMeshTile * | +tile, | +
| + | + | const unsigned char * | +data, | +
| + | + | const int | +maxDataSize | +
| + | ) | ++ |
Restores the state of the tile.
+| [in] | tile | The tile. |
| [in] | data | The new state. (Obtained from storeTileState.) |
| [in] | maxDataSize | The size of the state within the data buffer. |
Tile state includes non-structural data such as polygon flags, area ids, etc.
+| dtStatus dtNavMesh::setPolyArea | +( | +dtPolyRef | +ref, | +
| + | + | unsigned char | +area | +
| + | ) | ++ |
Sets the user defined area for the specified polygon.
+| [in] | ref | The polygon reference. |
| [in] | area | The new area id for the polygon. [Limit: < DT_MAX_AREAS] |
| dtStatus dtNavMesh::setPolyFlags | +( | +dtPolyRef | +ref, | +
| + | + | unsigned short | +flags | +
| + | ) | ++ |
Sets the user defined flags for the specified polygon.
+| [in] | ref | The polygon reference. |
| [in] | flags | The new flags for the polygon. |
| dtStatus dtNavMesh::storeTileState | +( | +const dtMeshTile * | +tile, | +
| + | + | unsigned char * | +data, | +
| + | + | const int | +maxDataSize | +
| + | ) | +const | +
Stores the non-structural state of the tile in the specified buffer.
+(Flags, area ids, etc.)
| [in] | tile | The tile. |
| [out] | data | The buffer to store the tile's state in. |
| [in] | maxDataSize | The size of the data buffer. [Limit: >= getTileStateSize] |
Tile state includes non-structural data such as polygon flags, area ids, etc.
+
|
+ +friend | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtNavMeshQuery, including all inherited members.
+| closestPointOnPoly(dtPolyRef ref, const float *pos, float *closest, bool *posOverPoly) const | dtNavMeshQuery | |
| closestPointOnPolyBoundary(dtPolyRef ref, const float *pos, float *closest) const | dtNavMeshQuery | |
| dtNavMeshQuery() | dtNavMeshQuery | |
| finalizeSlicedFindPath(dtPolyRef *path, int *pathCount, const int maxPath) | dtNavMeshQuery | |
| finalizeSlicedFindPathPartial(const dtPolyRef *existing, const int existingSize, dtPolyRef *path, int *pathCount, const int maxPath) | dtNavMeshQuery | |
| findDistanceToWall(dtPolyRef startRef, const float *centerPos, const float maxRadius, const dtQueryFilter *filter, float *hitDist, float *hitPos, float *hitNormal) const | dtNavMeshQuery | |
| findLocalNeighbourhood(dtPolyRef startRef, const float *centerPos, const float radius, const dtQueryFilter *filter, dtPolyRef *resultRef, dtPolyRef *resultParent, int *resultCount, const int maxResult) const | dtNavMeshQuery | |
| findNearestPoly(const float *center, const float *halfExtents, const dtQueryFilter *filter, dtPolyRef *nearestRef, float *nearestPt) const | dtNavMeshQuery | |
| findNearestPoly(const float *center, const float *halfExtents, const dtQueryFilter *filter, dtPolyRef *nearestRef, float *nearestPt, bool *isOverPoly) const | dtNavMeshQuery | |
| findPath(dtPolyRef startRef, dtPolyRef endRef, const float *startPos, const float *endPos, const dtQueryFilter *filter, dtPolyRef *path, int *pathCount, const int maxPath) const | dtNavMeshQuery | |
| findPolysAroundCircle(dtPolyRef startRef, const float *centerPos, const float radius, const dtQueryFilter *filter, dtPolyRef *resultRef, dtPolyRef *resultParent, float *resultCost, int *resultCount, const int maxResult) const | dtNavMeshQuery | |
| findPolysAroundShape(dtPolyRef startRef, const float *verts, const int nverts, const dtQueryFilter *filter, dtPolyRef *resultRef, dtPolyRef *resultParent, float *resultCost, int *resultCount, const int maxResult) const | dtNavMeshQuery | |
| findRandomPoint(const dtQueryFilter *filter, float(*frand)(), dtPolyRef *randomRef, float *randomPt) const | dtNavMeshQuery | |
| findRandomPointAroundCircle(dtPolyRef startRef, const float *centerPos, const float maxRadius, const dtQueryFilter *filter, float(*frand)(), dtPolyRef *randomRef, float *randomPt) const | dtNavMeshQuery | |
| findStraightPath(const float *startPos, const float *endPos, const dtPolyRef *path, const int pathSize, float *straightPath, unsigned char *straightPathFlags, dtPolyRef *straightPathRefs, int *straightPathCount, const int maxStraightPath, const int options=0) const | dtNavMeshQuery | |
| getAttachedNavMesh() const | dtNavMeshQuery | inline |
| getNodePool() const | dtNavMeshQuery | inline |
| getPathFromDijkstraSearch(dtPolyRef endRef, dtPolyRef *path, int *pathCount, int maxPath) const | dtNavMeshQuery | |
| getPolyHeight(dtPolyRef ref, const float *pos, float *height) const | dtNavMeshQuery | |
| getPolyWallSegments(dtPolyRef ref, const dtQueryFilter *filter, float *segmentVerts, dtPolyRef *segmentRefs, int *segmentCount, const int maxSegments) const | dtNavMeshQuery | |
| init(const dtNavMesh *nav, const int maxNodes) | dtNavMeshQuery | |
| initSlicedFindPath(dtPolyRef startRef, dtPolyRef endRef, const float *startPos, const float *endPos, const dtQueryFilter *filter, const unsigned int options=0) | dtNavMeshQuery | |
| isInClosedList(dtPolyRef ref) const | dtNavMeshQuery | |
| isValidPolyRef(dtPolyRef ref, const dtQueryFilter *filter) const | dtNavMeshQuery | |
| moveAlongSurface(dtPolyRef startRef, const float *startPos, const float *endPos, const dtQueryFilter *filter, float *resultPos, dtPolyRef *visited, int *visitedCount, const int maxVisitedSize) const | dtNavMeshQuery | |
| queryPolygons(const float *center, const float *halfExtents, const dtQueryFilter *filter, dtPolyRef *polys, int *polyCount, const int maxPolys) const | dtNavMeshQuery | |
| queryPolygons(const float *center, const float *halfExtents, const dtQueryFilter *filter, dtPolyQuery *query) const | dtNavMeshQuery | |
| raycast(dtPolyRef startRef, const float *startPos, const float *endPos, const dtQueryFilter *filter, float *t, float *hitNormal, dtPolyRef *path, int *pathCount, const int maxPath) const | dtNavMeshQuery | |
| raycast(dtPolyRef startRef, const float *startPos, const float *endPos, const dtQueryFilter *filter, const unsigned int options, dtRaycastHit *hit, dtPolyRef prevRef=0) const | dtNavMeshQuery | |
| updateSlicedFindPath(const int maxIter, int *doneIters) | dtNavMeshQuery | |
| ~dtNavMeshQuery() | dtNavMeshQuery |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Provides the ability to perform pathfinding related queries against a navigation mesh. + More...
+ +#include <DetourNavMeshQuery.h>
+Public Member Functions | |
| dtNavMeshQuery () | |
| ~dtNavMeshQuery () | |
| dtStatus | init (const dtNavMesh *nav, const int maxNodes) |
| Initializes the query object. More... | |
Standard Pathfinding Functions | |
| dtStatus | findPath (dtPolyRef startRef, dtPolyRef endRef, const float *startPos, const float *endPos, const dtQueryFilter *filter, dtPolyRef *path, int *pathCount, const int maxPath) const |
| Finds a path from the start polygon to the end polygon. More... | |
| dtStatus | findStraightPath (const float *startPos, const float *endPos, const dtPolyRef *path, const int pathSize, float *straightPath, unsigned char *straightPathFlags, dtPolyRef *straightPathRefs, int *straightPathCount, const int maxStraightPath, const int options=0) const |
| Finds the straight path from the start to the end position within the polygon corridor. More... | |
Sliced Pathfinding Functions | |
Common use case: +
| |
| dtStatus | initSlicedFindPath (dtPolyRef startRef, dtPolyRef endRef, const float *startPos, const float *endPos, const dtQueryFilter *filter, const unsigned int options=0) |
| Intializes a sliced path query. More... | |
| dtStatus | updateSlicedFindPath (const int maxIter, int *doneIters) |
| Updates an in-progress sliced path query. More... | |
| dtStatus | finalizeSlicedFindPath (dtPolyRef *path, int *pathCount, const int maxPath) |
| Finalizes and returns the results of a sliced path query. More... | |
| dtStatus | finalizeSlicedFindPathPartial (const dtPolyRef *existing, const int existingSize, dtPolyRef *path, int *pathCount, const int maxPath) |
| 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. More... | |
Dijkstra Search Functions | |
| |
| dtStatus | findPolysAroundCircle (dtPolyRef startRef, const float *centerPos, const float radius, const dtQueryFilter *filter, dtPolyRef *resultRef, dtPolyRef *resultParent, float *resultCost, int *resultCount, const int maxResult) const |
| Finds the polygons along the navigation graph that touch the specified circle. More... | |
| dtStatus | findPolysAroundShape (dtPolyRef startRef, const float *verts, const int nverts, const dtQueryFilter *filter, dtPolyRef *resultRef, dtPolyRef *resultParent, float *resultCost, int *resultCount, const int maxResult) const |
| Finds the polygons along the naviation graph that touch the specified convex polygon. More... | |
| dtStatus | getPathFromDijkstraSearch (dtPolyRef endRef, dtPolyRef *path, int *pathCount, int maxPath) const |
| Gets a path from the explored nodes in the previous search. More... | |
Local Query Functions | |
| dtStatus | findNearestPoly (const float *center, const float *halfExtents, const dtQueryFilter *filter, dtPolyRef *nearestRef, float *nearestPt) const |
| Finds the polygon nearest to the specified center point. More... | |
| dtStatus | findNearestPoly (const float *center, const float *halfExtents, const dtQueryFilter *filter, dtPolyRef *nearestRef, float *nearestPt, bool *isOverPoly) const |
| Finds the polygon nearest to the specified center point. More... | |
| dtStatus | queryPolygons (const float *center, const float *halfExtents, const dtQueryFilter *filter, dtPolyRef *polys, int *polyCount, const int maxPolys) const |
| Finds polygons that overlap the search box. More... | |
| dtStatus | queryPolygons (const float *center, const float *halfExtents, const dtQueryFilter *filter, dtPolyQuery *query) const |
| Finds polygons that overlap the search box. More... | |
| dtStatus | findLocalNeighbourhood (dtPolyRef startRef, const float *centerPos, const float radius, const dtQueryFilter *filter, dtPolyRef *resultRef, dtPolyRef *resultParent, int *resultCount, const int maxResult) const |
| Finds the non-overlapping navigation polygons in the local neighbourhood around the center position. More... | |
| dtStatus | moveAlongSurface (dtPolyRef startRef, const float *startPos, const float *endPos, const dtQueryFilter *filter, float *resultPos, dtPolyRef *visited, int *visitedCount, const int maxVisitedSize) const |
| Moves from the start to the end position constrained to the navigation mesh. More... | |
| dtStatus | raycast (dtPolyRef startRef, const float *startPos, const float *endPos, const dtQueryFilter *filter, float *t, float *hitNormal, dtPolyRef *path, int *pathCount, const int maxPath) const |
| Casts a 'walkability' ray along the surface of the navigation mesh from the start position toward the end position. More... | |
| dtStatus | raycast (dtPolyRef startRef, const float *startPos, const float *endPos, const dtQueryFilter *filter, const unsigned int options, dtRaycastHit *hit, dtPolyRef prevRef=0) const |
| Casts a 'walkability' ray along the surface of the navigation mesh from the start position toward the end position. More... | |
| dtStatus | findDistanceToWall (dtPolyRef startRef, const float *centerPos, const float maxRadius, const dtQueryFilter *filter, float *hitDist, float *hitPos, float *hitNormal) const |
| Finds the distance from the specified position to the nearest polygon wall. More... | |
| dtStatus | getPolyWallSegments (dtPolyRef ref, const dtQueryFilter *filter, float *segmentVerts, dtPolyRef *segmentRefs, int *segmentCount, const int maxSegments) const |
| Returns the segments for the specified polygon, optionally including portals. More... | |
| dtStatus | findRandomPoint (const dtQueryFilter *filter, float(*frand)(), dtPolyRef *randomRef, float *randomPt) const |
| Returns random location on navmesh. More... | |
| dtStatus | findRandomPointAroundCircle (dtPolyRef startRef, const float *centerPos, const float maxRadius, const dtQueryFilter *filter, float(*frand)(), dtPolyRef *randomRef, float *randomPt) const |
| Returns random location on navmesh within the reach of specified location. More... | |
| dtStatus | closestPointOnPoly (dtPolyRef ref, const float *pos, float *closest, bool *posOverPoly) const |
| Finds the closest point on the specified polygon. More... | |
| dtStatus | closestPointOnPolyBoundary (dtPolyRef ref, const float *pos, float *closest) const |
| Returns a point on the boundary closest to the source point if the source point is outside the polygon's xz-bounds. More... | |
| dtStatus | getPolyHeight (dtPolyRef ref, const float *pos, float *height) const |
| Gets the height of the polygon at the provided position using the height detail. More... | |
Miscellaneous Functions | |
| bool | isValidPolyRef (dtPolyRef ref, const dtQueryFilter *filter) const |
| Returns true if the polygon reference is valid and passes the filter restrictions. More... | |
| bool | isInClosedList (dtPolyRef ref) const |
| Returns true if the polygon reference is in the closed list. More... | |
| class dtNodePool * | getNodePool () const |
| Gets the node pool. More... | |
| const dtNavMesh * | getAttachedNavMesh () const |
| Gets the navigation mesh the query object is using. More... | |
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.
+ +| dtNavMeshQuery::dtNavMeshQuery | +( | +) | ++ |
| dtNavMeshQuery::~dtNavMeshQuery | +( | +) | ++ |
| dtStatus dtNavMeshQuery::closestPointOnPoly | +( | +dtPolyRef | +ref, | +
| + | + | const float * | +pos, | +
| + | + | float * | +closest, | +
| + | + | bool * | +posOverPoly | +
| + | ) | +const | +
Finds the closest point on the specified polygon.
+| [in] | ref | The reference id of the polygon. |
| [in] | pos | The position to check. [(x, y, z)] |
| [out] | closest | The closest point on the polygon. [(x, y, z)] |
| [out] | posOverPoly | True of the position is over the polygon. |
Uses the detail polygons to find the surface height. (Most accurate.)
+pos does not have to be within the bounds of the polygon or navigation mesh.
See closestPointOnPolyBoundary() for a limited but faster option.
+ +| dtStatus dtNavMeshQuery::closestPointOnPolyBoundary | +( | +dtPolyRef | +ref, | +
| + | + | const float * | +pos, | +
| + | + | float * | +closest | +
| + | ) | +const | +
Returns a point on the boundary closest to the source point if the source point is outside the polygon's xz-bounds.
+| [in] | ref | The reference id to the polygon. |
| [in] | pos | The position to check. [(x, y, z)] |
| [out] | closest | The closest point. [(x, y, z)] |
Much faster than closestPointOnPoly().
+If the provided position lies within the polygon's xz-bounds (above or below), then pos and closest will be equal.
The height of closest will be the polygon boundary. The height detail is not used.
pos does not have to be within the bounds of the polybon or the navigation mesh.
| dtStatus dtNavMeshQuery::finalizeSlicedFindPath | +( | +dtPolyRef * | +path, | +
| + | + | int * | +pathCount, | +
| + | + | const int | +maxPath | +
| + | ) | ++ |
Finalizes and returns the results of a sliced path query.
+| [out] | path | An ordered list of polygon references representing the path. (Start to end.) [(polyRef) * pathCount] |
| [out] | pathCount | The number of polygons returned in the path array. |
| [in] | maxPath | The max number of polygons the path array can hold. [Limit: >= 1] |
| dtStatus dtNavMeshQuery::finalizeSlicedFindPathPartial | +( | +const dtPolyRef * | +existing, | +
| + | + | const int | +existingSize, | +
| + | + | dtPolyRef * | +path, | +
| + | + | int * | +pathCount, | +
| + | + | const int | +maxPath | +
| + | ) | ++ |
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.
+| [in] | existing | An array of polygon references for the existing path. |
| [in] | existingSize | The number of polygon in the existing array. |
| [out] | path | An ordered list of polygon references representing the path. (Start to end.) [(polyRef) * pathCount] |
| [out] | pathCount | The number of polygons returned in the path array. |
| [in] | maxPath | The max number of polygons the path array can hold. [Limit: >= 1] |
| dtStatus dtNavMeshQuery::findDistanceToWall | +( | +dtPolyRef | +startRef, | +
| + | + | const float * | +centerPos, | +
| + | + | const float | +maxRadius, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | float * | +hitDist, | +
| + | + | float * | +hitPos, | +
| + | + | float * | +hitNormal | +
| + | ) | +const | +
Finds the distance from the specified position to the nearest polygon wall.
+| [in] | startRef | The reference id of the polygon containing centerPos. |
| [in] | centerPos | The center of the search circle. [(x, y, z)] |
| [in] | maxRadius | The radius of the search circle. |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | hitDist | The distance to the nearest wall from centerPos. |
| [out] | hitPos | The nearest position on the wall that was hit. [(x, y, z)] |
| [out] | hitNormal | The normalized ray formed from the wall point to the source point. [(x, y, z)] |
hitPos is not adjusted using the height detail data.
hitDist will equal the search radius if there is no wall within the radius. In this case the values of hitPos and hitNormal are undefined.
The normal will become unpredicable if hitDist is a very small number.
| dtStatus dtNavMeshQuery::findLocalNeighbourhood | +( | +dtPolyRef | +startRef, | +
| + | + | const float * | +centerPos, | +
| + | + | const float | +radius, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | dtPolyRef * | +resultRef, | +
| + | + | dtPolyRef * | +resultParent, | +
| + | + | int * | +resultCount, | +
| + | + | const int | +maxResult | +
| + | ) | +const | +
Finds the non-overlapping navigation polygons in the local neighbourhood around the center position.
+| [in] | startRef | The reference id of the polygon where the search starts. |
| [in] | centerPos | The center of the query circle. [(x, y, z)] |
| [in] | radius | The radius of the query circle. |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | resultRef | The reference ids of the polygons touched by the circle. |
| [out] | resultParent | The reference ids of the parent polygons for each result. Zero if a result polygon has no parent. [opt] |
| [out] | resultCount | The number of polygons found. |
| [in] | maxResult | The maximum number of polygons the result arrays can hold. |
This method is optimized for a small search radius and small number of result polygons.
+Candidate polygons are found by searching the navigation graph beginning at the start polygon.
+The same intersection test restrictions that apply to the findPolysAroundCircle mehtod applies to this method.
+The value of the center point is used as the start point for cost calculations. It is not projected onto the surface of the mesh, so its y-value will effect the costs.
+Intersection tests occur in 2D. All polygons and the search circle are projected onto the xz-plane. So the y-value of the center point does not effect intersection tests.
+If the result arrays are is too small to hold the entire result set, they will be filled to capacity.
+ +| dtStatus dtNavMeshQuery::findNearestPoly | +( | +const float * | +center, | +
| + | + | const float * | +halfExtents, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | dtPolyRef * | +nearestRef, | +
| + | + | float * | +nearestPt | +
| + | ) | +const | +
Finds the polygon nearest to the specified center point.
+[opt] means the specified parameter can be a null pointer, in that case the output parameter will not be set.
+| [in] | center | The center of the search box. [(x, y, z)] |
| [in] | halfExtents | The search distance along each axis. [(x, y, z)] |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | nearestRef | The reference id of the nearest polygon. Will be set to 0 if no polygon is found. |
| [out] | nearestPt | The nearest point on the polygon. Unchanged if no polygon is found. [opt] [(x, y, z)] |
nearestRef will be zero. So if in doubt, check nearestRef before using nearestPt. | dtStatus dtNavMeshQuery::findNearestPoly | +( | +const float * | +center, | +
| + | + | const float * | +halfExtents, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | dtPolyRef * | +nearestRef, | +
| + | + | float * | +nearestPt, | +
| + | + | bool * | +isOverPoly | +
| + | ) | +const | +
Finds the polygon nearest to the specified center point.
+[opt] means the specified parameter can be a null pointer, in that case the output parameter will not be set.
+| [in] | center | The center of the search box. [(x, y, z)] |
| [in] | halfExtents | The search distance along each axis. [(x, y, z)] |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | nearestRef | The reference id of the nearest polygon. Will be set to 0 if no polygon is found. |
| [out] | nearestPt | The nearest point on the polygon. Unchanged if no polygon is found. [opt] [(x, y, z)] |
| [out] | isOverPoly | Set to true if the point's X/Z coordinate lies inside the polygon, false otherwise. Unchanged if no polygon is found. [opt] |
| dtStatus dtNavMeshQuery::findPath | +( | +dtPolyRef | +startRef, | +
| + | + | dtPolyRef | +endRef, | +
| + | + | const float * | +startPos, | +
| + | + | const float * | +endPos, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | dtPolyRef * | +path, | +
| + | + | int * | +pathCount, | +
| + | + | const int | +maxPath | +
| + | ) | +const | +
Finds a path from the start polygon to the end polygon.
+| [in] | startRef | The refrence id of the start polygon. |
| [in] | endRef | The reference id of the end polygon. |
| [in] | startPos | A position within the start polygon. [(x, y, z)] |
| [in] | endPos | A position within the end polygon. [(x, y, z)] |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | path | An ordered list of polygon references representing the path. (Start to end.) [(polyRef) * pathCount] |
| [out] | pathCount | The number of polygons returned in the path array. |
| [in] | maxPath | The maximum number of polygons the path array can hold. [Limit: >= 1] |
If the end polygon cannot be reached through the navigation graph, the last polygon in the path will be the nearest the end polygon.
+If the path array is to small to hold the full result, it will be filled as far as possible from the start polygon toward the end polygon.
+The start and end positions are used to calculate traversal costs. (The y-values impact the result.)
+ +| dtStatus dtNavMeshQuery::findPolysAroundCircle | +( | +dtPolyRef | +startRef, | +
| + | + | const float * | +centerPos, | +
| + | + | const float | +radius, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | dtPolyRef * | +resultRef, | +
| + | + | dtPolyRef * | +resultParent, | +
| + | + | float * | +resultCost, | +
| + | + | int * | +resultCount, | +
| + | + | const int | +maxResult | +
| + | ) | +const | +
Finds the polygons along the navigation graph that touch the specified circle.
+| [in] | startRef | The reference id of the polygon where the search starts. |
| [in] | centerPos | The center of the search circle. [(x, y, z)] |
| [in] | radius | The radius of the search circle. |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | resultRef | The reference ids of the polygons touched by the circle. [opt] |
| [out] | resultParent | The reference ids of the parent polygons for each result. Zero if a result polygon has no parent. [opt] |
| [out] | resultCost | The search cost from centerPos to the polygon. [opt] |
| [out] | resultCount | The number of polygons found. [opt] |
| [in] | maxResult | The maximum number of polygons the result arrays can hold. |
At least one result array must be provided.
+The order of the result set is from least to highest cost to reach the polygon.
+A common use case for this method is to perform Dijkstra searches. Candidate polygons are found by searching the graph beginning at the start polygon.
+If a polygon is not found via the graph search, even if it intersects the search circle, it will not be included in the result set. For example:
+polyA is the start polygon. polyB shares an edge with polyA. (Is adjacent.) polyC shares an edge with polyB, but not with polyA Even if the search circle overlaps polyC, it will not be included in the result set unless polyB is also in the set.
+The value of the center point is used as the start position for cost calculations. It is not projected onto the surface of the mesh, so its y-value will effect the costs.
+Intersection tests occur in 2D. All polygons and the search circle are projected onto the xz-plane. So the y-value of the center point does not effect intersection tests.
+If the result arrays are to small to hold the entire result set, they will be filled to capacity.
+ +| dtStatus dtNavMeshQuery::findPolysAroundShape | +( | +dtPolyRef | +startRef, | +
| + | + | const float * | +verts, | +
| + | + | const int | +nverts, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | dtPolyRef * | +resultRef, | +
| + | + | dtPolyRef * | +resultParent, | +
| + | + | float * | +resultCost, | +
| + | + | int * | +resultCount, | +
| + | + | const int | +maxResult | +
| + | ) | +const | +
Finds the polygons along the naviation graph that touch the specified convex polygon.
+| [in] | startRef | The reference id of the polygon where the search starts. |
| [in] | verts | The vertices describing the convex polygon. (CCW) [(x, y, z) * nverts] |
| [in] | nverts | The number of vertices in the polygon. |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | resultRef | The reference ids of the polygons touched by the search polygon. [opt] |
| [out] | resultParent | The reference ids of the parent polygons for each result. Zero if a result polygon has no parent. [opt] |
| [out] | resultCost | The search cost from the centroid point to the polygon. [opt] |
| [out] | resultCount | The number of polygons found. |
| [in] | maxResult | The maximum number of polygons the result arrays can hold. |
The order of the result set is from least to highest cost.
+At least one result array must be provided.
+A common use case for this method is to perform Dijkstra searches. Candidate polygons are found by searching the graph beginning at the start polygon.
+The same intersection test restrictions that apply to findPolysAroundCircle() method apply to this method.
+The 3D centroid of the search polygon is used as the start position for cost calculations.
+Intersection tests occur in 2D. All polygons are projected onto the xz-plane. So the y-values of the vertices do not effect intersection tests.
+If the result arrays are is too small to hold the entire result set, they will be filled to capacity.
+ +| dtStatus dtNavMeshQuery::findRandomPoint | +( | +const dtQueryFilter * | +filter, | +
| + | + | float(*)() | +frand, | +
| + | + | dtPolyRef * | +randomRef, | +
| + | + | float * | +randomPt | +
| + | ) | +const | +
Returns random location on navmesh.
+Polygons are chosen weighted by area. The search runs in linear related to number of polygon.
| [in] | filter | The polygon filter to apply to the query. |
| [in] | frand | Function returning a random number [0..1). |
| [out] | randomRef | The reference id of the random location. |
| [out] | randomPt | The random location. |
| dtStatus dtNavMeshQuery::findRandomPointAroundCircle | +( | +dtPolyRef | +startRef, | +
| + | + | const float * | +centerPos, | +
| + | + | const float | +maxRadius, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | float(*)() | +frand, | +
| + | + | dtPolyRef * | +randomRef, | +
| + | + | float * | +randomPt | +
| + | ) | +const | +
Returns random location on navmesh within the reach of specified location.
+Polygons are chosen weighted by area. The search runs in linear related to number of polygon. The location is not exactly constrained by the circle, but it limits the visited polygons.
| [in] | startRef | The reference id of the polygon where the search starts. |
| [in] | centerPos | The center of the search circle. [(x, y, z)] |
| [in] | maxRadius | The radius of the search circle. [Units: wu] |
| [in] | filter | The polygon filter to apply to the query. |
| [in] | frand | Function returning a random number [0..1). |
| [out] | randomRef | The reference id of the random location. |
| [out] | randomPt | The random location. [(x, y, z)] |
| dtStatus dtNavMeshQuery::findStraightPath | +( | +const float * | +startPos, | +
| + | + | const float * | +endPos, | +
| + | + | const dtPolyRef * | +path, | +
| + | + | const int | +pathSize, | +
| + | + | float * | +straightPath, | +
| + | + | unsigned char * | +straightPathFlags, | +
| + | + | dtPolyRef * | +straightPathRefs, | +
| + | + | int * | +straightPathCount, | +
| + | + | const int | +maxStraightPath, | +
| + | + | const int | +options = 0 |
+
| + | ) | +const | +
Finds the straight path from the start to the end position within the polygon corridor.
+| [in] | startPos | Path start position. [(x, y, z)] |
| [in] | endPos | Path end position. [(x, y, z)] |
| [in] | path | An array of polygon references that represent the path corridor. |
| [in] | pathSize | The number of polygons in the path array. |
| [out] | straightPath | Points describing the straight path. [(x, y, z) * straightPathCount]. |
| [out] | straightPathFlags | Flags describing each point. (See: dtStraightPathFlags) [opt] |
| [out] | straightPathRefs | The reference id of the polygon that is being entered at each point. [opt] |
| [out] | straightPathCount | The number of points in the straight path. |
| [in] | maxStraightPath | The maximum number of points the straight path arrays can hold. [Limit: > 0] |
| [in] | options | Query options. (see: dtStraightPathOptions) |
This method peforms what is often called 'string pulling'.
+The start position is clamped to the first polygon in the path, and the end position is clamped to the last. So the start and end positions should normally be within or very near the first and last polygons respectively.
+The returned polygon references represent the reference id of the polygon that is entered at the associated path position. The reference id associated with the end point will always be zero. This allows, for example, matching off-mesh link points to their representative polygons.
+If the provided result buffers are too small for the entire result set, they will be filled as far as possible from the start toward the end position.
+ +
+
|
+ +inline | +
Gets the navigation mesh the query object is using.
+
+
|
+ +inline | +
Gets the node pool.
+| dtStatus dtNavMeshQuery::getPathFromDijkstraSearch | +( | +dtPolyRef | +endRef, | +
| + | + | dtPolyRef * | +path, | +
| + | + | int * | +pathCount, | +
| + | + | int | +maxPath | +
| + | ) | +const | +
Gets a path from the explored nodes in the previous search.
+| [in] | endRef | The reference id of the end polygon. |
| [out] | path | An ordered list of polygon references representing the path. (Start to end.) [(polyRef) * pathCount] |
| [out] | pathCount | The number of polygons returned in the path array. |
| [in] | maxPath | The maximum number of polygons the path array can hold. [Limit: >= 0] |
endRef was not explored in the previous search. Returns DT_SUCCESS | DT_BUFFER_TOO_SMALL if path cannot contain the entire path. In this case it is filled to capacity with a partial path. Otherwise returns DT_SUCCESS. | dtStatus dtNavMeshQuery::getPolyHeight | +( | +dtPolyRef | +ref, | +
| + | + | const float * | +pos, | +
| + | + | float * | +height | +
| + | ) | +const | +
Gets the height of the polygon at the provided position using the height detail.
+(Most accurate.)
| [in] | ref | The reference id of the polygon. |
| [in] | pos | A position within the xz-bounds of the polygon. [(x, y, z)] |
| [out] | height | The height at the surface of the polygon. |
Will return DT_FAILURE | DT_INVALID_PARAM if the provided position is outside the xz-bounds of the polygon.
+ +| dtStatus dtNavMeshQuery::getPolyWallSegments | +( | +dtPolyRef | +ref, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | float * | +segmentVerts, | +
| + | + | dtPolyRef * | +segmentRefs, | +
| + | + | int * | +segmentCount, | +
| + | + | const int | +maxSegments | +
| + | ) | +const | +
Returns the segments for the specified polygon, optionally including portals.
+| [in] | ref | The reference id of the polygon. |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | segmentVerts | The segments. [(ax, ay, az, bx, by, bz) * segmentCount] |
| [out] | segmentRefs | The reference ids of each segment's neighbor polygon. Or zero if the segment is a wall. [opt] [(parentRef) * segmentCount] |
| [out] | segmentCount | The number of segments returned. |
| [in] | maxSegments | The maximum number of segments the result arrays can hold. |
If the segmentRefs parameter is provided, then all polygon segments will be returned. Otherwise only the wall segments are returned.
A segment that is normally a portal will be included in the result set as a wall if the filter results in the neighbor polygon becoomming impassable.
The segmentVerts and segmentRefs buffers should normally be sized for the maximum segments per polygon of the source navigation mesh.
| dtStatus dtNavMeshQuery::init | +( | +const dtNavMesh * | +nav, | +
| + | + | const int | +maxNodes | +
| + | ) | ++ |
Initializes the query object.
+| [in] | nav | Pointer to the dtNavMesh object to use for all queries. |
| [in] | maxNodes | Maximum number of search nodes. [Limits: 0 < value <= 65535] |
Must be the first function called after construction, before other functions are used.
+This function can be used multiple times.
+ +| dtStatus dtNavMeshQuery::initSlicedFindPath | +( | +dtPolyRef | +startRef, | +
| + | + | dtPolyRef | +endRef, | +
| + | + | const float * | +startPos, | +
| + | + | const float * | +endPos, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | const unsigned int | +options = 0 |
+
| + | ) | ++ |
Intializes a sliced path query.
+| [in] | startRef | The refrence id of the start polygon. |
| [in] | endRef | The reference id of the end polygon. |
| [in] | startPos | A position within the start polygon. [(x, y, z)] |
| [in] | endPos | A position within the end polygon. [(x, y, z)] |
| [in] | filter | The polygon filter to apply to the query. |
| [in] | options | query options (see: dtFindPathOptions) |
The filter pointer is stored and used for the duration of the sliced path query.
| bool dtNavMeshQuery::isInClosedList | +( | +dtPolyRef | +ref | ) | +const | +
Returns true if the polygon reference is in the closed list.
+| [in] | ref | The reference id of the polygon to check. |
The closed list is the list of polygons that were fully evaluated during the last navigation graph search. (A* or Dijkstra)
+ +| bool dtNavMeshQuery::isValidPolyRef | +( | +dtPolyRef | +ref, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | +const | +
Returns true if the polygon reference is valid and passes the filter restrictions.
+| [in] | ref | The polygon reference to check. |
| [in] | filter | The filter to apply. |
| dtStatus dtNavMeshQuery::moveAlongSurface | +( | +dtPolyRef | +startRef, | +
| + | + | const float * | +startPos, | +
| + | + | const float * | +endPos, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | float * | +resultPos, | +
| + | + | dtPolyRef * | +visited, | +
| + | + | int * | +visitedCount, | +
| + | + | const int | +maxVisitedSize | +
| + | ) | +const | +
Moves from the start to the end position constrained to the navigation mesh.
+| [in] | startRef | The reference id of the start polygon. |
| [in] | startPos | A position of the mover within the start polygon. [(x, y, x)] |
| [in] | endPos | The desired end position of the mover. [(x, y, z)] |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | resultPos | The result position of the mover. [(x, y, z)] |
| [out] | visited | The reference ids of the polygons visited during the move. |
| [out] | visitedCount | The number of polygons visited during the move. |
| [in] | maxVisitedSize | The maximum number of polygons the visited array can hold. |
This method is optimized for small delta movement and a small number of polygons. If used for too great a distance, the result set will form an incomplete path.
+resultPos will equal the endPos if the end is reached. Otherwise the closest reachable position will be returned.
resultPos is not projected onto the surface of the navigation mesh. Use getPolyHeight if this is needed.
This method treats the end position in the same manner as the raycast method. (As a 2D point.) See that method's documentation for details.
+If the visited array is too small to hold the entire result set, it will be filled as far as possible from the start position toward the end position.
| dtStatus dtNavMeshQuery::queryPolygons | +( | +const float * | +center, | +
| + | + | const float * | +halfExtents, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | dtPolyQuery * | +query | +
| + | ) | +const | +
Finds polygons that overlap the search box.
+| [in] | center | The center of the search box. [(x, y, z)] |
| [in] | halfExtents | The search distance along each axis. [(x, y, z)] |
| [in] | filter | The polygon filter to apply to the query. |
| [in] | query | The query. Polygons found will be batched together and passed to this query. |
The query will be invoked with batches of polygons. Polygons passed to the query have bounding boxes that overlap with the center and halfExtents passed to this function. The dtPolyQuery::process function is invoked multiple times until all overlapping polygons have been processed.
+ +| dtStatus dtNavMeshQuery::queryPolygons | +( | +const float * | +center, | +
| + | + | const float * | +halfExtents, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | dtPolyRef * | +polys, | +
| + | + | int * | +polyCount, | +
| + | + | const int | +maxPolys | +
| + | ) | +const | +
Finds polygons that overlap the search box.
+| [in] | center | The center of the search box. [(x, y, z)] |
| [in] | halfExtents | The search distance along each axis. [(x, y, z)] |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | polys | The reference ids of the polygons that overlap the query box. |
| [out] | polyCount | The number of polygons in the search result. |
| [in] | maxPolys | The maximum number of polygons the search result can hold. |
If no polygons are found, the function will return DT_SUCCESS with a polyCount of zero.
If polys is too small to hold the entire result set, then the array will be filled to capacity. The method of choosing which polygons from the full set are included in the partial result set is undefined.
| dtStatus dtNavMeshQuery::raycast | +( | +dtPolyRef | +startRef, | +
| + | + | const float * | +startPos, | +
| + | + | const float * | +endPos, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | const unsigned int | +options, | +
| + | + | dtRaycastHit * | +hit, | +
| + | + | dtPolyRef | +prevRef = 0 |
+
| + | ) | +const | +
Casts a 'walkability' ray along the surface of the navigation mesh from the start position toward the end position.
+| [in] | startRef | The reference id of the start polygon. |
| [in] | startPos | A position within the start polygon representing the start of the ray. [(x, y, z)] |
| [in] | endPos | The position to cast the ray toward. [(x, y, z)] |
| [in] | filter | The polygon filter to apply to the query. |
| [in] | options | govern how the raycast behaves. See dtRaycastOptions |
| [out] | hit | Pointer to a raycast hit structure which will be filled by the results. |
| [in] | prevRef | parent of start ref. Used during for cost calculation [opt] |
This method is meant to be used for quick, short distance checks.
+If the path array is too small to hold the result, it will be filled as far as possible from the start postion toward the end position.
+Using the Hit Parameter t of RaycastHit
+If the hit parameter is a very high value (FLT_MAX), then the ray has hit the end position. In this case the path represents a valid corridor to the end position and the value of hitNormal is undefined.
If the hit parameter is zero, then the start position is on the wall that was hit and the value of hitNormal is undefined.
If 0 < t < 1.0 then the following applies:
+Use Case Restriction
+The raycast ignores the y-value of the end position. (2D check.) This places significant limits on how it can be used. For example:
+Consider a scene where there is a main floor with a second floor balcony that hangs over the main floor. So the first floor mesh extends below the balcony mesh. The start position is somewhere on the first floor. The end position is on the balcony.
+The raycast will search toward the end position along the first floor mesh. If it reaches the end position's xz-coordinates it will indicate FLT_MAX (no wall hit), meaning it reached the end position. This is one example of why this method is meant for short distance checks.
+ +| dtStatus dtNavMeshQuery::raycast | +( | +dtPolyRef | +startRef, | +
| + | + | const float * | +startPos, | +
| + | + | const float * | +endPos, | +
| + | + | const dtQueryFilter * | +filter, | +
| + | + | float * | +t, | +
| + | + | float * | +hitNormal, | +
| + | + | dtPolyRef * | +path, | +
| + | + | int * | +pathCount, | +
| + | + | const int | +maxPath | +
| + | ) | +const | +
Casts a 'walkability' ray along the surface of the navigation mesh from the start position toward the end position.
+| [in] | startRef | The reference id of the start polygon. |
| [in] | startPos | A position within the start polygon representing the start of the ray. [(x, y, z)] |
| [in] | endPos | The position to cast the ray toward. [(x, y, z)] |
| [in] | filter | The polygon filter to apply to the query. |
| [out] | t | The hit parameter. (FLT_MAX if no wall hit.) |
| [out] | hitNormal | The normal of the nearest wall hit. [(x, y, z)] |
| [out] | path | The reference ids of the visited polygons. [opt] |
| [out] | pathCount | The number of visited polygons. [opt] |
| [in] | maxPath | The maximum number of polygons the path array can hold. |
This method is meant to be used for quick, short distance checks.
+If the path array is too small to hold the result, it will be filled as far as possible from the start postion toward the end position.
+Using the Hit Parameter (t)
+If the hit parameter is a very high value (FLT_MAX), then the ray has hit the end position. In this case the path represents a valid corridor to the end position and the value of hitNormal is undefined.
If the hit parameter is zero, then the start position is on the wall that was hit and the value of hitNormal is undefined.
If 0 < t < 1.0 then the following applies:
+Use Case Restriction
+The raycast ignores the y-value of the end position. (2D check.) This places significant limits on how it can be used. For example:
+Consider a scene where there is a main floor with a second floor balcony that hangs over the main floor. So the first floor mesh extends below the balcony mesh. The start position is somewhere on the first floor. The end position is on the balcony.
+The raycast will search toward the end position along the first floor mesh. If it reaches the end position's xz-coordinates it will indicate FLT_MAX (no wall hit), meaning it reached the end position. This is one example of why this method is meant for short distance checks.
+ +| dtStatus dtNavMeshQuery::updateSlicedFindPath | +( | +const int | +maxIter, | +
| + | + | int * | +doneIters | +
| + | ) | ++ |
Updates an in-progress sliced path query.
+| [in] | maxIter | The maximum number of iterations to perform. |
| [out] | doneIters | The actual number of iterations completed. [opt] |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtNodePool, including all inherited members.
+| clear() | dtNodePool | |
| dtNodePool(int maxNodes, int hashSize) | dtNodePool | |
| findNode(dtPolyRef id, unsigned char state) | dtNodePool | |
| findNodes(dtPolyRef id, dtNode **nodes, const int maxNodes) | dtNodePool | |
| getFirst(int bucket) const | dtNodePool | inline |
| getHashSize() const | dtNodePool | inline |
| getMaxNodes() const | dtNodePool | inline |
| getMemUsed() const | dtNodePool | inline |
| getNext(int i) const | dtNodePool | inline |
| getNode(dtPolyRef id, unsigned char state=0) | dtNodePool | |
| getNodeAtIdx(unsigned int idx) | dtNodePool | inline |
| getNodeAtIdx(unsigned int idx) const | dtNodePool | inline |
| getNodeCount() const | dtNodePool | inline |
| getNodeIdx(const dtNode *node) const | dtNodePool | inline |
| ~dtNodePool() | dtNodePool |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <DetourNode.h>
+Public Member Functions | |
| dtNodePool (int maxNodes, int hashSize) | |
| ~dtNodePool () | |
| void | clear () |
| dtNode * | getNode (dtPolyRef id, unsigned char state=0) |
| dtNode * | findNode (dtPolyRef id, unsigned char state) |
| unsigned int | findNodes (dtPolyRef id, dtNode **nodes, const int maxNodes) |
| unsigned int | getNodeIdx (const dtNode *node) const |
| dtNode * | getNodeAtIdx (unsigned int idx) |
| const dtNode * | getNodeAtIdx (unsigned int idx) const |
| int | getMemUsed () const |
| int | getMaxNodes () const |
| int | getHashSize () const |
| dtNodeIndex | getFirst (int bucket) const |
| dtNodeIndex | getNext (int i) const |
| int | getNodeCount () const |
| dtNodePool::dtNodePool | +( | +int | +maxNodes, | +
| + | + | int | +hashSize | +
| + | ) | ++ |
| dtNodePool::~dtNodePool | +( | +) | ++ |
| void dtNodePool::clear | +( | +) | ++ |
| dtNode * dtNodePool::findNode | +( | +dtPolyRef | +id, | +
| + | + | unsigned char | +state | +
| + | ) | ++ |
| unsigned int dtNodePool::findNodes | +( | +dtPolyRef | +id, | +
| + | + | dtNode ** | +nodes, | +
| + | + | const int | +maxNodes | +
| + | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| dtNode * dtNodePool::getNode | +( | +dtPolyRef | +id, | +
| + | + | unsigned char | +state = 0 |
+
| + | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtNodeQueue, including all inherited members.
+| clear() | dtNodeQueue | inline |
| dtNodeQueue(int n) | dtNodeQueue | |
| empty() const | dtNodeQueue | inline |
| getCapacity() const | dtNodeQueue | inline |
| getMemUsed() const | dtNodeQueue | inline |
| modify(dtNode *node) | dtNodeQueue | inline |
| pop() | dtNodeQueue | inline |
| push(dtNode *node) | dtNodeQueue | inline |
| top() | dtNodeQueue | inline |
| ~dtNodeQueue() | dtNodeQueue |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <DetourNode.h>
+Public Member Functions | |
| dtNodeQueue (int n) | |
| ~dtNodeQueue () | |
| void | clear () |
| dtNode * | top () |
| dtNode * | pop () |
| void | push (dtNode *node) |
| void | modify (dtNode *node) |
| bool | empty () const |
| int | getMemUsed () const |
| int | getCapacity () const |
| dtNodeQueue::dtNodeQueue | +( | +int | +n | ) | ++ |
| dtNodeQueue::~dtNodeQueue | +( | +) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtObstacleAvoidanceDebugData, including all inherited members.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <DetourObstacleAvoidance.h>
+Public Member Functions | |
| dtObstacleAvoidanceDebugData () | |
| ~dtObstacleAvoidanceDebugData () | |
| bool | init (const int maxSamples) |
| void | reset () |
| void | addSample (const float *vel, const float ssize, const float pen, const float vpen, const float vcpen, const float spen, const float tpen) |
| void | normalizeSamples () |
| int | getSampleCount () const |
| const float * | getSampleVelocity (const int i) const |
| float | getSampleSize (const int i) const |
| float | getSamplePenalty (const int i) const |
| float | getSampleDesiredVelocityPenalty (const int i) const |
| float | getSampleCurrentVelocityPenalty (const int i) const |
| float | getSamplePreferredSidePenalty (const int i) const |
| float | getSampleCollisionTimePenalty (const int i) const |
| dtObstacleAvoidanceDebugData::dtObstacleAvoidanceDebugData | +( | +) | ++ |
| dtObstacleAvoidanceDebugData::~dtObstacleAvoidanceDebugData | +( | +) | ++ |
| void dtObstacleAvoidanceDebugData::addSample | +( | +const float * | +vel, | +
| + | + | const float | +ssize, | +
| + | + | const float | +pen, | +
| + | + | const float | +vpen, | +
| + | + | const float | +vcpen, | +
| + | + | const float | +spen, | +
| + | + | const float | +tpen | +
| + | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| bool dtObstacleAvoidanceDebugData::init | +( | +const int | +maxSamples | ) | ++ |
| void dtObstacleAvoidanceDebugData::normalizeSamples | +( | +) | ++ |
| void dtObstacleAvoidanceDebugData::reset | +( | +) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtObstacleAvoidanceQuery, including all inherited members.
+| addCircle(const float *pos, const float rad, const float *vel, const float *dvel) | dtObstacleAvoidanceQuery | |
| addSegment(const float *p, const float *q) | dtObstacleAvoidanceQuery | |
| dtObstacleAvoidanceQuery() | dtObstacleAvoidanceQuery | |
| getObstacleCircle(const int i) | dtObstacleAvoidanceQuery | inline |
| getObstacleCircleCount() const | dtObstacleAvoidanceQuery | inline |
| getObstacleSegment(const int i) | dtObstacleAvoidanceQuery | inline |
| getObstacleSegmentCount() const | dtObstacleAvoidanceQuery | inline |
| init(const int maxCircles, const int maxSegments) | dtObstacleAvoidanceQuery | |
| reset() | dtObstacleAvoidanceQuery | |
| sampleVelocityAdaptive(const float *pos, const float rad, const float vmax, const float *vel, const float *dvel, float *nvel, const dtObstacleAvoidanceParams *params, dtObstacleAvoidanceDebugData *debug=0) | dtObstacleAvoidanceQuery | |
| sampleVelocityGrid(const float *pos, const float rad, const float vmax, const float *vel, const float *dvel, float *nvel, const dtObstacleAvoidanceParams *params, dtObstacleAvoidanceDebugData *debug=0) | dtObstacleAvoidanceQuery | |
| ~dtObstacleAvoidanceQuery() | dtObstacleAvoidanceQuery |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <DetourObstacleAvoidance.h>
+Public Member Functions | |
| dtObstacleAvoidanceQuery () | |
| ~dtObstacleAvoidanceQuery () | |
| bool | init (const int maxCircles, const int maxSegments) |
| void | reset () |
| void | addCircle (const float *pos, const float rad, const float *vel, const float *dvel) |
| void | addSegment (const float *p, const float *q) |
| int | sampleVelocityGrid (const float *pos, const float rad, const float vmax, const float *vel, const float *dvel, float *nvel, const dtObstacleAvoidanceParams *params, dtObstacleAvoidanceDebugData *debug=0) |
| int | sampleVelocityAdaptive (const float *pos, const float rad, const float vmax, const float *vel, const float *dvel, float *nvel, const dtObstacleAvoidanceParams *params, dtObstacleAvoidanceDebugData *debug=0) |
| int | getObstacleCircleCount () const |
| const dtObstacleCircle * | getObstacleCircle (const int i) |
| int | getObstacleSegmentCount () const |
| const dtObstacleSegment * | getObstacleSegment (const int i) |
| dtObstacleAvoidanceQuery::dtObstacleAvoidanceQuery | +( | +) | ++ |
| dtObstacleAvoidanceQuery::~dtObstacleAvoidanceQuery | +( | +) | ++ |
| void dtObstacleAvoidanceQuery::addCircle | +( | +const float * | +pos, | +
| + | + | const float | +rad, | +
| + | + | const float * | +vel, | +
| + | + | const float * | +dvel | +
| + | ) | ++ |
| void dtObstacleAvoidanceQuery::addSegment | +( | +const float * | +p, | +
| + | + | const float * | +q | +
| + | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| bool dtObstacleAvoidanceQuery::init | +( | +const int | +maxCircles, | +
| + | + | const int | +maxSegments | +
| + | ) | ++ |
| void dtObstacleAvoidanceQuery::reset | +( | +) | ++ |
| int dtObstacleAvoidanceQuery::sampleVelocityAdaptive | +( | +const float * | +pos, | +
| + | + | const float | +rad, | +
| + | + | const float | +vmax, | +
| + | + | const float * | +vel, | +
| + | + | const float * | +dvel, | +
| + | + | float * | +nvel, | +
| + | + | const dtObstacleAvoidanceParams * | +params, | +
| + | + | dtObstacleAvoidanceDebugData * | +debug = 0 |
+
| + | ) | ++ |
| int dtObstacleAvoidanceQuery::sampleVelocityGrid | +( | +const float * | +pos, | +
| + | + | const float | +rad, | +
| + | + | const float | +vmax, | +
| + | + | const float * | +vel, | +
| + | + | const float * | +dvel, | +
| + | + | float * | +nvel, | +
| + | + | const dtObstacleAvoidanceParams * | +params, | +
| + | + | dtObstacleAvoidanceDebugData * | +debug = 0 |
+
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtPathCorridor, including all inherited members.
+| dtPathCorridor() | dtPathCorridor | |
| findCorners(float *cornerVerts, unsigned char *cornerFlags, dtPolyRef *cornerPolys, const int maxCorners, dtNavMeshQuery *navquery, const dtQueryFilter *filter) | dtPathCorridor | |
| fixPathStart(dtPolyRef safeRef, const float *safePos) | dtPathCorridor | |
| getFirstPoly() const | dtPathCorridor | inline |
| getLastPoly() const | dtPathCorridor | inline |
| getPath() const | dtPathCorridor | inline |
| getPathCount() const | dtPathCorridor | inline |
| getPos() const | dtPathCorridor | inline |
| getTarget() const | dtPathCorridor | inline |
| init(const int maxPath) | dtPathCorridor | |
| isValid(const int maxLookAhead, dtNavMeshQuery *navquery, const dtQueryFilter *filter) | dtPathCorridor | |
| moveOverOffmeshConnection(dtPolyRef offMeshConRef, dtPolyRef *refs, float *startPos, float *endPos, dtNavMeshQuery *navquery) | dtPathCorridor | |
| movePosition(const float *npos, dtNavMeshQuery *navquery, const dtQueryFilter *filter) | dtPathCorridor | |
| moveTargetPosition(const float *npos, dtNavMeshQuery *navquery, const dtQueryFilter *filter) | dtPathCorridor | |
| optimizePathTopology(dtNavMeshQuery *navquery, const dtQueryFilter *filter) | dtPathCorridor | |
| optimizePathVisibility(const float *next, const float pathOptimizationRange, dtNavMeshQuery *navquery, const dtQueryFilter *filter) | dtPathCorridor | |
| reset(dtPolyRef ref, const float *pos) | dtPathCorridor | |
| setCorridor(const float *target, const dtPolyRef *polys, const int npath) | dtPathCorridor | |
| trimInvalidPath(dtPolyRef safeRef, const float *safePos, dtNavMeshQuery *navquery, const dtQueryFilter *filter) | dtPathCorridor | |
| ~dtPathCorridor() | dtPathCorridor |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Represents a dynamic polygon corridor used to plan agent movement. + More...
+ +#include <DetourPathCorridor.h>
+Public Member Functions | |
| dtPathCorridor () | |
| ~dtPathCorridor () | |
| bool | init (const int maxPath) |
| Allocates the corridor's path buffer. More... | |
| void | reset (dtPolyRef ref, const float *pos) |
| Resets the path corridor to the specified position. More... | |
| int | findCorners (float *cornerVerts, unsigned char *cornerFlags, dtPolyRef *cornerPolys, const int maxCorners, dtNavMeshQuery *navquery, const dtQueryFilter *filter) |
| Finds the corners in the corridor from the position toward the target. More... | |
| void | optimizePathVisibility (const float *next, const float pathOptimizationRange, dtNavMeshQuery *navquery, const dtQueryFilter *filter) |
| Attempts to optimize the path if the specified point is visible from the current position. More... | |
| bool | optimizePathTopology (dtNavMeshQuery *navquery, const dtQueryFilter *filter) |
| Attempts to optimize the path using a local area search. More... | |
| bool | moveOverOffmeshConnection (dtPolyRef offMeshConRef, dtPolyRef *refs, float *startPos, float *endPos, dtNavMeshQuery *navquery) |
| bool | fixPathStart (dtPolyRef safeRef, const float *safePos) |
| bool | trimInvalidPath (dtPolyRef safeRef, const float *safePos, dtNavMeshQuery *navquery, const dtQueryFilter *filter) |
| bool | isValid (const int maxLookAhead, dtNavMeshQuery *navquery, const dtQueryFilter *filter) |
| Checks the current corridor path to see if its polygon references remain valid. More... | |
| bool | movePosition (const float *npos, dtNavMeshQuery *navquery, const dtQueryFilter *filter) |
| Moves the position from the current location to the desired location, adjusting the corridor as needed to reflect the change. More... | |
| bool | moveTargetPosition (const float *npos, dtNavMeshQuery *navquery, const dtQueryFilter *filter) |
| Moves the target from the curent location to the desired location, adjusting the corridor as needed to reflect the change. More... | |
| void | setCorridor (const float *target, const dtPolyRef *polys, const int npath) |
| Loads a new path and target into the corridor. More... | |
| const float * | getPos () const |
| Gets the current position within the corridor. More... | |
| const float * | getTarget () const |
| Gets the current target within the corridor. More... | |
| dtPolyRef | getFirstPoly () const |
| The polygon reference id of the first polygon in the corridor, the polygon containing the position. More... | |
| dtPolyRef | getLastPoly () const |
| The polygon reference id of the last polygon in the corridor, the polygon containing the target. More... | |
| const dtPolyRef * | getPath () const |
| The corridor's path. More... | |
| int | getPathCount () const |
| The number of polygons in the current corridor path. More... | |
Represents a dynamic polygon corridor used to plan agent movement.
+,
+The corridor is loaded with a path, usually obtained from a dtNavMeshQuery::findPath() query. The corridor is then used to plan local movement, with the corridor automatically updating as needed to deal with inaccurate agent locomotion.
+Example of a common use case:
+The corridor position and target are always constrained to the navigation mesh.
+One of the difficulties in maintaining a path is that floating point errors, locomotion inaccuracies, and/or local steering can result in the agent crossing the boundary of the path corridor, temporarily invalidating the path. This class uses local mesh queries to detect and update the corridor as needed to handle these types of issues.
+The fact that local mesh queries are used to move the position and target locations results in two beahviors that need to be considered:
+Every time a move function is used there is a chance that the path will become non-optimial. Basically, the further the target is moved from its original location, and the further the position is moved outside the original corridor, the more likely the path will become non-optimal. This issue can be addressed by periodically running the optimizePathTopology() and optimizePathVisibility() methods.
+All local mesh queries have distance limitations. (Review the dtNavMeshQuery methods for details.) So the most accurate use case is to move the position and target in small increments. If a large increment is used, then the corridor may not be able to accurately find the new location. Because of this limiation, if a position is moved in a large increment, then compare the desired and resulting polygon references. If the two do not match, then path replanning may be needed. E.g. If you move the target, check getLastPoly() to see if it is the expected polygon.
+| dtPathCorridor::dtPathCorridor | +( | +) | ++ |
| dtPathCorridor::~dtPathCorridor | +( | +) | ++ |
| int dtPathCorridor::findCorners | +( | +float * | +cornerVerts, | +
| + | + | unsigned char * | +cornerFlags, | +
| + | + | dtPolyRef * | +cornerPolys, | +
| + | + | const int | +maxCorners, | +
| + | + | dtNavMeshQuery * | +navquery, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | ++ |
Finds the corners in the corridor from the position toward the target.
+(The straightened path.)
| [out] | cornerVerts | The corner vertices. [(x, y, z) * cornerCount] [Size: <= maxCorners] |
| [out] | cornerFlags | The flag for each corner. [(flag) * cornerCount] [Size: <= maxCorners] |
| [out] | cornerPolys | The polygon reference for each corner. [(polyRef) * cornerCount] [Size: <= maxCorners] |
| [in] | maxCorners | The maximum number of corners the buffers can hold. |
| [in] | navquery | The query object used to build the corridor. |
| [in] | filter | The filter to apply to the operation. |
maxCorners]This is the function used to plan local movement within the corridor. One or more corners can be detected in order to plan movement. It performs essentially the same function as dtNavMeshQuery::findStraightPath.
+Due to internal optimizations, the maximum number of corners returned will be (maxCorners - 1) For example: If the buffers are sized to hold 10 corners, the function will never return more than 9 corners. So if 10 corners are needed, the buffers should be sized for 11 corners.
If the target is within range, it will be the last corner and have a polygon reference id of zero.
+ +| bool dtPathCorridor::fixPathStart | +( | +dtPolyRef | +safeRef, | +
| + | + | const float * | +safePos | +
| + | ) | ++ |
+
|
+ +inline | +
The polygon reference id of the first polygon in the corridor, the polygon containing the position.
+
+
|
+ +inline | +
The polygon reference id of the last polygon in the corridor, the polygon containing the target.
+
+
|
+ +inline | +
The corridor's path.
+
+
|
+ +inline | +
The number of polygons in the current corridor path.
+
+
|
+ +inline | +
Gets the current position within the corridor.
+(In the first polygon.)
+
|
+ +inline | +
Gets the current target within the corridor.
+(In the last polygon.)
| bool dtPathCorridor::init | +( | +const int | +maxPath | ) | ++ |
Allocates the corridor's path buffer.
+| [in] | maxPath | The maximum path size the corridor can handle. |
| bool dtPathCorridor::isValid | +( | +const int | +maxLookAhead, | +
| + | + | dtNavMeshQuery * | +navquery, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | ++ |
Checks the current corridor path to see if its polygon references remain valid.
+| [in] | maxLookAhead | The number of polygons from the beginning of the corridor to search. |
| [in] | navquery | The query object used to build the corridor. |
| [in] | filter | The filter to apply to the operation. + |
The path can be invalidated if there are structural changes to the underlying navigation mesh, or the state of a polygon within the path changes resulting in it being filtered out. (E.g. An exclusion or inclusion flag changes.)
+ +| bool dtPathCorridor::moveOverOffmeshConnection | +( | +dtPolyRef | +offMeshConRef, | +
| + | + | dtPolyRef * | +refs, | +
| + | + | float * | +startPos, | +
| + | + | float * | +endPos, | +
| + | + | dtNavMeshQuery * | +navquery | +
| + | ) | ++ |
| bool dtPathCorridor::movePosition | +( | +const float * | +npos, | +
| + | + | dtNavMeshQuery * | +navquery, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | ++ |
Moves the position from the current location to the desired location, adjusting the corridor as needed to reflect the change.
+| [in] | npos | The desired new position. [(x, y, z)] |
| [in] | navquery | The query object used to build the corridor. |
| [in] | filter | The filter to apply to the operation. |
Behavior:
+The expected use case is that the desired position will be 'near' the current corridor. What is considered 'near' depends on local polygon density, query search half extents, etc.
+The resulting position will differ from the desired position if the desired position is not on the navigation mesh, or it can't be reached using a local search.
+ +| bool dtPathCorridor::moveTargetPosition | +( | +const float * | +npos, | +
| + | + | dtNavMeshQuery * | +navquery, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | ++ |
Moves the target from the curent location to the desired location, adjusting the corridor as needed to reflect the change.
+| [in] | npos | The desired new target position. [(x, y, z)] |
| [in] | navquery | The query object used to build the corridor. |
| [in] | filter | The filter to apply to the operation. |
Behavior:
+The expected use case is that the desired target will be 'near' the current corridor. What is considered 'near' depends on local polygon density, query search half extents, etc.
+The resulting target will differ from the desired target if the desired target is not on the navigation mesh, or it can't be reached using a local search.
+ +| bool dtPathCorridor::optimizePathTopology | +( | +dtNavMeshQuery * | +navquery, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | ++ |
Attempts to optimize the path using a local area search.
+(Partial replanning.)
| [in] | navquery | The query object used to build the corridor. |
| [in] | filter | The filter to apply to the operation. + |
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.
+ +| void dtPathCorridor::optimizePathVisibility | +( | +const float * | +next, | +
| + | + | const float | +pathOptimizationRange, | +
| + | + | dtNavMeshQuery * | +navquery, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | ++ |
Attempts to optimize the path if the specified point is visible from the current position.
+| [in] | next | The point to search toward. [(x, y, z]) |
| [in] | pathOptimizationRange | The maximum range to search. [Limit: > 0] |
| [in] | navquery | The query object used to build the corridor. |
| [in] | filter | The filter to apply to the operation. + |
Inaccurate locomotion or dynamic obstacle avoidance can force the argent position significantly outside the original corridor. Over time this can result in the formation of a non-optimal corridor. Non-optimal paths can also form near the corners of tiles.
+This function uses an efficient local visibility search to try to optimize the corridor between the current position and next.
The corridor will change only if next is visible from the current position and moving directly toward the point is better than following the existing path.
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.
+This function is not suitable for long distance searches.
+ +| void dtPathCorridor::reset | +( | +dtPolyRef | +ref, | +
| + | + | const float * | +pos | +
| + | ) | ++ |
Resets the path corridor to the specified position.
+| [in] | ref | The polygon reference containing the position. |
| [in] | pos | The new position in the corridor. [(x, y, z)] |
Essentially, the corridor is set of one polygon in size with the target equal to the position.
+ +| void dtPathCorridor::setCorridor | +( | +const float * | +target, | +
| + | + | const dtPolyRef * | +path, | +
| + | + | const int | +npath | +
| + | ) | ++ |
Loads a new path and target into the corridor.
+| [in] | target | The target location within the last polygon of the path. [(x, y, z)] |
| [in] | path | The path corridor. [(polyRef) * npolys] |
| [in] | npath | The number of polygons in the path. |
The current corridor position is expected to be within the first polygon in the path. The target is expected to be in the last polygon.
+| bool dtPathCorridor::trimInvalidPath | +( | +dtPolyRef | +safeRef, | +
| + | + | const float * | +safePos, | +
| + | + | dtNavMeshQuery * | +navquery, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtPathQueue, including all inherited members.
+| dtPathQueue() | dtPathQueue | |
| getNavQuery() const | dtPathQueue | inline |
| getPathResult(dtPathQueueRef ref, dtPolyRef *path, int *pathSize, const int maxPath) | dtPathQueue | |
| getRequestStatus(dtPathQueueRef ref) const | dtPathQueue | |
| init(const int maxPathSize, const int maxSearchNodeCount, dtNavMesh *nav) | dtPathQueue | |
| request(dtPolyRef startRef, dtPolyRef endRef, const float *startPos, const float *endPos, const dtQueryFilter *filter) | dtPathQueue | |
| update(const int maxIters) | dtPathQueue | |
| ~dtPathQueue() | dtPathQueue |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <DetourPathQueue.h>
+Public Member Functions | |
| dtPathQueue () | |
| ~dtPathQueue () | |
| bool | init (const int maxPathSize, const int maxSearchNodeCount, dtNavMesh *nav) |
| void | update (const int maxIters) |
| dtPathQueueRef | request (dtPolyRef startRef, dtPolyRef endRef, const float *startPos, const float *endPos, const dtQueryFilter *filter) |
| dtStatus | getRequestStatus (dtPathQueueRef ref) const |
| dtStatus | getPathResult (dtPathQueueRef ref, dtPolyRef *path, int *pathSize, const int maxPath) |
| const dtNavMeshQuery * | getNavQuery () const |
| dtPathQueue::dtPathQueue | +( | +) | ++ |
| dtPathQueue::~dtPathQueue | +( | +) | ++ |
+
|
+ +inline | +
| dtStatus dtPathQueue::getPathResult | +( | +dtPathQueueRef | +ref, | +
| + | + | dtPolyRef * | +path, | +
| + | + | int * | +pathSize, | +
| + | + | const int | +maxPath | +
| + | ) | ++ |
| dtStatus dtPathQueue::getRequestStatus | +( | +dtPathQueueRef | +ref | ) | +const | +
| bool dtPathQueue::init | +( | +const int | +maxPathSize, | +
| + | + | const int | +maxSearchNodeCount, | +
| + | + | dtNavMesh * | +nav | +
| + | ) | ++ |
| dtPathQueueRef dtPathQueue::request | +( | +dtPolyRef | +startRef, | +
| + | + | dtPolyRef | +endRef, | +
| + | + | const float * | +startPos, | +
| + | + | const float * | +endPos, | +
| + | + | const dtQueryFilter * | +filter | +
| + | ) | ++ |
| void dtPathQueue::update | +( | +const int | +maxIters | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtPolyQuery, including all inherited members.
+| process(const dtMeshTile *tile, dtPoly **polys, dtPolyRef *refs, int count)=0 | dtPolyQuery | pure virtual |
| ~dtPolyQuery() | dtPolyQuery | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Provides custom polygon query behavior. + More...
+ +#include <DetourNavMeshQuery.h>
+
++Public Member Functions | |
| virtual | ~dtPolyQuery () |
| virtual void | process (const dtMeshTile *tile, dtPoly **polys, dtPolyRef *refs, int count)=0 |
| Called for each batch of unique polygons touched by the search area in dtNavMeshQuery::queryPolygons. More... | |
Provides custom polygon query behavior.
+Used by dtNavMeshQuery::queryPolygons.
+
+
|
+ +virtual | +
+
|
+ +pure virtual | +
Called for each batch of unique polygons touched by the search area in dtNavMeshQuery::queryPolygons.
+This can be called multiple times for a single query.
+ +Implemented in dtCollectPolysQuery, and dtFindNearestPolyQuery.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtProximityGrid, including all inherited members.
+| addItem(const unsigned short id, const float minx, const float miny, const float maxx, const float maxy) | dtProximityGrid | |
| clear() | dtProximityGrid | |
| dtProximityGrid() | dtProximityGrid | |
| getBounds() const | dtProximityGrid | inline |
| getCellSize() const | dtProximityGrid | inline |
| getItemCountAt(const int x, const int y) const | dtProximityGrid | |
| init(const int poolSize, const float cellSize) | dtProximityGrid | |
| queryItems(const float minx, const float miny, const float maxx, const float maxy, unsigned short *ids, const int maxIds) const | dtProximityGrid | |
| ~dtProximityGrid() | dtProximityGrid |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <DetourProximityGrid.h>
+Public Member Functions | |
| dtProximityGrid () | |
| ~dtProximityGrid () | |
| bool | init (const int poolSize, const float cellSize) |
| void | clear () |
| void | addItem (const unsigned short id, const float minx, const float miny, const float maxx, const float maxy) |
| int | queryItems (const float minx, const float miny, const float maxx, const float maxy, unsigned short *ids, const int maxIds) const |
| int | getItemCountAt (const int x, const int y) const |
| const int * | getBounds () const |
| float | getCellSize () const |
| dtProximityGrid::dtProximityGrid | +( | +) | ++ |
| dtProximityGrid::~dtProximityGrid | +( | +) | ++ |
| void dtProximityGrid::addItem | +( | +const unsigned short | +id, | +
| + | + | const float | +minx, | +
| + | + | const float | +miny, | +
| + | + | const float | +maxx, | +
| + | + | const float | +maxy | +
| + | ) | ++ |
| void dtProximityGrid::clear | +( | +) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
| int dtProximityGrid::getItemCountAt | +( | +const int | +x, | +
| + | + | const int | +y | +
| + | ) | +const | +
| bool dtProximityGrid::init | +( | +const int | +poolSize, | +
| + | + | const float | +cellSize | +
| + | ) | ++ |
| int dtProximityGrid::queryItems | +( | +const float | +minx, | +
| + | + | const float | +miny, | +
| + | + | const float | +maxx, | +
| + | + | const float | +maxy, | +
| + | + | unsigned short * | +ids, | +
| + | + | const int | +maxIds | +
| + | ) | +const | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtQueryFilter, including all inherited members.
+| dtQueryFilter() | dtQueryFilter | |
| getAreaCost(const int i) const | dtQueryFilter | inline |
| getCost(const float *pa, const float *pb, const dtPolyRef prevRef, const dtMeshTile *prevTile, const dtPoly *prevPoly, const dtPolyRef curRef, const dtMeshTile *curTile, const dtPoly *curPoly, const dtPolyRef nextRef, const dtMeshTile *nextTile, const dtPoly *nextPoly) const | dtQueryFilter | inline |
| getExcludeFlags() const | dtQueryFilter | inline |
| getIncludeFlags() const | dtQueryFilter | inline |
| passFilter(const dtPolyRef ref, const dtMeshTile *tile, const dtPoly *poly) const | dtQueryFilter | inline |
| setAreaCost(const int i, const float cost) | dtQueryFilter | inline |
| setExcludeFlags(const unsigned short flags) | dtQueryFilter | inline |
| setIncludeFlags(const unsigned short flags) | dtQueryFilter | inline |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Defines polygon filtering and traversal costs for navigation mesh query operations. + More...
+ +#include <DetourNavMeshQuery.h>
+Public Member Functions | |
| dtQueryFilter () | |
| bool | passFilter (const dtPolyRef ref, const dtMeshTile *tile, const dtPoly *poly) const |
| Returns true if the polygon can be visited. More... | |
| float | getCost (const float *pa, const float *pb, const dtPolyRef prevRef, const dtMeshTile *prevTile, const dtPoly *prevPoly, const dtPolyRef curRef, const dtMeshTile *curTile, const dtPoly *curPoly, const dtPolyRef nextRef, const dtMeshTile *nextTile, const dtPoly *nextPoly) const |
| Returns cost to move from the beginning to the end of a line segment that is fully contained within a polygon. More... | |
Getters and setters for the default implementation data. | |
| float | getAreaCost (const int i) const |
| Returns the traversal cost of the area. More... | |
| void | setAreaCost (const int i, const float cost) |
| Sets the traversal cost of the area. More... | |
| unsigned short | getIncludeFlags () const |
| Returns the include flags for the filter. More... | |
| void | setIncludeFlags (const unsigned short flags) |
| Sets the include flags for the filter. More... | |
| unsigned short | getExcludeFlags () const |
| Returns the exclude flags for the filter. More... | |
| void | setExcludeFlags (const unsigned short flags) |
| Sets the exclude flags for the filter. More... | |
Defines polygon filtering and traversal costs for navigation mesh query operations.
+The Default Implementation
+At construction: All area costs default to 1.0. All flags are included and none are excluded.
+If a polygon has both an include and an exclude flag, it will be excluded.
+The way filtering works, a navigation mesh polygon must have at least one flag set to ever be considered by a query. So a polygon with no flags will never be considered.
+Setting the include flags to 0 will result in all polygons being excluded.
+Custom Implementations
+DT_VIRTUAL_QUERYFILTER must be defined in order to extend this class.
+Implement a custom query filter by overriding the virtual passFilter() and getCost() functions. If this is done, both functions should be as fast as possible. Use cached local copies of data rather than accessing your own objects where possible.
+Custom implementations do not need to adhere to the flags or cost logic used by the default implementation.
+
In order for A* searches to work properly, the cost should be proportional to the travel distance. Implementing a cost modifier less than 1.0 is likely to lead to problems during pathfinding.
+| dtQueryFilter::dtQueryFilter | +( | +) | ++ |
+
|
+ +inline | +
Returns the traversal cost of the area.
+| [in] | i | The id of the area. |
+
|
+ +inline | +
Returns cost to move from the beginning to the end of a line segment that is fully contained within a polygon.
+| [in] | pa | The start position on the edge of the previous and current polygon. [(x, y, z)] |
| [in] | pb | The end position on the edge of the current and next polygon. [(x, y, z)] |
| [in] | prevRef | The reference id of the previous polygon. [opt] |
| [in] | prevTile | The tile containing the previous polygon. [opt] |
| [in] | prevPoly | The previous polygon. [opt] |
| [in] | curRef | The reference id of the current polygon. |
| [in] | curTile | The tile containing the current polygon. |
| [in] | curPoly | The current polygon. |
| [in] | nextRef | The refernece id of the next polygon. [opt] |
| [in] | nextTile | The tile containing the next polygon. [opt] |
| [in] | nextPoly | The next polygon. [opt] |
+
|
+ +inline | +
Returns the exclude flags for the filter.
+Any polygons that include one ore more of these flags will be excluded from the operation.
+ +
+
|
+ +inline | +
Returns the include flags for the filter.
+Any polygons that include one or more of these flags will be included in the operation.
+ +
+
|
+ +inline | +
Returns true if the polygon can be visited.
+(I.e. Is traversable.)
| [in] | ref | The reference id of the polygon test. |
| [in] | tile | The tile containing the polygon. |
| [in] | poly | The polygon to test. |
+
|
+ +inline | +
Sets the traversal cost of the area.
+| [in] | i | The id of the area. |
| [in] | cost | The new cost of traversing the area. |
+
|
+ +inline | +
Sets the exclude flags for the filter.
+| [in] | flags | The new flags. |
+
|
+ +inline | +
Sets the include flags for the filter.
+| [in] | flags | The new flags. |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for dtTileCache, including all inherited members.
+| addBoxObstacle(const float *bmin, const float *bmax, dtObstacleRef *result) | dtTileCache | |
| addBoxObstacle(const float *center, const float *halfExtents, const float yRadians, dtObstacleRef *result) | dtTileCache | |
| addObstacle(const float *pos, const float radius, const float height, dtObstacleRef *result) | dtTileCache | |
| addTile(unsigned char *data, const int dataSize, unsigned char flags, dtCompressedTileRef *result) | dtTileCache | |
| buildNavMeshTile(const dtCompressedTileRef ref, class dtNavMesh *navmesh) | dtTileCache | |
| buildNavMeshTilesAt(const int tx, const int ty, class dtNavMesh *navmesh) | dtTileCache | |
| calcTightTileBounds(const struct dtTileCacheLayerHeader *header, float *bmin, float *bmax) const | dtTileCache | |
| decodeObstacleIdObstacle(dtObstacleRef ref) const | dtTileCache | inline |
| decodeObstacleIdSalt(dtObstacleRef ref) const | dtTileCache | inline |
| decodeTileIdSalt(dtCompressedTileRef ref) const | dtTileCache | inline |
| decodeTileIdTile(dtCompressedTileRef ref) const | dtTileCache | inline |
| dtTileCache() | dtTileCache | |
| encodeObstacleId(unsigned int salt, unsigned int it) const | dtTileCache | inline |
| encodeTileId(unsigned int salt, unsigned int it) const | dtTileCache | inline |
| getAlloc() | dtTileCache | inline |
| getCompressor() | dtTileCache | inline |
| getObstacle(const int i) const | dtTileCache | inline |
| getObstacleBounds(const struct dtTileCacheObstacle *ob, float *bmin, float *bmax) const | dtTileCache | |
| getObstacleByRef(dtObstacleRef ref) | dtTileCache | |
| getObstacleCount() const | dtTileCache | inline |
| getObstacleRef(const dtTileCacheObstacle *obmin) const | dtTileCache | |
| getParams() const | dtTileCache | inline |
| getTile(const int i) const | dtTileCache | inline |
| getTileAt(const int tx, const int ty, const int tlayer) | dtTileCache | |
| getTileByRef(dtCompressedTileRef ref) const | dtTileCache | |
| getTileCount() const | dtTileCache | inline |
| getTileRef(const dtCompressedTile *tile) const | dtTileCache | |
| getTilesAt(const int tx, const int ty, dtCompressedTileRef *tiles, const int maxTiles) const | dtTileCache | |
| init(const dtTileCacheParams *params, struct dtTileCacheAlloc *talloc, struct dtTileCacheCompressor *tcomp, struct dtTileCacheMeshProcess *tmproc) | dtTileCache | |
| queryTiles(const float *bmin, const float *bmax, dtCompressedTileRef *results, int *resultCount, const int maxResults) const | dtTileCache | |
| removeObstacle(const dtObstacleRef ref) | dtTileCache | |
| removeTile(dtCompressedTileRef ref, unsigned char **data, int *dataSize) | dtTileCache | |
| update(const float dt, class dtNavMesh *navmesh, bool *upToDate=0) | dtTileCache | |
| ~dtTileCache() | dtTileCache |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <DetourTileCache.h>
+Public Member Functions | |
| dtTileCache () | |
| ~dtTileCache () | |
| struct dtTileCacheAlloc * | getAlloc () |
| struct dtTileCacheCompressor * | getCompressor () |
| const dtTileCacheParams * | getParams () const |
| int | getTileCount () const |
| const dtCompressedTile * | getTile (const int i) const |
| int | getObstacleCount () const |
| const dtTileCacheObstacle * | getObstacle (const int i) const |
| const dtTileCacheObstacle * | getObstacleByRef (dtObstacleRef ref) |
| dtObstacleRef | getObstacleRef (const dtTileCacheObstacle *obmin) const |
| dtStatus | init (const dtTileCacheParams *params, struct dtTileCacheAlloc *talloc, struct dtTileCacheCompressor *tcomp, struct dtTileCacheMeshProcess *tmproc) |
| int | getTilesAt (const int tx, const int ty, dtCompressedTileRef *tiles, const int maxTiles) const |
| dtCompressedTile * | getTileAt (const int tx, const int ty, const int tlayer) |
| dtCompressedTileRef | getTileRef (const dtCompressedTile *tile) const |
| const dtCompressedTile * | getTileByRef (dtCompressedTileRef ref) const |
| dtStatus | addTile (unsigned char *data, const int dataSize, unsigned char flags, dtCompressedTileRef *result) |
| dtStatus | removeTile (dtCompressedTileRef ref, unsigned char **data, int *dataSize) |
| dtStatus | addObstacle (const float *pos, const float radius, const float height, dtObstacleRef *result) |
| dtStatus | addBoxObstacle (const float *bmin, const float *bmax, dtObstacleRef *result) |
| dtStatus | addBoxObstacle (const float *center, const float *halfExtents, const float yRadians, dtObstacleRef *result) |
| dtStatus | removeObstacle (const dtObstacleRef ref) |
| dtStatus | queryTiles (const float *bmin, const float *bmax, dtCompressedTileRef *results, int *resultCount, const int maxResults) const |
| dtStatus | update (const float dt, class dtNavMesh *navmesh, bool *upToDate=0) |
| Updates the tile cache by rebuilding tiles touched by unfinished obstacle requests. More... | |
| dtStatus | buildNavMeshTilesAt (const int tx, const int ty, class dtNavMesh *navmesh) |
| dtStatus | buildNavMeshTile (const dtCompressedTileRef ref, class dtNavMesh *navmesh) |
| void | calcTightTileBounds (const struct dtTileCacheLayerHeader *header, float *bmin, float *bmax) const |
| void | getObstacleBounds (const struct dtTileCacheObstacle *ob, float *bmin, float *bmax) const |
| dtCompressedTileRef | encodeTileId (unsigned int salt, unsigned int it) const |
| Encodes a tile id. More... | |
| unsigned int | decodeTileIdSalt (dtCompressedTileRef ref) const |
| Decodes a tile salt. More... | |
| unsigned int | decodeTileIdTile (dtCompressedTileRef ref) const |
| Decodes a tile id. More... | |
| dtObstacleRef | encodeObstacleId (unsigned int salt, unsigned int it) const |
| Encodes an obstacle id. More... | |
| unsigned int | decodeObstacleIdSalt (dtObstacleRef ref) const |
| Decodes an obstacle salt. More... | |
| unsigned int | decodeObstacleIdObstacle (dtObstacleRef ref) const |
| Decodes an obstacle id. More... | |
| dtTileCache::dtTileCache | +( | +) | ++ |
| dtTileCache::~dtTileCache | +( | +) | ++ |
| dtStatus dtTileCache::addBoxObstacle | +( | +const float * | +bmin, | +
| + | + | const float * | +bmax, | +
| + | + | dtObstacleRef * | +result | +
| + | ) | ++ |
| dtStatus dtTileCache::addBoxObstacle | +( | +const float * | +center, | +
| + | + | const float * | +halfExtents, | +
| + | + | const float | +yRadians, | +
| + | + | dtObstacleRef * | +result | +
| + | ) | ++ |
| dtStatus dtTileCache::addObstacle | +( | +const float * | +pos, | +
| + | + | const float | +radius, | +
| + | + | const float | +height, | +
| + | + | dtObstacleRef * | +result | +
| + | ) | ++ |
| dtStatus dtTileCache::addTile | +( | +unsigned char * | +data, | +
| + | + | const int | +dataSize, | +
| + | + | unsigned char | +flags, | +
| + | + | dtCompressedTileRef * | +result | +
| + | ) | ++ |
| dtStatus dtTileCache::buildNavMeshTile | +( | +const dtCompressedTileRef | +ref, | +
| + | + | class dtNavMesh * | +navmesh | +
| + | ) | ++ |
| dtStatus dtTileCache::buildNavMeshTilesAt | +( | +const int | +tx, | +
| + | + | const int | +ty, | +
| + | + | class dtNavMesh * | +navmesh | +
| + | ) | ++ |
| void dtTileCache::calcTightTileBounds | +( | +const struct dtTileCacheLayerHeader * | +header, | +
| + | + | float * | +bmin, | +
| + | + | float * | +bmax | +
| + | ) | +const | +
+
|
+ +inline | +
Decodes an obstacle id.
+ +
+
|
+ +inline | +
Decodes an obstacle salt.
+ +
+
|
+ +inline | +
Decodes a tile salt.
+ +
+
|
+ +inline | +
Decodes a tile id.
+ +
+
|
+ +inline | +
Encodes an obstacle id.
+ +
+
|
+ +inline | +
Encodes a tile id.
+ +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| void dtTileCache::getObstacleBounds | +( | +const struct dtTileCacheObstacle * | +ob, | +
| + | + | float * | +bmin, | +
| + | + | float * | +bmax | +
| + | ) | +const | +
| const dtTileCacheObstacle * dtTileCache::getObstacleByRef | +( | +dtObstacleRef | +ref | ) | ++ |
+
|
+ +inline | +
| dtObstacleRef dtTileCache::getObstacleRef | +( | +const dtTileCacheObstacle * | +obmin | ) | +const | +
+
|
+ +inline | +
+
|
+ +inline | +
| dtCompressedTile * dtTileCache::getTileAt | +( | +const int | +tx, | +
| + | + | const int | +ty, | +
| + | + | const int | +tlayer | +
| + | ) | ++ |
| const dtCompressedTile * dtTileCache::getTileByRef | +( | +dtCompressedTileRef | +ref | ) | +const | +
+
|
+ +inline | +
| dtCompressedTileRef dtTileCache::getTileRef | +( | +const dtCompressedTile * | +tile | ) | +const | +
| int dtTileCache::getTilesAt | +( | +const int | +tx, | +
| + | + | const int | +ty, | +
| + | + | dtCompressedTileRef * | +tiles, | +
| + | + | const int | +maxTiles | +
| + | ) | +const | +
| dtStatus dtTileCache::init | +( | +const dtTileCacheParams * | +params, | +
| + | + | struct dtTileCacheAlloc * | +talloc, | +
| + | + | struct dtTileCacheCompressor * | +tcomp, | +
| + | + | struct dtTileCacheMeshProcess * | +tmproc | +
| + | ) | ++ |
| dtStatus dtTileCache::queryTiles | +( | +const float * | +bmin, | +
| + | + | const float * | +bmax, | +
| + | + | dtCompressedTileRef * | +results, | +
| + | + | int * | +resultCount, | +
| + | + | const int | +maxResults | +
| + | ) | +const | +
| dtStatus dtTileCache::removeObstacle | +( | +const dtObstacleRef | +ref | ) | ++ |
| dtStatus dtTileCache::removeTile | +( | +dtCompressedTileRef | +ref, | +
| + | + | unsigned char ** | +data, | +
| + | + | int * | +dataSize | +
| + | ) | ++ |
| dtStatus dtTileCache::update | +( | +const float | +dt, | +
| + | + | class dtNavMesh * | +navmesh, | +
| + | + | bool * | +upToDate = 0 |
+
| + | ) | ++ |
Updates the tile cache by rebuilding tiles touched by unfinished obstacle requests.
+| [in] | dt | The time step size. Currently not used. |
| [in] | navmesh | The mesh to affect when rebuilding tiles. |
| [out] | upToDate | Whether the tile cache is fully up to date with obstacle requests and tile rebuilds. If the tile cache is up to date another (immediate) call to update will have no effect; otherwise another call will continue processing obstacle requests and tile rebuilds. |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for duDisplayList, including all inherited members.
+| areaToCol(unsigned int area) | duDebugDraw | virtual |
| begin(duDebugDrawPrimitives prim, float size=1.0f) | duDisplayList | virtual |
| clear() | duDisplayList | |
| depthMask(bool state) | duDisplayList | virtual |
| draw(struct duDebugDraw *dd) | duDisplayList | |
| duDisplayList(int cap=512) | duDisplayList | |
| end() | duDisplayList | virtual |
| texture(bool state)=0 | duDebugDraw | pure virtual |
| vertex(const float x, const float y, const float z, unsigned int color) | duDisplayList | virtual |
| vertex(const float *pos, unsigned int color) | duDisplayList | virtual |
| duDebugDraw::vertex(const float *pos, unsigned int color, const float *uv)=0 | duDebugDraw | pure virtual |
| duDebugDraw::vertex(const float x, const float y, const float z, unsigned int color, const float u, const float v)=0 | duDebugDraw | pure virtual |
| ~duDebugDraw()=0 | duDebugDraw | pure virtual |
| ~duDisplayList() | duDisplayList | virtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <DebugDraw.h>
+
++Public Member Functions | |
| duDisplayList (int cap=512) | |
| virtual | ~duDisplayList () |
| virtual void | depthMask (bool state) |
| virtual void | begin (duDebugDrawPrimitives prim, float size=1.0f) |
| Begin drawing primitives. More... | |
| virtual void | vertex (const float x, const float y, const float z, unsigned int color) |
| Submit a vertex. More... | |
| virtual void | vertex (const float *pos, unsigned int color) |
| Submit a vertex. More... | |
| virtual void | end () |
| End drawing primitives. More... | |
| void | clear () |
| void | draw (struct duDebugDraw *dd) |
Public Member Functions inherited from duDebugDraw | |
| virtual | ~duDebugDraw ()=0 |
| virtual void | texture (bool state)=0 |
| virtual void | vertex (const float *pos, unsigned int color, const float *uv)=0 |
| Submit a vertex. More... | |
| virtual void | vertex (const float x, const float y, const float z, unsigned int color, const float u, const float v)=0 |
| Submit a vertex. More... | |
| virtual unsigned int | areaToCol (unsigned int area) |
| Compute a color for given area. More... | |
| duDisplayList::duDisplayList | +( | +int | +cap = 512 | ) | ++ |
+
|
+ +virtual | +
+
|
+ +virtual | +
Begin drawing primitives.
+| prim | [in] primitive type to draw, one of rcDebugDrawPrimitives. |
| size | [in] size of a primitive, applies to point size and line width only. |
Implements duDebugDraw.
+ +| void duDisplayList::clear | +( | +) | ++ |
+
|
+ +virtual | +
Implements duDebugDraw.
+ +| void duDisplayList::draw | +( | +struct duDebugDraw * | +dd | ) | ++ |
+
|
+ +virtual | +
End drawing primitives.
+ +Implements duDebugDraw.
+ +
+
|
+ +virtual | +
Submit a vertex.
+| pos | [in] position of the verts. |
| color | [in] color of the verts. |
Implements duDebugDraw.
+ +
+
|
+ +virtual | +
Submit a vertex.
+| x,y,z | [in] position of the verts. |
| color | [in] color of the verts. |
Implements duDebugDraw.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for rcContext, including all inherited members.
+| doGetAccumulatedTime(const rcTimerLabel label) const | rcContext | inlineprotectedvirtual |
| doLog(const rcLogCategory category, const char *msg, const int len) | rcContext | inlineprotectedvirtual |
| doResetLog() | rcContext | protectedvirtual |
| doResetTimers() | rcContext | inlineprotectedvirtual |
| doStartTimer(const rcTimerLabel label) | rcContext | inlineprotectedvirtual |
| doStopTimer(const rcTimerLabel label) | rcContext | inlineprotectedvirtual |
| enableLog(bool state) | rcContext | inline |
| enableTimer(bool state) | rcContext | inline |
| getAccumulatedTime(const rcTimerLabel label) const | rcContext | inline |
| log(const rcLogCategory category, const char *format,...) | rcContext | |
| m_logEnabled | rcContext | protected |
| m_timerEnabled | rcContext | protected |
| rcContext(bool state=true) | rcContext | inline |
| resetLog() | rcContext | inline |
| resetTimers() | rcContext | inline |
| startTimer(const rcTimerLabel label) | rcContext | inline |
| stopTimer(const rcTimerLabel label) | rcContext | inline |
| ~rcContext() | rcContext | inlinevirtual |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Provides an interface for optional logging and performance tracking of the Recast build process. + More...
+ +#include <Recast.h>
+
++Public Member Functions | |
| rcContext (bool state=true) | |
| Constructor. More... | |
| virtual | ~rcContext () |
| void | enableLog (bool state) |
| Enables or disables logging. More... | |
| void | resetLog () |
| Clears all log entries. More... | |
| void | log (const rcLogCategory category, const char *format,...) |
| Logs a message. More... | |
| void | enableTimer (bool state) |
| Enables or disables the performance timers. More... | |
| void | resetTimers () |
| Clears all performance timers. (Resets all to unused.) More... | |
| void | startTimer (const rcTimerLabel label) |
| Starts the specified performance timer. More... | |
| void | stopTimer (const rcTimerLabel label) |
| Stops the specified performance timer. More... | |
| int | getAccumulatedTime (const rcTimerLabel label) const |
| Returns the total accumulated time of the specified performance timer. More... | |
+Protected Member Functions | |
| virtual void | doResetLog () |
| Clears all log entries. More... | |
| virtual void | doLog (const rcLogCategory category, const char *msg, const int len) |
| Logs a message. More... | |
| virtual void | doResetTimers () |
| Clears all timers. (Resets all to unused.) More... | |
| virtual void | doStartTimer (const rcTimerLabel label) |
| Starts the specified performance timer. More... | |
| virtual void | doStopTimer (const rcTimerLabel label) |
| Stops the specified performance timer. More... | |
| virtual int | doGetAccumulatedTime (const rcTimerLabel label) const |
| Returns the total accumulated time of the specified performance timer. More... | |
+Protected Attributes | |
| bool | m_logEnabled |
| True if logging is enabled. More... | |
| bool | m_timerEnabled |
| True if the performance timers are enabled. More... | |
Provides an interface for optional logging and performance tracking of the Recast build process.
+This class does not provide logging or timer functionality on its own. Both must be provided by a concrete implementation by overriding the protected member functions. Also, this class does not provide an interface for extracting log messages. (Only adding them.) So concrete implementations must provide one.
+If no logging or timers are required, just pass an instance of this class through the Recast build process.
+
+
|
+ +inline | +
Constructor.
+| [in] | state | TRUE if the logging and performance timers should be enabled. [Default: true] |
+
|
+ +inlinevirtual | +
+
|
+ +inlineprotectedvirtual | +
Returns the total accumulated time of the specified performance timer.
+| [in] | label | The category of the timer. |
Reimplemented in BuildContext.
+ +
+
|
+ +inlineprotectedvirtual | +
Logs a message.
+| [in] | category | The category of the message. |
| [in] | msg | The formatted message. |
| [in] | len | The length of the formatted message. |
Reimplemented in BuildContext.
+ +
+
|
+ +protectedvirtual | +
Clears all log entries.
+ +Reimplemented in BuildContext.
+ +
+
|
+ +inlineprotectedvirtual | +
Clears all timers. (Resets all to unused.)
+ +Reimplemented in BuildContext.
+ +
+
|
+ +inlineprotectedvirtual | +
Starts the specified performance timer.
+| [in] | label | The category of timer. |
Reimplemented in BuildContext.
+ +
+
|
+ +inlineprotectedvirtual | +
Stops the specified performance timer.
+| [in] | label | The category of the timer. |
Reimplemented in BuildContext.
+ +
+
|
+ +inline | +
Enables or disables logging.
+| [in] | state | TRUE if logging should be enabled. |
+
|
+ +inline | +
Enables or disables the performance timers.
+| [in] | state | TRUE if timers should be enabled. |
+
|
+ +inline | +
Returns the total accumulated time of the specified performance timer.
+| label | The category of the timer. |
| void rcContext::log | +( | +const rcLogCategory | +category, | +
| + | + | const char * | +format, | +
| + | + | + | ... | +
| + | ) | ++ |
Logs a message.
+Example:
| [in] | category | The category of the message. |
| [in] | format | The message. |
+
|
+ +inline | +
Clears all log entries.
+ +
+
|
+ +inline | +
Clears all performance timers. (Resets all to unused.)
+ +
+
|
+ +inline | +
Starts the specified performance timer.
+| label | The category of the timer. |
+
|
+ +inline | +
Stops the specified performance timer.
+| label | The category of the timer. |
+
|
+ +protected | +
True if logging is enabled.
+ +
+
|
+ +protected | +
True if the performance timers are enabled.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for rcIntArray, including all inherited members.
+| clear() | rcIntArray | inline |
| operator[](int index) | rcIntArray | inline |
| operator[](int index) const | rcIntArray | inline |
| pop() | rcIntArray | inline |
| push(int item) | rcIntArray | inline |
| rcIntArray() | rcIntArray | inline |
| rcIntArray(int n) | rcIntArray | inline |
| resize(int size) | rcIntArray | inline |
| size() const | rcIntArray | inline |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Legacy class. Prefer rcVector<int>. + More...
+ +#include <RecastAlloc.h>
+Public Member Functions | |
| rcIntArray () | |
| rcIntArray (int n) | |
| void | push (int item) |
| void | resize (int size) |
| void | clear () |
| int | pop () |
| int | size () const |
| int & | operator[] (int index) |
| int | operator[] (int index) const |
Legacy class. Prefer rcVector<int>.
+
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for rcMeshLoaderObj, including all inherited members.
+| getFileName() const | rcMeshLoaderObj | inline |
| getNormals() const | rcMeshLoaderObj | inline |
| getTriCount() const | rcMeshLoaderObj | inline |
| getTris() const | rcMeshLoaderObj | inline |
| getVertCount() const | rcMeshLoaderObj | inline |
| getVerts() const | rcMeshLoaderObj | inline |
| load(const std::string &fileName) | rcMeshLoaderObj | |
| rcMeshLoaderObj() | rcMeshLoaderObj | |
| ~rcMeshLoaderObj() | rcMeshLoaderObj |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <MeshLoaderObj.h>
+Public Member Functions | |
| rcMeshLoaderObj () | |
| ~rcMeshLoaderObj () | |
| bool | load (const std::string &fileName) |
| const float * | getVerts () const |
| const float * | getNormals () const |
| const int * | getTris () const |
| int | getVertCount () const |
| int | getTriCount () const |
| const std::string & | getFileName () const |
| rcMeshLoaderObj::rcMeshLoaderObj | +( | +) | ++ |
| rcMeshLoaderObj::~rcMeshLoaderObj | +( | +) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| bool rcMeshLoaderObj::load | +( | +const std::string & | +fileName | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for rcPermVector< T >, including all inherited members.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <RecastAlloc.h>
+
++Public Member Functions | |
| rcPermVector () | |
| rcPermVector (rcSizeType size) | |
| rcPermVector (rcSizeType size, const T &value) | |
| rcPermVector (const rcPermVector< T > &other) | |
| rcPermVector (const T *begin, const T *end) | |
Public Member Functions inherited from rcVectorBase< T, RC_ALLOC_PERM > | |
| rcVectorBase () | |
| rcVectorBase (const rcVectorBase< T, H > &other) | |
| rcVectorBase (rcSizeType count) | |
| rcVectorBase (rcSizeType count, const T &value) | |
| rcVectorBase (const T *begin, const T *end) | |
| ~rcVectorBase () | |
| bool | reserve (rcSizeType size) |
| void | assign (rcSizeType count, const T &value) |
| void | assign (const T *begin, const T *end) |
| void | resize (rcSizeType size) |
| void | resize (rcSizeType size, const T &value) |
| void | clear () |
| void | push_back (const T &value) |
| void | pop_back () |
| rcSizeType | size () const |
| rcSizeType | capacity () const |
| bool | empty () const |
| const T & | operator[] (rcSizeType i) const |
| T & | operator[] (rcSizeType i) |
| const T & | front () const |
| T & | front () |
| const T & | back () const |
| T & | back () |
| const T * | data () const |
| T * | data () |
| T * | begin () |
| const T * | begin () const |
| T * | end () |
| const T * | end () const |
| void | swap (rcVectorBase< T, H > &other) |
| rcVectorBase & | operator= (const rcVectorBase< T, H > &other) |
+Additional Inherited Members | |
Public Types inherited from rcVectorBase< T, RC_ALLOC_PERM > | |
| typedef rcSizeType | size_type |
| typedef T | value_type |
+
|
+ +inline | +
+
|
+ +inlineexplicit | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for rcScopedDelete< T >, including all inherited members.
+| operator T*() | rcScopedDelete< T > | inline |
| rcScopedDelete() | rcScopedDelete< T > | inline |
| rcScopedDelete(T *p) | rcScopedDelete< T > | inline |
| ~rcScopedDelete() | rcScopedDelete< T > | inline |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
A simple helper class used to delete an array when it goes out of scope. + More...
+ +#include <RecastAlloc.h>
+Public Member Functions | |
| rcScopedDelete () | |
| Constructs an instance with a null pointer. More... | |
| rcScopedDelete (T *p) | |
| Constructs an instance with the specified pointer. More... | |
| ~rcScopedDelete () | |
| operator T* () | |
| The root array pointer. More... | |
A simple helper class used to delete an array when it goes out of scope.
+
+
|
+ +inline | +
Constructs an instance with a null pointer.
+ +
+
|
+ +inline | +
Constructs an instance with the specified pointer.
+| [in] | p | An pointer to an allocated array. |
+
|
+ +inline | +
+
|
+ +inline | +
The root array pointer.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for rcScopedTimer, including all inherited members.
+| rcScopedTimer(rcContext *ctx, const rcTimerLabel label) | rcScopedTimer | inline |
| ~rcScopedTimer() | rcScopedTimer | inline |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
A helper to first start a timer and then stop it when this helper goes out of scope. + More...
+ +#include <Recast.h>
+Public Member Functions | |
| rcScopedTimer (rcContext *ctx, const rcTimerLabel label) | |
| Constructs an instance and starts the timer. More... | |
| ~rcScopedTimer () | |
A helper to first start a timer and then stop it when this helper goes out of scope.
+
+
|
+ +inline | +
Constructs an instance and starts the timer.
+| [in] | ctx | The context to use. |
| [in] | label | The category of the timer. |
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for rcTempVector< T >, including all inherited members.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <RecastAlloc.h>
+
++Public Member Functions | |
| rcTempVector () | |
| rcTempVector (rcSizeType size) | |
| rcTempVector (rcSizeType size, const T &value) | |
| rcTempVector (const rcTempVector< T > &other) | |
| rcTempVector (const T *begin, const T *end) | |
Public Member Functions inherited from rcVectorBase< T, RC_ALLOC_TEMP > | |
| rcVectorBase () | |
| rcVectorBase (const rcVectorBase< T, H > &other) | |
| rcVectorBase (rcSizeType count) | |
| rcVectorBase (rcSizeType count, const T &value) | |
| rcVectorBase (const T *begin, const T *end) | |
| ~rcVectorBase () | |
| bool | reserve (rcSizeType size) |
| void | assign (rcSizeType count, const T &value) |
| void | assign (const T *begin, const T *end) |
| void | resize (rcSizeType size) |
| void | resize (rcSizeType size, const T &value) |
| void | clear () |
| void | push_back (const T &value) |
| void | pop_back () |
| rcSizeType | size () const |
| rcSizeType | capacity () const |
| bool | empty () const |
| const T & | operator[] (rcSizeType i) const |
| T & | operator[] (rcSizeType i) |
| const T & | front () const |
| T & | front () |
| const T & | back () const |
| T & | back () |
| const T * | data () const |
| T * | data () |
| T * | begin () |
| const T * | begin () const |
| T * | end () |
| const T * | end () const |
| void | swap (rcVectorBase< T, H > &other) |
| rcVectorBase & | operator= (const rcVectorBase< T, H > &other) |
+Additional Inherited Members | |
Public Types inherited from rcVectorBase< T, RC_ALLOC_TEMP > | |
| typedef rcSizeType | size_type |
| typedef T | value_type |
+
|
+ +inline | +
+
|
+ +inlineexplicit | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
This is the complete list of members for rcVectorBase< T, H >, including all inherited members.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Variable-sized storage type. + More...
+ +#include <RecastAlloc.h>
+
++Public Types | |
| typedef rcSizeType | size_type |
| typedef T | value_type |
+Public Member Functions | |
| rcVectorBase () | |
| rcVectorBase (const rcVectorBase< T, H > &other) | |
| rcVectorBase (rcSizeType count) | |
| rcVectorBase (rcSizeType count, const T &value) | |
| rcVectorBase (const T *begin, const T *end) | |
| ~rcVectorBase () | |
| bool | reserve (rcSizeType size) |
| void | assign (rcSizeType count, const T &value) |
| void | assign (const T *begin, const T *end) |
| void | resize (rcSizeType size) |
| void | resize (rcSizeType size, const T &value) |
| void | clear () |
| void | push_back (const T &value) |
| void | pop_back () |
| rcSizeType | size () const |
| rcSizeType | capacity () const |
| bool | empty () const |
| const T & | operator[] (rcSizeType i) const |
| T & | operator[] (rcSizeType i) |
| const T & | front () const |
| T & | front () |
| const T & | back () const |
| T & | back () |
| const T * | data () const |
| T * | data () |
| T * | begin () |
| T * | end () |
| const T * | begin () const |
| const T * | end () const |
| void | swap (rcVectorBase< T, H > &other) |
| rcVectorBase & | operator= (const rcVectorBase< T, H > &other) |
Variable-sized storage type.
+Mimics the interface of std::vector<T> with some notable differences:
| typedef rcSizeType rcVectorBase< T, H >::size_type | +
| typedef T rcVectorBase< T, H >::value_type | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inlineexplicit | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| void rcVectorBase< T, H >::assign | +( | +const T * | +begin, | +
| + | + | const T * | +end | +
| + | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| rcVectorBase& rcVectorBase< T, H >::operator= | +( | +const rcVectorBase< T, H > & | +other | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| void rcVectorBase< T, H >::push_back | +( | +const T & | +value | ) | ++ |
| bool rcVectorBase< T, H >::reserve | +( | +rcSizeType | +size | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
| void rcVectorBase< T, H >::swap | +( | +rcVectorBase< T, H > & | +other | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | DetourTileCache.h [code] |
| file | DetourTileCacheBuilder.h [code] |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | DetourCrowd.h [code] |
| file | DetourLocalBoundary.h [code] |
| file | DetourObstacleAvoidance.h [code] |
| file | DetourPathCorridor.h [code] |
| file | DetourPathQueue.h [code] |
| file | DetourProximityGrid.h [code] |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | DetourTileCache.cpp |
| file | DetourTileCacheBuilder.cpp |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | DetourAlloc.cpp |
| file | DetourAssert.cpp |
| file | DetourCommon.cpp |
| file | DetourNavMesh.cpp |
| file | DetourNavMeshBuilder.cpp |
| file | DetourNavMeshQuery.cpp |
| file | DetourNode.cpp |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | DebugDraw.h [code] |
| file | DetourDebugDraw.h [code] |
| file | RecastDebugDraw.h [code] |
| file | RecastDump.h [code] |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | DetourAlloc.h [code] |
| file | DetourAssert.h [code] |
| file | DetourCommon.h [code] |
| file | DetourMath.h [code] |
| file | DetourNavMesh.h [code] |
| file | DetourNavMeshBuilder.h [code] |
| file | DetourNavMeshQuery.h [code] |
| file | DetourNode.h [code] |
| file | DetourStatus.h [code] |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | DetourCrowd.cpp |
| file | DetourLocalBoundary.cpp |
| file | DetourObstacleAvoidance.cpp |
| file | DetourPathCorridor.cpp |
| file | DetourPathQueue.cpp |
| file | DetourProximityGrid.cpp |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | ChunkyTriMesh.cpp |
| file | ConvexVolumeTool.cpp |
| file | CrowdTool.cpp |
| file | Filelist.cpp |
| file | imgui.cpp |
| file | imguiRenderGL.cpp |
| file | InputGeom.cpp |
| file | main.cpp |
| file | MeshLoaderObj.cpp |
| file | NavMeshPruneTool.cpp |
| file | NavMeshTesterTool.cpp |
| file | OffMeshConnectionTool.cpp |
| file | PerfTimer.cpp |
| file | Sample.cpp |
| file | Sample_Debug.cpp |
| file | Sample_SoloMesh.cpp |
| file | Sample_TempObstacles.cpp |
| file | Sample_TileMesh.cpp |
| file | SampleInterfaces.cpp |
| file | TestCase.cpp |
| file | ValueHistory.cpp |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | Recast.h [code] |
| file | RecastAlloc.h [code] |
| file | RecastAssert.h [code] |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | DebugDraw.cpp |
| file | DetourDebugDraw.cpp |
| file | RecastDebugDraw.cpp |
| file | RecastDump.cpp |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | ChunkyTriMesh.h [code] |
| file | ConvexVolumeTool.h [code] |
| file | CrowdTool.h [code] |
| file | Filelist.h [code] |
| file | imgui.h [code] |
| file | imguiRenderGL.h [code] |
| file | InputGeom.h [code] |
| file | MeshLoaderObj.h [code] |
| file | NavMeshPruneTool.h [code] |
| file | NavMeshTesterTool.h [code] |
| file | OffMeshConnectionTool.h [code] |
| file | PerfTimer.h [code] |
| file | Sample.h [code] |
| file | Sample_Debug.h [code] |
| file | Sample_SoloMesh.h [code] |
| file | Sample_TempObstacles.h [code] |
| file | Sample_TileMesh.h [code] |
| file | SampleInterfaces.h [code] |
| file | TestCase.h [code] |
| file | ValueHistory.h [code] |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Files | |
| file | Recast.cpp |
| file | RecastAlloc.cpp |
| file | RecastArea.cpp |
| file | RecastAssert.cpp |
| file | RecastContour.cpp |
| file | RecastFilter.cpp |
| file | RecastLayers.cpp |
| file | RecastMesh.cpp |
| file | RecastMeshDetail.cpp |
| file | RecastRasterization.cpp |
| file | RecastRegion.cpp |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Members in this module implement local steering and dynamic avoidance features. +More...
++Classes | |
| struct | dtCrowdNeighbour |
| Provides neighbor data for agents managed by the crowd. More... | |
| struct | dtCrowdAgentParams |
| Configuration parameters for a crowd agent. More... | |
| struct | dtCrowdAgent |
| Represents an agent managed by a dtCrowd object. More... | |
| class | dtCrowd |
| Provides local steering behaviors for a group of agents. More... | |
| class | dtPathCorridor |
| Represents a dynamic polygon corridor used to plan agent movement. More... | |
+Enumerations | |
| enum | CrowdAgentState { DT_CROWDAGENT_STATE_INVALID +, DT_CROWDAGENT_STATE_WALKING +, DT_CROWDAGENT_STATE_OFFMESH + } |
| The type of navigation mesh polygon the agent is currently traversing. More... | |
| enum | UpdateFlags { + DT_CROWD_ANTICIPATE_TURNS = 1 +, DT_CROWD_OBSTACLE_AVOIDANCE = 2 +, DT_CROWD_SEPARATION = 4 +, DT_CROWD_OPTIMIZE_VIS = 8 +, + DT_CROWD_OPTIMIZE_TOPO = 16 + + } |
| Crowd agent update flags. More... | |
+Functions | |
| dtCrowd * | dtAllocCrowd () |
| Allocates a crowd object using the Detour allocator. More... | |
| void | dtFreeCrowd (dtCrowd *ptr) |
| Frees the specified crowd object using the Detour allocator. More... | |
+Variables | |
| static const int | DT_CROWDAGENT_MAX_NEIGHBOURS = 6 |
| The maximum number of neighbors that a crowd agent can take into account for steering decisions. More... | |
| static const int | DT_CROWDAGENT_MAX_CORNERS = 4 |
| The maximum number of corners a crowd agent will look ahead in the path. More... | |
| static const int | DT_CROWD_MAX_OBSTAVOIDANCE_PARAMS = 8 |
| The maximum number of crowd avoidance configurations supported by the crowd manager. More... | |
| static const int | DT_CROWD_MAX_QUERY_FILTER_TYPE = 16 |
| The maximum number of query filter types supported by the crowd manager. More... | |
Members in this module implement local steering and dynamic avoidance features.
+The crowd is the big beast of the navigation features. It not only handles a lot of the path management for you, but also local steering and dynamic avoidance between members of the crowd. I.e. It can keep your agents from running into each other.
+Main class: dtCrowd
+The dtNavMeshQuery and dtPathCorridor classes provide perfectly good, easy to use path planning features. But in the end they only give you points that your navigation client should be moving toward. When it comes to deciding things like agent velocity and steering to avoid other agents, that is up to you to implement. Unless, of course, you decide to use dtCrowd.
+Basically, you add an agent to the crowd, providing various configuration settings such as maximum speed and acceleration. You also provide a local target to more toward. The crowd manager then provides, with every update, the new agent position and velocity for the frame. The movement will be constrained to the navigation mesh, and steering will be applied to ensure agents managed by the crowd do not collide with each other.
+This is very powerful feature set. But it comes with limitations.
+The biggest limitation is that you must give control of the agent's position completely over to the crowd manager. You can update things like maximum speed and acceleration. But in order for the crowd manager to do its thing, it can't allow you to constantly be giving it overrides to position and velocity. So you give up direct control of the agent's movement. It belongs to the crowd.
+The second biggest limitation revolves around the fact that the crowd manager deals with local planning. So the agent's target should never be more than 256 polygons aways from its current position. If it is, you risk your agent failing to reach its target. So you may still need to do long distance planning and provide the crowd manager with intermediate targets.
+Other significant limitations:
+| enum CrowdAgentState | +
The type of navigation mesh polygon the agent is currently traversing.
+| enum UpdateFlags | +
Crowd agent update flags.
+| Enumerator | |
|---|---|
| DT_CROWD_ANTICIPATE_TURNS | |
| DT_CROWD_OBSTACLE_AVOIDANCE | |
| DT_CROWD_SEPARATION | |
| DT_CROWD_OPTIMIZE_VIS | Use dtPathCorridor::optimizePathVisibility() to optimize the agent path. + |
| DT_CROWD_OPTIMIZE_TOPO | Use dtPathCorridor::optimizePathTopology() to optimize the agent path. + |
| dtCrowd* dtAllocCrowd | +( | +) | ++ |
Allocates a crowd object using the Detour allocator.
+| void dtFreeCrowd | +( | +dtCrowd * | +ptr | ) | ++ |
Frees the specified crowd object using the Detour allocator.
+| [in] | ptr | A crowd object allocated using dtAllocCrowd |
+
|
+ +static | +
The maximum number of crowd avoidance configurations supported by the crowd manager.
+ + +
+
|
+ +static | +
The maximum number of query filter types supported by the crowd manager.
+ + +
+
|
+ +static | +
The maximum number of corners a crowd agent will look ahead in the path.
+This value is used for sizing the crowd agent corner buffers. Due to the behavior of the crowd manager, the actual number of useful corners will be one less than this number.
+ +
+
|
+ +static | +
The maximum number of neighbors that a crowd agent can take into account for steering decisions.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Members in this module are used to create, manipulate, and query navigation meshes. +More...
++Classes | |
| struct | dtPoly |
| Defines a polygon within a dtMeshTile object. More... | |
| struct | dtMeshHeader |
| Provides high level information related to a dtMeshTile object. More... | |
| struct | dtMeshTile |
| Defines a navigation mesh tile. More... | |
| struct | dtNavMeshParams |
| Configuration parameters used to define multi-tile navigation meshes. More... | |
| class | dtNavMesh |
| A navigation mesh based on tiles of convex polygons. More... | |
| struct | dtNavMeshCreateParams |
| Represents the source data used to build an navigation mesh tile. More... | |
| class | dtQueryFilter |
| Defines polygon filtering and traversal costs for navigation mesh query operations. More... | |
| struct | dtRaycastHit |
| Provides information about raycast hit filled by dtNavMeshQuery::raycast. More... | |
| class | dtPolyQuery |
| Provides custom polygon query behavior. More... | |
| class | dtNavMeshQuery |
| Provides the ability to perform pathfinding related queries against a navigation mesh. More... | |
| class | dtPathCorridor |
| Represents a dynamic polygon corridor used to plan agent movement. 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... | |
+Functions | |
| dtNavMesh * | dtAllocNavMesh () |
| 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... | |
| bool | dtCreateNavMeshData (dtNavMeshCreateParams *params, unsigned char **outData, int *outDataSize) |
| Builds navigation mesh tile data from the provided tile creation data. More... | |
| dtNavMeshQuery * | dtAllocNavMeshQuery () |
| Allocates a query object using the Detour allocator. More... | |
| void | dtFreeNavMeshQuery (dtNavMeshQuery *query) |
| Frees the specified query object using the Detour allocator. More... | |
+Variables | |
| static const int | DT_VERTS_PER_POLYGON = 6 |
| The maximum number of vertices per navigation polygon. More... | |
| static const int | DT_MAX_AREAS = 64 |
| The maximum number of user defined area ids. More... | |
Members in this module are used to create, manipulate, and query navigation meshes.
+Members in this module are wrappers around the standard math library.
+| dtPolyRef | +
A handle to a polygon within a navigation mesh tile.
+Polygon references are subject to the same invalidate/preserve/restore rules that apply to dtTileRef's. If the dtTileRef for the polygon's tile changes, the polygon reference becomes invalid.
+Changing a polygon's flags, area id, etc. does not impact its polygon reference.
+ +| dtTileRef | +
A handle to a tile within a navigation mesh.
+The following changes will invalidate a tile reference:
+A tile reference is preserved/restored if the tile is added to a navigation mesh initialized with the original dtNavMeshParams and is added at the original reference location. (E.g. The lastRef parameter is used with dtNavMesh::addTile.)
+Basically, if the storage structure of a tile changes, its associated tile reference changes.
+ +| dtNavMesh* dtAllocNavMesh | +( | +) | ++ |
Allocates a navigation mesh object using the Detour allocator.
+| dtNavMeshQuery* dtAllocNavMeshQuery | +( | +) | ++ |
Allocates a query object using the Detour allocator.
+| bool dtCreateNavMeshData | +( | +dtNavMeshCreateParams * | +params, | +
| + | + | unsigned char ** | +outData, | +
| + | + | int * | +outDataSize | +
| + | ) | ++ |
Builds navigation mesh tile data from the provided tile creation data.
+| [in] | params | Tile creation data. |
| [out] | outData | The resulting tile data. |
| [out] | outDataSize | The size of the tile data array. |
The output data array is allocated using the detour allocator (dtAlloc()). The method used to free the memory will be determined by how the tile is added to the navigation mesh.
+| void dtFreeNavMesh | +( | +dtNavMesh * | +navmesh | ) | ++ |
Frees the specified navigation mesh object using the Detour allocator.
+| [in] | navmesh | A navigation mesh allocated using dtAllocNavMesh |
This function will only free the memory for tiles with the DT_TILE_FREE_DATA flag set.
+ +| void dtFreeNavMeshQuery | +( | +dtNavMeshQuery * | +query | ) | ++ |
Frees the specified query object using the Detour allocator.
+| [in] | query | A query object allocated using dtAllocNavMeshQuery |
+
|
+ +static | +
The maximum number of user defined area ids.
+ +
+
|
+ +static | +
The maximum number of vertices per navigation polygon.
+ +|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Members in this module are used to create mesh data that is then used to create Detour navigation meshes. +More...
++Classes | |
| class | rcContext |
| Provides an interface for optional logging and performance tracking of the Recast build process. More... | |
| struct | rcConfig |
| Specifies a configuration to use when performing Recast builds. More... | |
| struct | rcHeightfield |
| A dynamic heightfield representing obstructed space. More... | |
| struct | rcCompactHeightfield |
| A compact, static heightfield representing unobstructed space. More... | |
| struct | rcHeightfieldLayerSet |
| Represents a set of heightfield layers. More... | |
| struct | rcContourSet |
| Represents a group of related contours. More... | |
| struct | rcPolyMesh |
| Represents a polygon mesh suitable for use in building a navigation mesh. More... | |
| struct | rcPolyMeshDetail |
| Contains triangle meshes that represent detailed height data associated with the polygons in its associated polygon mesh object. More... | |
Allocation Functions | |
Functions used to allocate and de-allocate Recast objects. +
| |
| rcHeightfield * | rcAllocHeightfield () |
| Allocates a heightfield object using the Recast allocator. More... | |
| void | rcFreeHeightField (rcHeightfield *heightfield) |
| Frees the specified heightfield object using the Recast allocator. More... | |
| rcCompactHeightfield * | rcAllocCompactHeightfield () |
| Allocates a compact heightfield object using the Recast allocator. More... | |
| void | rcFreeCompactHeightfield (rcCompactHeightfield *compactHeightfield) |
| Frees the specified compact heightfield object using the Recast allocator. More... | |
| rcHeightfieldLayerSet * | rcAllocHeightfieldLayerSet () |
| Allocates a heightfield layer set using the Recast allocator. More... | |
| void | rcFreeHeightfieldLayerSet (rcHeightfieldLayerSet *layerSet) |
| Frees the specified heightfield layer set using the Recast allocator. More... | |
| rcContourSet * | rcAllocContourSet () |
| Allocates a contour set object using the Recast allocator. More... | |
| void | rcFreeContourSet (rcContourSet *contourSet) |
| Frees the specified contour set using the Recast allocator. More... | |
| rcPolyMesh * | rcAllocPolyMesh () |
| Allocates a polygon mesh object using the Recast allocator. More... | |
| void | rcFreePolyMesh (rcPolyMesh *polyMesh) |
| Frees the specified polygon mesh using the Recast allocator. More... | |
| rcPolyMeshDetail * | rcAllocPolyMeshDetail () |
| Allocates a detail mesh object using the Recast allocator. More... | |
| void | rcFreePolyMeshDetail (rcPolyMeshDetail *detailMesh) |
| Frees the specified detail mesh using the Recast allocator. More... | |
Heightfield Functions | |
| |
| void | rcCalcBounds (const float *verts, int numVerts, float *minBounds, float *maxBounds) |
| Calculates the bounding box of an array of vertices. More... | |
| void | rcCalcGridSize (const float *minBounds, const float *maxBounds, float cellSize, int *sizeX, int *sizeZ) |
| Calculates the grid size based on the bounding box and grid cell size. More... | |
| bool | rcCreateHeightfield (rcContext *context, rcHeightfield &heightfield, int sizeX, int sizeZ, const float *minBounds, const float *maxBounds, float cellSize, float cellHeight) |
| Initializes a new heightfield. More... | |
| void | rcMarkWalkableTriangles (rcContext *context, float walkableSlopeAngle, const float *verts, int numVerts, const int *tris, int numTris, unsigned char *triAreaIDs) |
| Sets the area id of all triangles with a slope below the specified value to RC_WALKABLE_AREA. More... | |
| void | rcClearUnwalkableTriangles (rcContext *context, float walkableSlopeAngle, const float *verts, int numVerts, const int *tris, int numTris, unsigned char *triAreaIDs) |
| Sets the area id of all triangles with a slope greater than or equal to the specified value to RC_NULL_AREA. More... | |
| bool | rcAddSpan (rcContext *context, rcHeightfield &heightfield, int x, int z, unsigned short spanMin, unsigned short spanMax, unsigned char areaID, int flagMergeThreshold) |
| Adds a span to the specified heightfield. More... | |
| bool | rcRasterizeTriangle (rcContext *context, const float *v0, const float *v1, const float *v2, unsigned char areaID, rcHeightfield &heightfield, int flagMergeThreshold=1) |
| Rasterizes a single triangle into the specified heightfield. More... | |
| bool | rcRasterizeTriangles (rcContext *context, const float *verts, int numVerts, const int *tris, const unsigned char *triAreaIDs, int numTris, rcHeightfield &heightfield, int flagMergeThreshold=1) |
| Rasterizes an indexed triangle mesh into the specified heightfield. More... | |
| bool | rcRasterizeTriangles (rcContext *context, const float *verts, int numVerts, const unsigned short *tris, const unsigned char *triAreaIDs, int numTris, rcHeightfield &heightfield, int flagMergeThreshold=1) |
| Rasterizes an indexed triangle mesh into the specified heightfield. More... | |
| bool | rcRasterizeTriangles (rcContext *context, const float *verts, const unsigned char *triAreaIDs, int numTris, rcHeightfield &heightfield, int flagMergeThreshold=1) |
| Rasterizes a triangle list into the specified heightfield. More... | |
| void | rcFilterLowHangingWalkableObstacles (rcContext *context, int walkableClimb, rcHeightfield &heightfield) |
Marks non-walkable spans as walkable if their maximum is within walkableClimb of a walkable neighbor. More... | |
| void | rcFilterLedgeSpans (rcContext *context, int walkableHeight, int walkableClimb, rcHeightfield &heightfield) |
| Marks spans that are ledges as not-walkable. More... | |
| void | rcFilterWalkableLowHeightSpans (rcContext *context, int walkableHeight, rcHeightfield &heightfield) |
| Marks walkable spans as not walkable if the clearance above the span is less than the specified height. More... | |
| int | rcGetHeightFieldSpanCount (rcContext *context, const rcHeightfield &heightfield) |
| Returns the number of spans contained in the specified heightfield. More... | |
Compact Heightfield Functions | |
| |
| bool | rcBuildCompactHeightfield (rcContext *context, int walkableHeight, int walkableClimb, rcHeightfield &heightfield, rcCompactHeightfield &compactHeightfield) |
| Builds a compact heightfield representing open space, from a heightfield representing solid space. More... | |
| bool | rcErodeWalkableArea (rcContext *ctx, int radius, rcCompactHeightfield &chf) |
| Erodes the walkable area within the heightfield by the specified radius. More... | |
| bool | rcMedianFilterWalkableArea (rcContext *ctx, rcCompactHeightfield &chf) |
| Applies a median filter to walkable area types (based on area id), removing noise. More... | |
| void | rcMarkBoxArea (rcContext *ctx, const float *bmin, const float *bmax, unsigned char areaId, rcCompactHeightfield &chf) |
| Applies an area id to all spans within the specified bounding box. More... | |
| void | rcMarkConvexPolyArea (rcContext *ctx, const float *verts, const int nverts, const float hmin, const float hmax, unsigned char areaId, rcCompactHeightfield &chf) |
| Applies the area id to the all spans within the specified convex polygon. More... | |
| int | rcOffsetPoly (const float *verts, const int nverts, const float offset, float *outVerts, const int maxOutVerts) |
| Helper function to offset voncex polygons for rcMarkConvexPolyArea. More... | |
| void | rcMarkCylinderArea (rcContext *ctx, const float *pos, const float r, const float h, unsigned char areaId, rcCompactHeightfield &chf) |
| Applies the area id to all spans within the specified cylinder. More... | |
| bool | rcBuildDistanceField (rcContext *ctx, rcCompactHeightfield &chf) |
| Builds the distance field for the specified compact heightfield. More... | |
| bool | rcBuildRegions (rcContext *ctx, rcCompactHeightfield &chf, int borderSize, int minRegionArea, int mergeRegionArea) |
| Builds region data for the heightfield using watershed partitioning. More... | |
| bool | rcBuildLayerRegions (rcContext *ctx, rcCompactHeightfield &chf, int borderSize, int minRegionArea) |
| Builds region data for the heightfield by partitioning the heightfield in non-overlapping layers. More... | |
| bool | rcBuildRegionsMonotone (rcContext *ctx, rcCompactHeightfield &chf, int borderSize, int minRegionArea, int mergeRegionArea) |
| Builds region data for the heightfield using simple monotone partitioning. More... | |
| void | rcSetCon (rcCompactSpan &span, int direction, int neighborIndex) |
| Sets the neighbor connection data for the specified direction. More... | |
| int | rcGetCon (const rcCompactSpan &span, int direction) |
| Gets neighbor connection data for the specified direction. More... | |
| int | rcGetDirOffsetX (int direction) |
| Gets the standard width (x-axis) offset for the specified direction. More... | |
| int | rcGetDirOffsetY (int direction) |
| Gets the standard height (z-axis) offset for the specified direction. More... | |
| int | rcGetDirForOffset (int offsetX, int offsetZ) |
| Gets the direction for the specified offset. More... | |
Layer, Contour, Polymesh, and Detail Mesh Functions | |
| |
| bool | rcBuildHeightfieldLayers (rcContext *ctx, rcCompactHeightfield &chf, int borderSize, int walkableHeight, rcHeightfieldLayerSet &lset) |
| Builds a layer set from the specified compact heightfield. More... | |
| bool | rcBuildContours (rcContext *ctx, rcCompactHeightfield &chf, float maxError, int maxEdgeLen, rcContourSet &cset, int buildFlags=RC_CONTOUR_TESS_WALL_EDGES) |
| Builds a contour set from the region outlines in the provided compact heightfield. More... | |
| bool | rcBuildPolyMesh (rcContext *ctx, rcContourSet &cset, const int nvp, rcPolyMesh &mesh) |
| Builds a polygon mesh from the provided contours. More... | |
| bool | rcMergePolyMeshes (rcContext *ctx, rcPolyMesh **meshes, const int nmeshes, rcPolyMesh &mesh) |
| Merges multiple polygon meshes into a single mesh. More... | |
| bool | rcBuildPolyMeshDetail (rcContext *ctx, const rcPolyMesh &mesh, const rcCompactHeightfield &chf, float sampleDist, float sampleMaxError, rcPolyMeshDetail &dmesh) |
| Builds a detail mesh from the provided polygon mesh. More... | |
| bool | rcCopyPolyMesh (rcContext *ctx, const rcPolyMesh &src, rcPolyMesh &dst) |
| Copies the poly mesh data from src to dst. More... | |
| bool | rcMergePolyMeshDetails (rcContext *ctx, rcPolyMeshDetail **meshes, const int nmeshes, rcPolyMeshDetail &mesh) |
| Merges multiple detail meshes into a single detail mesh. More... | |
Members in this module are used to create mesh data that is then used to create Detour navigation meshes.
+The are a large number of possible ways to building navigation mesh data. One of the simple piplines is as follows:
+The general life-cycle of the main classes is as follows:
+| bool rcAddSpan | +( | +rcContext * | +context, | +
| + | + | rcHeightfield & | +heightfield, | +
| + | + | int | +x, | +
| + | + | int | +z, | +
| + | + | unsigned short | +spanMin, | +
| + | + | unsigned short | +spanMax, | +
| + | + | unsigned char | +areaID, | +
| + | + | int | +flagMergeThreshold | +
| + | ) | ++ |
Adds a span to the specified heightfield.
+The span addition can be set to favor flags. If the span is merged to another span and the new spanMax is within flagMergeThreshold units from the existing span, the span flags are merged.
| [in,out] | context | The build context to use during the operation. |
| [in,out] | heightfield | An initialized heightfield. |
| [in] | x | The column x index where the span is to be added. [Limits: 0 <= value < rcHeightfield::width] |
| [in] | z | The column z index where the span is to be added. [Limits: 0 <= value < rcHeightfield::height] |
| [in] | spanMin | The minimum height of the span. [Limit: < spanMax] [Units: vx] |
| [in] | spanMax | The maximum height of the span. [Limit: <= RC_SPAN_MAX_HEIGHT] [Units: vx] |
| [in] | areaID | The area id of the span. [Limit: <= RC_WALKABLE_AREA) |
| [in] | flagMergeThreshold | The merge threshold. [Limit: >= 0] [Units: vx] |
| rcCompactHeightfield* rcAllocCompactHeightfield | +( | +) | ++ |
Allocates a compact heightfield object using the Recast allocator.
+| rcContourSet* rcAllocContourSet | +( | +) | ++ |
Allocates a contour set object using the Recast allocator.
+| rcHeightfield* rcAllocHeightfield | +( | +) | ++ |
Allocates a heightfield object using the Recast allocator.
+| rcHeightfieldLayerSet* rcAllocHeightfieldLayerSet | +( | +) | ++ |
Allocates a heightfield layer set using the Recast allocator.
+| rcPolyMesh* rcAllocPolyMesh | +( | +) | ++ |
Allocates a polygon mesh object using the Recast allocator.
+| rcPolyMeshDetail* rcAllocPolyMeshDetail | +( | +) | ++ |
Allocates a detail mesh object using the Recast allocator.
+| bool rcBuildCompactHeightfield | +( | +rcContext * | +context, | +
| + | + | int | +walkableHeight, | +
| + | + | int | +walkableClimb, | +
| + | + | rcHeightfield & | +heightfield, | +
| + | + | rcCompactHeightfield & | +compactHeightfield | +
| + | ) | ++ |
Builds a compact heightfield representing open space, from a heightfield representing solid space.
+This is just the beginning of the process of fully building a compact heightfield. Various filters may be applied, then the distance field and regions built. E.g: rcBuildDistanceField and rcBuildRegions
+See the rcConfig documentation for more information on the configuration parameters.
+ +| [in,out] | context | The build context to use during the operation. |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [in] | walkableClimb | Maximum ledge height that is considered to still be traversable. [Limit: >=0] [Units: vx] |
| [in] | heightfield | The heightfield to be compacted. |
| [out] | compactHeightfield | The resulting compact heightfield. (Must be pre-allocated.) |
| bool rcBuildContours | +( | +rcContext * | +ctx, | +
| + | + | rcCompactHeightfield & | +chf, | +
| + | + | const float | +maxError, | +
| + | + | const int | +maxEdgeLen, | +
| + | + | rcContourSet & | +cset, | +
| + | + | const int | +buildFlags | +
| + | ) | ++ |
Builds a contour set from the region outlines in the provided compact heightfield.
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | chf | A fully built compact heightfield. |
| [in] | maxError | The maximum distance a simplified contour's border edges should deviate the original raw contour. [Limit: >=0] [Units: wu] |
| [in] | maxEdgeLen | The maximum allowed length for contour edges along the border of the mesh. [Limit: >=0] [Units: vx] |
| [out] | cset | The resulting contour set. (Must be pre-allocated.) |
| [in] | buildFlags | The build flags. (See: rcBuildContoursFlags) |
The raw contours will match the region outlines exactly. The maxError and maxEdgeLen parameters control how closely the simplified contours will match the raw contours.
Simplified contours are generated such that the vertices for portals between areas match up. (They are considered mandatory vertices.)
+Setting maxEdgeLength to zero will disabled the edge length feature.
See the rcConfig documentation for more information on the configuration parameters.
+ + +| bool rcBuildDistanceField | +( | +rcContext * | +ctx, | +
| + | + | rcCompactHeightfield & | +chf | +
| + | ) | ++ |
Builds the distance field for the specified compact heightfield.
+| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
This is usually the second to the last step in creating a fully built compact heightfield. This step is required before regions are built using rcBuildRegions or rcBuildRegionsMonotone.
+After this step, the distance data is available via the rcCompactHeightfield::maxDistance and rcCompactHeightfield::dist fields.
+ + +| bool rcBuildHeightfieldLayers | +( | +rcContext * | +ctx, | +
| + | + | rcCompactHeightfield & | +chf, | +
| + | + | const int | +borderSize, | +
| + | + | const int | +walkableHeight, | +
| + | + | rcHeightfieldLayerSet & | +lset | +
| + | ) | ++ |
Builds a layer set from the specified compact heightfield.
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | chf | A fully built compact heightfield. |
| [in] | borderSize | The size of the non-navigable border around the heightfield. [Limit: >=0] [Units: vx] |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [out] | lset | The resulting layer set. (Must be pre-allocated.) |
See the rcConfig documentation for more information on the configuration parameters.
+ + +| bool rcBuildLayerRegions | +( | +rcContext * | +ctx, | +
| + | + | rcCompactHeightfield & | +chf, | +
| + | + | int | +borderSize, | +
| + | + | int | +minRegionArea | +
| + | ) | ++ |
Builds region data for the heightfield by partitioning the heightfield in non-overlapping layers.
+| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
| [in] | borderSize | The size of the non-navigable border around the heightfield. [Limit: >=0] [Units: vx] |
| [in] | minRegionArea | The minimum number of cells allowed to form isolated island areas. [Limit: >=0] [Units: vx]. |
| bool rcBuildPolyMesh | +( | +rcContext * | +ctx, | +
| + | + | rcContourSet & | +cset, | +
| + | + | const int | +nvp, | +
| + | + | rcPolyMesh & | +mesh | +
| + | ) | ++ |
Builds a polygon mesh from the provided contours.
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | cset | A fully built contour set. |
| [in] | nvp | The maximum number of vertices allowed for polygons generated during the contour to polygon conversion process. [Limit: >= 3] |
| [out] | mesh | The resulting polygon mesh. (Must be re-allocated.) |
| bool rcBuildPolyMeshDetail | +( | +rcContext * | +ctx, | +
| + | + | const rcPolyMesh & | +mesh, | +
| + | + | const rcCompactHeightfield & | +chf, | +
| + | + | const float | +sampleDist, | +
| + | + | const float | +sampleMaxError, | +
| + | + | rcPolyMeshDetail & | +dmesh | +
| + | ) | ++ |
Builds a detail mesh from the provided polygon mesh.
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | mesh | A fully built polygon mesh. |
| [in] | chf | The compact heightfield used to build the polygon mesh. |
| [in] | sampleDist | Sets the distance to use when sampling the heightfield. [Limit: >=0] [Units: wu] |
| [in] | sampleMaxError | The maximum distance the detail mesh surface should deviate from heightfield data. [Limit: >=0] [Units: wu] |
| [out] | dmesh | The resulting detail mesh. (Must be pre-allocated.) |
See the rcConfig documentation for more information on the configuration parameters.
+ + +| bool rcBuildRegions | +( | +rcContext * | +ctx, | +
| + | + | rcCompactHeightfield & | +chf, | +
| + | + | const int | +borderSize, | +
| + | + | const int | +minRegionArea, | +
| + | + | const int | +mergeRegionArea | +
| + | ) | ++ |
Builds region data for the heightfield using watershed partitioning.
+| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
| [in] | borderSize | The size of the non-navigable border around the heightfield. [Limit: >=0] [Units: vx] |
| [in] | minRegionArea | The minimum number of cells allowed to form isolated island areas. [Limit: >=0] [Units: vx]. |
| [in] | mergeRegionArea | Any regions with a span count smaller than this value will, if possible, be merged with larger regions. [Limit: >=0] [Units: vx] |
Non-null regions will consist of connected, non-overlapping walkable spans that form a single contour. Contours will form simple polygons.
+If multiple regions form an area that is smaller than minRegionArea, then all spans will be re-assigned to the zero (null) region.
Watershed partitioning can result in smaller than necessary regions, especially in diagonal corridors. mergeRegionArea helps reduce unecessarily small regions.
See the rcConfig documentation for more information on the configuration parameters.
+The region data will be available via the rcCompactHeightfield::maxRegions and rcCompactSpan::reg fields.
+| bool rcBuildRegionsMonotone | +( | +rcContext * | +ctx, | +
| + | + | rcCompactHeightfield & | +chf, | +
| + | + | const int | +borderSize, | +
| + | + | const int | +minRegionArea, | +
| + | + | const int | +mergeRegionArea | +
| + | ) | ++ |
Builds region data for the heightfield using simple monotone partitioning.
+| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
| [in] | borderSize | The size of the non-navigable border around the heightfield. [Limit: >=0] [Units: vx] |
| [in] | minRegionArea | The minimum number of cells allowed to form isolated island areas. [Limit: >=0] [Units: vx]. |
| [in] | mergeRegionArea | Any regions with a span count smaller than this value will, if possible, be merged with larger regions. [Limit: >=0] [Units: vx] |
Non-null regions will consist of connected, non-overlapping walkable spans that form a single contour. Contours will form simple polygons.
+If multiple regions form an area that is smaller than minRegionArea, then all spans will be re-assigned to the zero (null) region.
Partitioning can result in smaller than necessary regions. mergeRegionArea helps reduce unecessarily small regions.
See the rcConfig documentation for more information on the configuration parameters.
+The region data will be available via the rcCompactHeightfield::maxRegions and rcCompactSpan::reg fields.
+| void rcCalcBounds | +( | +const float * | +verts, | +
| + | + | int | +numVerts, | +
| + | + | float * | +minBounds, | +
| + | + | float * | +maxBounds | +
| + | ) | ++ |
Calculates the bounding box of an array of vertices.
+| [in] | verts | An array of vertices. [(x, y, z) * nv] |
| [in] | numVerts | The number of vertices in the verts array. |
| [out] | minBounds | The minimum bounds of the AABB. [(x, y, z)] [Units: wu] |
| [out] | maxBounds | The maximum bounds of the AABB. [(x, y, z)] [Units: wu] |
| void rcCalcGridSize | +( | +const float * | +minBounds, | +
| + | + | const float * | +maxBounds, | +
| + | + | float | +cellSize, | +
| + | + | int * | +sizeX, | +
| + | + | int * | +sizeZ | +
| + | ) | ++ |
Calculates the grid size based on the bounding box and grid cell size.
+| [in] | minBounds | The minimum bounds of the AABB. [(x, y, z)] [Units: wu] |
| [in] | maxBounds | The maximum bounds of the AABB. [(x, y, z)] [Units: wu] |
| [in] | cellSize | The xz-plane cell size. [Limit: > 0] [Units: wu] |
| [out] | sizeX | The width along the x-axis. [Limit: >= 0] [Units: vx] |
| [out] | sizeZ | The height along the z-axis. [Limit: >= 0] [Units: vx] |
| void rcClearUnwalkableTriangles | +( | +rcContext * | +context, | +
| + | + | float | +walkableSlopeAngle, | +
| + | + | const float * | +verts, | +
| + | + | int | +numVerts, | +
| + | + | const int * | +tris, | +
| + | + | int | +numTris, | +
| + | + | unsigned char * | +triAreaIDs | +
| + | ) | ++ |
Sets the area id of all triangles with a slope greater than or equal to the specified value to RC_NULL_AREA.
+Only sets the area id's for the un-walkable triangles. Does not alter the area id's for walkable triangles.
+See the rcConfig documentation for more information on the configuration parameters.
+ +| [in,out] | context | The build context to use during the operation. |
| [in] | walkableSlopeAngle | The maximum slope that is considered walkable. [Limits: 0 <= value < 90] [Units: Degrees] |
| [in] | verts | The vertices. [(x, y, z) * nv] |
| [in] | numVerts | The number of vertices. |
| [in] | tris | The triangle vertex indices. [(vertA, vertB, vertC) * nt] |
| [in] | numTris | The number of triangles. |
| [out] | triAreaIDs | The triangle area ids. [Length: >= nt] |
| bool rcCopyPolyMesh | +( | +rcContext * | +ctx, | +
| + | + | const rcPolyMesh & | +src, | +
| + | + | rcPolyMesh & | +dst | +
| + | ) | ++ |
Copies the poly mesh data from src to dst.
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | src | The source mesh to copy from. |
| [out] | dst | The resulting detail mesh. (Must be pre-allocated, must be empty mesh.) |
| bool rcCreateHeightfield | +( | +rcContext * | +context, | +
| + | + | rcHeightfield & | +heightfield, | +
| + | + | int | +sizeX, | +
| + | + | int | +sizeZ, | +
| + | + | const float * | +minBounds, | +
| + | + | const float * | +maxBounds, | +
| + | + | float | +cellSize, | +
| + | + | float | +cellHeight | +
| + | ) | ++ |
Initializes a new heightfield.
+See the rcConfig documentation for more information on the configuration parameters.
+| [in,out] | context | The build context to use during the operation. |
| [in,out] | heightfield | The allocated heightfield to initialize. |
| [in] | sizeX | The width of the field along the x-axis. [Limit: >= 0] [Units: vx] |
| [in] | sizeZ | The height of the field along the z-axis. [Limit: >= 0] [Units: vx] |
| [in] | minBounds | The minimum bounds of the field's AABB. [(x, y, z)] [Units: wu] |
| [in] | maxBounds | The maximum bounds of the field's AABB. [(x, y, z)] [Units: wu] |
| [in] | cellSize | The xz-plane cell size to use for the field. [Limit: > 0] [Units: wu] |
| [in] | cellHeight | The y-axis cell size to use for field. [Limit: > 0] [Units: wu] |
| bool rcErodeWalkableArea | +( | +rcContext * | +ctx, | +
| + | + | int | +radius, | +
| + | + | rcCompactHeightfield & | +chf | +
| + | ) | ++ |
Erodes the walkable area within the heightfield by the specified radius.
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | radius | The radius of erosion. [Limits: 0 < value < 255] [Units: vx] |
| [in,out] | chf | The populated compact heightfield to erode. |
Basically, any spans that are closer to a boundary or obstruction than the specified radius are marked as unwalkable.
+This method is usually called immediately after the heightfield has been built.
+ + +| void rcFilterLedgeSpans | +( | +rcContext * | +context, | +
| + | + | int | +walkableHeight, | +
| + | + | int | +walkableClimb, | +
| + | + | rcHeightfield & | +heightfield | +
| + | ) | ++ |
Marks spans that are ledges as not-walkable.
+A ledge is a span with one or more neighbors whose maximum is further away than walkableClimb from the current span's maximum. This method removes the impact of the overestimation of conservative voxelization so the resulting mesh will not have regions hanging in the air over ledges.
A span is a ledge if: rcAbs(currentSpan.smax - neighborSpan.smax) > walkableClimb
| [in,out] | context | The build context to use during the operation. |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [in] | walkableClimb | Maximum ledge height that is considered to still be traversable. [Limit: >=0] [Units: vx] |
| [in,out] | heightfield | A fully built heightfield. (All spans have been added.) |
| void rcFilterLowHangingWalkableObstacles | +( | +rcContext * | +context, | +
| + | + | int | +walkableClimb, | +
| + | + | rcHeightfield & | +heightfield | +
| + | ) | ++ |
Marks non-walkable spans as walkable if their maximum is within walkableClimb of a walkable neighbor.
Allows the formation of walkable regions that will flow over low lying objects such as curbs, and up structures such as stairways.
+Two neighboring spans are walkable if: rcAbs(currentSpan.smax - neighborSpan.smax) < waklableClimb
| [in,out] | context | The build context to use during the operation. |
| [in] | walkableClimb | Maximum ledge height that is considered to still be traversable. [Limit: >=0] [Units: vx] |
| [in,out] | heightfield | A fully built heightfield. (All spans have been added.) |
| void rcFilterWalkableLowHeightSpans | +( | +rcContext * | +context, | +
| + | + | int | +walkableHeight, | +
| + | + | rcHeightfield & | +heightfield | +
| + | ) | ++ |
Marks walkable spans as not walkable if the clearance above the span is less than the specified height.
+For this filter, the clearance above the span is the distance from the span's maximum to the next higher span's minimum. (Same grid column.)
+| [in,out] | context | The build context to use during the operation. |
| [in] | walkableHeight | Minimum floor to 'ceiling' height that will still allow the floor area to be considered walkable. [Limit: >= 3] [Units: vx] |
| [in,out] | heightfield | A fully built heightfield. (All spans have been added.) |
| void rcFreeCompactHeightfield | +( | +rcCompactHeightfield * | +compactHeightfield | ) | ++ |
Frees the specified compact heightfield object using the Recast allocator.
+| [in] | compactHeightfield | A compact heightfield allocated using rcAllocCompactHeightfield |
| void rcFreeContourSet | +( | +rcContourSet * | +contourSet | ) | ++ |
Frees the specified contour set using the Recast allocator.
+| [in] | contourSet | A contour set allocated using rcAllocContourSet |
| void rcFreeHeightField | +( | +rcHeightfield * | +heightfield | ) | ++ |
Frees the specified heightfield object using the Recast allocator.
+| [in] | heightfield | A heightfield allocated using rcAllocHeightfield |
| void rcFreeHeightfieldLayerSet | +( | +rcHeightfieldLayerSet * | +layerSet | ) | ++ |
Frees the specified heightfield layer set using the Recast allocator.
+| [in] | layerSet | A heightfield layer set allocated using rcAllocHeightfieldLayerSet |
| void rcFreePolyMesh | +( | +rcPolyMesh * | +polyMesh | ) | ++ |
Frees the specified polygon mesh using the Recast allocator.
+| [in] | polyMesh | A polygon mesh allocated using rcAllocPolyMesh |
| void rcFreePolyMeshDetail | +( | +rcPolyMeshDetail * | +detailMesh | ) | ++ |
Frees the specified detail mesh using the Recast allocator.
+| [in] | detailMesh | A detail mesh allocated using rcAllocPolyMeshDetail |
+
|
+ +inline | +
Gets neighbor connection data for the specified direction.
+| [in] | span | The span to check. |
| [in] | direction | The direction to check. [Limits: 0 <= value < 4] |
Can be used to locate neighbor spans in a compact heightfield. See the rcCompactHeightfield documentation for details on its use.
+
+
|
+ +inline | +
Gets the direction for the specified offset.
+One of x and y should be 0.
| [in] | offsetX | The x offset. [Limits: -1 <= value <= 1] |
| [in] | offsetZ | The z offset. [Limits: -1 <= value <= 1] |
+
|
+ +inline | +
Gets the standard width (x-axis) offset for the specified direction.
+| [in] | direction | The direction. [Limits: 0 <= value < 4] |
The value of dir will be automatically wrapped. So a value of 6 will be interpreted as 2.
See the rcCompactHeightfield documentation for usage details.
+ +
+
|
+ +inline | +
Gets the standard height (z-axis) offset for the specified direction.
+| [in] | direction | The direction. [Limits: 0 <= value < 4] |
The value of dir will be automatically wrapped. So a value of 6 will be interpreted as 2.
See the rcCompactHeightfield documentation for usage details.
+ +| int rcGetHeightFieldSpanCount | +( | +rcContext * | +context, | +
| + | + | const rcHeightfield & | +heightfield | +
| + | ) | ++ |
Returns the number of spans contained in the specified heightfield.
+| [in,out] | context | The build context to use during the operation. |
| [in] | heightfield | An initialized heightfield. |
| void rcMarkBoxArea | +( | +rcContext * | +ctx, | +
| + | + | const float * | +bmin, | +
| + | + | const float * | +bmax, | +
| + | + | unsigned char | +areaId, | +
| + | + | rcCompactHeightfield & | +chf | +
| + | ) | ++ |
Applies an area id to all spans within the specified bounding box.
+(AABB)
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | bmin | The minimum of the bounding box. [(x, y, z)] |
| [in] | bmax | The maximum of the bounding box. [(x, y, z)] |
| [in] | areaId | The area id to apply. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | chf | A populated compact heightfield. |
The value of spacial parameters are in world units.
+ + +| void rcMarkConvexPolyArea | +( | +rcContext * | +ctx, | +
| + | + | const float * | +verts, | +
| + | + | const int | +nverts, | +
| + | + | const float | +hmin, | +
| + | + | const float | +hmax, | +
| + | + | unsigned char | +areaId, | +
| + | + | rcCompactHeightfield & | +chf | +
| + | ) | ++ |
Applies the area id to the all spans within the specified convex polygon.
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | verts | The vertices of the polygon [Fomr: (x, y, z) * nverts] |
| [in] | nverts | The number of vertices in the polygon. |
| [in] | hmin | The height of the base of the polygon. |
| [in] | hmax | The height of the top of the polygon. |
| [in] | areaId | The area id to apply. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | chf | A populated compact heightfield. |
The value of spacial parameters are in world units.
+The y-values of the polygon vertices are ignored. So the polygon is effectively projected onto the xz-plane at hmin, then extruded to hmax.
| void rcMarkCylinderArea | +( | +rcContext * | +ctx, | +
| + | + | const float * | +pos, | +
| + | + | const float | +r, | +
| + | + | const float | +h, | +
| + | + | unsigned char | +areaId, | +
| + | + | rcCompactHeightfield & | +chf | +
| + | ) | ++ |
Applies the area id to all spans within the specified cylinder.
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | pos | The center of the base of the cylinder. [Form: (x, y, z)] |
| [in] | r | The radius of the cylinder. |
| [in] | h | The height of the cylinder. |
| [in] | areaId | The area id to apply. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | chf | A populated compact heightfield. |
The value of spacial parameters are in world units.
+ + +| void rcMarkWalkableTriangles | +( | +rcContext * | +context, | +
| + | + | float | +walkableSlopeAngle, | +
| + | + | const float * | +verts, | +
| + | + | int | +numVerts, | +
| + | + | const int * | +tris, | +
| + | + | int | +numTris, | +
| + | + | unsigned char * | +triAreaIDs | +
| + | ) | ++ |
Sets the area id of all triangles with a slope below the specified value to RC_WALKABLE_AREA.
+Only sets the area id's for the walkable triangles. Does not alter the area id's for un-walkable triangles.
+See the rcConfig documentation for more information on the configuration parameters.
+ +| [in,out] | context | The build context to use during the operation. |
| [in] | walkableSlopeAngle | The maximum slope that is considered walkable. [Limits: 0 <= value < 90] [Units: Degrees] |
| [in] | verts | The vertices. [(x, y, z) * nv] |
| [in] | numVerts | The number of vertices. |
| [in] | tris | The triangle vertex indices. [(vertA, vertB, vertC) * nt] |
| [in] | numTris | The number of triangles. |
| [out] | triAreaIDs | The triangle area ids. [Length: >= nt] |
| bool rcMedianFilterWalkableArea | +( | +rcContext * | +ctx, | +
| + | + | rcCompactHeightfield & | +chf | +
| + | ) | ++ |
Applies a median filter to walkable area types (based on area id), removing noise.
+| [in,out] | ctx | The build context to use during the operation. |
| [in,out] | chf | A populated compact heightfield. |
This filter is usually applied after applying area id's using functions such as rcMarkBoxArea, rcMarkConvexPolyArea, and rcMarkCylinderArea.
+| bool rcMergePolyMeshDetails | +( | +rcContext * | +ctx, | +
| + | + | rcPolyMeshDetail ** | +meshes, | +
| + | + | const int | +nmeshes, | +
| + | + | rcPolyMeshDetail & | +mesh | +
| + | ) | ++ |
Merges multiple detail meshes into a single detail mesh.
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | meshes | An array of detail meshes to merge. [Size: nmeshes] |
| [in] | nmeshes | The number of detail meshes in the meshes array. |
| [out] | mesh | The resulting detail mesh. (Must be pre-allocated.) |
| bool rcMergePolyMeshes | +( | +rcContext * | +ctx, | +
| + | + | rcPolyMesh ** | +meshes, | +
| + | + | const int | +nmeshes, | +
| + | + | rcPolyMesh & | +mesh | +
| + | ) | ++ |
Merges multiple polygon meshes into a single mesh.
+| [in,out] | ctx | The build context to use during the operation. |
| [in] | meshes | An array of polygon meshes to merge. [Size: nmeshes] |
| [in] | nmeshes | The number of polygon meshes in the meshes array. |
| [in] | mesh | The resulting polygon mesh. (Must be pre-allocated.) |
| int rcOffsetPoly | +( | +const float * | +verts, | +
| + | + | const int | +nverts, | +
| + | + | const float | +offset, | +
| + | + | float * | +outVerts, | +
| + | + | const int | +maxOutVerts | +
| + | ) | ++ |
Helper function to offset voncex polygons for rcMarkConvexPolyArea.
+| [in] | verts | The vertices of the polygon [Form: (x, y, z) * nverts] |
| [in] | nverts | The number of vertices in the polygon. |
| [in] | offset | How much to offset the polygon by. [Units: wu] |
| [out] | outVerts | The offset vertices (should hold up to 2 * nverts) [Form: (x, y, z) * return value] |
| [in] | maxOutVerts | The max number of vertices that can be stored to outVerts. |
outVerts. | bool rcRasterizeTriangle | +( | +rcContext * | +context, | +
| + | + | const float * | +v0, | +
| + | + | const float * | +v1, | +
| + | + | const float * | +v2, | +
| + | + | unsigned char | +areaID, | +
| + | + | rcHeightfield & | +heightfield, | +
| + | + | int | +flagMergeThreshold = 1 |
+
| + | ) | ++ |
Rasterizes a single triangle into the specified heightfield.
+Calling this for each triangle in a mesh is less efficient than calling rcRasterizeTriangles
+No spans will be added if the triangle does not overlap the heightfield grid.
+| [in,out] | context | The build context to use during the operation. |
| [in] | v0 | Triangle vertex 0 [(x, y, z)] |
| [in] | v1 | Triangle vertex 1 [(x, y, z)] |
| [in] | v2 | Triangle vertex 2 [(x, y, z)] |
| [in] | areaID | The area id of the triangle. [Limit: <= RC_WALKABLE_AREA] |
| [in,out] | heightfield | An initialized heightfield. |
| [in] | flagMergeThreshold | The distance where the walkable flag is favored over the non-walkable flag. [Limit: >= 0] [Units: vx] |
| bool rcRasterizeTriangles | +( | +rcContext * | +context, | +
| + | + | const float * | +verts, | +
| + | + | const unsigned char * | +triAreaIDs, | +
| + | + | int | +numTris, | +
| + | + | rcHeightfield & | +heightfield, | +
| + | + | int | +flagMergeThreshold = 1 |
+
| + | ) | ++ |
Rasterizes a triangle list into the specified heightfield.
+Expects each triangle to be specified as three sequential vertices of 3 floats.
+Spans will only be added for triangles that overlap the heightfield grid.
+| [in,out] | context | The build context to use during the operation. |
| [in] | verts | The triangle vertices. [(ax, ay, az, bx, by, bz, cx, by, cx) * nt] |
| [in] | triAreaIDs | The area id's of the triangles. [Limit: <= RC_WALKABLE_AREA] [Size: nt] |
| [in] | numTris | The number of triangles. |
| [in,out] | heightfield | An initialized heightfield. |
| [in] | flagMergeThreshold | The distance where the walkable flag is favored over the non-walkable flag. [Limit: >= 0] [Units: vx] |
| bool rcRasterizeTriangles | +( | +rcContext * | +context, | +
| + | + | const float * | +verts, | +
| + | + | int | +numVerts, | +
| + | + | const int * | +tris, | +
| + | + | const unsigned char * | +triAreaIDs, | +
| + | + | int | +numTris, | +
| + | + | rcHeightfield & | +heightfield, | +
| + | + | int | +flagMergeThreshold = 1 |
+
| + | ) | ++ |
Rasterizes an indexed triangle mesh into the specified heightfield.
+Spans will only be added for triangles that overlap the heightfield grid.
+| [in,out] | context | The build context to use during the operation. |
| [in] | verts | The vertices. [(x, y, z) * nv] |
| [in] | numVerts | The number of vertices. (unused) TODO (graham): Remove in next major release |
| [in] | tris | The triangle indices. [(vertA, vertB, vertC) * nt] |
| [in] | triAreaIDs | The area id's of the triangles. [Limit: <= RC_WALKABLE_AREA] [Size: nt] |
| [in] | numTris | The number of triangles. |
| [in,out] | heightfield | An initialized heightfield. |
| [in] | flagMergeThreshold | The distance where the walkable flag is favored over the non-walkable flag. [Limit: >= 0] [Units: vx] |
| bool rcRasterizeTriangles | +( | +rcContext * | +context, | +
| + | + | const float * | +verts, | +
| + | + | int | +numVerts, | +
| + | + | const unsigned short * | +tris, | +
| + | + | const unsigned char * | +triAreaIDs, | +
| + | + | int | +numTris, | +
| + | + | rcHeightfield & | +heightfield, | +
| + | + | int | +flagMergeThreshold = 1 |
+
| + | ) | ++ |
Rasterizes an indexed triangle mesh into the specified heightfield.
+Spans will only be added for triangles that overlap the heightfield grid.
+| [in,out] | context | The build context to use during the operation. |
| [in] | verts | The vertices. [(x, y, z) * nv] |
| [in] | numVerts | The number of vertices. (unused) TODO (graham): Remove in next major release |
| [in] | tris | The triangle indices. [(vertA, vertB, vertC) * nt] |
| [in] | triAreaIDs | The area id's of the triangles. [Limit: <= RC_WALKABLE_AREA] [Size: nt] |
| [in] | numTris | The number of triangles. |
| [in,out] | heightfield | An initialized heightfield. |
| [in] | flagMergeThreshold | The distance where the walkable flag is favored over the non-walkable flag. [Limit: >= 0] [Units: vx] |
+
|
+ +inline | +
Sets the neighbor connection data for the specified direction.
+| [in] | span | The span to update. |
| [in] | direction | The direction to set. [Limits: 0 <= value < 4] |
| [in] | neighborIndex | The index of the neighbor span. |
This function is used by the build process. It is rarely of use to end users.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
| CBoundsItem | |
| CBuildSettings | |
| CBVItem | |
| CConvexVolume | |
| CCrowdToolParams | |
| CDirtyEntry | |
| CdtBVNode | Bounding volume node |
| CdtCompressedTile | |
| CdtCrowd | Provides local steering behaviors for a group of agents |
| CdtCrowdAgent | Represents an agent managed by a dtCrowd object |
| CdtCrowdAgentAnimation | |
| CdtCrowdAgentDebugInfo | |
| CdtCrowdAgentParams | Configuration parameters for a crowd agent |
| CdtCrowdNeighbour | Provides neighbor data for agents managed by the crowd |
| CdtFixedArray< T > | |
| CdtLayerMonotoneRegion | |
| CdtLayerSweepSpan | |
| CdtLink | Defines a link between polygons |
| CdtLocalBoundary | |
| CdtMeshHeader | Provides high level information related to a dtMeshTile object |
| CdtMeshTile | Defines a navigation mesh tile |
| CdtNavMesh | A navigation mesh based on tiles of convex polygons |
| CdtNavMeshCreateParams | Represents the source data used to build an navigation mesh tile |
| CdtNavMeshParams | Configuration parameters used to define multi-tile navigation meshes |
| CdtNavMeshQuery | Provides the ability to perform pathfinding related queries against a navigation mesh |
| CdtNode | |
| CdtNodePool | |
| CdtNodeQueue | |
| CdtObstacleAvoidanceDebugData | |
| CdtObstacleAvoidanceParams | |
| CdtObstacleAvoidanceQuery | |
| CdtObstacleBox | |
| CdtObstacleCircle | |
| CdtObstacleCylinder | |
| CdtObstacleOrientedBox | |
| CdtObstacleSegment | |
| CdtOffMeshConnection | Defines an navigation mesh off-mesh connection within a dtMeshTile object |
| CdtPathCorridor | Represents a dynamic polygon corridor used to plan agent movement |
| CdtPathQueue | |
| CdtPoly | Defines a polygon within a dtMeshTile object |
| CdtPolyDetail | Defines the location of detail sub-mesh data within a dtMeshTile |
| ►CdtPolyQuery | Provides custom polygon query behavior |
| CdtPolyState | |
| CdtProximityGrid | |
| CdtQueryFilter | Defines polygon filtering and traversal costs for navigation mesh query operations |
| CdtRaycastHit | Provides information about raycast hit filled by dtNavMeshQuery::raycast |
| CdtSegInterval | |
| CdtTempContour | |
| CdtTileCache | |
| ►CdtTileCacheAlloc | |
| ►CdtTileCacheCompressor | |
| CdtTileCacheContour | |
| CdtTileCacheContourSet | |
| CdtTileCacheLayer | |
| CdtTileCacheLayerHeader | |
| ►CdtTileCacheMeshProcess | |
| CdtTileCacheObstacle | |
| CdtTileCacheParams | |
| CdtTileCachePolyMesh | |
| CdtTileState | |
| ►CduDebugDraw | Abstract debug draw interface |
| ►CduFileIO | |
| CGLCheckerTexture | |
| CGraphParams | |
| CGuiState | |
| CimguiGfxCmd | |
| CimguiGfxLine | |
| CimguiGfxRect | |
| CimguiGfxText | |
| CInputGeom | |
| CNavmeshFlags | |
| CNavMeshSetHeader | |
| CNavMeshTileBuildContext | |
| CNavMeshTileHeader | |
| CRasterizationContext | |
| CrcChunkyTriMesh | |
| CrcChunkyTriMeshNode | |
| CrcCompactCell | Provides information on the content of a cell column in a compact heightfield |
| CrcCompactHeightfield | A compact, static heightfield representing unobstructed space |
| CrcCompactSpan | Represents a span of unobstructed space within a compact heightfield |
| CrcConfig | Specifies a configuration to use when performing Recast builds |
| ►CrcContext | Provides an interface for optional logging and performance tracking of the Recast build process |
| CrcContour | Represents a simple, non-overlapping contour in field space |
| CrcContourHole | |
| CrcContourRegion | |
| CrcContourSet | Represents a group of related contours |
| CrcEdge | |
| CrcHeightfield | A dynamic heightfield representing obstructed space |
| CrcHeightfieldLayer | Represents a heightfield layer within a layer set |
| CrcHeightfieldLayerSet | Represents a set of heightfield layers |
| CrcHeightPatch | |
| CrcIntArray | Legacy class. Prefer rcVector<int> |
| CrcLayerRegion | |
| CrcLayerSweepSpan | |
| CrcMeshLoaderObj | |
| CrcNewTag | An implementation of operator new usable for placement new |
| CrcPolyMesh | Represents a polygon mesh suitable for use in building a navigation mesh |
| CrcPolyMeshDetail | Contains triangle meshes that represent detailed height data associated with the polygons in its associated polygon mesh object |
| CrcPotentialDiagonal | |
| CrcRegion | |
| CrcScopedDelete< T > | A simple helper class used to delete an array when it goes out of scope |
| CrcScopedTimer | A helper to first start a timer and then stop it when this helper goes out of scope |
| CrcSpan | Represents a span in a heightfield |
| CrcSpanPool | A memory pool used for quick allocation of spans within a heightfield |
| CrcSweepSpan | |
| ►CrcVectorBase< T, H > | Variable-sized storage type |
| ►CrcVectorBase< T, RC_ALLOC_PERM > | |
| ►CrcVectorBase< T, RC_ALLOC_TEMP > | |
| ►CSample | |
| CSampleItem | |
| ►CSampleTool | |
| ►CSampleToolState | |
| CTestCase | |
| CTileCacheData | |
| CTileCacheSetHeader | |
| CTileCacheTileHeader | |
| CValueHistory |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <cmath>#include <cstdio>#include "imgui.h"#include "SDL.h"#include "SDL_opengl.h"#include "stb_truetype.h"+Macros | |
| #define | STBTT_malloc(x, y) imguimalloc(x,y) |
| #define | STBTT_free(x, y) imguifree(x,y) |
| #define | STB_TRUETYPE_IMPLEMENTATION |
+Functions | |
| void | imguifree (void *ptr, void *userptr) |
| void * | imguimalloc (size_t size, void *userptr) |
| unsigned int | RGBA (unsigned char r, unsigned char g, unsigned char b, unsigned char a) |
| static void | drawPolygon (const float *coords, unsigned numCoords, float r, unsigned int col) |
| static void | drawRect (float x, float y, float w, float h, float fth, unsigned int col) |
| static void | drawRoundedRect (float x, float y, float w, float h, float r, float fth, unsigned int col) |
| static void | drawLine (float x0, float y0, float x1, float y1, float r, float fth, unsigned int col) |
| bool | imguiRenderGLInit (const char *fontpath) |
| void | imguiRenderGLDestroy () |
| static void | getBakedQuad (stbtt_bakedchar *chardata, int pw, int ph, int char_index, float *xpos, float *ypos, stbtt_aligned_quad *q) |
| static float | getTextLength (stbtt_bakedchar *chardata, const char *text) |
| static void | drawText (float x, float y, const char *text, int align, unsigned int col) |
| void | imguiRenderGLDraw () |
+Variables | |
| static const float | PI = 3.14159265f |
| static const unsigned | TEMP_COORD_COUNT = 100 |
| static float | g_tempCoords [TEMP_COORD_COUNT *2] |
| static float | g_tempNormals [TEMP_COORD_COUNT *2] |
| static const int | CIRCLE_VERTS = 8*4 |
| static float | g_circleVerts [CIRCLE_VERTS *2] |
| static stbtt_bakedchar | g_cdata [96] |
| static GLuint | g_ftex = 0 |
| static const float | g_tabStops [4] = {150, 210, 270, 330} |
| #define STB_TRUETYPE_IMPLEMENTATION | +
| #define STBTT_free | +( | ++ | x, | +
| + | + | + | y | +
| + | ) | +imguifree(x,y) | +
| #define STBTT_malloc | +( | ++ | x, | +
| + | + | + | y | +
| + | ) | +imguimalloc(x,y) | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
| void imguifree | +( | +void * | +ptr, | +
| + | + | void * | +userptr | +
| + | ) | ++ |
| void * imguimalloc | +( | +size_t | +size, | +
| + | + | void * | +userptr | +
| + | ) | ++ |
| void imguiRenderGLDestroy | +( | +) | ++ |
| void imguiRenderGLDraw | +( | +) | ++ |
| bool imguiRenderGLInit | +( | +const char * | +fontpath | ) | ++ |
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Functions | |
| bool | imguiRenderGLInit (const char *fontpath) |
| void | imguiRenderGLDestroy () |
| void | imguiRenderGLDraw () |
| void imguiRenderGLDestroy | +( | +) | ++ |
| void imguiRenderGLDraw | +( | +) | ++ |
| bool imguiRenderGLInit | +( | +const char * | +fontpath | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
+Classes | |
| struct | GuiState |
+Functions | |
| static const char * | allocText (const char *text) |
| static void | resetGfxCmdQueue () |
| static void | addGfxCmdScissor (int x, int y, int w, int h) |
| static void | addGfxCmdRect (float x, float y, float w, float h, unsigned int color) |
| static void | addGfxCmdLine (float x0, float y0, float x1, float y1, float r, unsigned int color) |
| static void | addGfxCmdRoundedRect (float x, float y, float w, float h, float r, unsigned int color) |
| static void | addGfxCmdTriangle (int x, int y, int w, int h, int flags, unsigned int color) |
| static void | addGfxCmdText (int x, int y, int align, const char *text, unsigned int color) |
| bool | anyActive () |
| bool | isActive (unsigned int id) |
| bool | isHot (unsigned int id) |
| bool | inRect (int x, int y, int w, int h, bool checkScroll=true) |
| void | clearInput () |
| void | clearActive () |
| void | setActive (unsigned int id) |
| void | setHot (unsigned int id) |
| static bool | buttonLogic (unsigned int id, bool over) |
| static void | updateInput (int mx, int my, unsigned char mbut, int scroll) |
| void | imguiBeginFrame (int mx, int my, unsigned char mbut, int scroll) |
| void | imguiEndFrame () |
| const imguiGfxCmd * | imguiGetRenderQueue () |
| int | imguiGetRenderQueueSize () |
| bool | imguiBeginScrollArea (const char *name, int x, int y, int w, int h, int *scroll) |
| void | imguiEndScrollArea () |
| bool | imguiButton (const char *text, bool enabled) |
| bool | imguiItem (const char *text, bool enabled) |
| bool | imguiCheck (const char *text, bool checked, bool enabled) |
| bool | imguiCollapse (const char *text, const char *subtext, bool checked, bool enabled) |
| void | imguiLabel (const char *text) |
| void | imguiValue (const char *text) |
| bool | imguiSlider (const char *text, float *val, float vmin, float vmax, float vinc, bool enabled) |
| void | imguiIndent () |
| void | imguiUnindent () |
| void | imguiSeparator () |
| void | imguiSeparatorLine () |
| void | imguiDrawText (int x, int y, int align, const char *text, unsigned int color) |
| void | imguiDrawLine (float x0, float y0, float x1, float y1, float r, unsigned int color) |
| void | imguiDrawRect (float x, float y, float w, float h, unsigned int color) |
| void | imguiDrawRoundedRect (float x, float y, float w, float h, float r, unsigned int color) |
+Variables | |
| static const unsigned | TEXT_POOL_SIZE = 50000 |
| static char | g_textPool [TEXT_POOL_SIZE] |
| static unsigned | g_textPoolSize = 0 |
| static const unsigned | GFXCMD_QUEUE_SIZE = 5000 |
| static imguiGfxCmd | g_gfxCmdQueue [GFXCMD_QUEUE_SIZE] |
| static unsigned | g_gfxCmdQueueSize = 0 |
| static GuiState | g_state |
| static const int | BUTTON_HEIGHT = 20 |
| static const int | SLIDER_HEIGHT = 20 |
| static const int | SLIDER_MARKER_WIDTH = 10 |
| static const int | CHECK_SIZE = 8 |
| static const int | DEFAULT_SPACING = 4 |
| static const int | TEXT_HEIGHT = 8 |
| static const int | SCROLL_AREA_PADDING = 6 |
| static const int | INDENT_SIZE = 16 |
| static const int | AREA_HEADER = 28 |
| static int | g_scrollTop = 0 |
| static int | g_scrollBottom = 0 |
| static int | g_scrollRight = 0 |
| static int | g_scrollAreaTop = 0 |
| static int * | g_scrollVal = 0 |
| static int | g_focusTop = 0 |
| static int | g_focusBottom = 0 |
| static unsigned int | g_scrollId = 0 |
| static bool | g_insideScrollArea = false |
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
| void imguiBeginFrame | +( | +int | +mx, | +
| + | + | int | +my, | +
| + | + | unsigned char | +mbut, | +
| + | + | int | +scroll | +
| + | ) | ++ |
| bool imguiBeginScrollArea | +( | +const char * | +name, | +
| + | + | int | +x, | +
| + | + | int | +y, | +
| + | + | int | +w, | +
| + | + | int | +h, | +
| + | + | int * | +scroll | +
| + | ) | ++ |
| bool imguiButton | +( | +const char * | +text, | +
| + | + | bool | +enabled | +
| + | ) | ++ |
| bool imguiCheck | +( | +const char * | +text, | +
| + | + | bool | +checked, | +
| + | + | bool | +enabled | +
| + | ) | ++ |
| bool imguiCollapse | +( | +const char * | +text, | +
| + | + | const char * | +subtext, | +
| + | + | bool | +checked, | +
| + | + | bool | +enabled | +
| + | ) | ++ |
| void imguiDrawLine | +( | +float | +x0, | +
| + | + | float | +y0, | +
| + | + | float | +x1, | +
| + | + | float | +y1, | +
| + | + | float | +r, | +
| + | + | unsigned int | +color | +
| + | ) | ++ |
| void imguiDrawRect | +( | +float | +x, | +
| + | + | float | +y, | +
| + | + | float | +w, | +
| + | + | float | +h, | +
| + | + | unsigned int | +color | +
| + | ) | ++ |
| void imguiDrawRoundedRect | +( | +float | +x, | +
| + | + | float | +y, | +
| + | + | float | +w, | +
| + | + | float | +h, | +
| + | + | float | +r, | +
| + | + | unsigned int | +color | +
| + | ) | ++ |
| void imguiDrawText | +( | +int | +x, | +
| + | + | int | +y, | +
| + | + | int | +align, | +
| + | + | const char * | +text, | +
| + | + | unsigned int | +color | +
| + | ) | ++ |
| void imguiEndFrame | +( | +) | ++ |
| void imguiEndScrollArea | +( | +) | ++ |
| const imguiGfxCmd* imguiGetRenderQueue | +( | +) | ++ |
| int imguiGetRenderQueueSize | +( | +) | ++ |
| void imguiIndent | +( | +) | ++ |
| bool imguiItem | +( | +const char * | +text, | +
| + | + | bool | +enabled | +
| + | ) | ++ |
| void imguiLabel | +( | +const char * | +text | ) | ++ |
| void imguiSeparator | +( | +) | ++ |
| void imguiSeparatorLine | +( | +) | ++ |
| bool imguiSlider | +( | +const char * | +text, | +
| + | + | float * | +val, | +
| + | + | float | +vmin, | +
| + | + | float | +vmax, | +
| + | + | float | +vinc, | +
| + | + | bool | +enabled | +
| + | ) | ++ |
| void imguiUnindent | +( | +) | ++ |
| void imguiValue | +( | +const char * | +text | ) | ++ |
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +inline | +
+
|
+ +inline | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
+
|
+ +static | +
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
Go to the source code of this file.
++Classes | |
| struct | imguiGfxRect |
| struct | imguiGfxText |
| struct | imguiGfxLine |
| struct | imguiGfxCmd |
+Enumerations | |
| enum | imguiMouseButton { IMGUI_MBUT_LEFT = 0x01 +, IMGUI_MBUT_RIGHT = 0x02 + } |
| enum | imguiTextAlign { IMGUI_ALIGN_LEFT +, IMGUI_ALIGN_CENTER +, IMGUI_ALIGN_RIGHT + } |
| enum | imguiGfxCmdType { + IMGUI_GFXCMD_RECT +, IMGUI_GFXCMD_TRIANGLE +, IMGUI_GFXCMD_LINE +, IMGUI_GFXCMD_TEXT +, + IMGUI_GFXCMD_SCISSOR + + } |
+Functions | |
| unsigned int | imguiRGBA (unsigned char r, unsigned char g, unsigned char b, unsigned char a=255) |
| void | imguiBeginFrame (int mx, int my, unsigned char mbut, int scroll) |
| void | imguiEndFrame () |
| bool | imguiBeginScrollArea (const char *name, int x, int y, int w, int h, int *scroll) |
| void | imguiEndScrollArea () |
| void | imguiIndent () |
| void | imguiUnindent () |
| void | imguiSeparator () |
| void | imguiSeparatorLine () |
| bool | imguiButton (const char *text, bool enabled=true) |
| bool | imguiItem (const char *text, bool enabled=true) |
| bool | imguiCheck (const char *text, bool checked, bool enabled=true) |
| bool | imguiCollapse (const char *text, const char *subtext, bool checked, bool enabled=true) |
| void | imguiLabel (const char *text) |
| void | imguiValue (const char *text) |
| bool | imguiSlider (const char *text, float *val, float vmin, float vmax, float vinc, bool enabled=true) |
| void | imguiDrawText (int x, int y, int align, const char *text, unsigned int color) |
| void | imguiDrawLine (float x0, float y0, float x1, float y1, float r, unsigned int color) |
| void | imguiDrawRoundedRect (float x, float y, float w, float h, float r, unsigned int color) |
| void | imguiDrawRect (float x, float y, float w, float h, unsigned int color) |
| const imguiGfxCmd * | imguiGetRenderQueue () |
| int | imguiGetRenderQueueSize () |
| enum imguiGfxCmdType | +
| enum imguiMouseButton | +
| enum imguiTextAlign | +
| void imguiBeginFrame | +( | +int | +mx, | +
| + | + | int | +my, | +
| + | + | unsigned char | +mbut, | +
| + | + | int | +scroll | +
| + | ) | ++ |
| bool imguiBeginScrollArea | +( | +const char * | +name, | +
| + | + | int | +x, | +
| + | + | int | +y, | +
| + | + | int | +w, | +
| + | + | int | +h, | +
| + | + | int * | +scroll | +
| + | ) | ++ |
| bool imguiButton | +( | +const char * | +text, | +
| + | + | bool | +enabled = true |
+
| + | ) | ++ |
| bool imguiCheck | +( | +const char * | +text, | +
| + | + | bool | +checked, | +
| + | + | bool | +enabled = true |
+
| + | ) | ++ |
| bool imguiCollapse | +( | +const char * | +text, | +
| + | + | const char * | +subtext, | +
| + | + | bool | +checked, | +
| + | + | bool | +enabled = true |
+
| + | ) | ++ |
| void imguiDrawLine | +( | +float | +x0, | +
| + | + | float | +y0, | +
| + | + | float | +x1, | +
| + | + | float | +y1, | +
| + | + | float | +r, | +
| + | + | unsigned int | +color | +
| + | ) | ++ |
| void imguiDrawRect | +( | +float | +x, | +
| + | + | float | +y, | +
| + | + | float | +w, | +
| + | + | float | +h, | +
| + | + | unsigned int | +color | +
| + | ) | ++ |
| void imguiDrawRoundedRect | +( | +float | +x, | +
| + | + | float | +y, | +
| + | + | float | +w, | +
| + | + | float | +h, | +
| + | + | float | +r, | +
| + | + | unsigned int | +color | +
| + | ) | ++ |
| void imguiDrawText | +( | +int | +x, | +
| + | + | int | +y, | +
| + | + | int | +align, | +
| + | + | const char * | +text, | +
| + | + | unsigned int | +color | +
| + | ) | ++ |
| void imguiEndFrame | +( | +) | ++ |
| void imguiEndScrollArea | +( | +) | ++ |
| const imguiGfxCmd* imguiGetRenderQueue | +( | +) | ++ |
| int imguiGetRenderQueueSize | +( | +) | ++ |
| void imguiIndent | +( | +) | ++ |
| bool imguiItem | +( | +const char * | +text, | +
| + | + | bool | +enabled = true |
+
| + | ) | ++ |
| void imguiLabel | +( | +const char * | +text | ) | ++ |
+
|
+ +inline | +
| void imguiSeparator | +( | +) | ++ |
| void imguiSeparatorLine | +( | +) | ++ |
| bool imguiSlider | +( | +const char * | +text, | +
| + | + | float * | +val, | +
| + | + | float | +vmin, | +
| + | + | float | +vmax, | +
| + | + | float | +vinc, | +
| + | + | bool | +enabled = true |
+
| + | ) | ++ |
| void imguiUnindent | +( | +) | ++ |
| void imguiValue | +( | +const char * | +text | ) | ++ |
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+

Recast is state of the art navigation mesh construction toolset for games.
+Recast is...
Recast constructs a navmesh through a multi-step rasterization process:
+Recast is accompanied by Detour, a path-finding and spatial reasoning toolkit. You can use any navigation mesh with Detour, but of course the data generated with Recast fits perfectly.
+Detour offers a simple static navmesh data representation which is suitable for many simple cases. It also provides a tiled navigation mesh representation, which allows you to stream of navigation data in and out as the player progresses through the world and regenerate sections of the navmesh data as the world changes.
+You can find a comprehensive demo project in the RecastDemo folder. It's a kitchen sink demo showcasing all the functionality of the library. If you are new to Recast & Detour, check out Sample_SoloMesh.cpp to get started with building navmeshes and NavMeshTesterTool.cpp to see how Detour can be used to find paths.
RecastDemo uses premake5 to build platform specific projects. Download it and make sure it's available on your path, or specify the path to it.
+RecastDemo folder and run premake5 gmake2RecastDemo/Build/gmake2 and run makeRecastDemo/Bin and run ./RecastDemoSDL2.framework in RecastDemo/BinRecastDemo folder and run premake5 xcode4Build/xcode4/recastnavigation.xcworkspaceRecastDemo\Contrib. Rename the SDL folder such that the path RecastDemo\Contrib\SDL\lib\x86 is valid.RecastDemo folder and run premake5 vs2022Build/vs2022/recastnavigation.sln.RecastDemo as the startup project, build, and run.RecastDemo/Bin/It is recommended to add the source directories DebugUtils, Detour, DetourCrowd, DetourTileCache, and Recast into your own project depending on which parts of the project you need. For example your level building tool could include DebugUtils, Recast, and Detour, and your game runtime could just include Detour.
If you are using the vcpkg dependency manager you can download and install Recast with:
+Check out the Project Roadmap to see what features and functionality you might be able to help with, and the Contributing doc for guidance on making contributions.
+Recast & Detour is licensed under ZLib license, see License.txt for more information.
+|
+ Recast Navigation
+
+ Navigation-mesh Toolset for Games
+ |
+
#include <cstdio>#include <cmath>#include "SDL.h"#include "SDL_opengl.h"#include <GL/glu.h>#include <vector>#include <string>#include "imgui.h"#include "imguiRenderGL.h"#include "Recast.h"#include "RecastDebugDraw.h"#include "InputGeom.h"#include "TestCase.h"#include "Filelist.h"#include "Sample_SoloMesh.h"#include "Sample_TileMesh.h"#include "Sample_TempObstacles.h"#include "Sample_Debug.h"+Classes | |
| struct | SampleItem |
+Functions | |
| Sample * | createSolo () |
| Sample * | createTile () |
| Sample * | createTempObstacle () |
| Sample * | createDebug () |
| int | main (int, char **) |
+Variables | |
| static SampleItem | g_samples [] |
| static const int | g_nsamples = sizeof(g_samples) / sizeof(SampleItem) |
| Sample* createDebug | +( | +) | ++ |
| Sample* createSolo | +( | +) | ++ |
| Sample* createTempObstacle | +( | +) | ++ |
| Sample* createTile | +( | +) | ++ |
| int main | +( | +int | +, | +
| + | + | char ** | ++ |
| + | ) | ++ |
+
|
+ +static | +
+
|
+ +static | +