| 319 | _cache = nullptr; |
| 320 | } |
| 321 | _levelLoaded = _nMipmaps; |
| 322 | } |
| 323 | |
| 324 | void 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(); |