/* * Reimport * Reloads the model data (such as the size of it) */ void CAbstractStreaming::Reimport(ModelFile& file, bool bLock) { if(bLock) { // Lock just to be sure we're not in concurrency with the streaming thread scoped_lock xlock(this->cs); // Reprocess the file data file.ProcessFileData(); } else { file.ProcessFileData(); } }
/* * Reimport * Imports a new model into @index */ void CAbstractStreaming::Reimport(ModelFile& file, int index) { scoped_lock xlock(this->cs); auto it = this->imports.find(index); if(it != this->imports.end()) it->second = file; else this->imports.emplace(index, file); file.ProcessFileData(); }