Jump to content
  • Advertisement
Sign in to follow this  
Nick T

ZIP Resource Management Question

This topic is 2783 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have a question regarding resource management with zip files and C++. Currently I am using a ZLib derived zip compression/decompression library. I am using it as the base for the resource management code in my own engine. So far everything has gone fairly smoothly. However, I am stuck in regards to how and when to call the decompression functions. I am implementing clip-mapping, meaning that the terrain textures will be somewhat large in size. So loading everything at run time would just be too costly. But at the same time, making a new call to open the zip file every time a block of resources is needed sounds like it'd be equally as costly. I do realize that a 3D game now is going to be costly regardless, it is the nature of the beast now-days. But I'd like to make it efficient as possible, considering I am going to have to be streaming a lot of data (clip-maps and some other stuff).

I thought about developing a "Required Resource Table" where a file stores the needed information for a level (a BSP map). The resource manager would load all of the data from the table when the level/world loads. It would still require loading the zip files, but any data not needed could be unloaded after the world load process. Although that is fine for static resources, it leaves much to be desired for streaming content.

For content that requires streaming, although it may increase file count (not something I am worried about at this moment in time), having the textures which will be clip-mapped as ZLib compressed single files may be the ticket.

Any thoughts and advice on this would be greatly appreciated.

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!