[This is preliminary documentation and is subject to change.]

Extracts the tile data from a serialized navigation mesh.

Namespace: org.critterai.nav
Assembly: cai-nav (in cai-nav.dll) Version: 0.4.0.0 (0.4.0.0)

Syntax

         
 C#  Visual Basic  Visual C++ 
public static NavStatus ExtractTileData(
	byte[] serializedMesh,
	out NavmeshTileExtract[] tileData,
	out NavmeshParams config
)
Public Shared Function ExtractTileData ( _
	serializedMesh As Byte(), _
	<OutAttribute> ByRef tileData As NavmeshTileExtract(), _
	<OutAttribute> ByRef config As NavmeshParams _
) As NavStatus
public:
static NavStatus ExtractTileData(
	array<unsigned char>^ serializedMesh, 
	[OutAttribute] array<NavmeshTileExtract>^% tileData, 
	[OutAttribute] NavmeshParams^% config
)

Parameters

serializedMesh
array<Byte>[]()[][]
A valid serialized navigation mesh.
tileData
array<NavmeshTileExtract>[]()[][]%
The extracted tile data. [Length: GetMaxTiles()()()()]
config
NavmeshParams%
The navigation mesh's configuration.

Return Value

The NavStatus flags for the operation.

Remarks

Tile data is normally preserved by serializing the the content of the NavmeshTileData objects used to create the navigation mesh. That is the most efficient method and should be used whenever possible.

This method can be used to extract the tile data when the original data is not available. It should only be used as a backup to the normal method since this method is not efficient.

Always check the header polygon count of the resulting NavmeshTileExtract objects before use since some tiles in the navigation mesh may be empty. The data field will be null for empty tiles.

See Also