PathEngine home previous: iMesh::saveUnobstructedSpaceFor()next: iMesh::shapeCanCollide()
Contents, API Reference, Interfaces, iMesh, setTerrainCallBack

iMesh::setTerrainCallBack()

Description

Supplies a callback object to be used by PathEngine for looking up height detail at points in the specified terrain layer on this mesh.

Syntax

void setTerrainCallBack(int32_t terrainLayer, iTerrainCallBack* callBack);

Parameters

terrainLayer The terrain layer for which this callback should be used.
callBack The callback object. This pointer must remain valid for the lifetime of this mesh.

Remarks

Terrain callbacks must be set before any preprocess generation is performed on a mesh.

The terrain layer index passed in must be in the range terrainLayer >= 0 && terrainLayer < numberOfSectionsPresentInMesh, (where numberOfSectionsPresentInMesh can be determined by calling iMesh::getNumberOfSections()).

See Working with Terrain for details about the terrain callback mechanism.

C# Mapping

void setTerrainCallBack(int terrainLayer, TerrainCallBack callBack);

Java Mapping

void setTerrainCallBack(int terrainLayer, TerrainCallBack callBack);

Documentation for PathEngine release 6.04 - Copyright © 2002-2024 PathEnginenext: iMesh::shapeCanCollide()