PVR inside zip?

PVR inside zip?
0.0 0


Is it possible to load a PVR file from a zip file? I need good quality PVR for my 2D game (PNG often crashed the game due to huge memory size) so I tried RGBA4444 and it looks great with no crash (BPP4 is not suitable for my game graphic) but each of the PVR file is around 2MB.

I somehow found out that if I zip the PVR file it became only 150kb which is very good but I don’t know how to convert the file data I obtained from the zip file into a valid CCTexture2D format. Any tips on that?

I previously tried

CCTexture2D* tex_idle0 = new CCTexture2D();
tex_idle0->initWithData((const char**), “character_idle0.pvr”)), kCCTexture2DPixelFormat_RGBA4444, 1024, 1024, CCSize);
and openZip looks like this
unsigned char** openZip(const char* zip, const char* file)
unsigned long fileSize = 0;
unsigned char* result = cocos2d::CCFileUtils::getFileDataFromZip(zip, file, &fileSize);
if (fileSize > 0)
return result;
std::cout << “Oh no~~” << std::endl;
return (unsigned char*)“”;

but my sprite seems to look very lossy and slightly offset to the side (looks ok if I just directly load the PVR file from directory and not zip). any other solution for this?
Sorry for my english.


Putting PVR in a ZIP file reduces your app size -but changes nothing how much texture space the PVR needs. Maybe you can just use PVRC for your project.
Check tools like TexturePacker.app to reduce your PNG or PVR image