[Freeciv-Dev] (PR#39574) BUG: trying to load graphics in too many places

2007-08-16 Thread William Allen Simpson

URL: http://bugs.freeciv.org/Ticket/Display.html?id=39574 

Reported in the past (for example, PR#39397), the client tries to load
graphics for a never displayed None -- or as the older bug(s)
improperly displayed, Nichts (fixed by PR#39389).

The iterator at client/tilespec.c tilespec_reread() is now smart enough
to start at A_FIRST. (PR#39525)

But the client/packhand.c handle_ruleset_tech() also tries to load the
graphic.  Why are the graphics loaded in multiple places?

Moreover, this seems a symptom of a larger problem.  It would be far
more efficient to only load graphics as the set changes, rather than
piecemeal as individual packets arrive.



___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


Re: [Freeciv-Dev] (PR#39574) BUG: trying to load graphics in too many places

2007-08-16 Thread Marko Lindqvist

URL: http://bugs.freeciv.org/Ticket/Display.html?id=39574 

On 16/08/07, William Allen Simpson [EMAIL PROTECTED] wrote:

 Moreover, this seems a symptom of a larger problem.  It would be far
 more efficient to only load graphics as the set changes, rather than
 piecemeal as individual packets arrive.

 I fixed some memory management problems in this some months ago, and
if I remember correctly (can't check code now):
 When tileset changes, it *is* loaded in one place.
 However, initial tileset (after ruleset change) is loaded piece by
piece as information about what graphics are actually needed. becomes
available. Still, it should be possible to load tileset only after we
know all the required tags (or is there some problme I can't remember.
I looked that a bit, but for some reason did nothing. Should check if
I created some ticket related to this at the time)


 - ML



___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev