I’m developing an android app that has a lot of bitmaps that uses a lot of RAM. My question is that when I keep my app running for a long time and the ram usage exceeds 64 MB, the app crashes with an “OUT OF MEMORY ERROR, VM won’t let us allocate … etc”.
While other apps such as facebook reaches 200 MB ram sometimes without any crashes and with a very fast performance. My device is Galaxy S II.
and please notice that my question is not about reducing the memory usage, it’s about the difference in memory limit between my app and other apps.
Thanks.
I think there is a limit on the amount of memory that an application can use… Used to be 32MB… There might be a permission that you can change to request more memory, in the same way that you can request hardware acceleration. From a quick google android:largeHeap=”true” might be your answer… Also Runtime.getRuntime().maxMemory(); might help? This link was also interesting…