LowMemory log written - memory issues

Monkey Targets Forums/iOS/LowMemory log written - memory issues

frank(Posted 2013) [#1]
I have been making a simple app with a few (6) images. Those images were quite big (storage wise) at first but now they are very small (< 100kb) ; around 500 kb images and font. The images are large resolution 1536x2048 (ipad 3) and i'm using Diddy virtual resolution to fit them on lower iPads.

Everything works fine on iPhone 4(s), 5 and iPad 2,3,mini. However on iPad 1 and iPhone 3g the app conks out after loading the images. I see the splash screen during which all assets are loaded (the 6 images and some setup code). I removed all setup code and ONLY loading that 500 kb is enough to kill the app after the splash.

When I load about half of the images, the app works (but ofcourse then it misses a lot).

What could be the issue? I cannot imagine a mere 500 kb of images can be the issue...


Grey Alien(Posted 2013) [#2]
It's the size of the uncompressed image in memory that is the problem. Let's see a 1536x2048 image at 4 byes per pixel is 12.5Mb each. 6 of those is 75MB for images alone let alone any code or music/sounds etc. I know from experience that once you start to hit 90Mb of memory use on 3GS and iPad1 then the app may well bomb out as those device only have 256Mb of RAM and you don't get to use much of it at all. Also iPhone 3G only has 128Mb so you should probably not even bother supporting it. Use Instruments on your Mac to check the memory use of the app, you may be surprised...


frank(Posted 2013) [#3]
Ah. That makes sense ... Ok, back to the drawing board! Thank you!