title: Drawing UIImage into CurrentContext
body: <p>In my application I've used a <code>UIImagePickerController</code> to take a photo, and after I took the photo, I can't draw it using <code>UIImageView</code> because I want to draw some lines on it with my finger.</p>
  
  <p>To this end I have written in draw rect methods this code:</p>
  
  <pre><code>- (void)drawRect:(CGRect)rect { 
      [self.myimage drawInRect: rect];
  
      //Disegno rettangolo del tag
      CGContextRef myContext = UIGraphicsGetCurrentContext();
  
      CGContextSetRGBStrokeColor(myContext, 0.5, 0.5, 0.5, 1.0);
  
      CGContextSetLineWidth(myContext, 3.0f);
  
      CGContextAddPath(myContext, pathTouches);
  
      CGContextStrokePath(myContext);
  
  }
  </code></pre>
  
  <p>and in touchesMoved:</p>
  
  <pre><code>- (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event {
  
      UITouch *touch = [touches anyObject];
      CGPoint locationInView = [touch locationInView:self];
  
      // Draw a connected sequence of line segments
      CGPoint addLines[] =
      {
          //....
              //some lines
      };
  
      CGMutablePathRef newPath = CGPathCreateMutable();
      CGPathRelease(pathTouches);
      pathTouches = CGPathCreateMutableCopy(newPath);
      CGPathRelease(newPath);
  
      CGPathAddLines(pathTouches, NULL, addLines, sizeof(addLines)/sizeof(addLines[0]));
  
      [self setNeedsDisplay];
  
  }
  </code></pre>
  
  <p>Is it correct to call <code>[self setNeedsDisplay];</code> every time I move my finger, or there is a better way to do this?</p>