2021-06-29 01:49:21 +00:00
|
|
|
#ifndef OPENMW_COMPONENTS_DETOURNAVIGATOR_RECASTMESHPROVIDER_H
|
|
|
|
#define OPENMW_COMPONENTS_DETOURNAVIGATOR_RECASTMESHPROVIDER_H
|
|
|
|
|
|
|
|
#include "recastmesh.hpp"
|
|
|
|
#include "tilecachedrecastmeshmanager.hpp"
|
|
|
|
#include "tileposition.hpp"
|
|
|
|
|
|
|
|
#include <functional>
|
|
|
|
#include <memory>
|
|
|
|
|
|
|
|
namespace DetourNavigator
|
|
|
|
{
|
|
|
|
class RecastMesh;
|
|
|
|
|
|
|
|
class RecastMeshProvider
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
RecastMeshProvider(TileCachedRecastMeshManager& impl)
|
|
|
|
: mImpl(impl)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2024-05-19 12:26:28 +00:00
|
|
|
std::shared_ptr<RecastMesh> getMesh(ESM::RefId worldspace, const TilePosition& tilePosition) const
|
2021-06-29 01:49:21 +00:00
|
|
|
{
|
2021-07-09 20:51:42 +00:00
|
|
|
return mImpl.get().getNewMesh(worldspace, tilePosition);
|
2021-06-29 01:49:21 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
private:
|
|
|
|
std::reference_wrapper<TileCachedRecastMeshManager> mImpl;
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|