Mail Archives: djgpp/1997/09/15/09:32:11
In article <E6di6cCZz$G0EwLo AT talula DOT demon DOT co DOT uk>, Shawn AT talula DOT demon DOT co DOT uk
says...
>
>Herman Schoenfeld writes:
>>Well, allegro allocates memory for lots of things (bitmaps, objects, etc)
these
>>
>>4meg
>>----------------------------------------
>> A | B | C | D |
>>----------------------------------------
>>
>>Say all these objects take 1 meg, free B and D, and try allocating 2 meg. You
>>can't.
>
>Yes you can, if you are working in protected mode...
>
>Sure, fragmentation can occasionally be a problem, but I don't think it
>is something that Allegro should be concerned with. If you need custom
>memory management routines you are very welcome to write some, but the
>standard library routines are perfectly good enough for most situations.
>The only 100% sure way to prevent fragmentation is to use a handle based
>system with movable blocks, which would incur way too much overhead for
>something like Allegro...
Well, for starters it doesn't take much overhead at all (I think I might show
you some working code sometime) and secondly, all games have custom memory
handlers. Thirdly, it has caused problems for me (ie, I load an 2-4 FLI's as a
textures and I get problems).
>
>
>--
>Shawn Hargreaves - shawn AT talula DOT demon DOT co DOT uk - http://www.talula.demon.co.uk/
>Beauty is a French phonetic corruption of a short cloth neck ornament.
- Raw text -