title: java.lang.OutOfMemoryError: bitmap size exceeds VM budget - android - how many images?
body: <p>I am developing an android app and as I read all around and learned for myself, I cant have a lot of images on the screen at the same time or I will get an exception.</p>
  
  <p>The question is how many images or how many KB in images or how many layouts/images can I have at the same time in the screen.</p>
  
  <p>I know this is not the only thing that has influence on memory, but I am looking for a number so I can plan around it. </p>
  
  <p>Thanks</p>
  
  <p>Daniel</p>
  
  <hr>
  
  <p>Edit:</p>
  
  <p>I just found this on the android dev site (<a href="http://developer.android.com/resources/articles/future-proofing.html" rel="nofollow noreferrer">http://developer.android.com/resources/articles/future-proofing.html</a>)</p>
  
  <p>Technique to Avoid, #3: Going Overboard with Layouts</p>
  
  <p>Due to changes in the View rendering infrastructure, unreasonably deep (more than 10 or so) or broad (more than 30 total) View hierarchies in layouts are now likely to cause crashes. This was always a risk for excessively complex layouts, but you can think of Android 1.5 as being better than 1.1 at exposing this problem. Most developers won't need to worry about this, but if your app has very complicated layouts, you'll need to put it on a diet. You can simplify your layouts using the more advanced layout classes like FrameLayout and TableLayout.</p>
  
  <p>I guess this can be my problem.</p>
  
  <p>When it says 'broad' , is it saying on the last level ?</p>
  
  <p>Thanks</p>
  
  <p>Daniel</p>