I am new to programming (learned how to write apps a few months ago) and recently wrote an app that crashes every time after about 5 minutes with several ‘Received memory warning. Level=1’ warnings. While testing with instruments, I have been unable to detect any leaks and I’m fairly confident I’m releasing the objects correctly so I suspect the memory problems stem from the large number of png images I use (around 80). I’ve tried changing from the -imageNamed method to -imageWithContentsOfFile and saw no real improvement. If anyone could offer any tips I would really appreciate it since I am completely stuck.
Share
Running out of memory does not necessarily imply memory leaks. It could mean that you’ve asked for too much memory at once. In your case, you’re probably trying to create too many
UIImageobjects that all exist simultaneously. Without seeing a lot more of your code, there’s not much to say except try and find a way to use fewer images at the same time.