Ok......
I'm implementing a simple OpenGL ES application on the iPhone and I recently added in Pinch Media Analytics. Doing this helped uncover a memory management problem, and I'm not entirely sure how to deal with it.
In a perfect world, my application - which loads PNGs and .CAF files in didFinishLoading will launch, load all of it's resources, and run just fine.
HOWEVER, if my program gets a crash (which happened as I was integrating the Pinch Media libraries) or if I run Safari and open a bunch of pages and then launch my game, the game will crash back to the menu because it is out of memory.
This problem will persist until I do a hard reset of the system.
The default answer that you sort of get online is to implement the didReceiveMemoryWarning method as listed below....
- (void)didReceiveMemoryWarning
{
// default behavior is to release the view if it doesn't have a superview.
// remember to clean up anything outside of this view's scope, such as
// data cached in the class instance and other global data.
[super didReceiveMemoryWarning];
}
But this doesn't really help as it's the other programs that are holding onto memory not mine. I don't want to release my own view do I? Is there a good description of how to handle this situation and / or what happens in the didReceiveMemoryWarning event?