2020-12-28 21:11:58 +04:00
|
|
|
#ifndef OPENMW_MWRENDER_LANDMANAGER_H
|
|
|
|
#define OPENMW_MWRENDER_LANDMANAGER_H
|
2017-03-06 19:04:17 +01:00
|
|
|
|
|
|
|
#include <osg/Object>
|
|
|
|
|
|
|
|
#include <components/resource/resourcemanager.hpp>
|
|
|
|
#include <components/esmterrain/storage.hpp>
|
|
|
|
|
|
|
|
namespace ESM
|
|
|
|
{
|
|
|
|
struct Land;
|
|
|
|
}
|
|
|
|
|
|
|
|
namespace MWRender
|
|
|
|
{
|
|
|
|
|
2019-03-13 11:15:58 +04:00
|
|
|
class LandManager : public Resource::GenericResourceManager<std::pair<int, int> >
|
2017-03-06 19:04:17 +01:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
LandManager(int loadFlags);
|
|
|
|
|
2018-10-09 10:21:12 +04:00
|
|
|
/// @note Will return nullptr if not found.
|
2017-03-06 19:04:17 +01:00
|
|
|
osg::ref_ptr<ESMTerrain::LandObject> getLand(int x, int y);
|
|
|
|
|
2020-10-16 22:18:54 +04:00
|
|
|
void reportStats(unsigned int frameNumber, osg::Stats* stats) const override;
|
2017-03-06 19:04:17 +01:00
|
|
|
|
|
|
|
private:
|
|
|
|
int mLoadFlags;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|