title: Drawing subset of a bitmap to a canvas?
body: <p>I'm writing my first app of any consequence, so I may be going about this the entire wrong way, but...</p>
  
  <p>I have a resource image that is 1600x880.  I'd like to fill the entire screen with a subset of that image to my canvas, such that an arbitrary x,y coordinate marks the top-left corner drawn at the top-left corner of the screen.  For instance, if I was viewing this image on an N1 and I entered x=100 and y=50, I'd expect to see from 100,50 to 580,850 since it's display area is 480x800.</p>
  
  <p>I think I need to use <code>Canvas.drawBitmap(Bitmap bitmap, Rect src, Rect dst, Paint paint)</code>.  But, no matter what I plug in to either Rect (even if it's a perfectly sane set of values that shouldn't butt up against any edges of the image), I end up with an unexpected area or a grossly stretched/smooshed output.</p>
  
  <p>I've tried using various combinations of calculations involving <code>display.getWidth()</code> and <code>getHeight()</code>, <code>canvas.getWidth() and getHeight()</code>, and <code>bitmap.getWidth() and getHeight()</code> but nothing seems to be working.</p>
  
  <p>I don't know what I'm doing wrong.</p>