iDevGames Forums
Guideline for Memory Usage - Printable Version

+- iDevGames Forums (
+-- Forum: Development Zone (/forum-3.html)
+--- Forum: iPhone, iPad & iPod Game Development (/forum-11.html)
+--- Thread: Guideline for Memory Usage (/thread-1999.html)

Guideline for Memory Usage - aarku - Dec 23, 2008 02:54 PM

Is there a rough guideline for app memory usage? I haven't found one. Would 30 megabytes be too high? How about 35?


Guideline for Memory Usage - kodex - Dec 23, 2008 02:57 PM

It is all over the place, I find that touches have more memory available then iPhones in general. I have had memory warnings with as little as 12 MBs used however. Just keep an eye on didReceiveMemoryWarning and try to keep things as slim as possible =)

Guideline for Memory Usage - AnotherJake - Dec 23, 2008 05:49 PM

Yeah, the lowest I've heard is kodex's 12 MB. Apple reps I've seen on other forums seem to recommend 20 or less. 30 seems to be universally regarded as too high. I am targeting 10-15 (...maybe up to 20) if possible. That's minimum, but I'll go over that temporarily if I can get away with it for a separate web view or something. My attitude is that if it can't support 10-15 MB, then forget it, I ain't gonna try to program any game for it.

Guideline for Memory Usage - aarku - Dec 24, 2008 07:39 AM

Thanks for the info. I've now also heard that the evangelists were saying 25 megabytes at the iPhone developer talks. So it is indeed all over.

Currently with Unity bringing up a spinning cube with a 512 square pvrtc 4 bpp texture uses like 19 megabytes. Ouch. Hope they can improve that. Sad


Guideline for Memory Usage - AnotherJake - Dec 24, 2008 08:04 AM

The 25 MB figure might be coming from what is max recommended for OpenGL ES, which is 24 MB for textures and rendering surfaces combined, but yeah, that could be general app recommendation, who knows for sure... The 24 MB recommendation for the GL threw me off at first, thinking I could maybe go into the thirties for the whole app myself. It wasn't until Zwilnik and kodex brought it up much later that I started paying attention.

A 512 x 512 pvrtc texture at 4 bits is probably 128 KB I think (whatever the file size is on disk should be same in memory), so they're probably going to need to slim some other stuff down! I don't know how much of the desktop Unity they're trying to get over (as much as possible seems logical), but I'd be willing to guess the big bugger is Mono if that's in there.

Guideline for Memory Usage - jaguard - Dec 25, 2008 01:53 PM

In Orions: Legend of Wizards, I'm consuming around 35 Mb. This turns out is a bit too much, since some (very few, maybe 1 of 100, but they spoil rating a lot) users somehow experience crashes. It was hard for me to squeeze stuff more, so I decided to leave it at 35. Bad idea, it's too much, so I'm gonna reduce this to 30 with the next update. There's no way I can go with 25 or 20, though.

Guideline for Memory Usage - funkboy - Dec 25, 2008 02:23 PM

Jaguard, what is causing the most memory usage do you think?

I think 20MB is a good guideline - I have seen memory warnings at that level often.

Guideline for Memory Usage - jaguard - Dec 27, 2008 07:19 AM

funkboy Wrote:Jaguard, what is causing the most memory usage do you think?

For me, it's obviously the textures. If I load all of them at once, I'd be well over 50-60 Mb. I wish iphone resolution was 512x256, this would save a nice little extra Smile.