1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-04 02:41:19 +00:00
OpenMW/components/detournavigator/recastmeshprovider.hpp
florent.teppe 150e2ba885 Revert "Use ESM::RefId for worldspace in detournavigator"
This reverts commit b4ab153418.

# Conflicts:
#	apps/navmeshtool/worldspacedata.cpp
2023-01-21 18:39:57 +01:00

34 lines
773 B
C++

#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)
{
}
std::shared_ptr<RecastMesh> getMesh(std::string_view worldspace, const TilePosition& tilePosition) const
{
return mImpl.get().getNewMesh(worldspace, tilePosition);
}
private:
std::reference_wrapper<TileCachedRecastMeshManager> mImpl;
};
}
#endif