title: How to draw lines on the bitmap used in ImageViewZoom?
body: <p>I recently started using ImageViewZoom 
  (<a href="https://github.com/sephiroth74/ImageViewZoom" rel="nofollow">https://github.com/sephiroth74/ImageViewZoom</a>)
  and what I'm going to do is to draw some lines on the bitmap used in this View from time to time. </p>
  
  <p>I tried to do it in the following way, but the result is that the View is no longer able to zoom.</p>
  
  <pre><code>protected void onDraw(Canvas canvas) 
  {   
      // TODO Auto-generated method stub
      super.onDraw(canvas);
  
      Canvas bmp_canvas = new Canvas(bmp);//bmp is the original bitmap
  
      Paint paint = new Paint();
  
      //Draw map
      paint. setColor(Color.BLUE);
      paint. setStrokeWidth(10);
      int i;
      for(i=0; i&lt;toDraw.size();i++)
      {
          Segment now = toDraw.get(i); //toDraw is a List and stores the lines
  
          PointType tmp_start = now.s;
          PointType tmp_end = now.e;
  
          bmp_canvas.drawLine((float)tmp_start.x, (float)tmp_start.y, 
                  (float)tmp_end.x, (float)tmp_end.y, paint);
      }
  
      Matrix matrix = getImageViewMatrix();
      setImageBitmap(bmp, matrix, ZOOM_INVALID, ZOOM_INVALID);        
      return;
  }
  </code></pre>
  
  <p>So what is the correct way to do it? Thank you very much!</p>