title: refresh a bitmap or canvas in android
body: <blockquote>
    <p>can anybody tell me how to refresh or
    reset a bitmap or canvas to draw
    another image on it?</p>
  </blockquote>
  
  <p>actually i have a map binary file which contains bitmap tiles in bytes now problem is i have a buffer image with buffer image i get screen image to display. so when i move my screen image i need to refresh my buffer image and draw new tiles to display on screen.</p>
  
  <p>here is code to display image.</p>
  
  <pre><code>bitmap = Bitmap.createBitmap(screenWidth * (int)mapState.getiBufferMult(), screenHeight * (int)mapState.getiBufferMult(), Config.RGB_565);
          canvas = new Canvas(bitmap);
          image = new ImageView(this);
  </code></pre>
  
  <p>this is not full source but i hope you guys can have idea. </p>
  
  <p>thanks a lot</p>