Fix cleanup issue

move
scrawl 9 years ago
parent d3808580b0
commit 6bfeb118d7

@ -169,6 +169,13 @@ namespace MWWorld
{
}
CellPreloader::~CellPreloader()
{
for (PreloadMap::iterator it = mPreloadCells.begin(); it != mPreloadCells.end();++it)
it->second.mWorkItem->waitTillDone();
mPreloadCells.clear();
}
void CellPreloader::preload(CellStore *cell, double timestamp)
{
if (!mWorkQueue)

@ -24,6 +24,7 @@ namespace MWWorld
{
public:
CellPreloader(Resource::ResourceSystem* resourceSystem, Resource::BulletShapeManager* bulletShapeManager, Terrain::World* terrain);
~CellPreloader();
/// Ask a background thread to preload rendering meshes and collision shapes for objects in this cell.
/// @note The cell itself must be in State_Loaded or State_Preloaded.

Loading…
Cancel
Save