title: Android Imageview with AnimationDrawable source changes size
body: <ol>
  <li><p>I have made a set of 3 images that will represent the move of a animal. Each image represents a frame and consists only in the animal with transparent background.</p></li>
  <li><p>I have made a AnimationDrawable in code and created the animation:</p>
  
  <pre>AnimationDrawable staticAnimation = new AnimationDrawable();
  staticAnimation.addFrame(ctx.getResources().getDrawable("frame1"),150);
  staticAnimation.addFrame(ctx.getResources().getDrawable("frame2"),150);
  staticAnimation.addFrame(ctx.getResources().getDrawable("frame3"),150);</pre></li>
  <li><p>I set the animation as a background for a Imageview and start it</p>
  
  <pre>imgAnimal.setBackgroundDrawable(staticAnimation );
  staticAnimation.start()</pre></li>
  </ol>
  
  <p>Because the frames have different width (the drawing needs to recreate steps move) looks like the Imageview resizes the images in the animation. Better to say, if frame1 is bigger then frame2, frame 1 is displayed ok but frame 2 is stretched to be as big as frame1 was. Looks really awful. </p>
  
  <p>Any suggestions on how to stop this behavior ? Thank you.</p>