mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-04-10 03:18:55 +02:00
Again
This commit is contained in:
parent
67ba7301f8
commit
005e9b9693
1 changed files with 2 additions and 6 deletions
|
|
@ -133,11 +133,7 @@ void TextureCache<P>::RunGarbageCollector() {
|
||||||
if (True(image.flags & ImageFlagBits::IsDecoding)) {
|
if (True(image.flags & ImageFlagBits::IsDecoding)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
const bool must_download = image.IsSafeDownload() && False(image.flags & ImageFlagBits::BadOverlap);
|
if (image.IsSafeDownload() && False(image.flags & ImageFlagBits::BadOverlap)) {
|
||||||
if (!high_priority_mode && must_download) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
if (must_download) {
|
|
||||||
auto map = runtime.DownloadStagingBuffer(image.unswizzled_size_bytes);
|
auto map = runtime.DownloadStagingBuffer(image.unswizzled_size_bytes);
|
||||||
const auto copies = FixSmallVectorADL(FullDownloadCopies(image.info));
|
const auto copies = FixSmallVectorADL(FullDownloadCopies(image.info));
|
||||||
image.DownloadMemory(map, copies);
|
image.DownloadMemory(map, copies);
|
||||||
|
|
@ -148,7 +144,7 @@ void TextureCache<P>::RunGarbageCollector() {
|
||||||
UntrackImage(image, image_id);
|
UntrackImage(image, image_id);
|
||||||
}
|
}
|
||||||
UnregisterImage(image_id);
|
UnregisterImage(image_id);
|
||||||
DeleteImage(image_id, image.scale_tick > frame_tick + 5);
|
DeleteImage(image_id, image.scale_tick > frame_tick + 5 || aggressive_mode);
|
||||||
if (aggressive_mode && total_used_memory < critical_memory) {
|
if (aggressive_mode && total_used_memory < critical_memory) {
|
||||||
num_iterations >>= 2;
|
num_iterations >>= 2;
|
||||||
aggressive_mode = false;
|
aggressive_mode = false;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue