PathEngine home previous: iMesh::positionFor3DPoint()next: iMesh::positionForPointIn3DFace()
Contents, API Reference, Interfaces, iMesh, positionFor3DPoint_ExcludeTerrain

iMesh::positionFor3DPoint_ExcludeTerrain()

Description

Used for resolving anchor positions in the case where the anchor should not resolve to 'terrain stand-in' geometry.

Syntax

cPosition positionFor3DPoint_ExcludeTerrain(int32_t x, int32_t y, int32_t z, int32_t numberOfTerrainLayers) const;

Parameters

x X coordinate of the 3D query point.
y Y coordinate of the 3D query point.
z Z coordinate (height) of the 3D query point.
numberOfTerrainLayers Specifies the number of sectionID values that should be excluded from the query.

Return Value

A cPosition representing a point on the mesh directly underneath the specified 3D point.
If there is no such position then an explicitly invalid position is returned (i.e. a cPosition with cell set to -1).

Remarks

The x and y coordinates must be within the PathEngine horizontal coordinate range limit.

Behaves exactly the same as iMesh::positionFor3DPoint() except that faces with certain values for the sectionID face attribute are excluded from the query.

Reserved values for sectionID start at zero, so passing 1 into numberOfTerrainLayers excludes faces where sectionID == 0, passing 2 into numberOfTerrainLayers excludes faces where sectionID == 0 || sectionID == 1, and so on.

Once terrain callbacks have been supplied by the client application position resolution methods will transparently resolve positions to both terrain and non-terrain parts of a mesh.
So, in most cases it's not necessary to use this method.
This method is designed specifically for use at content time, in cases where access to terrain detail may not be available.

C# Mapping

PathEngine.Position positionFor3DPoint_ExcludeTerrain(int x, int y, int z, int numberOfTerrainLayers);

Java Mapping

Position positionFor3DPoint_ExcludeTerrain(int x, int y, int z, int numberOfTerrainLayers);

Documentation for PathEngine release 6.00 - Copyright © 2002-2016 PathEnginenext: iMesh::positionForPointIn3DFace()