MCPcopy Create free account
hub / github.com/BohemiaInteractive/CWR / CacheUse

Method CacheUse

engine/PoseidonGL33/TextureGL33_Loading.cpp:321–336  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

319 _cache = nullptr;
320 }
321 _levelLoaded = _nMipmaps;
322}
323
324void TextureGL33::ReleaseMemory(bool store)
325{
326 TextBankGL33* bank = static_cast<TextBankGL33*>(GEngine->TextBank());
327 if (_surface.GetTexture())
328 {
329 if (store)
330 {
331 bank->AddReleased(_surface);
332 }
333 else
334 {
335 bank->_totalAllocated -= _surface.SizeUsed();
336 bank->_thisFrameAlloc++;
337 }
338 _surface.Free(!store);
339 MemoryReleased();

Callers 1

UseMipmapMethod · 0.80

Calls 2

DeleteMethod · 0.45
InsertMethod · 0.45

Tested by

no test coverage detected