| 626 | } |
| 627 | |
| 628 | void GPUTexture::OnReleaseGPU() |
| 629 | { |
| 630 | #if COMPILE_WITH_PROFILER |
| 631 | auto group = ProfilerMemory::Groups::GraphicsTextures; |
| 632 | if (_desc.IsRenderTarget()) |
| 633 | group = ProfilerMemory::Groups::GraphicsRenderTargets; |
| 634 | else if (_desc.IsCubeMap()) |
| 635 | group = ProfilerMemory::Groups::GraphicsCubeMaps; |
| 636 | else if (_desc.IsVolume()) |
| 637 | group = ProfilerMemory::Groups::GraphicsVolumeTextures; |
| 638 | ProfilerMemory::DecrementGroup(group, _memoryUsage); |
| 639 | #endif |
| 640 | |
| 641 | _desc.Clear(); |
| 642 | _residentMipLevels = 0; |
| 643 | } |
| 644 | |
| 645 | GPUTask* GPUTexture::UploadMipMapAsync(const BytesContainer& data, int32 mipIndex, bool copyData) |
| 646 | { |