java.lang.OutOfMemoryError

tip

Try adding these lines to your manifest: "android:hardwareAccelerated="false"" and "android:largeHeap="true"" as it seems to work for some cases. See also this article about handling bitmaps on android's documentation: https://goo.gl/8LVrzp

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • OutOfMemoryError when loading an image
    via Stack Overflow by AMb
    ,
  • java.lang.OutOfMemoryError
    via GitHub by wussup
    ,
  • OutOfMemoryError
    via GitHub by chathudan
    ,
  • Out of memory while creating bitmap in android
    via by Unknown author,
  • Out of memory
    via GitHub by androidbyxj
    ,
  • OutOfMemoryError
    via GitHub by kamoljan
    ,
  • OOM in ImageCleanupTask
    via GitHub by Tan-Tshunglee
    ,
    • java.lang.OutOfMemoryError at android.graphics.Bitmap.nativeCreate(Native Method) at android.graphics.Bitmap.createBitmap(Bitmap.java:928) at android.graphics.Bitmap.createBitmap(Bitmap.java:901) at android.graphics.Bitmap.createBitmap(Bitmap.java:868) at processing.core.PGraphicsAndroid2D.allocate(Unknown Source) at processing.core.PGraphics.setSize(Unknown Source) at processing.core.PApplet.makeGraphics(Unknown Source) at processing.core.PApplet.initSurface(Unknown Source) at processing.android.PFragment.onCreateView(Unknown Source) at android.support.v4.app.Fragment.performCreateView(Fragment.java:1974) at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1067) at android.support.v4.app.FragmentManagerImpl.attachFragment(FragmentManager.java:1430) at android.support.v4.app.BackStackRecord.run(BackStackRecord.java:732) at android.support.v4.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1617) at android.support.v4.app.FragmentManagerImpl.executePendingTransactions(FragmentManager.java:570) at android.support.v4.app.FragmentPagerAdapter.finishUpdate(FragmentPagerAdapter.java:141) at android.support.v4.view.ViewPager.populate(ViewPager.java:1177) at android.support.v4.view.ViewPager.setCurrentItemInternal(ViewPager.java:608) at android.support.v4.view.ViewPager.setCurrentItemInternal(ViewPager.java:570) at android.support.v4.view.ViewPager.setCurrentItem(ViewPager.java:551) at imc_ebola.test.imcebola.MainActivity$1.onTabSelected(MainActivity.java:91) at android.support.design.widget.TabLayout.selectTab(TabLayout.java:1025) at android.support.design.widget.TabLayout.selectTab(TabLayout.java:995) at android.support.design.widget.TabLayout$Tab.select(TabLayout.java:1272) at android.support.design.widget.TabLayout$TabView.performClick(TabLayout.java:1377) at android.view.View$PerformClick.run(View.java:19270) at android.os.Handler.handleCallback(Handler.java:733) at android.os.Handler.dispatchMessage(Handler.java:95) at android.os.Looper.loop(Looper.java:146) at android.app.ActivityThread.main(ActivityThread.java:5602) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:515) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1099) at dalvik.system.NativeStart.main(Native Method)

    Users with the same issue

    aakash
    aakash1 times, last one,
    Agócs Tamás
    Agócs Tamás3 times, last one,
    bayukresno
    bayukresno7 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    11 more bugmates