On Apr 24, 2008, at 6:08 AM, Daniel DeCovnick wrote:

The tips are appreciated. AFAICT, the limit on total resource sizes is within a kB or 2 of 2 or 4 GB, with the limitation that the last resource must start within the first ~16 MB. Given the fact that the files I'm opening are in the 1-300k range, I suspect I have bigger problems than the resource file format if I start to approach that limit.

One thing I can't figure out though... why is the limit 2727? Assuming you have only 1 resource type and no names, you can fit exactly twice that many references in the map. It's not relevant to my problem, but I am curious.


Each resource entry is a 12 byte structure (2 byte ID, 2 byte offset to name, 1 byte flag, 3 byte offset to data, 4 bytes used as handle when loaded into memory). Combined with 2 byte offset limit on the size of the resource entry list, that gives 65535 / 12 = 2727.


Glenn Andreas                      [EMAIL PROTECTED]
 <http://www.gandreas.com/> wicked fun!
Cardographer | the custom playing card designer


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to