InvokeHelper.h 1.0 KB

12345678910111213141516171819202122232425262728293031323334
  1. #ifndef INVOKE_HELPER_H
  2. #define INVOKE_HELPER_H
  3. #if !RECASTNAVIGATION_STATIC && WIN32
  4. #define RECAST_DLL _declspec(dllexport)
  5. #else
  6. #define RECAST_DLL
  7. #endif
  8. #include "DetourNavMesh.h"
  9. #include <cstdint>
  10. #include <string>
  11. #include <map>
  12. #ifdef __cplusplus
  13. extern "C" {
  14. #endif
  15. class NavMeshContex;
  16. RECAST_DLL NavMeshContex* RecastLoad(const char* buffer, int32_t n);
  17. RECAST_DLL void RecastClear(NavMeshContex* navMeshContex);
  18. RECAST_DLL int32_t RecastFind(NavMeshContex* navMeshContex, float* extents, float* startPos, float* endPos, float* straightPath);
  19. RECAST_DLL int32_t RecastFindNearestPoint(NavMeshContex* navMeshContex, float* extents, float* pos, float* nearestPos);
  20. RECAST_DLL int32_t RecastFindRandomPoint(NavMeshContex* navMeshContex, float* pos);
  21. RECAST_DLL int32_t RecastFindRandomPointAroundCircle(NavMeshContex* navMeshContex, float* extents, const float* centerPos, const float maxRadius, float* pos);
  22. #ifdef __cplusplus
  23. }
  24. #endif
  25. int32_t InitNav(const char* buffer, int32_t n, dtNavMesh*& navMesh);
  26. #endif