I’ve come across a problem with PVR and PVR.CCZ textures not reloading when the gl context is lost, however PNG textures reload fine. Please tell me if I’m doing something wrong. I have developed the following simple repro case to help illustrate the problem.
- Add the following code to the end of the HelloWorld::init() function:
CCSpriteFrameCache **frameCache = CCSpriteFrameCache::sharedSpriteFrameCache;
CCSprite* pngTestSprite = CCSprite::spriteWithSpriteFrame);
- Add the attached image and plist assets to the HelloWorld/Resource folder.
- Execute the program on android hardware. The normal HelloWorld background will be displayed and a reddish icon will show in the middle.
- Press HOME on the android device.
- Navigate back to the HelloWorld app by long-pressing the HOME button and selecting the app. When loading pngtest.plist the reddish icon is displayed as normal.
- Repeat the test by using either “pvrccztest.plist” or “pvrtest.plist”. If either the pvrccztest.plist or pvrtest.plist is loaded,**the reddish icon will be a white square* when returning from the background.
I also attached some images to further illustrate the problem.
I’m using Android 2.2.1 SDK API level 8.
imageAssets.zip (7.9 KB)
pvrStartUp.png (66.5 KB)
pvrReturnFromBackground.png (62.6 KB)