This issue tracker is now in read-only mode. We migrated all our old bug reports to our bitbucket issue tracker
Please use our new issue tracker to report bugs. You can easily find all mantis tickets on our new issue tracker by selecting the appropriate bitbucket repo (CEGUI/CEED/Silly) and searching for the mantis ticket ID number.

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000345CEGUICore library (CEGUIBase)public2010-03-19 19:322010-03-26 14:12
Assigned ToCrazyEddie 
PlatformOSOS Version
Product Version0.6.2 
Target VersionFixed in VersionMercurial: default branch 
Summary0000345: A zip-archive based ResourceProvider for CEGUI
DescriptionI eventually got around to writing a zip-archive based resource provider for CEGUI. I originally mentioned this in 'The Development of CEGUI 0.7.x' thread and there seemed to be a little interest in this, so I figured I would add this to mantis to see if it can be added into the library. As initially hinted at I decided to use zlib, along with the minizip contribution accompanying zlib, since these use MIT style licenses.

I wanted a resource provider that could provide the same functionality as the default resource provider, with the additional capability to load resources from an archive. By providing backwards compatability with the default resource provider, users can easily test new resources without having to recompile the archive. In addition, the new resource provider can be dropped into an existing project (that uses the default resource provider) without any noticable difference in functionality. The user can also turn off loading of local resources, so that only resources from the archive can be loaded.

I only tested this class with v0.6.2. But looking at the default resource provider for v0.7, I see no reason why it would not also work with v0.7.
Additional InformationThis actually only required a very small portion of code. Probably less than 15 or so lines of glue code. The remaining 200 lines in the header/source being mostly fluff.

It appears that zlib is already included in the CEGUI v0.7 dependency package. The minzip dependencies would need to be added to the project. Minizip is included in the zlib distribution and can be located at zlib/contrib/minizip. Creating a minizip.lib from the source for distribution should be trivial; just create a library-project with all files in the minizip directory excluding minizip.c and miniunz.c and link to zlib.

I have only tested this on windows, as that is the only development platform I am currently familiar with, but minizip includes file-io routines for both win32 and linux (and so I presume will run on mac).

It should be noted that I inherited CEGUI::MinizipResourceProvider from CEGUI::DefaultResourceProvider since the MRP is ment as a drop-in replacement for the DRP, with the added capability to load resources from an archive. An issue with this is that the DRP does not have a virtual destructor, so the DRP needs to be updated or the user should know not to delete an MRP casted to a DRP.
TagsNo tags attached.
Attached Fileszip file icon CEGUIMinizipResourceProvider.zip [^] (3,378 bytes) 2010-03-19 19:32

- Relationships

-  Notes
Jamarr (reporter)
2010-03-19 19:36

I forgot to add the CEGUIEXPORT macro on the class definition. I was not building this into the cegui library, so the macro was not needed at the time. If the class is included within the cegui library, the macro should be added.
CrazyEddie (administrator)
2010-03-24 14:36

I am working on this at the moment, so thought I would update on my progress.

I see this going into branches/v0-7 with some minor mods and 1 enhancement.

Aside from a minor style changes, I will be incorporating a copy of parts of the minizip code into the CEGUI tree to save adding a new external dependency.

I made small changes to remove the unzip.h dependency from the public header.

The enhancement is for a 0.7.x only thing for pattern matched file loading (where you can basically load all fonts by saying "*.font").

Should be done and committed in a couple of days :)
CrazyEddie (administrator)
2010-03-26 14:12

This is now in branches/v0-7 as of r2491.

Thanks again :)

- Issue History
Date Modified Username Field Change
2010-03-19 19:32 Jamarr New Issue
2010-03-19 19:32 Jamarr File Added: CEGUIMinizipResourceProvider.zip
2010-03-19 19:36 Jamarr Note Added: 0000436
2010-03-20 08:14 CrazyEddie Status new => assigned
2010-03-20 08:14 CrazyEddie Assigned To => CrazyEddie
2010-03-24 14:36 CrazyEddie Note Added: 0000437
2010-03-26 14:12 CrazyEddie Note Added: 0000440
2010-03-26 14:12 CrazyEddie Status assigned => resolved
2010-03-26 14:12 CrazyEddie Fixed in Version 0.8.3 => Mercurial: default branch
2010-03-26 14:12 CrazyEddie Resolution open => fixed
Get Crazy Eddies GUI System at SourceForge.net. Fast, secure and Free Open Source software downloads

Copyright © 2000 - 2012 MantisBT Group
Powered by Mantis Bugtracker