楊健 wrote: > 07-01 11:32:02.192: VERBOSE/QualcommCameraHardware(35): state > transition QCS_WAITING_JPEG --> QCS_IDLE > 07-01 11:32:02.232: ERROR/dalvikvm-heap(395): 6291456-byte external > allocation too large for this process. > 07-01 11:32:02.232: ERROR/(395): VM won't let us allocate 6291456 > bytes > 07-01 11:32:02.242: DEBUG/AndroidRuntime(395): Shutting down VM > 07-01 11:32:02.242: WARN/dalvikvm(395): threadid=3: thread exiting > with uncaught exception (group=0x4000fe70) > 07-01 11:32:02.242: ERROR/AndroidRuntime(395): Uncaught handler: > thread main exiting due to uncaught exception > 07-01 11:32:02.302: ERROR/AndroidRuntime(395): > java.lang.OutOfMemoryError: bitmap size exceeds VM budget > > My app shut down when i load a jpg file,i can avoid it by call > system.gc().But I think memory limit will be 14M or 16M.
The available heap is 16MB. That does not necessarily mean that there is a contiguous 6MB buffer that you can allocate, depending on what else your application is doing. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android App Developer Books: http://commonsware.com/books.html --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---