It is currently 16 Apr 2024, 19:29
   
Text Size

BA keeps all pictures on memory and crashes

Moderators: FranAvalon, Marek14, CCGHQ Admins

BA keeps all pictures on memory and crashes

Postby Jean le Chauve » 17 Nov 2012, 17:26

Rheikon reported on Slightlymagic:
If you look at lots of pictures BA keeps them all in memory eventually crashing when running out. On occasion it will simply stop showing pictures.

I've tested it and that is right and happens on deckbuilder when you see between 2500 and 3000 cards, ay least on my PC. I never got it playing games.

BA must be picture memory cache limited to for example 500 card or so.

marek14:
That would probably explain some of my crashes, given that I'm prone to play with big testing decks containing lots of cards.

void:
As a matter of fact such a mechanism is already implemented.
CGdiplus::FlushBitmaps() is called (no more often then 10s between calls) then there are more then 256 pictures stored.
At least that's what I can see in the code.

The mechanism is so advanced that it takes into account hit ratio.

FranAvalon:
To me BA crashes when it hits a size of 1.3 Gb more or less.

If i load all card images from letter A, it get a size of 614 Mb, and after wait a couple of minutes, it down to 469 Mb, and no more changes happen on next 5 min.

MORE TEST:
If you exit from deckbuilder, size doesn't down, but if you start a game, and then you finnish it, BA size goes to 98Mb more or less. So end game has a rutine to clear card picture cache.

void:
Jul 17, 2011, 5:24pm, FranAvalon wrote:

If you exit from deckbuilder, size doesn't down, but if you start a game, and then you finnish it, BA size goes to 98Mb more or less. So end game has a rutine to clear card picture cache.
The routine is CGdiplus::ClearBitmapCache

The logic and functionality is there, but some bug has slipped into it.
Jean le Chauve
 
Posts: 56
Joined: 30 Jan 2012, 10:28
Has thanked: 1 time
Been thanked: 1 time

Return to User Interface and AI issues

Who is online

Users browsing this forum: No registered users and 9 guests


Who is online

In total there are 9 users online :: 0 registered, 0 hidden and 9 guests (based on users active over the past 10 minutes)
Most users ever online was 4143 on 23 Jan 2024, 08:21

Users browsing this forum: No registered users and 9 guests

Login Form