Titanium Community Questions & Answer Archive

We felt that 6+ years of knowledge should not die so this is the Titanium Community Questions & Answer Archive

Unable to load bitmap. Not enough memory: bitmap size exceeds VM budget

Hey guys,

after using my Application for about 2 min's, images start disappearing, and eventually the Application crashes.

through the Titanium log, i am getting this error.

[TRACE] E/TitaniumUIHelper( 221): (main) [692,26213] Unable to load bitmap. Not enough memory: bitmap size exceeds VM budget.

Anyone know how I can combat this error?

— asked July 6th 2010 by Thomas Shurrock
  • android
  • crash
  • memory
0 Comments

8 Answers

  • Accepted Answer

    you can find tutorials for compiling the code yourself here at the bottom of the page:

    http://developer.appcelerator.com/doc/mobile/guides

    — answered July 6th 2010 by Christian Sigl
    permalink
    0 Comments
  • after 2 years, titanium sdk 3.1.2 same problem, somebody, fix it, please !

    — answered September 30th 2013 by andrei perv
    permalink
    0 Comments
  • This is due to memory issue with emulator. The simplest solution is to add below lines in tiapp.xml file

        <property name="ti.android.threadstacksize" type="int">131072</property>
    <property name="ti.android.httpclient.maxbuffersize" type="int">131072</property>
    
    — answered January 9th 2013 by zeeshan pervez
    permalink
    0 Comments
  • have same problem titaniun sdk 3.1.2

    — answered September 30th 2013 by andrei perv
    permalink
    0 Comments
  • I have the same problem on mac os x snow leopard. I really need an answer on this please !

    — answered September 16th 2011 by Miguel Unamuno
    permalink
    1 Comment
    • Hi Miguel,

      Did you ever find a fix or solution for this problem? I am getting the same error too.

      If you did fix it, can you please let me know? It will be a big help!

      I am using Titanium 1.7.3 and Android 2.2

      Thanks,
      Sri

      — commented October 28th 2011 by Sridevi Kolluri
  • Using DDMS i found that Memory allocated to application is get increases as i am navigating screen by screen and after some time it crash application with force close message/Fail to load resources. Even i have remove all objects from window and after that assign null to it. i.e
    window.remove(viewname);
    viewname=null;
    window.close();
    window=null.
    Please help Me OUT.

    — answered February 16th 2012 by Fernan Delgado
    permalink
    0 Comments
  • Using DDMS i found that Memory allocated to application is get increases as i am navigating screen by screen and after some time it crash application with force close message/Fail to load resources. Even i have remove all objects from window and after that assign null to it. i.e window.remove(viewname); viewname=null; window.close(); window=null. Please help Me OUT.

    — answered February 21st 2012 by Fernan Delgado
    permalink
    0 Comments
  • this is a known bug in 1.3.2, precisely it's a memory leak coming from imageviews. wait for the next offical release or compile head from github, and the bug should no longer appear

    — answered July 6th 2010 by Christian Sigl
    permalink
    8 Comments
    • How do I go about compiling the head from github?

      -Thanks again!

      — commented July 6th 2010 by Thomas Shurrock
    • I'm still having an issue with this on TiStudio w/SDK 1.7.2
      any ideas ?

      — commented July 30th 2011 by Brian Burgess
    • Same problem like Brian, but using Titanium SDK 1.7.1. Any solutions please?

      — commented August 1st 2011 by Kathrin Holweger
    • I am getting the same issue setting background images on buttons as it loops over 10 buttons… any ideas for fixes? Using 1.7.2

      — commented August 1st 2011 by Hart Woolery
    • Same problem here. Loading a 43K image leads to the same out of memory error on 1.7.2 with Android on Mac (OS X Lion).

      Oddly enough, the exact same code does NOT cause an error on 1.7.2 with Android on Windows 7.

      — commented August 5th 2011 by Akil Franklin
    • I'm getting this too with 1.7.2 (was fine a few weeks ago)

      — commented August 26th 2011 by Caspar Addyman
    • Getting same error on 1.7.3 using the Tweetanium app.

      — commented October 26th 2011 by Justin Toth
    • I am getting the same error using 2.1.1 . Any idea if there is a workaround.

      — commented August 9th 2012 by Vinayakam Murugan
The ownership of individual contributions to this community generated content is retained by the authors of their contributions.
All trademarks remain the property of the respective owner.