From: Jesus M. <fo...@gm...> - 2010-07-02 22:29:27
|
Hi david (and all)! Thank you. I want to write code that can read a campaign file for tuxhistory. This file should be a compressed file that contains map files, lua scripts, etc... Mainly I need a transparent access to this files (I don't need inflate the files in a directory) to load the content in to memory. I was searching, but cant find any good resource to do that with zlib. I found a very good article [1], but it only shows a transparent access for one compressed file using zlib. The same text illustrates a good way to access multiple files using zzip[2]. Even though the library seems to be written in ANSI-C some comments specifics multiplaform/cross compiling problems. Any idea to deal this issue? [1] http://www.kekkai.org/roger/sdl/rwops/rwops.html [2] http://zziplib.sourceforge.net/ 2010/6/30 David Bruce <dav...@gm...>: > Hi, > > On Wed, Jun 30, 2010 at 11:40 AM, Jesus Mager <fo...@gm...> wrote: >> Hi all! >> >> I'm trying to find a good way to compress and inflate the campaing >> files that should contain things like XML files, and in the future LUA >> and other text files. I was thinking zlib is a good option > > I take it you want to save space on the user's HD? Obviously, our > tarballs and installer files are already compressed. > > Anyway, zlib is definitely cross-platform and is already part of our > dependencies (IIRC, SDL_image depends on zlib). Thus, if it does what > needs to be done, you can use it without worrying about having to drag > in additional libs. If that is what you do, we should add a test in > configure.ac to directly test for it, just so we still know that it is > available even if a future version of SDL_image no longer uses it. > > Cheers, > > David > -- Jesus Mager [www.h1n1-al.blogspot.com] |