Re: [AD] loading pcx from memory

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


soja@xxxxxxxxxx wrote:

No, but we decided to go with our own animation file format, where the
animation frames are stored as a pcx file inside the animation file.


Then, you could write your own decompressor.


Otherwise loading pcx from memory can be usefull for example while reciving
it over a network.


True.




Plus, you made the original load_pcx() use 2x the memory!

Yes, roughly, on the other side I belive that it is faster because the hole
file is loaded at once.


Not quite. The packfile routines are buffered, so the speed gain will be marginal, if there is any.


 The reason why I changed load_pcx() was that i dislike duplicant code.


Agreed. But I think it would have been better to update the pack_* routines. That way, any file can be loaded from memory, or from disk, with virtually no changes to the code.



--
- Robert J Ohannessian
"Microsoft code is probably O(n^20)" (my CS prof)
http://pages.infinit.net/voidstar/



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/