AnimationDrawable can't load too many images
<p>main java</p>

<pre><code>import android.app.Activity;
import android.graphics.drawable.AnimationDrawable;
import android.os.Bundle;
import android.widget.ImageView;



public class AndroidAnimation extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState){
    super.onCreate(savedInstanceState);
    setContentView(R.layout.animation1);

    ImageView myAnimation = (ImageView)findViewById(R.id.myanimation1);
    final AnimationDrawable myAnimationDrawable
        = (AnimationDrawable)myAnimation.getDrawable();

    myAnimation.post(
            new Runnable(){

                public void run() {
                    myAnimationDrawable.start();
                }
            });
}
}
</code></pre>

<p>xml files</p>

<pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;animation-list xmlns:android="http://schemas.android.com/apk/res/android"
android:oneshot="false"
&gt;
&lt;item
    android:drawable="@drawable/default_01_0001"
    android:duration="80"/&gt;
&lt;item
    android:drawable="@drawable/default_01_0002"
    android:duration="80"/&gt;
 &lt;item
    android:drawable="@drawable/default_01_0003"
    android:duration="80"/&gt;
  &lt;item
    android:drawable="@drawable/default_01_0004"
    android:duration="80"/&gt;
   &lt;item
    android:drawable="@drawable/default_01_0005"
    android:duration="80"/&gt;
    &lt;item
    android:drawable="@drawable/default_01_0006"
    android:duration="80"/&gt;
     &lt;item
    android:drawable="@drawable/default_01_0007"
    android:duration="80"/&gt;
      &lt;item
    android:drawable="@drawable/default_01_0008"
    android:duration="80"/&gt;
       &lt;item
    android:drawable="@drawable/default_01_0009"
    android:duration="80"/&gt;
        &lt;item
    android:drawable="@drawable/default_01_0010"
    android:duration="80"/&gt;
         &lt;item
    android:drawable="@drawable/default_01_0011"
    android:duration="80"/&gt;
          &lt;item
    android:drawable="@drawable/default_01_0012"
    android:duration="80"/&gt;
           &lt;item
    android:drawable="@drawable/default_01_0013"
    android:duration="80"/&gt;
            &lt;item
    android:drawable="@drawable/default_01_0014"
    android:duration="80"/&gt;
             &lt;item
    android:drawable="@drawable/default_01_0015"
    android:duration="80"/&gt;
              &lt;item
    android:drawable="@drawable/default_01_0016"
    android:duration="80"/&gt;
               &lt;item
    android:drawable="@drawable/default_01_0017"
    android:duration="80"/&gt;
                &lt;item
    android:drawable="@drawable/default_01_0018"
    android:duration="80"/&gt;
                 &lt;item
    android:drawable="@drawable/default_01_0019"
    android:duration="80"/&gt;
                  &lt;item
    android:drawable="@drawable/default_01_0020"
    android:duration="80"/&gt;
                   &lt;item
    android:drawable="@drawable/default_01_0021"
    android:duration="80"/&gt;
                    &lt;item
    android:drawable="@drawable/default_01_0022"
    android:duration="80"/&gt;
                     &lt;item
    android:drawable="@drawable/default_01_0023"
    android:duration="80"/&gt;
                      &lt;item
    android:drawable="@drawable/default_01_0024"
    android:duration="80"/&gt;
                       &lt;item
    android:drawable="@drawable/default_01_0025"
    android:duration="80"/&gt;
       &lt;item
    android:drawable="@drawable/default_03_0001"
    android:duration="80"/&gt;
&lt;item
    android:drawable="@drawable/default_03_0002"
    android:duration="80"/&gt;
 &lt;item
    android:drawable="@drawable/default_03_0003"
    android:duration="80"/&gt;
  &lt;item
    android:drawable="@drawable/default_03_0004"
    android:duration="80"/&gt;
   &lt;item
    android:drawable="@drawable/default_03_0005"
    android:duration="80"/&gt;
    &lt;item
    android:drawable="@drawable/default_03_0006"
    android:duration="80"/&gt;
     &lt;item
    android:drawable="@drawable/default_03_0007"
    android:duration="80"/&gt;
      &lt;item
    android:drawable="@drawable/default_03_0008"
    android:duration="80"/&gt;
       &lt;item
    android:drawable="@drawable/default_03_0009"
    android:duration="80"/&gt;
        &lt;item
    android:drawable="@drawable/default_03_0010"
    android:duration="80"/&gt;
         &lt;item
    android:drawable="@drawable/default_03_0011"
    android:duration="80"/&gt;
          &lt;item
    android:drawable="@drawable/default_03_0012"
    android:duration="80"/&gt;
           &lt;item
    android:drawable="@drawable/default_03_0013"
    android:duration="80"/&gt;
            &lt;item
    android:drawable="@drawable/default_03_0014"
    android:duration="80"/&gt;
             &lt;item
    android:drawable="@drawable/default_03_0015"
    android:duration="80"/&gt;
              &lt;item
    android:drawable="@drawable/default_03_0016"
    android:duration="80"/&gt;
               &lt;item
    android:drawable="@drawable/default_03_0017"
    android:duration="80"/&gt;
                &lt;item
    android:drawable="@drawable/default_03_0018"
    android:duration="80"/&gt;
                 &lt;item
    android:drawable="@drawable/default_03_0019"
    android:duration="80"/&gt;
                  &lt;item
    android:drawable="@drawable/default_03_0020"
    android:duration="80"/&gt;
                   &lt;item
    android:drawable="@drawable/default_03_0021"
    android:duration="80"/&gt;
                    &lt;item
    android:drawable="@drawable/default_03_0022"
    android:duration="80"/&gt;
                     &lt;item
    android:drawable="@drawable/default_03_0023"
    android:duration="80"/&gt;
                      &lt;item
    android:drawable="@drawable/default_03_0024"
    android:duration="80"/&gt;
                       &lt;item
    android:drawable="@drawable/default_03_0025"
    android:duration="80"/&gt;
                           &lt;item
    android:drawable="@drawable/default_03_0026"
    android:duration="80"/&gt;
&lt;item
    android:drawable="@drawable/default_03_0027"
    android:duration="80"/&gt;
 &lt;item
    android:drawable="@drawable/default_03_0028"
    android:duration="80"/&gt;
  &lt;item
    android:drawable="@drawable/default_03_0029"
    android:duration="80"/&gt;

   &lt;item
    android:drawable="@drawable/default_03_0030"
    android:duration="80"/&gt;
    &lt;item
    android:drawable="@drawable/default_03_0031"
    android:duration="80"/&gt;
     &lt;item
    android:drawable="@drawable/default_03_0032"
    android:duration="80"/&gt;
      &lt;item
    android:drawable="@drawable/default_03_0033"
    android:duration="80"/&gt;
       &lt;item
    android:drawable="@drawable/default_03_0034"
    android:duration="80"/&gt;
        &lt;item
    android:drawable="@drawable/default_03_0035"
    android:duration="80"/&gt;

         &lt;item
    android:drawable="@drawable/default_03_0036"
    android:duration="80"/&gt;
          &lt;item
    android:drawable="@drawable/default_03_0037"
    android:duration="80"/&gt;
           &lt;item
    android:drawable="@drawable/default_03_0038"
    android:duration="80"/&gt;
            &lt;item
    android:drawable="@drawable/default_03_0039"
    android:duration="80"/&gt;
             &lt;item
    android:drawable="@drawable/default_03_0040"
    android:duration="80"/&gt;
              &lt;item
    android:drawable="@drawable/default_03_0041"
    android:duration="80"/&gt;
               &lt;item
    android:drawable="@drawable/default_03_0042"
    android:duration="80"/&gt;
                &lt;item
    android:drawable="@drawable/default_03_0043"
    android:duration="80"/&gt;
                 &lt;item
    android:drawable="@drawable/default_03_0044"
    android:duration="80"/&gt;
                  &lt;item
    android:drawable="@drawable/default_03_0045"
    android:duration="80"/&gt;
         &lt;item
    android:drawable="@drawable/default_02_0001"
    android:duration="80"/&gt;
&lt;item
    android:drawable="@drawable/default_02_0002"
    android:duration="80"/&gt;
 &lt;item
    android:drawable="@drawable/default_02_0003"
    android:duration="80"/&gt;
  &lt;item
    android:drawable="@drawable/default_02_0004"
    android:duration="80"/&gt;
   &lt;item
    android:drawable="@drawable/default_02_0005"
    android:duration="80"/&gt;
    &lt;item
    android:drawable="@drawable/default_02_0006"
    android:duration="80"/&gt;
     &lt;item
    android:drawable="@drawable/default_02_0007"
    android:duration="80"/&gt;
      &lt;item
    android:drawable="@drawable/default_02_0008"
    android:duration="80"/&gt;
       &lt;item
    android:drawable="@drawable/default_02_0009"
    android:duration="80"/&gt;
        &lt;item
    android:drawable="@drawable/default_02_0010"
    android:duration="80"/&gt;
         &lt;item
    android:drawable="@drawable/default_02_0011"
    android:duration="80"/&gt;
          &lt;item
    android:drawable="@drawable/default_02_0012"
    android:duration="80"/&gt;
           &lt;item
    android:drawable="@drawable/default_02_0013"
    android:duration="80"/&gt;
            &lt;item
    android:drawable="@drawable/default_02_0014"
    android:duration="80"/&gt;
             &lt;item
    android:drawable="@drawable/default_02_0015"
    android:duration="80"/&gt;
              &lt;item
    android:drawable="@drawable/default_02_0016"
    android:duration="80"/&gt;
               &lt;item
    android:drawable="@drawable/default_02_0017"
    android:duration="80"/&gt;
                &lt;item
    android:drawable="@drawable/default_02_0018"
    android:duration="80"/&gt;
                 &lt;item
    android:drawable="@drawable/default_02_0019"
    android:duration="80"/&gt;
                  &lt;item
    android:drawable="@drawable/default_02_0020"
    android:duration="80"/&gt;
                   &lt;item
    android:drawable="@drawable/default_02_0021"
    android:duration="80"/&gt;
                    &lt;item
    android:drawable="@drawable/default_02_0022"
    android:duration="80"/&gt;
                     &lt;item
    android:drawable="@drawable/default_02_0023"
    android:duration="80"/&gt;
                      &lt;item
    android:drawable="@drawable/default_02_0024"
    android:duration="80"/&gt;
                       &lt;item
    android:drawable="@drawable/default_02_0025"
    android:duration="80"/&gt;
                           &lt;item
    android:drawable="@drawable/default_02_0026"
    android:duration="80"/&gt;
&lt;item
    android:drawable="@drawable/default_02_0027"
    android:duration="80"/&gt;
 &lt;item
    android:drawable="@drawable/default_02_0028"
    android:duration="80"/&gt;
  &lt;item
    android:drawable="@drawable/default_02_0029"
    android:duration="80"/&gt;
   &lt;item
    android:drawable="@drawable/default_02_0030"
    android:duration="80"/&gt;
    &lt;item
    android:drawable="@drawable/default_02_0031"
    android:duration="80"/&gt;
     &lt;item
    android:drawable="@drawable/default_02_0032"
    android:duration="80"/&gt;
      &lt;item
    android:drawable="@drawable/default_02_0033"
    android:duration="80"/&gt;
       &lt;item
    android:drawable="@drawable/default_02_0034"
    android:duration="80"/&gt;
        &lt;item
    android:drawable="@drawable/default_02_0035"
    android:duration="80"/&gt;
         &lt;item
    android:drawable="@drawable/default_02_0036"
    android:duration="80"/&gt;
          &lt;item
    android:drawable="@drawable/default_02_0037"
    android:duration="80"/&gt;
           &lt;item
    android:drawable="@drawable/default_02_0038"
    android:duration="80"/&gt;
            &lt;item
    android:drawable="@drawable/default_02_0039"
    android:duration="80"/&gt;
             &lt;item
    android:drawable="@drawable/default_02_0040"
    android:duration="80"/&gt;
              &lt;item
    android:drawable="@drawable/default_02_0041"
    android:duration="80"/&gt;
               &lt;item
    android:drawable="@drawable/default_02_0042"
    android:duration="80"/&gt;
                &lt;item
    android:drawable="@drawable/default_02_0043"
    android:duration="80"/&gt;
                 &lt;item
    android:drawable="@drawable/default_02_0044"
    android:duration="80"/&gt;
                  &lt;item
    android:drawable="@drawable/default_02_0045"
    android:duration="80"/&gt;

&lt;/animation-list&gt;
</code></pre>

<p>i have making a frame by frame animation using AnimationDrawable. 
when the images is below 20pic the apps is working fine but after i add more images in the apps with get crash .</p>

<p>any can share some tutorial how to make a animation can load more images ?
i have buy 2 books also using a same way to create frame by frame animation. any good book suggest? </p>

<p>thx</p>
