Hi Everyone! I'm developing a game for S_40 , and I run into the problem with memory ,
I have 20Kb of graphics , and 37Kb total .jar file size , my code spawned just a few objects ( not so-o big - I hope ) ,yet I got "Out of memory" message from Nokia_7210 Emulator ,Please consult me , what options do I have to free the memory effectively ?
be aware of the fact that the heap memory required by images does not anything related to its size in jar. eg. a 128x128's image would occupy (128x128x2+6x) bytes of heap memory but it may only be 3k in a jar file.
Therefore, be sure there's not too many images are loaded at the same time...s40 normally have about 2xxKB heap memory(always assume 200KB heap memory would make your games runnable on most s40 mobiles).