Put together tiles in android sdk and use as background
<p>In a feeble attempt to learn some Android development am I stuck at graphics. My aim here is pretty simple:</p>

<ol>
<li>Take n small images and build a random image, larger than the screen with possibility to scroll around.</li>
<li>Have an animated object move around on it</li>
</ol>

<p>I have looked at the SDK examples, Lunar Lander especially but there are a few things I utterly fail to wrap my head around. I've got a birds view plan (which in my head seems reasonably sane):</p>

<p>How do I merge the tiles into one large image? 
The background is static so I figure I should do like this:</p>

<ol>
<li>Make a 2d array with refs to the tiles</li>
<li>Make a large Drawable and draw the tiles on it </li>
<li>At init draw this big image as the background</li>
<li>At each onDraw redraw the background of the previous spot of the moving object, and the moving object at its new location </li>
</ol>

<p>The problem is the hands on things. I load the small images with "Bitmap img1 = BitmapFactory.decodeResource (res, R.drawable.img1)", but then what? Should I make a canvas and draw the images on it with "canvas.drawBitmap (img1, x, y, null);"? If so how to get a Drawable/Bitmap from that?</p>

<p>I'm totally lost here, and would really appreciate some hands on help (I would of course be grateful for general hints as well, but I'm primarily trying to understand the Graphics objects). To make you, dear reader, see my level of confusion will I add my last desperate try:</p>

<pre><code>Drawable drawable;
Canvas canvas = new Canvas ();
Bitmap img1 = BitmapFactory.decodeResource (res, R.drawable.img1); // 50 x 100 px image
Bitmap img2 = BitmapFactory.decodeResource (res, R.drawable.img2); // 50 x 100 px image
canvas.drawBitmap (img1, 0, 0, null);
canvas.drawBitmap (img2, 50, 0, null);

drawable.draw (canvas); // obviously wrong as draw == null
this.setBackground (drawable); 
</code></pre>

<p>Thanks in advance</p>
