| PathEngine home | previous: | next: |
Objects derived from this interface are passed in to
This interface is defined in SDKRoot/include/i_pathengine.h.
PathEngine calls back to this method for application-side validation of drop type connection candidates. | ||
PathEngine calls back to this method for application-side validation of jump type connection candidates. |
Jump type connections are generated between pairs of endpoints at the mesh edge.
Drop type connections are generated where one piece of ground mesh overhangs another.
The call-back methods return two penalty values, corresponding to the two possible directions for off-mesh connection
between the given endpoints.
Pass -1 for a penalty to indicate that it is not possible to move 'off mesh' between the given endpoints,
otherwise an off-mesh connection will be created with the given penalty value.
The following code snippet shows how a 'null' connection test call-back can be implemented.
This simply permits all connection candidates.
This can be useful for debugging, as it can help with visualising the set of candidate connections generated by the auto connection generation framework.
class cNullConnectionTestCallBack : public iConnectionTestCallBack
{
public:
void
testJumpCandidatePair(const tSigned32* fromPoint3D, const tSigned32* toPoint3D, tSigned32& penaltyOut, tSigned32& penaltyBack)
{
penaltyOut = 0;
penaltyBack = 0;
}
void
testDropCandidatePair(const tSigned32* fromPoint3D, const tSigned32* toPoint3D, tSigned32& penaltyOut, tSigned32& penaltyBack)
{
penaltyOut = 0;
penaltyBack = 0;
}
};
|
| Documentation for PathEngine release 5.17 - Copyright © 2002-2008 PathEngine | next: |